Rawi

مرجع API · Billing & payment gateway

List own payments

get/billing/payments
احراز هویتتوکن مشتری (Bearer)
سطح دسترسیکاربر رایگان · کاربر حرفه‌ای

Customer token (Bearer) — free and paid users

All payments of the caller (any status), newest first.

پاسخ‌ها

200 — Payment[]

فیلدنوعتوضیح
id*integerUnique ID.
period*string
status*stringCurrent status.
base_amount*integer
period_discount*integer
code_discount*integer
vat*integer
total*integer
currency*stringCurrency code, e.g. USD, EUR or IRT.
tracking_code*string | null
gateway_message*string | null
gateway_name*string | null
period_start*string | null
period_end*string | null
paid_at*string | null
created_at*string | nullWhen it was created (ISO 8601).
auto_renew*boolean
renewal_amount*integer | null«Renew automatically» (Stripe subscription)
amount_refunded*integerRefunds (status refunded / partially_refunded): total refunded so far and when the last one was made.
refunded_at*string | null
json
[
  {
    "id": 19,
    "period": "quarterly",
    "status": "success",
    "base_amount": 5400000,
    "period_discount": 540000,
    "code_discount": 1458000,
    "vat": 340200,
    "total": 3742200,
    "currency": "IRT",
    "tracking_code": "427999304",
    "gateway_message": null,
    "gateway_name": "درگاه بانکی (آزمایشی)",
    "period_start": "2026-10-25T00:00:00Z",
    "period_end": "2027-01-25T00:00:00Z",
    "paid_at": "2026-10-25T11:42:00Z",
    "created_at": "2026-10-25T11:42:00Z"
  }
]

401 — Missing/invalid token, or a token of the wrong owner (admin token on a user route or vice versa): {"message":"…","code":"unauthenticated"} (message in the request language)

فیلدنوع
message*string
codestring
json
{
  "message": "Please sign in to continue; your session has ended or is not valid.",
  "code": "unauthenticated"
}

نمونهٔ curl

bash
curl -X GET 'http://127.0.0.1:8010/api/billing/payments' \
  -H 'Accept: application/json' \
  -H "Authorization: Bearer $RAWI_USER_TOKEN"

امتحان در کنسول