---
title: "Update Payment Link"
method: PATCH
path: "/links/{linkId}"
tags: ["Payment Links"]
---

# Update Payment Link

`PATCH /links/{linkId}`

Allows a user to update payment link details<br><br>

## Path parameters

- `linkId` string, required

## Headers

- `Content-Type` string
- `Authorization` string

## Request body

- object
  - `name` string — The title of the payment link
  - `description` string — Payment description. This will appear on the payment checkout page.
  - `capacity` integer — The number of times a payment link can be used. The capacity will be ignored when the subscription params exist.
  - `active` boolean
  - `return_url` string, uri — The URL which the customer will be redirected to after a successful payment.
  - `failure_return_url` string, uri — The URL which the customer will be redirected to after a failure payment.
  - `terms_and_conditions_url` string, uri — The URL to the terms and conditions page, if provided, the customer will be required to accept the terms before proceeding to payment.
  - `processing_fee_percentage` number
  - `amount` number — amount could be 0 with save_card 'required' option for card verification
  - `amount_currency` 'AED' | 'USD' | 'EUR' | 'GBP' | 'SAR'
  - `link_type` 'standalone' | 'modal' | 'inline' — Type of link to be created.
  - `enable_tabby` boolean — Enables the ability for customers to buy now and pay later.
  - `enable_message` boolean — Enables the ability for customers to add a message during the checkout process.
  - `enable_tips` boolean — Enables the tips option. This will be displayed on the first screen.
  - `save_card` 'off' | 'optional' | 'required' — Allows the merchant to enable the option to store card details to be used later on for Merchant Initiated Transactions.
  - `enable_customer_details` boolean — Enables adding customer details such as the name, email, and phone number. This screen will be displayed before the payment details screen.
  - `enable_quantity` boolean — When enabled, customers can specify the number of items they intend to purchase. This quantity will serve as a multiplier for the base amount.
  - `enable_qr_code` boolean — Adds the ability to verify a payment through a QR code.
  - `send_customer_receipt` boolean — Enables the sending of customer receipts.
  - `payment_methods` unknown[] — An array of accepted payment methods, card always apart of default option. Example: ['card', 'wallet']
    - unknown
  - `rules` object — Setting the rule for payment link
    - `allowed` object[] — An array of one or more rules
      - `type` 'bins' — name of rules
      - `list` unknown[] — value of bins
        - unknown
      - `decline_message` string — Custom decline message for this rule
  - `subscription` object — to be populated if this payment link is for a subscription. Otherwise, this property can be left out.
    - `frequency` 'annually' | 'monthly' | 'weekly' — defines the interval that this subscription will be run on.
    - `frequency_interval` integer — defines how often this subscription will run. This will be based on the frequency property defined above.
    - `start_date` string — the first date this subscription will run on.
    - `end_date` string — the last date this subscription could run on.
    - `payment_quantity` integer — number of times this subscription will occur. If end_date defined, end_date takes precedence.
  - `first_name` string — The first name of customer which will pre-populate in card info step.
  - `last_name` string — The last name of customer which will pre-populate in card info step.
  - `email` string — The email of customer which will pre-populate in card info step.
  - `external_id` string
  - `hold_and_charge_later` boolean — Indicates whether to place the payment on hold and charge it later using the "captures" API.
  - `custom_data` object
  - `payouts_share` object
    - `recipient_id` string — The ID of an already added recipient that the transaction amount will be shared with.
    - `percentage_to_recipient` number — The percentage of the transaction amount that will be sent to the recipient.
    - `recipient_pays_fees` boolean — Whether Mamo fees for a given transaction will be passed on to the recipient.

## Response `200`

Successful response

- object
  - `id` string
  - `name` string
  - `description` string
  - `capacity` integer
  - `active` boolean
  - `return_url` string
  - `failure_return_url` string
  - `processing_fee_percentage` number
  - `link_type` string
  - `amount` number
  - `amount_currency` string
  - `send_customer_receipt` boolean
  - `enable_tabby` boolean
  - `enable_message` boolean
  - `enable_tips` boolean
  - `save_card` string
  - `enable_quantity` boolean
  - `enable_customer_details` boolean
  - `payment_url` string
  - `first_name` string
  - `last_name` string
  - `email` string
  - `external_id` string
  - `custom_data` object
  - `payment_methods` unknown[]
    - unknown
  - `rules` object
    - `allowed` unknown[]
      - unknown
  - `subscription` object
    - `identifier` string
    - `repeats_every` string
    - `frequency_interval` integer
    - `start_date` string
    - `end_date` string
    - `payment_quantity` integer
    - `frequency` string

## Other responses

- `403` — Unauthorised
- `404` — Invalid request
- `500` — Unexpected error

---

[API](https://skmtc.net/mamopay/apis/payments.md) · [All operations](https://skmtc.net/mamopay/apis/payments/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/mamopay/payments/versions/65bb3871a425/schema)
