Home Pulse : How upgrade customer API works
The document defines the steps how a upgrade model works. Following questions will be answered in this document.
Â
1.What triggers the API to run
On the ERP system we have two options to verify the upgrade eligibility for the customers.
Use Upgrade Model
In the form, if a checkbox titled as “use DW algorithm for upgrade criteria“ is checked, this will trigger the API to run.
Use ERP Prams
2. The end points of the API
The endpoint to verify the customer eligibility is given below, where you can pass the unique_customer_id as parameter
https://data-api-dev.bboxx.co.uk/user/upgarde/customer/unique_customer_id
If the checkbox in unchecked, than system will be using the ERP data to check the customer upgrade status. From the ERP we received two parameters.
Upgrade status (Boolean)
Minimum CP for Upgrades(%) , This parameter managed in ERP and should be above to 80% for valid customer upgrade.
3. What data is retrieved in the API
On the API, we pass unique_customer_id, in the response we receive data object with following customer personal details.
bboxx_shop_erp_id
bboxx_Shop_name
customer_full_name
customer_gender
customer_phone_1
customer_phone_2
install_address_physical_location
prediction_datetime
sales_agent_bboxx_id
sales_agent_id
scores
unique_customer_id
Â
On the API. the data will be only received if their credit check is passed. On the daily basis, a crone job is scheduled, which takes all the customers, filter out the customers with credit check (if credit check is passed) and dump these customers data in the table.
When system calls the upgrade customer API, It scans the table with the unique_customer_id and gives response either customer is eligible for the upgrade or not.
Â
What data in the API is used by the front end?
No data is being used on the frontend. On the frontend they checks if data object length is greater than 0, it means API gets the response for this customer, so the system allows to upgrade this customer.
Â
How does this data impact the front end Are there any limitations to the API?
Based on the API response, system decides the customer upgrade, as on the front end no data is published/printed, received from the API.
Â