commerce

POST /v1/carts

Open a shopping cart.

সমস্ত commerce এন্ডপয়েন্ট

প্রমাণীকরণ

একটি বিয়ারার টোকেন হিসেবে একটি এপিআই কি পাঠান। কি-টির অবশ্যই billing.payment.manage অনুমতি থাকতে হবে; এটি ছাড়া কোনো কি ৪০৪ নয়, বরং ৪০৩ ত্রুটি দিয়ে প্রত্যাখ্যাত হবে।

যেখানে আপনার অর্গানাইজেশন আইডি দেওয়া হবে

এই এন্ডপয়েন্টটি JSON বডিতে একটি ক্ষেত্র হিসেবে org_id গ্রহণ করে।

আপনার ড্যাশবোর্ডের API কি স্ক্রিনে, কি-এর ঠিক পাশেই আপনার অর্গানাইজেশন আইডি রয়েছে। আপনি যে কলই করুন না কেন, সবগুলিতেই এই আইডি একই থাকে।

চেষ্টা করুন

কোণ বন্ধনীতে থাকা যেকোনো কিছু আপনার নিজস্ব মান দিয়ে এবং কী প্লেসহোল্ডারটি আপনার ড্যাশবোর্ডের একটি কী দিয়ে প্রতিস্থাপন করুন।

curl -X POST https://api.zinndigital.com/v1/carts \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{  }'

লগ ইন করা আছে? আপনার ড্যাশবোর্ডের এপিআই কনসোল আপনার আসল অর্গানাইজেশন আইডি এবং আপনার নিজের কি পূরণ করে দেয়, এবং লাইভ এপিআই-এর বিপরীতে অনুরোধটি চালায় যাতে আপনি প্রকৃত প্রতিক্রিয়া দেখতে পান। এই এন্ডপয়েন্টটি এপিআই কনসোলে খুলুন

বিবরণ

Creates an empty open cart for the organization. Prices on its lines are server-authoritative and re-computed on every read (the client price is never trusted). Requires `billing.payment.manage`.

অনুরোধের বডি

নামধরনআবশ্যকএটি কী
org_idUuid | nullনাDefaults to the caller's org; the caller must hold `billing.payment.manage` there.
product_linestringনা
currencyCurrencyCode | nullনাThe currency to open the basket in — what the customer will be **billed** in. Omit it and the engine uses the `X-Zinn-Currency` header the dashboard already sends, falling back…

প্রতিক্রিয়া

নামধরনআবশ্যকএটি কী
idUuidহ্যাঁUUIDv7 identifier — sortable by creation time (docs/02 §8).
org_idUuidহ্যাঁUUIDv7 identifier — sortable by creation time (docs/02 §8).
statusstring<open, checking_out, converted, abandoned, expired>হ্যাঁ
currencyCurrencyCode | nullনাFixed when the cart is opened, from `CartCreate.currency` or the `X-Zinn-Currency` header, and then locked — every line must match it. Null only on a legacy cart created before…
product_lineobjectনা
linesCartLine[]হ্যাঁ
subtotalMoneyAmountহ্যাঁA money value — integer minor units + an ISO 4217 code (CLAUDE.md §2.8).
discountMoneyAmountহ্যাঁA money value — integer minor units + an ISO 4217 code (CLAUDE.md §2.8).
totalMoneyAmountহ্যাঁA money value — integer minor units + an ISO 4217 code (CLAUDE.md §2.8).
created_atstringহ্যাঁ
updated_atstringনা

এই এন্ডপয়েন্ট থেকে যেসব ত্রুটি আসতে পারে

401 · 403 · 422 · 429