commerce

POST /v1/orders/{orderId}/refund-request

Request a refund for an order.

تمام commerce اینڈ پوائنٹس

توثيقِ شناخت

ایک بیرر ٹوکن کے طور پر ایک API کی بھیجیں۔ کی کے پاس 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 کنسول آپ کی حقیقی تنظیم کی آئی ڈی اور آپ کی اپنی کلید خود بخود پُر کر دیتا ہے، اور لائیو API پر درخواست چلاتا ہے تاکہ آپ اصل ردعمل دیکھ سکیں۔ اس اینڈ پوائنٹ کو 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_idUuidنہیںUUIDv7 identifier — sortable by creation time (docs/02 §8).
reasonstringنہیں
to_walletbooleanنہیں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…

جواب

نامقسملازمییہ کیا ہے
idUuidہاںUUIDv7 identifier — sortable by creation time (docs/02 §8).
org_idUuidہاںUUIDv7 identifier — sortable by creation time (docs/02 §8).
order_idUuidہاںUUIDv7 identifier — sortable by creation time (docs/02 §8).
statusRefundRequestStatusہاںA refund request's lifecycle state (docs/05 §4.13).
policy_classRefundPolicyClassہاںHow the refund policy classified a request (captured at request time).
amountMoneyAmountہاںA money value — integer minor units + an ISO 4217 code (CLAUDE.md §2.8).
to_walletbooleanہاں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…
reasonstringہاں
decided_bystringہاں
decision_notestringہاں
decided_atobjectہاں
refund_referencestringہاںSet once the refund has been issued (its idempotency key).
created_atstringہاں
updated_atstringہاں

وہ خرابیان جو یہ اینڈ پوائنٹ واپس کر سکتا ہے

401 · 403 · 404 · 409 · 422 · 429