post https://{host}/v1.1/customer/add
Registers customers in the org’s loyalty program with the primary identifier (mobile number/email id/external id).
Make sure you have the appropriate access control configured. For more information, see access group documentation.
API Behaviour
- If
CONFIG_SKIP_SECONDARY_ID_ON_PRIMARY_MISMATCH
is enabled, if the primary identifier is different but any of the secondary identifiers exist, a new customer is registered with the primary identifier ignoring the secondary identifier. The config is available on the Registration Page of InTouch Profile > Organization Settings > Miscellaneous.- Also, this config overrides
CONF_PRIMARY_IDENTIFIER_STRICT_CHECK
.
- Also, this config overrides
- Adds custom field details.
- Adds extended field values.
API endpoint
/v1.1/customer/add
Body Parameters
The mandatory attributes for customer registration depend on the configurations set on InTouch Settings > Registration Configuration. You need to know your org configurations before using this API.
Parameter | Description |
---|---|
mobile** | The mobile number of the customer. Note: For mobile numbers, add the mobile number with the country code. |
email** | The email address of the customer |
external_id** | An external identifier for the customer |
firstname | The first name of the customer |
lastname | The last name of the customer |
updated_on | The date and time the customer was last updated |
registered_till | The registration validity of the customer |
associated_with | What or whom the customer is associated with |
type | The type of customer |
fraud_status | The fraud status of the customer |
City_name (custom field) | The city where the customer resides |
address (custom field) | The address of the customer |
bde_mobile_number (custom field) | The mobile number of the BDE associated with the customer |
bde_name (custom field) | The name of the BDE associated with the customer |
firm_name (custom field) | The name of the firm associated with the customer |
club (custom field) | The club associated with the customer |
pincode (custom field) | The pin code of the customer's address |
pwgConsumption (custom field) | The PWG consumption status of the customer. |
state (custom field) | The state where the customer resides. |
profile_image_name (custom field) | The name of the customer's profile image file. |
**
To add a customer, you must provide at least one of the parameters marked with **
Response Parameters
Parameter | Description |
---|---|
status.success | Indicates the success of the operation |
status.code | The code representing the status of the operation |
status.message | The message describing the status of the operation |
status.total | The total count in the response |
status.success_count | The count of successful operations |
customer.user_id | The unique identifier for the customer |
customer.firstname | The first name of the customer |
customer.lastname | The last name of the customer |
customer.mobile | The mobile number of the customer |
customer.email | The email address of the customer |
customer.external_id | An external identifier for the customer |
customer.lifetime_points | The total lifetime points accumulated by the customer |
customer.loyalty_points | The current loyalty points of the customer |
customer.current_slab | The current slab of the customer in the loyalty program |
customer.tier_expiry_date | The expiry date of the customer's current tier |
points_summary.programId | The ID of the program associated with the points summary |
points_summary.redeemed | The number of points redeemed |
points_summary.expired | The number of points expired |
points_summary.returned | The number of points returned |
points_summary.adjusted | The number of points adjusted |
points_summary.lifetimePoints | The lifetime points in the summary |
points_summary.loyaltyPoints | The loyalty points in the summary |
points_summary.cumulativePurchases | The cumulative purchases in the summary |
points_summary.currentSlab | The current slab in the points summary |
points_summary.slabSNo | The serial number of the slab |
points_summary.slabExpiryDate | The expiry date of the slab |
customer.lifetime_purchases | The total lifetime purchases made by the customer |
customer.registered_on | The date and time when the customer registered |
customer.updated_on | The date and time when the customer's information was last updated |
customer.type | The type of customer |
customer.source | The source through which the customer was acquired |
customer.fraud_status | The fraud status of the customer |
customer.reason | The reason field (not populated in this response) |
item_status.success | Indicates the success of the customer item operation |
item_status.code | The code representing the status of the customer item operation |
item_status.message | The message describing the status of the customer item operation |
item_status.warnings.warning | Warning codes associated with the operation |