Card Enrichment

Enrich a batch of card transactions

Submit a batch of transactions for enrichment. This endpoint will return a batchId which can be used in the /batches/{batchId} and /batches/{batchId}/results endpoints to check the status of the batch job and retrieve the results.

You can pass ?synchronous=true to enrich smaller sets of transactions synchronously. See the Microbatch enrichment guide for details.

Note that we impose a rate limit on the number of batch requests made in a rolling 12 hour window. Please reach out to sales@spade.com with any questions.

post/batches/transactions/cards/enrich

Request

  • Base URL
    https://east.sandbox.spade.com
  • URL
    https://east.sandbox.spade.com/batches/transactions/cards/enrich
  • Auth
    API key in header X-Api-Key

Query parameters

synchronousboolean

When true, returns enriched results inline in the response instead of a batchId. Microbatches are capped to ensure timely processing. See the Microbatch enrichment guide for details.

Request body

callbackUrlstring url

Set this URL if you want to receive a notification when the batch job is complete.

Example request

{
  "transactions": [
    {
      "merchantName": "Amazon",
      "organizationId": "organization_id_123",
      "programId": "program_id_123",
      "userId": "user_id_123456789",
      "cardId": "card_id_123456789",
      "cardFirstSix": "123456",
      "cardLastFour": "7890",
      "transactionId": "transaction_id_123456789",
      "acquirerId": "000000000123456",
      "currencyCode": "USD",
      "occurredAt": "2022-06-15 18:27:51Z",
      "categoryCode": "5812",
      "categoryType": "MCC",
      "location": {
        "address": "1234 W 5th Ave Suite 100",
        "city": "New York",
        "region": "NY",
        "country": "USA",
        "postalCode": "10001",
        "latitude": 45,
        "longitude": 120
      },
      "billingProfile": "standard",
      "customAttributes": {
        "custom_attribute_1": "value_1",
        "custom_attribute_2": "value_2"
      }
    }
  ],
  "callbackUrl": "https://example.com/callback"
}

Response

Successful operation

OR

Example response

{
  "batchSize": 1,
  "submittedAt": "2024-11-21T20:07:20.213660Z"
}

Changes

No recorded changes to this operation across all 1 revision of this API.