Search…
⌃K
🛃

Customers

Keep track of all your customers with this API endpoint you can programmatically fetch and list all the customers linked to your Lazerpay account :

All Customers

List all the customers associated with your Lazerpay account
get
https://api.lazerpay.engineering/api/v1
/customers
fetch all customers

Example : NodeJs - Request

var request = require('request');
var options = {
'method': 'GET',
'url': 'https://api.lazerpay.engineering/api/v1/customers',
'headers': {
Authorization: 'Bearer SECRET_KEY',
'Content-Type': 'application/json'
}
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});

Sample Response

{
"message": "Customers retrieved successfully",
"status": "success",
"statusCode": 200,
"data": [
{
"id": "bc48cc84-71cc-XXX-8562-XXXXX",
"walletId": "33cbb77a-35a2-421f-a733-XXXXX",
"name": "Abdulfatai Suleiman",
"email": "[email protected]",
"shippingAddress": null,
"phone": null,
"network": "testnet",
"createdAt": "2022-09-05T22:09:57.119Z",
"updatedAt": "2022-09-05T22:09:57.119Z",
"transactions": [
{
"id": "XXXXXX-731e-46a2-XXXX-3495b35d99a6",
"walletId": "XXXXXX-35a2-421f-XXXX-d23149572fd7",
"reference": "Vuzr458xTg",
"senderAddress": null,
"recipientAddress": "0x79A0cd9390384XXXXXXXXX5128d4884094c",
"actualAmount": 10,
"amountPaid": 0,
"amountPaidFiat": 0,
"fiatAmount": 10,
"amountReceived": 0,
"amountReceivedFiat": 0,
"fee": 0.1,
"coin": "BUSD",
"currency": "USD",
"hash": null,
"blockNumber": null,
"type": "received",
"acceptPartialPayment": false,
"status": "pending",
"network": "testnet",
"paymentChannel": "crypto_transfer",
"blockchain": "Binance Smart Chain",
"fiatRate": 1,
"cryptoRate": 1,
"metadata": {},
"fromCoin": null,
"toCoin": null,
"createdAt": "2022-09-05T22:09:57.119Z",
"updatedAt": "2022-09-05T22:09:57.119Z"
}
]
}
],
"count": 1,
"currentPage": 1,
"nextPage": null,
"prevPage": null,
"lastPage": 1
}

Get customers by customer ID

Fetch a specific customer using its transaction id
get
https://api.lazerpay.engineering/api/v1/transactions
/:customer_id
List customer by customer Id

Sample Request: Nodejs - request

var request = require('request');
var options = {
'method': 'GET',
'url': 'https://api.lazerpay.engineering/api/v1/customers/<id>',
'headers': {
Authorization: 'Bearer SECRET_KEY',
'Content-Type': 'application/json'
}
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
{
"message": "Customer retrieved successfully",
"data": {
"id": "bc48cc84-XXXX-45e3-XXXX-6b54585ac53e",
"walletId": "33cbb77a-XXXX-XXXX-a733-d23149572fd7",
"name": "Abdulfatai Suleiman",
"email": "[email protected]",
"shippingAddress": null,
"phone": null,
"network": "testnet",
"createdAt": "2022-09-05T22:09:57.119Z",
"updatedAt": "2022-09-05T22:09:57.119Z",
"transactions": [
{
"id": "93754962-XXXX-XXXX-9858-3495b35d99a6",
"walletId": "XXXXXX-35a2-421f-XXXX-d23149572fd7",
"reference": "Vuzr458xTg",
"senderAddress": null,
"recipientAddress": "0x79A0cd9390384E3XXXXXX005128d4884094c",
"actualAmount": 10,
"amountPaid": 0,
"amountPaidFiat": 0,
"fiatAmount": 10,
"amountReceived": 0,
"amountReceivedFiat": 0,
"fee": 0.1,
"coin": "BUSD",
"currency": "USD",
"hash": null,
"blockNumber": null,
"type": "received",
"acceptPartialPayment": false,
"status": "pending",
"network": "testnet",
"paymentChannel": "crypto_transfer",
"blockchain": "Binance Smart Chain",
"fiatRate": 1,
"cryptoRate": 1,
"metadata": {},
"fromCoin": null,
"toCoin": null,
"createdAt": "2022-09-05T22:09:57.119Z",
"updatedAt": "2022-09-05T22:09:57.119Z"
}
]
},
"status": "success",
"statusCode": 200
}