KashierDevelopersKashier Developers
Get started

Quick start

Make your first test payment in about five minutes

1. Get your test credentials

Test vs live modes → API keys.

2. Create a payment session

Replace the three placeholders and run this — or open Create payment session and press Send with the same values in the playground:

curl https://test-api.kashier.io/v3/payment/sessions \
  --header 'Authorization: YOUR_TEST_SECRET_KEY' \
  --header 'api-key: YOUR_TEST_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
    "expireAt": "2030-01-01T00:00:00.000Z",
    "maxFailureAttempts": 3,
    "paymentType": "credit",
    "amount": "100.00",
    "currency": "EGP",
    "order": "quickstart-001",
    "merchantId": "YOUR_MID",
    "merchantRedirect": "https://your-website.com/redirect",
    "display": "en",
    "type": "one-time",
    "allowedMethods": "card,wallet",
    "customer": { "email": "[email protected]", "reference": "customer-001" }
  }'
Replace the placeholders — or save your keys once and copy the ready command.

Ten of those fields are required; the session is rejected without them. The other two are worth sending anyway:

FieldWhat it does
expireAtrequiredWhen the session stops accepting payment. Must be a future ISO 8601 timestamp.
maxFailureAttemptsrequiredHow many failed attempts the customer gets before the session closes.
amountrequiredThe amount to charge, as a string.
currencyrequiredEGP, USD, GBP, or EUR.
orderrequiredYour own order identifier. Must be unique.
merchantIdrequiredYour MID-….
merchantRedirectrequiredWhere Kashier sends the customer after payment.
typerequiredone-time here.
displayrequiredCheckout language, en or ar.
customerrequiredAt minimum an email and your own reference.
paymentTypeoptionalDefaults are applied when omitted.
allowedMethodsoptionalRestricts the methods offered at checkout. Omit to offer everything your account has enabled.

The response includes a sessionUrl:

{
  "status": "CREATED",
  "sessionUrl": "https://payments.kashier.io/session/…?mode=test"
}

3. Pay with a test card

Open the sessionUrl in your browser — this is the hosted checkout your customers see. Pay with:

  • Card number: 5123450000000008 (Mastercard, 3-D Secure enrolled)
  • Expiry: 06/25 · CVV: 100

The expiry is not arbitrary. In test mode it selects the outcome06/25 is the value that returns APPROVED, and other values return declines, timeouts, and errors on purpose. The full list is in test cards.

4. Confirm the result

Open your dashboard (test mode) — the payment is at the top of Transactions. Or fetch it over the API: Get payment session.

Next steps

On this page