Bill Query & Payment Confirmation API

Endpoints for Education, ISP and Insurance bill query and payment confirmation — JSON over HTTPS.

Authentication

Headers required
Header KeyValue / Notes
API-KEYWill be generated by the API provider and configured at SSLCOMMERZ end(required)
AuthorizationBearer <token> (optional if API-KEY used)
Content-Typeapplication/json

1. Bill Query

POST /api/v1/bill/query

Request Body (common)

FieldTypeRequiredDescription
service_typestringoptionalOne of education, isp, insurance
amountnumberoptionalIf known. Query allowed without it.
reference_idstringYesThis information will be used to identify the payee and the outstanding bill on your end.
mobile_nostringrequired for education & ispMSISDN (e.g. 01XXXXXXXXX)
dobstring (YYYY-MM-DD)optionalif applicable at your end
bill_monthstring (YYYY-MM)optionalBilling month if applicable.

Service-specific fields

  • Education: reference_id could be student_id (string)
  • ISP: reference_id could be the customer_no (string)
  • Insurance: reference_id could be the proposal_number (string)
Sample Request — Education
{
  "service_type": "education",
  "reference_id": "STU123456",
  "bill_month": "2025-09",
  "mobile_no": "01712345678",
  "dob": "2008-10-02"
}
Sample Response — Education
{
  "status": "success",
  "message": "Bill Found",
  "data": {
    "name": "Rahim Uddin",
    "reference_id": "STU123456",
    "bill_month": "2025-09",
    "amount_due": 5000,
    "due_date": "2025-10-15",
    "transaction_id": "TXN548257"
  }
}
Sample Request — ISP
{
  "service_type": "isp",
  "reference_id": "CUST89011",
  "mobile_no": "01898765432"
}
Sample Response — ISP
{
  "status": "success",
  "message": "Bill Found",
  "data": {
    "name": "XYZ Internet Client",
    "reference_id": "ISP123456",    
    "package": "50 Mbps",
    "amount_due": 1500,
    "billing_cycle": "2025-10",
    "transaction_id": "TXN548257"
  }
}
Sample Request — Insurance
{
  "service_type": "insurance",
  "reference_id": "PROP112233",
  "amount": 7000
}
Sample Response — Insurance
{
  "status": "success",
  "message": "Premium Due",
  "data": {
    "name": "Abdul Karim",
    "reference_id": "INS123456",    
    "amount_due": 7000,
    "due_date": "2025-11-30",
    "transaction_id": "TXN548257"
  }
}

Reponse Body (common)

FieldTypeRequiredDescription
namestringoptionalThe customer name could be a student, an ISP user, or a policyholder based on your service.
amount_duenumberYesThe amount will be collected through the payment gateway.
reference_idstringYesThis information will be used to identify the payee and the outstanding bill on your end. Your system must have the capability to process the due bill based on this parameter.
transaction_idstringYesIt will be the unique ID that will be used by the payment gateway at the time of payment.

2. Payment Confirmation

POST /api/v1/bill/payment/confirm

Request Body

{
  "transaction_id": "TXN548257",
  "payment_approval_id": "APP548257",  
  "reference_id": "STU123456",
  "amount": 5000
}
Sample Response — Confirm
{
  "status": "success",
  "message": "Payment Confirmed",
  "confirmation_id": "CONF987654321",
  "transaction_id": "TXN548257",
  "payment_approval_id": "APP548257",    
  "data": {
    "service_type": "education",
    "amount": 5000
  }
}

3. Payment Confirmation Status

POST /api/v1/bill/payment/status

Request Body

{
  "transaction_id": "TXN548257",
  "reference_id": "STU123456",
  "amount": 5000,
  "mobile_no": "01712345678"
}
Sample Response — Confirm
{
  "status": "success",
  "message": "Payment Success",
  "confirmation_id": "CONF987654321",
  "transaction_id": "TXN548257",
  "payment_approval_id": "APP548257",   
  "details": {
    "service_type": "education",
    "amount": 5000
  }
}

Error Responses & Status Codes

{
  "status": "failed",
  "error_code": "BILL_NOT_FOUND",
  "message": "No bill available for provided information"
}

Status Codes:
200 - Success
400 - Invalid Request
404 - Bill Not Found
500 - Internal Server Error

Notes & Recommendations