تصدیقهویت
یو API کی د بیئرر ټوکن (bearer token) په توګه ولیکئ. کی باید د billing.payment.manage اجازه ولري؛ له دې اجازې پرته کی د 404 پرځای د 403 په واسطه رد کیږي.
چیرته چې ستاسو د سازمان آی ډي ځي
دا پای ټکی د JSON په متن کې د یوې ساحې په توګه org_id اخلي.
ستاسو د سازمان آی ډي ستاسو په ډشبورډ کې د API کېلي پر سکرین، خپله د کېلي څنګ ته شتون لري. دا په هره هغه غوښتنه کې چې تاسو یې کوئ، ورته آی ډي وي.
هڅه وکړئ
د انګلیسي په زاوي پنسونو کې هرڅه د خپلو ارزښتونو سره بدل کړئ، او د کلي ځای لرونکی ستاسو د ډشبورډ د کلي سره.
curl -X POST https://api.zinndigital.com/v1/orders/{orderId}/refund-request \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ }'ننوتي یاست؟ ستاسو په ډشبورډ کې د API کنسول ستاسو د اصلي سازمان ID او ستاسو خپله کیلي ډکوي، او غوښتنه د ژوندی API په وړاندې پرمخ وړي ترڅو تاسو وکولی شئ اصلي ځواب وګورئ. دا پای ټکی (endpoint) د API په کنسول کې پرانیزئ
تفصیلات
Opens a refund request per the policy: within the 30-day money-back window the refund is issued immediately (status `auto_approved`); otherwise a pro-rata request is recorded `pending` for staff approval (docs/05 §4.13). The amount and approval path come from the server, never the client. Requires `billing.payment.manage`.
پارامترونه
| نوم | ډول | اړین | دا څه شی دی |
|---|---|---|---|
orderId (path) | Uuid | هو | The order's id. |
د غوښتنې بدن
| نوم | ډول | اړین | دا څه شی دی |
|---|---|---|---|
org_id | Uuid | نه | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
reason | string | نه | — |
to_wallet | boolean | نه | Where the refund goes. Omit it and the money is returned to the original payment method — the money-back guarantee is money back, and store credit is an opt-in the customer has… |
ځواب
| نوم | ډول | اړین | دا څه شی دی |
|---|---|---|---|
id | Uuid | هو | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
org_id | Uuid | هو | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
order_id | Uuid | هو | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
status | RefundRequestStatus | هو | A refund request's lifecycle state (docs/05 §4.13). |
policy_class | RefundPolicyClass | هو | How the refund policy classified a request (captured at request time). |
amount | MoneyAmount | هو | A money value — integer minor units + an ISO 4217 code (CLAUDE.md §2.8). |
to_wallet | boolean | هو | Refund destination, frozen at request time — `false` (the default) reverses the original payment, `true` credits the account wallet. Any part of the order that was settled from… |
reason | string | هو | — |
decided_by | string | هو | — |
decision_note | string | هو | — |
decided_at | object | هو | — |
refund_reference | string | هو | Set once the refund has been issued (its idempotency key). |
created_at | string | هو | — |
updated_at | string | هو | — |
تېروتنې چې دا پای ټکی یې بیرته راګرځولی شي
401 · 403 · 404 · 409 · 422 · 429