Create a setup intent

Creates a setup intent. If successfully created, it returns a SetupIntent object that contains information related to the setup intent.

SecurityOAuth2
Request
Request Body schema: application/json
customerId
required
string <uuid>

The unique identifier for the customer record.

externalReferenceId
string

The unique identifier for the setup intent generated by the location or the integration partner.

standingInstructionType
string

The instruction type used by the merchant and sent to the payment processor. Include the standingInstructionType field in the request body to indicate the transaction is a merchant-initiated transaction.

  • INSTALLMENT - The total purchase amount split into a fixed number of payments.

  • RECURRING - A series of set payments charged at regular intervals.

  • UNSCHEDULED - A single merchant-initiated payment.

Enum: "UNSCHEDULED" "INSTALLMENT" "RECURRING"
usage
required
string (Usage)
Default: "ON_SESSION"

Field used to determine what type of transaction the saved card will be set up for.

  • ON_SESSION - Set up and save a payment method to the customer’s record for future customer-initiated transactions.
  • OFF_SESSION - Set up and save a payment method for future merchant-initiated transactions.
Enum: "ON_SESSION" "OFF_SESSION"
Responses
201

Successful operation. Setup intent created.

400

Bad request / Missing required fields.

401

Unauthorized.

403

Forbidden.

500

Internal server error.

post/v1/setup-intents
Request samples
application/json
{
  • "customerId": "87d8e330-2878-4742-a86f-dbbb3bf522ac",
  • "usage": "ON_SESSION",
  • "standingInstructionType": "UNSCHEDULED",
  • "externalReferenceId": "string"
}
Response samples
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "customerId": "87d8e330-2878-4742-a86f-dbbb3bf522ac",
  • "sessionSecret": "string",
  • "usage": "ON_SESSION",
  • "externalReferenceId": "string",
  • "mandateId": "d4dbf0da-b5aa-43ae-b9db-c2aff331d3ad",
  • "paymentMethodTypes": [ ],
  • "creationDate": "2023-07-07T14:01:27Z"
}