Endpoint Reference

Base URL: https://guarantorpay.ng/api/v1 · All bodies and responses are JSON · All authenticated routes require Authorization: Bearer and Accept: application/json.

Identity

GET/me

Connectivity probe. Returns your merchant identity, scopes, test-mode flag.

{
  "merchant": { "serial": 20, "name": "ACME Retail", "organisation": "ACME RETAIL LTD",
               "status": "active", "test_mode": false, "sees_pending": true },
  "scopes": ["read","transactions","registration"]
}

Eligibility

GET/eligibility

Query paramTypeRequired
customer_numberstringyes — the customer's payroll number
amountnumber (Naira, GP-covered)no
repayment_periodint 1–12 (months)with amount

Without an amount → buyer's available headroom. With amount + period → the same eligibility gates the transaction will pass (GP's own limit, salary-data verification, retirement, account verification), plus the full cost math.

{
  "eligible": true,
  "amount": 10000,
  "repayment_period": 3,
  "charges_total": 1050,
  "monthly_installment": 3683.33,
  "total_amount_expected": 11050,
  "max_amount": 61656.19,
  "monthly_max": 61656.19
}

Declines come back with a machine code + human message, e.g. "reason": "SALARY_GATE_BLOCKED". A declined pre-check means the create call will decline too — show another payment method.

Transactions

POST/transactions

Creates the GP payment. Idempotent per merchant_reference.

FieldTypeRule
customer_numberstringrequired — the customer's payroll number, must exist in GP
amountnumberrequired > 0 — the GP-covered portion
repayment_periodintrequired, 1–12
descriptionstringrequired, ≤190 chars — shown to the buyer
merchant_referencestringrequired, ≤64 — your unique order reference
order_total_valuenumberoptional ≥ amount — display only
merchant_collected_excessnumberoptional ≥ 0 — display only

201:

{
  "replayed": false,
  "consent_url": "https://guarantorpay.ng/consent/GRT-PAY%3A0001328?sig=...",
  "transaction_id": "GRT-PAY:0001328",
  "status": "pending",
  "amount": 10000,
  "monthly_installment": 3683.33,
  "total_amount_expected": 11050,
  "repayment_period": 3,
  "description": "Order #1234",
  "merchant_reference": "ORDER-1234",
  "customer_number": "155508",
  "buyer_name": "ISAH YAHAYA",
  "order_total_value": 12500,
  "merchant_collected_excess": 2500,
  "is_test": false,
  "created_at": "2026-11-25T12:47:47+01:00"
}
Redirect the customer to consent_url (or show a "Approve on your phone" note — they also receive an SMS link). The consent page shows the covered amount, the monthly schedule and the total with charges.

Idempotency: retrying the same reference with the same payload returns the original transaction with "replayed": true (HTTP 200) — never a duplicate. The same reference with a different amount or customer number returns 409 DUPLICATE_REFERENCE.

GET/transactions

Your transactions, newest first (limit 100). Filters: ?status=pending|approved|cancelled|completed, &from=YYYY-MM-DD, &to=YYYY-MM-DD, &test=0|1.

Whether pending rows are visible is a per-merchant switch the GP admin controls for API merchants (sees_pending in /me).

GET/transactions/{transaction_id}

One transaction by its GRT-PAY serial, plus repayment counters. Another merchant's serial → 404 NOT_FOUND.

GET/transactions/{transaction_id}/repayments

Salary-deduction history for the transaction: installment, amount, month, reference, status.

POST/transactions/{transaction_id}/cancel

Cancels a pending transaction (e.g. customer abandoned the cart). Approved or completed transactions return 422 NOT_CANCELLABLE — contact GP for those.

Civil-servant onboarding

POST/registrations

Register a civil servant so they can transact (they still complete GP's document verification). Fields: firstname, lastname, email, phone_number, customer_number, password (min 8), stateoforigin, id_number.

201: { "created": true, "user": { "name": "EKAETE UDO", "customer_number": "9610471",
       "approval_status": "unapproved" },
       "note": "The civil servant must complete GP verification before transacting." }

Never duplicates: a customer number that already exists returns 200 {"existing": true, ...} (with the profile's status) when the email matches, or 409 CUSTOMER_TAKEN when it doesn't. A known email on a new customer number returns 409 EMAIL_TAKEN. The buyer receives GP's standard registration email.