Cancel PayPal Pay Link
POST/api/paypal-payment-links/:id/cancel
Cancels an active pay link so the customer can no longer pay it.
Authentication: Requires Bearer token with the Sales Orders Manage payments permission.
Only an active link can be cancelled: a paid, pending (payment clearing), expired or already cancelled link returns 422 and keeps its status. The 422 message says why in plain words (still clearing with PayPal, already paid, or no longer payable).
This endpoint currently requires session authentication; Personal Access Token scope support is in progress.
Request
Responses
- 200
- 401
- 403
- 404
- 422
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not Found
Response Headers
Unprocessable Content
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.