Prerequisites
Before you start using the payment gateway you must upgrade your account to a commercial account to get your key to use our payment portal.
How do I upgrade my account to a merchant account?
Log in to https://cms.reach2pay.com/ar/cms/user/auth/login with your login credentials.
Going to Settings > Transfer to Business Account .
Fill in the required data from you
Fill in KYC file.
Click Submit.
Admission application approval
After the application approval go to Settings
Going to Settings > Business Account Information > Copy your keys.
How does the R2P payment gateway work?
• A special session is created for your payment process
• After verifying the authenticity of your data, a transfer link for the application process will be sent
• You convert the user to the conversion link you have been provided with
• The gateway will complete the payment at the required amount of the order.
• The user return to your store with the status of the operation success or failure
Initiate a Checkout Session
POST
https://test.getway.reach2pay.com/api/v1/payment/getway/create/session
You must create a payment session to complete the payment process to verify your data and requests. Enter the details of the session you want to create. Send the session data in your Request Body consisting of:
• Value of order amount
• Your own reply Link
• Through your reply link the order and session cases will be sent to you after the process is successfully completed or the customer is returned to your store
• Through your reply link the order and session cases will be sent to you after the process is successfully completed or the customer is returned to your store
• The currency of the operation (IQD) is mandatory and there are no other currency
• Add data and add any information you want in this process and if there is non, send it blank
• Note : You must send Client Key & Secret Key at Hyder to distinguish your store and verify who you are to create a session for your store, to bring your private information Client Key & Secret Key You must
Request Header Sample
Accept: application/json ClientKey: YOUR_CLIENT_KEY SecretKey: YOUR_SECRET_KEY
Request Body Sample
{ "amount" : 100, "url_callback" : YOUR_CALLBAK_URL, "extra_data" : "[]", "currency_code" : "IQD", "order_id" : "23552123" }
Response Sample
{ "status": true, "message": "Successfully create session for this transaction", "data": { "code": "Pay-20231003-4320", "amount": 100, "order_id": "2355121233", "currency_code": "IQD", "extra": [], "signature": "0cb4539e-6860-4ef7-b4a7-db41f5954791", "redirectUrl": "https://test.getway.reach2pay.com/payment/getway/redirect?signature=0cb4539e-6860-4ef7-b4a7-db41f5954791&transactionId=Pay-20231003-4320" } }
Response
After submitting your information and requesting the session, you will gets a response containing the data you entered as well as the transfer link to the payment gateway to complete the process containing:
• The code is your payment number
• The amount of this order
• The currency_code is the payment currency on which the transaction will be made
• signature, a distinctive symbol of this process
redirectUrl Transfer Link for transaction completion.
Access to all your past and ongoing operations
GET
https://test.getway.reach2pay.com/api/v1/payment/getway/sessions
Sessions
Through this section you monitor all payments that are currently made or made in advance of your store and monitor their progress , This End Point brings all your sessions with their status (cancellation, waiting, success, failure)
Request Header Sample
Accept: application/json ClientKey: YOUR_CLIENT_KEY SecretKey: YOUR_SECRET_KEY
Response Sample
{ "status": true, "message": "Retrieved successfully", "data": [ { "status": "cancel", "code": "Pay-20230913-8303", "signature": "0cb4539e-6860-4ed7-b9a8-db41f5964890", "order_id": "Order-33333", "amount": 100, "currency_code": "IQD", "extra_data": [] }, { "status": "success", "code": "Pay-20230914-9114", "signature": "0cb4539e-6860-4ef7-b4a7-db4115d954791", "order_id": "Order-333321", "amount": 100000, "currency_code": "IQD", "extra_data": [] }, { "status": "pending", "code": "Pay-20231003-4320", "signature": "0cb4539e-6860-4ef7-b4a7-dh412323431", "order_id": "2355121233", "amount": 100, "currency_code": "IQD", "extra_data": [] } ] }
Session By Signature
GET
https://test.getway.reach2pay.com/api/v1/payment/getway/sessions/signature/SIGNATURE_SESSION
Sessions By Signature
You can use this endpoint to access a particular process using the process "SIGNATURE" of the process you want to access
Request Header Sample
Accept: application/json ClientKey: YOUR_CLIENT_KEY SecretKey: YOUR_SECRET_KEY
Response Sample
{ "status": true, "message": "Retrieved successfully", "data": { "status": "cancel", "code": "Pay-20230913-8303", "signature": "0cb4539e-6860-4ed7-b9a8-db41f5964890", "order_id": "Order-33333", "amount": 100, "currency_code": "IQD", "extra_data": [] } }
Session By Status
GET
https://test.getway.reach2pay.com/api/v1/payment/getway/sessions/status/STATUS
Sessions By Status
Through this endpoint you can access all operations by the status of the operation from success or failure etc.. Here are the cases you can use.
• success
• faild
• cancel
• pending
Request Header Sample
Accept: application/json ClientKey: YOUR_CLIENT_KEY SecretKey: YOUR_SECRET_KEY
Response Sample
{ "status": true, "message": "Retrieved successfully", "data": [ { "status": "cancel", "code": "Pay-20230913-8303", "signature": "0cb4539e-6860-4ed7-b9a8-db41f5964890", "order_id": "Order-33333", "amount": 100, "currency_code": "IQD", "extra_data": [] }, { "status": "cancel", "code": "Pay-20230913-8303", "signature": "0cb4539e-6860-4ed7-b9a8-db41f5964890", "order_id": "Order-33333", "amount": 100, "currency_code": "IQD", "extra_data": [] } ] }
All Transactions
GET
https://test.getway.reach2pay.com/api/v1/payment/getway/transactions
Transactions
Through this section you monitor all payments made on your store and the specific cases of success, failure and cancellation of these transactions , You bring all the operations made on your store in all the specific cases of the operation where you explain the details of the process .
Request Header Sample
Accept: application/json ClientKey: YOUR_CLIENT_KEY SecretKey: YOUR_SECRET_KEY
Response Sample
{ "status": true, "message": "Retrieved successfully", "data": [ { "id": 2, "code": "Pay-20230918-2252", "orderId": "Order-333341", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11019786.72 } }, { "id": 3, "code": "Pay-20230918-8214", "orderId": "Order-333311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 0, "vendor_wallet_balance_after": 11310 } }, { "id": 4, "code": "Pay-20230918-5880", "orderId": "Order-333311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11019786.72 } }, { "id": 5, "code": "Pay-20230918-8115", "orderId": "Order-3323311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11019786.72 } }, { "id": 6, "code": "Pay-20230918-9415", "orderId": "Order-33233311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": -88590, "fees": 88690, "amount_without_fee": 100, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 10919886.72 } }, { "id": 7, "code": "Pay-20230918-4280", "orderId": "Order-233233311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 78, "fees": 22, "amount_without_fee": 100, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11008554.72 } }, { "id": 8, "code": "Pay-20230918-4280", "orderId": "Order-233233311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 78, "fees": 22, "amount_without_fee": 100, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11008554.72 } }, { "id": 9, "code": "Pay-20230918-2016", "orderId": "Order-23321", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 78, "fees": 22, "amount_without_fee": 100, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11008554.72 } } ] }
Transactions By Id
GET
https://test.getway.reach2pay.com/api/v1/payment/getway/transactions/:id
Transactions By Id
It brings the process according to the ID of this process and shows its case individually and its information
Request Header Sample
Accept: application/json ClientKey: YOUR_CLIENT_KEY SecretKey: YOUR_SECRET_KEY
Response Sample
{ "status": true, "message": "Retrieved successfully", "data": { "id": 4, "code": "Pay-20230918-5880", "orderId": "Order-333311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11019786.72 } } }
Session By Status
GET
https://test.getway.reach2pay.com/api/v1/payment/getway/transactions/status/STATUS
Transactions By Status
It brings all the processes according to the status you are looking for to you the cases you can search using
• success
• faild
• cancel
• pending
Request Header Sample
Accept: application/json ClientKey: YOUR_CLIENT_KEY SecretKey: YOUR_SECRET_KEY
Response Sample
{ "status": true, "message": "Retrieved successfully", "data": [ { "id": 2, "code": "Pay-20230918-2252", "orderId": "Order-333341", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11019786.72 } }, { "id": 3, "code": "Pay-20230918-8214", "orderId": "Order-333311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 0, "vendor_wallet_balance_after": 11310 } }, { "id": 4, "code": "Pay-20230918-5880", "orderId": "Order-333311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11019786.72 } }, { "id": 5, "code": "Pay-20230918-8115", "orderId": "Order-3323311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 11310, "fees": 88690, "amount_without_fee": 100000, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11019786.72 } }, { "id": 6, "code": "Pay-20230918-9415", "orderId": "Order-33233311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": -88590, "fees": 88690, "amount_without_fee": 100, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 10919886.72 } }, { "id": 7, "code": "Pay-20230918-4280", "orderId": "Order-233233311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 78, "fees": 22, "amount_without_fee": 100, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11008554.72 } }, { "id": 8, "code": "Pay-20230918-4280", "orderId": "Order-233233311", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 78, "fees": 22, "amount_without_fee": 100, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11008554.72 } }, { "id": 9, "code": "Pay-20230918-2016", "orderId": "Order-23321", "status": "pending", "extra_data": [], "user_fullName": "Ahmad Nahal", "user_mobile": "0592146781", "amount_details": { "currency": "IQD", "amount": 78, "fees": 22, "amount_without_fee": 100, "vendor_wallet_balance_before": 11008476.72, "vendor_wallet_balance_after": 11008554.72 } } ] }