Skip to content

Tokenization Service (0.0.8)

This service is used to tokenize securely converts sensitive payment information (such as credit card numbers, bank account details, or mobile wallet identifiers) into unique, non-sensitive tokens.

Download OpenAPI description
Languages
Servers
Mock server
https://docs.nelnetpay.com/_mock/apis/osi-token-api/
LOCAL
http://localhost:8080/tokenization-service/
DEV
https://localhost:16778/tokenization-service/
SIT
https://localhost:16779/tokenization-service/
QA
https://localhost:16780/tokenization-service/
UAT
https://localhost:16781/tokenization-service/

Tokenize API

Tokenization offers a set of RESTful APIs for token management, including creation, update, retrieval, and deletion of tokens. The APIs enable secure tokenization of the various payment account data like ACH Bank Account, Credit Card, and Apple Pay.

Operations

Tokenize a Payment Account Data

Request

Creates a secure token for various payment data account including ACH Bank Account, Credit Card, and Apple Pay.

Security
bearerAuth
Bodyapplication/jsonrequired

Payment account data to tokenize.

paymentTypeobjectrequired
paymentType.​achobject
paymentType.​creditCardobject
paymentType.​applePayobject
tokenGroupstring

Token group name.

Example: "COMPANYTG"
curl -i -X POST \
  https://docs.nelnetpay.com/_mock/apis/osi-token-api/token-service/tokens \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "paymentType": {
      "ach": {
        "bankAccount": {
          "accountNumber": "4111111111111111",
          "routingNumber": "021000031",
          "accountType": "Savings",
          "tenderType": "Consumer"
        }
      }
    },
    "tokenGroup": "COMPANYTG"
  }'

Responses

Successful tokenization or error response.

Bodyapplication/json
responseCodestringrequired

A code that represents the outcome of the transaction

Example: "0"
responseMessagestring

A list of brief descriptions about the error encountered. If multiple messages need to be returned, it will be separated with ';' character

Example: "An unexpected system error occurred. Please check with support."
tokenstring

Token in UUID format

Example: "85ce5afd-31b2-4612-a6ef-c1e2aba3ca71"
formatPreservedTokenstring

Format preserved token

Example: "3464594731bvtegfdstgv463"
binstring

Bank Identification Number

Example: "40212300"
binLevelstring

Only present for CC: card level like classic, platinum etc.

Example: "Classic"
categorystring

Only present for CC: credit card, debit card, cash card

Example: "Credit Card"
lastFourstring

Only present for CC: last 4 of card number

Example: "4444"
binLengthinteger(int32)

Only present for CC: BIN length

Example: 8
networkstring

Only present for CC: card brand like Visa

Example: "VISA"
isoCountrystring

Country code representing the country associated with the payment account

Example: "UNITED STATES OF AMERICA (THE)"
isoCountryCodestring

Country code indicating the country where the payment account's issuing institution is located

Example: "840"
isInternationalboolean

Flag indicating whether the payment account is considered international

Example: false
tokenGroupNamestring

Name of the token group

Example: "Credit Card Tokens"
Response
application/json

ACH Response

{ "responseCode": "0", "responseMessage": "Token Created", "token": "13634e83-5ad1-4814-afde-c6e2e0f32bbe", "formatPreservedToken": "2848580716091111", "tokenGroupName": "DEVTESTTG" }

Delete Specific Token

Request

Security
bearerAuth
Bodyapplication/jsonrequired

Token that would be deleted.

tokenstringrequired

Token that would be decrypted.

Example: "e4eaaaf2-d142-11e1-b3e4-080027620cdd"
typesArray of strings

Type of decrypted details that would be returned.

Example: ["ACH","PAN"]
curl -i -X DELETE \
  https://docs.nelnetpay.com/_mock/apis/osi-token-api/token-service/tokens \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "token": "9c5a8d98-ccd3-452b-be55-e66ad2132e98"
  }'

Responses

Successful deletion of token

Bodyapplication/json
responseCodestringrequired

A code that represents the outcome of the transaction

Example: "0"
responseMessagestring

A list of brief descriptions about the error encountered. If multiple messages need to be returned, it will be separated with ';' character

Example: "An unexpected system error occurred. Please check with support."
Response
application/json

Delete Token Response

{ "responseCode": "0", "responseMessage": "Token Deleted" }

Update Token

Request

Updates an existing token for various payment methods including credit cards, ACH bank accounts, and Apple Pay

Security
bearerAuth
Bodyapplication/jsonrequired

Payment method details to update

paymentTypeobjectrequired
paymentType.​achobject
paymentType.​creditCardobject
paymentType.​applePayobject
tokenGroupstring

Token group name.

Example: "COMPANYTG"
curl -i -X PATCH \
  https://docs.nelnetpay.com/_mock/apis/osi-token-api/token \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "token": "9c5a8d98-ccd3-452b-be55-e66ad2132e98",
    "paymentType": {
      "ach": {
        "bankAccount": {
          "accountNumber": "4111111111111111",
          "routingNumber": "021000031",
          "accountType": "Savings",
          "tenderType": "Consumer"
        }
      }
    },
    "tokenGroup": "COMPANYTG"
  }'

Responses

Successful token update or error response.

Bodyapplication/json
responseCodestringrequired

A code that represents the outcome of the transaction

Example: "0"
responseMessagestring

A list of brief descriptions about the error encountered. If multiple messages need to be returned, it will be separated with ';' character

Example: "An unexpected system error occurred. Please check with support."
Response
application/json

ACH Response

{ "responseCode": "0", "responseMessage": "Token Updated" }

Get Payment Data By Token

Request

Retrieve the a payment data associated with a specific token. This will return meta data about the payment data but not the sensitive payment data.

Security
bearerAuth
Bodyapplication/jsonrequired

Token and Type parameters for retrieving payment account data.

tokenstringrequired

Token that would be decrypted.

Example: "e4eaaaf2-d142-11e1-b3e4-080027620cdd"
typesArray of strings

Type of decrypted details that would be returned.

Example: ["ACH","PAN"]
curl -i -X GET \
  https://docs.nelnetpay.com/_mock/apis/osi-token-api/token-service/tokens/metadata \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "token": "9c5a8d98-ccd3-452b-be55-e66ad2132e98",
    "types": [
      "ACH"
    ]
  }'

Responses

Successful retrieval of token details

Bodyapplication/json
responseCodestringrequired

A code that represents the outcome of the transaction

Example: "0"
typestring

Type of token

tokenstring

Token in UUID format

Example: "85ce5afd-31b2-4612-a6ef-c1e2aba3ca71"
formatPreservedTokenstring

Format preserved token

creditCardobject
bankAccountobject
dpanobject
mpanobject
responseMessagestring

A list of brief descriptions about the error encountered. If multiple messages need to be returned, it will be separated with ';' character

Example: "An unexpected system error occurred. Please check with support."
Response
application/json

ACH Response

{ "responseCode": "0", "responseMessage": "Payment Data Retrieved", "token": "07ba706d-dcfc-4bfc-b161-4469a2633862", "formatPreservedToken": "6558766560401113", "bankAccount": { "routingNumber": "021000032", "accountType": "Savings", "tenderType": "Consumer" } }

Decrypt Token API

This endpoint allows authorized clients to securely retrieve the original payment data associated with a specific token.

Operations