Partially update payment link

View as MarkdownOpen in Claude
Use this method to partially update a payment link. Structure your request to follow the [RFC 6902](https://datatracker.ietf.org/doc/html/rfc6902) standard. To update a payment link, you need its paymentLinkId, which we sent you in the response of the [Create Payment Link](https://docs.payroc.com/api/schema/payment-links/create) method. **Note:** If you don't have the paymentLinkId, use our [List Payment Links](https://docs.payroc.com/api/schema/payment-links/list) method to search for the payment link. You can update the following properties of a multi-use link: - **expiresOn parameter** - Expiration date of the link. - **customLabels object** - Label for the payment button. - **credentialOnFile object** - Settings for saving the customer's payment details. You can update the following properties of a single-use link: - **expiresOn parameter** - Expiration date of the link. - **authType parameter** - Transaction type of the payment link. - **amount parameter** - Total amount of the transaction. - **currency parameter** - Currency of the transaction. - **description parameter** - Brief description of the transaction. - **customLabels object** - Label for the payment button. - **credentialOnFile object** - Settings for saving the customer's payment details. **Note:** When a merchant updates a single-use link, we update the payment URL and HTML code in the assets object. The customer can't use the original link to make a payment.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

paymentLinkIdstringRequired=10 characters
Unique identifier that we assigned to the payment link.

Headers

Idempotency-KeystringRequiredformat: "uuid"
Unique identifier that you generate for each request. You must use the [UUID v4 format](https://www.rfc-editor.org/rfc/rfc4122) for the identifier. For more information about the idempotency key, go to [Idempotency](https://docs.payroc.com/api/idempotency).

Request

This endpoint expects a list of objects.
addobjectRequired
A Patch Add Operation.
OR
removeobjectRequired
A Patch Remove Operation.
OR
replaceobjectRequired
A Patch Replace Operation.
OR
moveobjectRequired
A Patch Move Operation.
OR
copyobjectRequired
A Patch Copy Operation.
OR
testobjectRequired
A Patch Test Operation.

Response

Successful request. We updated the payment link and return a polymorphic object that contains payment link information. The value of the type parameter determines which variant you should use: - `multiUse` - Create a link that the merchant can use to take multiple payments. - `singleUse` - Create a link that the merchant can use for only one payment.
multiUseobject
OR
singleUseobject

Errors