Everything you need to connect 16Pay to your business.
Use these guides, API references and sample requests to create payment links, verify transactions and connect your website or application with 16Pay Payment Gateway.
Welcome to 16Pay Docs Developer reference
16Pay helps merchants accept payments through configured payment methods and merchant accounts. Customers are redirected securely to complete their payment, and once the payment is finished, your website receives the status and transaction details for further processing.
Introduction
Understand how 16Pay works, what information you need, and how the payment flow connects your website to the gateway.
API Reference
Find API endpoints, headers, parameters and response details for payment creation and payment verification.
Integration Guides
Use sample requests, code snippets and verify calls to integrate your PHP, Laravel, WordPress or other applications.
API Reference
16Pay supports secure REST API calls for payment creation and payment verification. Use your API-KEY, SECRET-KEY and BRAND-KEY in the request headers to authenticate requests.
API Endpoints
Use the create endpoint to generate a payment link for your customer, and the verify endpoint to confirm a transaction after payment completion.
Create Payment URL
https://pay.16bazar.com/api/payment/create
Verify Payment
https://pay.16bazar.com/api/payment/verify
Your server should support cURL or any HTTP client. During testing, use your test credentials. For production, switch to live credentials and live merchant configuration.
Parameters & Headers
Required fields for creating a payment URL
Field Name
Description
Required
Example Value
cus_name
Customer full name
Yes
John Doe
cus_email
Email address of the customer
Yes
john@gmail.com
amount
The total amount payable
Yes
10 or 10.50
success_url
Where the customer will return after successful payment
Yes
https://yourdomain.com/success
cancel_url
Where the customer will return if the payment is cancelled or fails
Yes
https://yourdomain.com/cancel
metadata
Optional JSON formatted additional data
No
{"phone":"016****"}
Required field for payment verification
Field Name
Description
Required
Example Value
transaction_id
Transaction ID received after payment completion
Yes
OVKPXW165414
Required headers
Header Name
Value
Content-Type
application/json
API-KEY
App key from API credentials
SECRET-KEY
Secret key from API credentials
BRAND-KEY
Brand key from Brands
Integration Guides
Use the examples below to generate a payment URL and then verify the transaction status from your website or application.
Sample Requests
Review payment creation examples with PHP, Guzzle, Node.js, Python and Native code samples.
Verify Payments
Use the verify endpoint to fetch transaction details and confirm the final payment status.
After the payment page task is completed, your success or cancel URL may receive parameters like: transactionId, paymentMethod, paymentAmount, paymentFee and status.