Skip to main content

Get Spending Prerequisites

POST 

https://api.immersve.com/api/spending-prerequisites

Check for outstanding cardholder "Spending Prerequisites". Clients should use the returned prerequisite instructions to guide the user through the card onboarding user journey.

Spending prerequisites are divided into three stages: Funding, KYC, and AML. When each of these three stages indicate the status is "ok" then the cardholder can proceed to transact with their card.

See the KYC Spending Prerequisites guide for more details about how to consume the prerequisite instructions for your cardholder onboarding experience.

Request

Body

required

    cardProgramId stringrequired

    ID of card program to create the card under

    fundingSourceId stringrequired

    ID of the Funding Source the card will authorize against

    spendableAmount stringrequired

    Amount of fiat money that should be available on the card, denominated in minor units

    spendableCurrency stringrequired

    Possible values: [USD]

    Currency to be used when creating the card. Currently only supports USD

    fundingMode string

    Possible values: [deposit, approval]

    Hint for the prerequisite funding transaction type. Presently only universal-evm funding supports the funding mode hint.
    deposit (default) — Funding instruction should be a token transfer.
    approval — Funding instruction should be a token approval.

    kycType string

    Possible values: [immersve-conducted, partner-conducted]

    Type of KYC depending on which party is conducting it

    kycRedirectUrl string

    A URL to which the user can be redirected after they have completed or exited the kyc process.

    kycRegion string

    The country in which the user resides, in two letter country code format (e.g. AU). This must be one of the countries enabled in the card program for your partner account.
    Note - this is only required when using the kycHiddenSteps option to hide the region KYC step.

    kycHiddenSteps array

    Possible values: [region, expected-spend, contact-channels, residential-address]

    A list of KYC steps to skip in the Immersve Conducted UI. Cardholder information for these steps must be provided separately via API.

Responses

Schema

    prerequisites

    object[]

  • Array [

  • anyOf

    stage required

    Possible values: [funding]

    status required

    Possible values: [action-required, pending, blocked, ok]

    actionType

    Possible values: [smart_contract_write, simulator_call]

    type stringdeprecated

    The prerequisite instruction type. This attribute is deprecated. Clients should use stage and actionType instead.

    params

    object

    The parameters for the prerequisite instruction, if applicable. Specific parameters vary based on the prerequisite instruction's action type.

    oneOf

    contractAddress string

    The address of the smart contract

    abi

    object[]

    The JSON ABI of the smart contract (contains only required details. more details here https://docs.soliditylang.org/en/v0.8.19/abi-spec.html#json)

  • Array [

  • type string

    Possible values: [function]

    name string

    The name of the function

    inputs

    object[]

  • Array [

  • name string

    The name of the parameter

    type string

    The type of the parameter

  • ]

  • ]

  • method string

    Smart contract method

    params object

    Smart contract call params. Keys are matching names and order defined in ABI

  • ]

curl -L 'https://api.immersve.com/api/spending-prerequisites' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
-d '{
"cardProgramId": "string",
"fundingSourceId": "string",
"spendableAmount": "string",
"spendableCurrency": "USD",
"fundingMode": "deposit",
"kycType": "immersve-conducted",
"kycRedirectUrl": "string",
"kycRegion": "string",
"kycHiddenSteps": [
null
]
}'
Request Collapse all
Base URL
https://api.immersve.com
Auth
Body required
{
  "cardProgramId": "string",
  "fundingSourceId": "string",
  "spendableAmount": "string",
  "spendableCurrency": "USD",
  "fundingMode": "deposit",
  "kycType": "immersve-conducted",
  "kycRedirectUrl": "string",
  "kycRegion": "string",
  "kycHiddenSteps": [
    null
  ]
}
ResponseClear

Click the Send API Request button above and see the response here!