Перейти к содержимому
Документация OneGate
Панель управления
Руководства

Эта страница доступна только на английском. Код, поля API и идентификаторы не переводятся.

Payment links

A reusable hosted link for a fixed amount — no checkout code needed.

bash
curl https://api.onegate.am/v1/payment-links \
  -H "Authorization: Bearer sk_test_..." \
  -H "Idempotency-Key: link-spring-sale" \
  -d '{"amount": 5000, "currency": "AMD", "description": "Gift card", "return_url": "https://shop.am/thanks"}'
json
{
  "id": "plink_06GD...",
  "object": "payment_link",
  "livemode": false,
  "url": "https://pay.onegate.am/l/plink_06GD...",
  "amount": 5000,
  "currency": "AMD",
  "description": "Gift card",
  "active": true,
  "return_url": "https://shop.am/thanks",
  "metadata": {},
  "created_at": "2026-09-27T10:00:00Z"
}

How it works

Each time a customer opens url, OneGate creates a separate payment and checkout session. Track results with the payment.* webhooks exactly as for API-created payments.

Fields: amount (integer minor units), currency, optional description, return_url and metadata. Retrieve a link with GET /v1/payment-links/{id}.

Links use your Test or Live environment according to the key that created them.