Get Customer API
The Get Customer API will help you in getting the list of existing customer details in the Kapture Database.
Get Customer.
POST
https://devapi.kapturecrm.com/search-customer-by-customer-id.html
Authentication:
To access this API endpoint, you need to include your API key in the request headers. For authentication, use the following header:
Basic <Your Token>
Request Body
The request body should be a JSON object containing the details of the customer to be fetched. Here are the list of parameters. Note: Either of kapture_customer_id,email_id or phone is mandatory to fetch data.
kapture_customer_id
Yes
Number
The Id of the customer which is generated in Kapture Database
email_id
No
String
Email Address of the customer
phone
No
Number
Phone number of the customer
[
{
"kapture_customer_id": "191121684",
"email_id": "[email protected]",
"phone": "1234567890"
}
]
Response Body
The API responds with a JSON object containing the details of the updated customer. If successful, the response will include the customer ID and the other relevant information.
{ ..., "status": "success"}
Customer data pushed successfully.
{"message": "Invalid Auth Key","status": "failed"}
Authorization key is either not passed in header, or incorrect, or expired/disabled
{"Customer Details": "Information given by you does not exist in our sytsem.","status": "failed"}
Details provided doesn't match with records available in the system.
{
"Customer Details": {
"id": 191121684,
"cmId": 1000298,
"isOrganization": true,
"name": "Sashank",
"website": "",
"address": " ",
"state": "",
"city": "",
"country": "",
"latitude": "",
"longitude": "",
"currentStatus": "N",
"generationDate": "May 2, 2024 4:15:42 PM",
"creatorId": 0,
"channelPartnerId": 0,
"remarks": "",
"ratePlanId": 0,
"customerCode": "",
"isChannelPartner": false,
"pinCode": "",
"campaignId": 0,
"campaignItemId": 0,
"campaignActivityId": 0,
"totalNoOfEnquiries": 1,
"feedbackOnCustomer": "0",
"contacts": [
{
"id": 209432475,
"cmId": 1000298,
"leadId": 191121684,
"contactPerson": "Sashank",
"gender": " ",
"phone": "9380491326",
"additionalPhone": "",
"email": "[email protected]",
"isPrimaryContact": true,
"isActive": true,
"generationDate": {
"year": 2024,
"month": 4,
"dayOfMonth": 2,
"hourOfDay": 16,
"minute": 15,
"second": 42
},
"parentContactId": 0,
"subOfficeId": 0,
"creatorId": 0,
"age": 0,
"maritalStatus": " ",
"isGuest": false,
"phoneCountryCode": "",
"enquiryId": 0,
"orderId": 0,
"isMergeEnable": false,
"isMobileMasked": false,
"isEmailMasked": false,
"showBirthYear": false
}
],
"imageReferenceId": "CUS_2024-05-02 16:15:42.249",
"classification": "",
"customerType": "",
"customerLevel": 0,
"zone": 0,
"companyParentId": 0,
"assignedToId": 0,
"maxCreditAmt": 0.0,
"maxCreditPeriod": 0,
"historyEmpId": 0,
"channelPartnerEmpId": 0,
"deleted": false,
"companyStatus": "A",
"isExistingCustomer": false,
"isExistingContact": false,
"syncStatus": false,
"syncdLocationId": "0",
"crossRemarks": "",
"syncedStepNumber": 0,
"outStandingAmount": 0.0,
"salesAdminZone": 0,
"referralId": 0,
"isApi": false
},
"status": "success"
}
Error Codes
400
Bad Request - Invalid parameters or missing data
401
Unauthorized - Invalid or missing API key
403
Forbidden - Insufficient permissions
404
Not Found - Resource or endpoint not found
500
Internal Server Error - Server-side issue
Example of a working curl
curl --location 'https://devapi.kapturecrm.com/search-customer-by-customer-id.html' \
--header 'Authorization: Basic <Your Token>' \
--header 'Content-Type: application/json' \
--header 'Cookie: JSESSIONID=; _KAPTURECRM_SESSION=' \
--data-raw '[
{
"kapture_customer_id": "191121684",
"email_id": "[email protected]",
"phone": "1234567890"
}
]'
Last updated
Was this helpful?