commerce

GET /v1/carts/{cartId}

Get a cart.

جميع نقاط نهاية commerce

المصادقة

أرسل مفتاح واجهة برمجة التطبيقات (API) كرمز حامل (bearer token). لا يحدد نقطة النهاية هذه إذنًا محددًا في المواصفات، لذا امنح مفتاحك الحد الأدنى الذي محتاجه وتحقق من الاستجابة بدلاً من الافتراض.

لا يقبل هذا الطرف أي معرف للمؤسسة. يحدد مفتاحك بالفعل المؤسسة التي ينتمي إليها، وتكون الاستجابة محصورة في نطاقها.

جربه الآن

استبدل أي شيء بين أقواس زاوية بقيمك الخاصة، والعنصر النائب للمفتاح بمفتاح من لوحة تحكمك.

curl -X GET https://api.zinndigital.com/v1/carts/{cartId} \
  -H "Authorization: Bearer zdk_live_…"

هل سجلت الدخول؟ تقوم وحدة تحكم واجهة برمجة التطبيقات في لوحة التحكم الخاصة بك بربط معرف مؤسستك الحقيقي ومفتاحك الخاص، وتنفذ الطلب مقابل واجهة برمجة التطبيقات المباشرة لتتمكن من رؤية الاستجابة الفعلية. افتح هذه النهاية الطرفية في وحدة تحكم API

التفاصيل

Returns the cart with its lines re-priced from the live catalog and its pre-tax totals.

المعلمات

الاسمالنوعمطلوبما هو هذا
cartId (path)UuidنعمThe cart's id.

الاستجابة

الاسمالنوعمطلوبما هو هذا
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 · 404 · 429