Skip to content
Guarantee Pay Docs

API · scope create_payment

Checkout (native)

The native endpoint takes explicit customer fields. It creates the same payment and returns the same response as create charge.

POST https://payment.yamin.bd/api/checkout/redirect
Content-Type: application/json
MHS-GUARANTEEPAY-API-KEY: YOUR_API_KEY

Body fields

FieldRequiredNotes
full_nameyesCustomer name.
email_addressyesMust be a valid email.
mobile_numberyesAny non-empty value.
amountyesPositive plain decimal string.
currencynoDefaults to BDT.
return_urlnoWhere the customer returns. Host must be whitelisted.
webhook_urlnoYour webhook endpoint. Host must be whitelisted.
metadatanoJSON object, returned unchanged.

Example request

{
  "full_name": "Rahim Uddin",
  "email_address": "rahim@example.com",
  "mobile_number": "01700000000",
  "amount": "500",
  "currency": "BDT",
  "metadata": { "order_id": "ORD-1001" },
  "return_url": "https://shop.example.com/pay/return?order_id=ORD-1001",
  "webhook_url": "https://shop.example.com/hooks/guaranteepay"
}

Response

{ "status": true, "pp_id": "k3J9x…", "pp_url": "https://payment.yamin.bd/payment/k3J9x…" }

Popup variant

POST /api/checkout/popup takes the same fields except return_url. Use it when you open pp_url in a popup or in-app browser and rely on the webhook or verify call instead of a redirect.