NICTBD API · v1

Bill Payment API integration

View the live integration contract: catalog, signed order creation, order status and signed IPN delivery. Merchant access requires an enabled Webhook URL. Individual services may remain unavailable until the administrator enables them.

01

Base URL and authorization

https://gigora.com.bd

Create your NICT Store ID, API Key and API Secret in the merchant panel. Save and enable a public HTTPS Webhook/IPN URL before making any API request.

Accept: application/json
Content-Type: application/json
X-Store-ID: YOUR_STORE_ID
X-API-Key: YOUR_API_KEY
X-Timestamp: UNIX_SECONDS
X-Nonce: UNIQUE_RANDOM_16_TO_80_CHARS
X-Signature: LOWERCASE_SHA256_HMAC_HEX

METHOD is uppercase; PATH is the exact request path without host/query parameters; hash the exact UTF-8 body bytes. GET requests use SHA256 of an empty body. The timestamp must be within 300 seconds; never reuse a nonce.

bodyHash = SHA256_HEX(rawBody)
canonical = timestamp + "\n" + nonce + "\n" + METHOD + "\n" + PATH + "\n" + bodyHash
X-Signature = HMAC_SHA256_HEX(canonical, API_SECRET)
02

Endpoints

GET/api/services/v1/bill/catalogActive catalog (service IDs)
GET/api/services/v1/bill/ordersList your orders
POST/api/services/v1/bill/ordersCreate order
GET/api/services/v1/bill/orders/{orderRef}Read final/current order status

Every call requires the signed headers above, including catalog and status requests.

03

Order request JSON

Fetch catalog first: each bill service defines fields_json, account requirements, amount limits, provider and charge. The meter field name can vary (e.g. metter_number). Send all required fields exactly as returned by the catalog. If contact_number is listed, submit the customer's phone; the administrator's settings determine which number is used for device processing.

POST /api/services/v1/bill/orders
{
  "service_id": 123,
  "account_number": "METER_NUMBER_HERE",
  "details": {
    "metter_number": "METER_NUMBER_HERE",
    "contact_number": "01XXXXXXXXX"
  },
  "amount": "300.00",
  "idempotency_key": "BILL_20261124_000001"
}

idempotency_key is 16–80 characters (letters, digits, underscores or hyphens), unique per new order. Reusing an existing key with different details will fail. The service_id is only an example; get the real ID from catalog.

04

Response and status

HTTP 202 Accepted
{
  "success": true,
  "order_ref": "EXAMPLE123",
  "kind": "bill",
  "status": "processing",
  "amount": "100.00",
  "commission": "0.00",
  "fee": "0.00",
  "wallet_debit": "100.00"
}

Response amounts are illustrative; actual values come from your configured service. processing is not a successful payment. Check status with the exact returned order_ref or wait for the signed IPN.

pendingprocessingreviewpaidsuccesscancelledfailed

Typical errors: 401 invalid credentials/signature, 403 webhook not configured or merchant unavailable, 409 repeated nonce, 422 invalid service/amount/fields or insufficient funds.

05

Webhook / IPN verification

When an order reaches final settlement, your enabled HTTPS webhook receives a server-to-server POST. Return a successful 2xx response after validating the signature and processing the event idempotently.

X-NICT-Event-ID: UUID
X-NICT-Timestamp: UNIX_SECONDS
X-NICT-Signature: sha256=HEX_HMAC

expected = HMAC_SHA256_HEX(timestamp + "." + rawWebhookBody, WEBHOOK_SECRET)

{
  "event_id": "UUID",
  "event": "service.order.completed",
  "data": {
    "order_ref": "EXAMPLE123",
    "kind": "bill",
    "status": "success",
    "transaction_id": "PROVIDER_TRX_ID"
  }
}

Use the webhook secret configured in your merchant panel, not the API secret, for incoming IPN signature verification. Handle duplicate delivery attempts.