Terminal
Terminal Readers
Register terminal readers and manage their active actions from your integration.
Reader registrationCancel actionDelete reader
Register reader
POST
/readersRegisters a terminal reader to a merchant location.
| Parameter | Type | Required | Description |
|---|---|---|---|
label | string | Yes | Friendly reader label, for example Front counter. |
location_id | string | Yes | NeroPay location id or local location id returned by locations API. |
registration_code | string | Yes | Pairing/registration code shown on the reader. |
'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $secretKey,
'Accept: application/json',
'Content-Type: application/json',
'X-NeroPay-Timestamp: ' . $timestamp,
'X-NeroPay-Signature: ' . $signature,
'Idempotency-Key: ' . bin2hex(random_bytes(16)),
],
CURLOPT_POSTFIELDS => $rawBody,
]);
$response = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
echo $response;
{
"success": true,
"data": {
"id": 501,
"label": "Front counter",
"status": "online",
"neropay_reader_id": "tmr_nero_123",
"location_id": "tml_nero_123",
"account_id": "NPEE4E742AB2_6165"
}
}
List readers
true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $secretKey,
'Accept: application/json',
],
]);
$response = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
echo $response;
{
"success": true,
"data": [
{
"id": 501,
"label": "Front counter",
"status": "online",
"neropay_reader_id": "tmr_nero_123",
"location_id": "tml_nero_123"
}
]
}
Cancel reader action
true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $secretKey,
'Accept: application/json',
],
]);
$response = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
echo $response;
{
"success": true,
"data": {
"reader_id": "tmr_nero_123",
"status": "cancelled"
}
}
Delete reader
true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $secretKey,
'Accept: application/json',
],
]);
$response = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
echo $response;
{
"success": true,
"data": {
"id": 501,
"deleted": true
}
}
{
"success": false,
"error": {
"code": "resource_not_found",
"message": "Reader was not found for this merchant.",
"details": null
}
}