API Documentation
Simulate Webhooks
1 min
below api can be used to simulate the webhooks which are triggered by pay3's system webhooks are sent to the api endpoint shared during client onboarding in the webhooks docid zgiyfgasxs2uqr272qa format this api can be used for testing the back end of client application asynchronously even when order is not being performed from ui the list for possible statuses can be found webhooks docid zgiyfgasxs2uqr272qa note this does not create any state changes or orders in pay3's system { "name" "simulate webhook", "method" "post", "url" "https //your hostname pay3 app/v1/client/simulate webhook", "description" "simulate receiving webhook data", "tab" "examples", "examples" { "languages" \[ { "id" "9tlb3mnzidcgfdo fqrsd", "language" "curl", "code" "curl location 'https //your hostname pay3 app/v1/client/simulate webhook' \\\\\n header 'access token dynamic access token' \\\\\n header 'content type application/json' \\\\\n data '{\n \\"requestid\\" \\"bc77de4c 9b63 4e3b ab3e 9c509518dcf3\\",\n \\"clientid\\" \\"320f1376 84b7 4d80 8358 bcb97c9d43a8\\",\n \\"orderid\\" \\"10520f5d 6c20 481f b17e 01e1ed1e75bb\\",\n \\"orderstatus\\" \\"failed\\",\n \\"ordertype\\" \\"checkout\\",\n \\"eventtype\\" \\"pay3 sdk transaction status\\",\n \\"errorcode\\" \\"9005\\"\n}'", "customlabel" "" } ], "selectedlanguageid" "9tlb3mnzidcgfdo fqrsd" }, "results" { "languages" \[ { "id" "gje7dlzgkif9oesgwexqf", "language" "200", "customlabel" "", "code" "{\n \\"message\\" \\"webhook simulated successfully\\"\n}" } ], "selectedlanguageid" "gje7dlzgkif9oesgwexqf" }, "request" { "pathparameters" \[], "queryparameters" \[], "headerparameters" \[ { "name" "access token", "kind" "required", "type" "string", "description" "access token received from access token api you can reuse the access token across multiple api calls till it is expired ", "children" \[] } ], "bodydataparameters" \[ { "name" "requestid", "kind" "required", "type" "string", "description" "identifier that is created by application's backend " }, { "name" "clientid", "kind" "required", "type" "string", "description" "client id application's identifier", "children" \[] }, { "name" "orderid", "kind" "required", "type" "string", "description" "this is the unique identifier in pay3's system this is equivalent to token shared in create order api's response ", "children" \[] }, { "name" "orderstatus", "kind" "required", "type" "string", "description" "this is the status for which you want to simulate webhook for you will be receiving webhook data corresponding to this status", "children" \[] }, { "name" "ordertype", "kind" "required", "type" "string", "description" "this represents the order type for which you want to simulate webhook it can be checkout, payout etc ", "children" \[] }, { "name" "eventtype", "kind" "required", "type" "string", "description" "this respresents the event type field, which is received in webhook it should be passed as \n\npay3 sdk transaction status for payment related webhooks\n\npay3 sdk login status for easy sign related webhooks", "children" \[] }, { "name" "errorcode", "kind" "optional", "type" "string", "description" "this param accepts any one errorcode defined in sdk errors", "children" \[] } ], "formdataparameters" \[] }, "currentnewparameter" { "label" "body parameter", "value" "bodydataparameters" } }