POST https://sandbox.payme.io/api/buyer-token-to-card-numberPOST https://live.payme.io/api/buyer-token-to-card-numberNo credentials are documented for this endpoint.
This endpoint can be used only if you are PCI compliant and allow to handle raw credit card infromation.
This end-point is used for receiving the full credit card data by sending a request with the buyer token.
Please note that in the response you won't receive CVV details, as we don't save it due to regulation.
This endpoint takes no path, query or header parameters.
Content type: application/json
| Field | Type | Required | Description |
|---|---|---|---|
seller_payme_id |
string | no | Our unique seller ID. |
buyer_uuid2 |
string | no | Buyer's public key |
buyer_key |
string | no | Buyer's private key |
{
"seller_payme_id": "MPL1DEMO-XXXXXXXX-XXXXXXXX-XXXXXXXX",
"buyer_uuid2": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"buyer_key": "BUYER111-XXXXXXXX-XXXXXXXX-XXXXXXXX"
}
curl -X POST 'https://sandbox.payme.io/api/buyer-token-to-card-number' \
-H 'Content-Type: application/json' \
--data-raw '{
"seller_payme_id": "MPL1DEMO-XXXXXXXX-XXXXXXXX-XXXXXXXX",
"buyer_uuid2": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"buyer_key": "BUYER111-XXXXXXXX-XXXXXXXX-XXXXXXXX"
}'
const response = await fetch("https://sandbox.payme.io/api/buyer-token-to-card-number", {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
"seller_payme_id": "MPL1DEMO-XXXXXXXX-XXXXXXXX-XXXXXXXX",
"buyer_uuid2": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"buyer_key": "BUYER111-XXXXXXXX-XXXXXXXX-XXXXXXXX"
}),
});
console.log(await response.text());
import requests
response = requests.post(
"https://sandbox.payme.io/api/buyer-token-to-card-number",
json={
"seller_payme_id": "MPL1DEMO-XXXXXXXX-XXXXXXXX-XXXXXXXX",
"buyer_uuid2": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"buyer_key": "BUYER111-XXXXXXXX-XXXXXXXX-XXXXXXXX",
},
)
print(response.text)
<?php
$body = <<<'BODY'
{
"seller_payme_id": "MPL1DEMO-XXXXXXXX-XXXXXXXX-XXXXXXXX",
"buyer_uuid2": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
"buyer_key": "BUYER111-XXXXXXXX-XXXXXXXX-XXXXXXXX"
}
BODY;
$ch = curl_init('https://sandbox.payme.io/api/buyer-token-to-card-number');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => $body,
]);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
| Field | Type | Description |
|---|---|---|
buyer_key |
string | Buyer's unique token. |
buyer_card_number |
string | Buyer's card mask. |
buyer_card_exp_month |
string | Buyer's card exp (MMYY). |
buyer_card_exp_year |
string | Credit card expiration date |
{
"buyer_key": "BUYER111-XXXXXXXX-XXXXXXXX-XXXXXXXX",
"buyer_card_number": "532**********846",
"buyer_card_exp_month": "04",
"buyer_card_exp_year": "26",
"status_code": 0
}