Whenever Distributor hits the Live Buy Price API to query the live price, along with the Buy Price, SafeGold will send “rate_id” and “rate_validity” parameters in the response.
rate_id represents an ID assigned to a particular rate when the buy price was queried. So when the customer comes on the Landing page of Buy on the website/app, the live buy price will be queried from SafeGold by the Distributor. SafeGold will send the live buy gold rate, a rate_id associated with the particular rate, and the validity time till which the rate will be valid. The rate would be valid for “7 minutes” on SafeGold’s side.
The distributor would send the rate_id in the Buy Verify API instead of the gold rate and SafeGold will check whether the rate has expired or not. If the rate has not expired and all other validations are true, SafeGold will create a transaction ID and send it as a response.
The Current Gold price published by SafeGold
The applicable GST percentage
The rate ID corresponds to the live rate sent in the response.
The time till which the rate will be valid for. On SafeGold’s side, the validity time would be for 7 minutes.
HTTP Status 500
Service is not functioning
For creating a transaction, the Distributor will call the Buy Verify API bypassing the User ID which was generated during the registration of the particular customer in the URL.
Points to Remember -
- The Buy Price API generates a new buying price for the customers to buy digital gold which is derived from the real-time market. The newly generated price is only valid for few minutes (validity limit is present in the response of the API).
- The current_price in the response should be copied and pasted in the sg_rate parameter of the Buy Verify API for initiating a valid transaction.