logo
POST/api/v1/create/qr

Create Qr Code

Endpoints for creating QR codes for customer payments. Merchants use these APIs to initiate payment requests and generate secure QR codes. Customers are redirected to these pages to complete payments via their financial institution.

Authentication

Requires the following headers:

app-id: Your application identifier (from Account Management → Generate API Key → APP id)
api-key: Your secret API key (from Account Management → Generate API Key → API Keys)

Request Processing

  • Verifies required fields (pin)
  • Validates Credentials
  • Generates a unique payment reference
  • Creates secure Payment Link URL

Parameters

pinstringRequired

Manager pin to create the QR code

Response

Returns JSON containing:

  • Payment reference ID
  • Payment Link URL for customer redirection
  • Initial transaction status

Payment Flow

  1. Customer completes payment via the provided payment_link
  2. QR code generated can be used again for payments

Important Notes

  • PIN: Must be 6 digits and valid

Error Handling

Returns 400 status code for:

  • Missing required fields
Error Response Example
{
    "pin": [
        "This field may not be blank."
    ]
}

Code Examples

Request
curl -X POST "{base_url}/api/v1/create/qr" \
  -H "Content-Type: application/json" \
  -H "app-id: YOUR_APP_ID" \
  -H "api-key: YOUR_API_KEY" \
  -d '{
  "pin": "000000"
}'

Response Examples

200 - OK
Example Value
{
    "id": "5BV000JKCC",
    "status": "PROCESSED",
    "status_code": 200,
    "payment_link": "https://checkout.beqelal.net//#/qr/payment/00ed4c0c-0000-0000-b962-50fb40bd59d2"
}
400 - Bad Request

e.g., Wrong PIN

Example Value
{
  "error": {
    "status": "FAILED",
    "status_code": "423",
    "message": "INVALID_PIN",
    "detail": "Wrong PIN, please try again."
  }
}
479 - Unauthorized IP

Request from IP not whitelisted in Merchant Portal

Example Value
{
  "error": {
    "status": "FAILED",
    "status_code": "479",
    "message": "UNAUTHORIZED_IP_ACCESS",
    "detail": "Unauthorized IP address access."
  }
}