Skip to main content

Create a payment link

POST 

/v1/links

Creates a payment link.

Request

Body

required

    allow_adjustable_quantity booleanrequired

    Has the value of true if the quantity of the line items can be adjusted by the customer or false if the quantity is fixed.

    branding

    object

    Details on branding elements to apply when rendering the Payment Link page.

    icon stringnullable

    A secure URL to an image icon

    logo stringnullable

    A secure URL to an image logo

    use_logo boolean

    Has the value of true if logo should be rendered in payment page or false if icon should be used.

    primary_color stringnullable

    A hex color code that will be used as background color of the Payment Link page

    secondary_color stringnullable

    A hex color code that will be used as color of the submit button and links

    currency stringrequired

    Three-letter ISO currency code, in lowercase. Must be a supported currency.

    description stringnullable

    A description for the Payment Link.

    expiry date

    The date when the Payment Link will automatically expire. The format is MM/DD/YYYY.

    internal_name stringrequired

    A reference name for the Payment Link that is only visible to the merchant for easy identification.

    line_items

    LineItem[]

    required

    A list of line items that will be displayed in the Payment Link page.

  • Array [

  • amount integerrequired

    Unit amount of the product in cents represented as a whole integer.

    description stringnullable

    A description of the product

    image stringnullable

    A secure URL to an image of the product

    name stringrequired

    The name of the product

    quantity integerrequired

    The total number of stocks for the product

    remaining integer

    The total number of stocks remaining for the product

  • ]

  • metadata

    object

    A set of key-value pairs that you can attach to the Payment Link. It can be used to store additional information about the Payment Link.

    property name* string
    payment_method_types PaymentMethodType (string)[]required

    Possible values: [card, bpi, gcash, paymaya, alipay, unionpay, wechat]

    The payment methods that are available for the customer to pay the Payment Link.

    phone_number_collection boolean

    Describes whether to collect the customer's phone number at Checkout.

    redirect_url stringnullable

    The URL to redirect the customer to after the payment is successful.

    require_auth boolean

    Default value: true

    Indicates whether 3D Secure authentication shall be required for card payments. Always have a value true.

    shipping_address_collection

Responses

Created

Schema

    id string

    The unique identifier of the Payment Link.

    object string

    String representing the object's type. Objects of the same type share the same value.

    active boolean

    Has the value of true if the Payment Link is accessible or false otherwise.

    allow_adjustable_quantity boolean

    Has the value of true if the quantity of the line items can be adjusted by the customer or false otherwise.

    branding

    object

    Details on branding elements to apply when rendering the Payment Link page.

    icon stringnullable

    A secure URL to an image icon

    logo stringnullable

    A secure URL to an image logo

    use_logo boolean

    Has the value of true if logo should be rendered in payment page or false if icon should be used.

    primary_color stringnullable

    A hex color code that will be used as background color of the Payment Link page

    secondary_color stringnullable

    A hex color code that will be used as color of the submit button and links

    created timestamp

    Time at which the object was created. Measured in seconds since the Unix epoch.

    currency string

    Three-letter ISO currency code, in lowercase. Must be a supported currency.

    description stringnullable

    A description for the Payment Link.

    expiry date

    The date when the Payment Link will automatically expire. The format is MM/DD/YYYY.

    internal_name string

    A reference name for the Payment Link that is only visible to the merchant for easy identification.

    line_items

    LineItem[]

    A list of line items that will be displayed in the Payment Link page.

  • Array [

  • amount integerrequired

    Unit amount of the product in cents represented as a whole integer.

    description stringnullable

    A description of the product

    image stringnullable

    A secure URL to an image of the product

    name stringrequired

    The name of the product

    quantity integerrequired

    The total number of stocks for the product

    remaining integer

    The total number of stocks remaining for the product

  • ]

  • livemode boolean

    Has the value of true if the object exists in live mode or the value of false if the object exists in test mode.

    maximum_payments integernullable

    The maximum number of payments that can be made to the Payment Link.

    metadata

    object

    A set of key-value pairs that you can attach to the Payment Link. It can be used to store additional information about the Payment Link.

    property name* string
    payment_method_types PaymentMethodType (string)[]

    Possible values: [card, bpi, gcash, paymaya, alipay, unionpay, wechat]

    The payment methods that are available for the customer to pay the Payment Link.

    phone_number_collection boolean

    Describes whether to collect the customer's phone number at Checkout.

    redirect_url stringnullable

    The URL to redirect the customer to after the payment is successful.

    require_auth boolean

    Default value: true

    Indicates whether 3D Secure authentication shall be required for card payments. Always have a value true.

    shipping_address_collection
    updated timestamp

    Time at which the object was last updated. Measured in seconds since the Unix epoch.

    url string

    The URL of the Payment Link.

Loading...