Get Customer API

This is a Server-to-Server API which retrieves the customer entity for a given identifier, allowing verification of the customer's existence in the Juspay system. This API retrieves all customer-related information, including first name, last name, mobile number, email address (as provided during the Create Customer API call), along with the customer creation date and the last updated date of the customer details.

API Endpoints
Sandbox Link
GET
https://sandbox.juspay.in/customers/{customer_id}
Production Link
GET
https://api.juspay.in/customers/{customer_id}
Authorization Header
Headers
Path Params
200 : Success
401 : Authentication Failed
404 : Not Found

Error Codes

Scroll inside to view more
Scenario
Error Codes
Description
Sample Error Message
Checking for random customer_id value
404
Not Found
{"error_message": "Cannot find what you are looking for","status": "invalid_request_error","error_code": "object_not_found","error_info": {"user_message": "Cannot process your request as customer account not found.","developer_message": "Customer account not found.","code": "RESOURCE_NOT_FOUND","category": "USER_ERROR"}}
Whitelisting of IP in dashboard
403
IP Verification Failed
{"error":true,"error_message":"Internal Server error.","user_message":"Bad Origin.","error_info":{"code":"BAD_ORIGIN","category":"USER_ERROR","user_message":"Bad Origin.","developer_message":"IP Verification Failed"}}
Wrong API Key
401
Unauthorized
{"status":"error","error_code":"access_denied","error_info": {"user_message":"Unauthorized.","developer_message":"Invalid API Key. Please pass a valid and active api key.","code":"UNAUTHORIZED","category":"USER_ERROR"}}
Wrong API endpoint
404
Not Found