API – Do Not Call
In the event that you wish to mark a particular phone number as Do Not Call, you can do this through the API or by changing the status in the UI. If you wish to make the change in the UI, reference the article Customer Phone Number for instructions on how to do so. Changing the status to Do Not Call will remove the phone number from any TCN phone calls. It can also be used to notify your employees not to contact the Customer via that method.
Changing the status of a phone to Do Not Call via the API is a 2 step process. Step 1 is to GET the phone number entity for the customer you're working with, and step 2 is to update the status to Do Not Call. The example listed below is for customer Id 308 and the phone number entity of 196. These id's will need to be replaced by the customer you are specifically working with.
Use a GET API call to pull the needed phone information from LoanPro. You will send the request to the following endpoint: https://loanpro.simnang.com/api/public/api/1/odata.svc/Customers(308)?$expand=Phones. The id referenced in the example is 308. This is the customer id, not the phone id. The response given will then provide all the id's for the phone numbers that are tied to the customer. The id of the phone number that needs to be marked as Do Not Call will be used in step 2.
Send a PUT request to set the Do Not Call setting for the customer. Send the request to the URL: https://loanpro.simnang.com/api/public/api/1/odata.svc/Customers(308). Again, use the customer id in the endpoint. In the payload you will reference the id of the phone number. In the example below, the phone id: 196.