The diagram illustrates system interactions between the merchant and PhonePe for initiating a credit to the customer.
A payment has following flow:
Merchant calls the Send OTP API with the user's mobile number. PhonePe server will trigger the OTP to the received mobile number. Then, the user will enter the received OTP and Merchant should call Verify OTP API to validate. On Successful validation, merchants will receive the User Auth Token in response.
Fetch Credit Options API:
With the received token, merchants call the Credit Payment Options API. In response, the available payment options for that user will be returned and merchants should display it to the user.
Once the user selects the option displayed in UI, merchant does a server to server call to initiate payment request (Pay Credit API).
If the user selects the VPA Address, then the merchant will call the Validate VPA API to check whether the user entered VPA address is valid or not.
Merchant checks the transaction status using the Check transaction status API and verifies the amount in the response. The order is then placed based on the transaction status provided by PhonePe.
Updated about 1 year ago