Pakistan H2H Integration
API Documentation for Pakistan H2H Integration
Overview
This API allows Pakistan customers to integrate JazzCash and EasyPaisa payment methods into their applications seamlessly.
API Endpoint
POST
https://{domain}/api/request.php
Request Headers
Content-Type
application/json
Request Parameters
pid
String
Yes
Your provided PID
amount
Integer
Yes
The requested payment amount
order_id
String
Yes
Unique order identifier from your system
name
String
Yes
Customer's full name
String
Yes
Customer's email address
phone
String
Yes
Customer's phone number
pak_wallet
String
Yes
Payment wallet type. Allowed values: JAZZCASH, EASYPAISA
account_number
String
Yes
Customer's JazzCash or EasyPaisa account number (must start with '03')
Sample Request
{
"pid": "09xxxxx",
"amount": 60,
"order_id": "ORD123",
"name": "demo",
"email": "demo123@gmail.com",
"phone":"9990000000",
"pak_wallet": "JAZZCASH",
"account_number": "03333333333"
}
API Response
Success Response
{
"status": "success",
"ref_code": "a5510c2738c08f8....",
"amount": 60,
"wallet": "JAZZCASH"
}
Response Parameters
status
String
Transaction status (success
or error
)
ref_code
String
Unique reference code for the transaction
amount
Integer
Confirmed payment amount
wallet
String
Payment wallet used (JAZZCASH
or EASYPAISA
)
Error Response
{
"status": "error",
"message": "Error description"
}
Common Error Messages
pid
is required field
PID parameter is missing
amount
is required field
Amount parameter is missing
order_id
is required field
Order ID parameter is missing
We support only 'JAZZCASH', 'EASYPAISA'
Invalid pak_wallet
value
account_number
is required when pak_wallet is provided
Account number is missing when pak_wallet
is specified
Duplicate order_id
found
Oder iD already exists in the system
invalid pid
Provided PID is not valid
Important Notes
Account Number Format: The account_number must start with '03'
Last updated