Create a new payment link
POSThttps://app.shuttleglobal.com/c/api/instances/{instance_key}/payment_links
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”object
object
Expiry date for the payment link. Must be a future date - cannot set expiry to a past date.
Configuration options for the payment link experience
object
Account ID to skip authentication section
/^acc_[0-9]+_[0-9a-z]+$/Customer account details
object
Customer’s address
object
Country code
Address line 1
Address line 2
Address line 3
City/Town
Post code/ZIP code
State/Province (using ISO 3166-2 subdivision codes, e.g., ‘CA’ for California)
External CRM identifier for the customer
Customer’s email address
Customer’s first name
Customer’s last name
Customer’s phone number
Whether to allow the payer to add a comment
Fixed reference for the payment (if specified, user cannot modify)
"18.18"Fixed amount for the payment in major currency units, as a decimal string without commas, using ‘.’ as the decimal separator (e.g. “18.18” for £18.18). If specified, the payer cannot modify it.
Fixed comment to show with payment
Three-letter ISO currency code
/^[A-Z]{3}$/Default reference that user can modify
"100.00"Default amount in major currency units, as a decimal string without commas, using ‘.’ as the decimal separator (e.g. “100.00”). The payer can modify it.
Default comment to show (can be changed by payer if allow_description is true)
Custom name for the payment link (defaults to instance name)
Custom introduction message for the payment page
Message to display to the user when their payment is pending authorization. Only shown on the receipt page when skip_receipt is false and no pending_url is provided.
Message to display to the user when their payment is successful. Only shown on the receipt page when skip_receipt is false and no success_url is provided.
URL to redirect to when a payment requires authorization (pending state). If skip_receipt is true, redirect happens immediately after payment submission. If skip_receipt is false, URL is presented as a button on the receipt page. Query parameters will be appended to this URL - see RedirectUrlParameters schema. Parameters include: payment_link, status, contract, charge, transaction, payment_method, account. Example: https://shop.example.com/pending?payment_link=pl_1234_abcdef&status=PENDING… Use these parameters to verify payment status and retrieve additional details via API.
Controls whether the payment method will be saved:
- If true: Payment method will be saved with the payment
- If false: Payment method won’t be saved and user won’t be given the option
- If not set: User will be given the option to save their payment method
Note that save_card: false also withdraws any payment method that can only be
used by storing a token first - GoCardless Direct Debit and Instant Bank Pay, for
example - since those cannot be offered under a hard “never save” instruction. To
take a payment that saves nothing while still offering them, leave save_card
unset and use default_save_card with hide_save_card_toggle instead.
Initial state of the “save payment method” checkbox. The payer can still change it,
and it is ignored when save_card is set. Unlike save_card, it does not restrict
which payment methods are offered.
Hides the “save payment method” checkbox from the payer, leaving whatever
default_save_card set in force. Pair the two to express a preference rather than
an instruction: do not save, but stay available to methods that need a token.
Controls redirect behavior after payment submission:
- true - Immediately redirect to success_url/pending_url
- false - Show receipt page with messages before redirect
- If true: Immediately redirect to success_url (successful payment) or pending_url (pending authorization)
- If false: Show receipt page with a button to proceed to the appropriate URL
"ECOMMERCE"Source of the payment link
Channel identifier to process the payment through
Only allow new payment methods, do not show saved payment methods
IANA timezone name for date/time display (e.g., America/New_York)
URL to redirect users after successful payment completion. Query parameters included in redirect:
- payment_link - Payment link ID
- status - Will be ‘COMPLETED’
- contract - Contract ID if created
- charge - Charge ID if created
- transaction - Transaction ID if created
- payment_method - Payment method ID if created
- account - Account ID if created If skip_receipt is true, redirect happens immediately after successful authorization. If skip_receipt is false, URL is presented as a button on the receipt page. Query parameters will be appended to this URL - see RedirectUrlParameters schema. Parameters include: payment_link, status, contract, charge, transaction, payment_method, account. Example: https://shop.example.com/success?payment_link=pl_1234_abcdef&status=COMPLETED… Use these parameters to verify payment status and retrieve additional details via API.
Responses
Section titled “Responses”Payment link created successfully
object
object
Unique identifier for the payment link (also used as payment nonce)
/^pl_[a-zA-Z0-9]+_[a-zA-Z0-9-]+$/Associated account ID (populated on PAYMENT_PENDING or PAYMENT_SUCCESS)
Associated charge ID (populated on PAYMENT_PENDING or PAYMENT_SUCCESS)
Client ID (read-only, derived from credentials)
/^cl_[a-zA-Z0-9]+$/Associated contract ID (populated on PAYMENT_PENDING or PAYMENT_SUCCESS)
Expiry date for the payment link. Must be a future date - cannot set expiry to a past date.
Payment nonce for tokenization actions (same as id)
Configuration options for the payment link experience
object
Account ID to skip authentication section
/^acc_[0-9]+_[0-9a-z]+$/Customer account details
object
Customer’s address
object
Country code
Address line 1
Address line 2
Address line 3
City/Town
Post code/ZIP code
State/Province (using ISO 3166-2 subdivision codes, e.g., ‘CA’ for California)
External CRM identifier for the customer
Customer’s email address
Customer’s first name
Customer’s last name
Customer’s phone number
"PAYMENT"Action type for the payment link.
PAYMENT— take the payment immediately.AUTH— authorise only, reserving the funds without capturing. Capture later via the Activity view or the Capture API.TOKENISE— capture the customer’s payment details without taking a payment, producing a reusable token you can charge later.
Note the spelling: the value is TOKENISE, not TOKENIZE.
When using TOKENISE, omit amount and default_amount — the link takes no
payment. save_card is redundant, as storing the card is the whole operation.
Keep currency: it determines which payment methods are offered. Retrieve the
stored token from the payment_method field when you fetch the payment link, or
from the PAYMENT_METHOD.ACTIVE webhook.
Only payment methods capable of the requested action are displayed. For example
Apple Pay does not support TOKENISE, and ACH does not support AUTH.
Whether to enable the note/comment field
"18.18"Fixed amount for the payment in major currency units, as a decimal string without commas, using ‘.’ as the decimal separator (e.g. “18.18” for £18.18). If specified, the payer cannot modify it.
Fixed note/comment for the payment (if specified, user cannot modify)
"USD"Fixed currency for the payment (e.g. USD)
"100.00"Default amount in major currency units, as a decimal string without commas, using ‘.’ as the decimal separator (e.g. “100.00”). The payer can modify it.
Default note/comment to show (user can modify)
Default reference to show (user can modify)
Custom name for the payment link (defaults to instance name)
Custom introduction message for the payment page
Message to display to the user when their payment is pending authorization.
Message to display to the user when their payment is successful.
URL to redirect users when payment requires authorization. Query parameters included in redirect:
- payment_link - Payment link ID
- status - Will be ‘PENDING’
- contract - Contract ID if created
- charge - Charge ID if created
- transaction - Transaction ID if created
- payment_method - Payment method ID if created
- account - Account ID if created If skip_receipt is true, redirect happens immediately after authorization is required. If skip_receipt is false, URL is presented after showing the pending message.
Fixed reference for the payment (if specified, user cannot modify)
"ECOMMERCE"Source of the payment link
Channel identifier to process the payment through
Only allow new payment methods, do not show saved payment methods
IANA timezone name for date/time display (e.g., America/New_York)
URL to redirect users after successful payment completion. Query parameters included in redirect:
- payment_link - Payment link ID
- status - Will be ‘COMPLETED’
- contract - Contract ID if created
- charge - Charge ID if created
- transaction - Transaction ID if created
- payment_method - Payment method ID if created
- account - Account ID if created If skip_receipt is true, redirect happens immediately after successful authorization. If skip_receipt is false, URL is presented as a button on the receipt page. Query parameters will be appended to this URL - see RedirectUrlParameters schema. Parameters include: payment_link, status, contract, charge, transaction, payment_method, account. Example: https://shop.example.com/success?payment_link=pl_1234_abcdef&status=COMPLETED… Use these parameters to verify payment status and retrieve additional details via API.
Associated payment method ID (populated on various payment events)
Associated payment ID (populated on PAYMENT_PENDING or PAYMENT_SUCCESS)
Current status of the payment link:
- ACTIVE - Payment link is available and can be used for payment
- PENDING - Payment is in process (either actively processing or in an unresolved state)
- COMPLETED - Payment link has been successfully paid
- EXPIRED - Payment link has passed its expiration date without being paid or reaching pending state
- ARCHIVE - Payment link has been deleted (soft-delete)
Status transitions:
- ACTIVE → PENDING: When payment/tokenization starts
- PENDING → COMPLETED: On successful payment
- PENDING → ACTIVE: On failed payment attempt
- Any → EXPIRED: When expiration time is reached
- Any → ARCHIVE: When explicitly archived via DELETE
Associated transaction ID (populated on PAYMENT_PENDING or PAYMENT_SUCCESS)
"https://app.shuttleglobal.com/cp/link/{id}"Payment link URL (read-only)
1Object version for optimistic concurrency control
Bad request
Every error has a code and a message. Some add more fields alongside them, with detail about the error.
object
The error code, for example VALIDATION_ERROR, INVALID, INVALID_REQUEST, UNAUTHORIZED, FORBIDDEN or NOT_FOUND. Program against this, not the message.
What went wrong, in words, for logs and support.
Authentication required
Every error has a code and a message. Some add more fields alongside them, with detail about the error.
object
The error code, for example VALIDATION_ERROR, INVALID, INVALID_REQUEST, UNAUTHORIZED, FORBIDDEN or NOT_FOUND. Program against this, not the message.
What went wrong, in words, for logs and support.
Example
{ "code": "UNAUTHORIZED", "message": "Unauthorised"}Instance not found (only checked after successful authentication)
Every error has a code and a message. Some add more fields alongside them, with detail about the error.
object
The error code, for example VALIDATION_ERROR, INVALID, INVALID_REQUEST, UNAUTHORIZED, FORBIDDEN or NOT_FOUND. Program against this, not the message.
What went wrong, in words, for logs and support.
Internal server error
object
object
Was this page helpful?
What went wrong?
Thanks for telling us.