Create a Direct Debit Single-Use Token

POST /customervault/v1/achsingleusetokens

The Customer Vault API allows you to create Direct Debit single-use tokens, which can then be used to process Purchases and Standalone Credits through the Direct Debit API or when using Paysafe Checkout.

You can also use the Direct Debit single-use tokens for other requests in the Customer Vault API, such as creating profiles and creating bank accounts.

You have to generate a new single-use token for each Direct Debit or Customer Vault API request you wish to process. Single-use tokens are valid for only 15 minutes.

The example below shows you how to create an ACH single-use token. In the response, you will find a paymentToken value that you would include with your Direct Debit Purchase or Standalone Credit, or with Paysafe Checkout requests.

To create an EFT single-use token instead of an ACH single-use token:

  • Send the request to the eftsingleusetokens endpoint
  • Replace the achBankAccount object with an eftBankAccount object like the following:
"eftBankAccount": {
    "accountNumber": "5002205",
    "accountHolderName": "R. Smith",
    "transitNumber": "20250",
    "institutionId": "001"

See our full API Reference section for a complete description of parameters required.

Before trying the example, you should:

  • Replace the API key (after the u) with your API key for single-use tokens.
Value Required? Type Description
profile object This is some optional information about the customer.
achBankAccount Yes object These are the bank account details, including account number and routing number.
billingAddress Yes object This is the customer's billing address, including street, city, and country.

The response contains the paymentToken and a timeToLiveSeconds value which indicates how many seconds remain for this payment token. Single-use tokens last 15 minutes.

Value Type Description
id string This is the ID for the request.
paymentToken string This is the single-use payment token that represents the ACH bank account and that will be used for the Purchase/Standalone Credit request.
timeToLiveSeconds integer This is the period of time the single-use token is valid before expiration, in seconds.
profile object This is some optional information about the customer.
billingAddress object This is the customer's billing address.
achBankAccount object These are the bank account details.
Did you find this page useful?