Manage bulk tokens
This page describes how to upload, check the status, and download the response output file of the bulk tokenization file using the Tokenization API.
Before you begin
To initiate the bulk tokenization process via the Tokenization API, you need to:
- Understand how to acquire and Manage bulk keys.
- Prepare the bulk tokenization data in a comma-separated value (CSV) format.
Request a bulk upload of tokens
Once you have prepared the tokens in CSV format, perform a POST call to the /bulk-tokens endpoint to request the upload.
HTTP method: POST
Endpoint: /bulk-tokens
{
"fileRecordCount": 10,
"merchantFileIdentifier": "123",
"fileName": "sample-123.txt",
"fileCreationDate": "09/08/2022",
"fileData": "0,123456789012,20220124,D,PAN2NWT"
}
Response:
{
"batchFileIdentifier": "379f0966-71a1-4db5-b1b3-0e87cb864ff0",
"fileName": " sample-123.txt",
"merchantFileIdentifier": "123",
"fileRecordCount": 10,
"fileReceivedTimestamp": "2023-09-08-16:13:03",
"message": {
"responseStatus": "SUCCESS",
"responseCode": "ACCEPTED",
"responseMessage": "Upload Successful Batch Id: 5e339850-4a5f-482e-9afb-79870d4056cf"
}
}
Check the status of a bulk tokenization file
Check the status of a bulk tokenization file by performing a GET call to the /bulk-tokens/{merchant-file-identifier} endpoint.
HTTP method: GET
Endpoint: /bulk-tokens/123
{
"responseStatus": "SUCCESS",
"responseCode": "ACCEPTED",
"responseMessage": "Upload Successful Batch Id: 5e339850-4a5f-482e-9afb-79870d4056cf"
}
Download the response file
Download the response file of a bulk tokenization file upload by performing a GET call to the /bulk-tokens/{merchant-file-identifier}/download endpoint.
HTTP method: GET
Endpoint: /bulk-tokens/{123}/download
{
"batchFileIdentifier": "379f0966-71a1-4db5-b1b3-0e87cb864ff0",
"errorCount": 0,
"processedCount": 10,
"merchantFileIdentifier": 123,
"message": {
"responseStatus": "SUCCESS",
"responseCode": "ACCEPTED",
"responseMessage": "Upload Successful Batch Id: 5e339850-4a5f-482e-9afb-79870d4056cf"
}
}