curl --request POST \
--url https://api.pushcash.com/user/{id}/credential \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"token": "token_mbDRHFi3dxIZEtykHsgUGC",
"type": "card_only"
}
'{
"id": "cred_9AmC1KkUn0WabPyPUdHclX",
"created_at": "2023-05-26T14:35:45.456Z",
"card_last4": "4444",
"authenticated": true,
"type": "card_only_debit",
"account_last4": null,
"bank_name": null
}Create a credential on a user’s profile using a token from the Push Cash SDK.
curl --request POST \
--url https://api.pushcash.com/user/{id}/credential \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"token": "token_mbDRHFi3dxIZEtykHsgUGC",
"type": "card_only"
}
'{
"id": "cred_9AmC1KkUn0WabPyPUdHclX",
"created_at": "2023-05-26T14:35:45.456Z",
"card_last4": "4444",
"authenticated": true,
"type": "card_only_debit",
"account_last4": null,
"bank_name": null
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
The push identifier for the user
"user_28CJjV7P4Go5PNJvfzghiD"
Credential created successfully
The unique identifier assigned by Push
When the payment credential was created (ISO 8061 date string)
The last 4 digits of the card number
For secure_debit credentials, whether the user has authenticated with the bank.
The type of payment credential:
secure_debit: A debit card which can be used for withdrawals and depositscard_only_credit: A credit card which can be used for deposits alonecard_only_debit: A debit card which can be used for deposits alonesecure_debit, card_only_credit, card_only_debit For authenticated secure_debit credentials, the last 4 digits of the bank account number for the user's account. This field is null otherwise.
For secure_debit credentials, the name of the user's bank. This field is null otherwise.