Paddle Billing
Search

Set the webpage for payment links against a transaction

More easily work with multiple production environments that use separate domains by specifying a URL for an approved domain as the checkout payment link when creating a transaction.

What's new?

We made transaction.checkout.url a writeable field. You can pass a URL for an approved domain to this field when creating or updating a transaction to specify a URL to be used for the returned payment link for a transaction.

checkoutobject or null

Paddle Checkout details for this transaction. You may pass a URL when creating or updating an automatically-collected transaction, or when creating or updating a manually-collected transaction where billing_details.enable_checkout is true.

urlstring or null

Checkout URL to use for the payment link for this transaction. Pass the URL for an approved domain, or omit to use your default payment URL.

Paddle returns a unique payment link composed of the URL passed or your default payment URL + _?txn= and the Paddle ID for this transaction.

How it works

The checkout.url field against a transaction contains a link that Paddle generates that you can use to open a checkout for this transaction.

This link is composed of your default payment link + _?txn= and the Paddle ID for a transaction. Provided the default payment URL page includes Paddle.js, it automatically opens a checkout for the transaction passed in the URL.

Previously, checkout.url was a read-only field. This means that it was returned in responses from the API, but not valid if included in requests to the API.

With this update, you can pass a URL for an approved domain to checkout.url when creating or updating transactions. When included in requests, Paddle returns a checkout.url that's composed of the URL for the approved domain + _?txn= and the Paddle ID for a transaction.

If you don't include checkout.url in your request, Paddle returns a checkout.url composed using your default payment link as normal. When updating, you can pass null to checkout.url to set back to your default payment link.

Only approved domains can be used for transaction payment links. View and request approval for domains in Paddle > Checkout > Request domain approval.

Domains on sandbox are automatically approved. If a domain in sandbox is pending, remove and re-add it.

Next steps

This change is available in version 1 of the Paddle API.

It's a non-breaking change, meaning it doesn't impact existing integrations.

Create or update a transaction using the API to set checkout.url for a transaction.

Learn more