Skip to main content
POST

Authorizations

X-API-KEY
string
header
required

Your secret API key obtained from the Clink dashboard (Developers section)

Headers

X-Timestamp
string
required

Current timestamp in milliseconds since Unix epoch (required for request signing)

Example:

"1783513683000"

Body

application/json

Parameters required to initialize a customer portal session

customerId
string
required

Existing customer's unique identifier

returnUrl
string

Redirect URL when customer click on 'Return to Merchant'

subscriptionUpdateProductIds
string[]

Product IDs allowed for subscription upgrades or downgrades in this customer portal session. When omitted or empty, this session does not restrict eligible products. Blank or invalid product IDs are rejected.

Example:

Response

200 - application/json

Customer portal session created successfully

Response object returned when creating a new checkout session

code
integer<int32>

HTTP status code indicating the request result (200 for success, 4xx for client errors, 5xx for server errors)

Example:

200

msg
string

Human-readable message describing the result ('success' for successful operations, error details for failures)

Example:

"success"

data
object

Customer Portal session details when successfully created