reseller

PUT /v1/reseller/prices

Set your own price for one plan.

همه نقاط پایانی reseller

احراز هویت

یک کلید API را به عنوان یک توکن حامل ارسال کنید. این کلید باید دارای مجوز reseller.manage باشد؛ کلیدی که فاقد آن باشد با خطای 403 رد می‌شود، نه 404.

جایی که شناسه سازمان شما قرار می‌گیرد

این نقطه پایانی org_id را به عنوان یک پارامتر پرس‌وجو می‌پذیرد. آن را رها کنید تا فراخوانی کل زیردرخت اجاره‌ای شما را پوشش دهد؛ آن را ارسال کنید تا فراخوانی به یک سازمان محدود شود.

شناسه سازمان شما در صفحه کلیدهای API در داشبوردتان، در کنار خود کلید قرار دارد. این شناسه در تمام درخواست‌هایی که ارسال می‌کنید یکسان است.

امتحان کنید

هر چیزی را که داخل براکت‌های زاویه‌دار قرار دارد با مقادیر خودتان جایگزین کنید، و نگهدارنده کلید را با کلیدی از داشبورد خود جایگزین نمایید.

curl -X PUT https://api.zinndigital.com/v1/reseller/prices \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "plan_id": <Uuid>, "interval": <string>, "currency": <string>, "amount_minor": <integer> }'

وارد شده‌اید؟ کنسول API در داشبورد شما شناسه سازمان واقعی و کلید خودتان را پر می‌کند و درخواست را روی API زنده اجرا می‌کند تا بتوانید پاسخ واقعی را ببینید. این نقطه پایانی را در کنسول API باز کنید

جزئیات

Upserts one row of your price list, keyed on (plan, interval, currency). Editing it never re-prices a client already sold — their subscription captured the price at purchase. Requires `reseller.manage`.

پارامترها

نامنوعالزامیچیست
org_id (query)UuidخیرWhich of your organizations this applies to. Required only when you belong to more than one here — otherwise it is inferred, and an id outside your direct memberships is a 404 r…

بدنه درخواست

نامنوعالزامیچیست
plan_idUuidبلهUUIDv7 identifier — sortable by creation time (docs/02 §8).
intervalstringبله
currencystringبله
amount_minorintegerبله
is_activebooleanخیر

پاسخ

نامنوعالزامیچیست
idUuid | nullخیرNull when you have not authored this row yet.
plan_idUuidبلهUUIDv7 identifier — sortable by creation time (docs/02 §8).
plan_codestringبله
plan_namestringبله
intervalstringبله
currencystringبله
amount_minorintegerبلهWhat YOUR client pays, in minor units.
is_activebooleanبله
list_amount_minorobjectخیرZinn®'s list price for the same plan.
wholesale_amount_minorobjectخیرWhat the plan costs YOU after your wholesale discount.
wholesale_discount_bpsintegerخیر
price_sourcestring<price_list, markup, unpriced>بلهWhether the price is one you set, one derived from list by your default markup, or absent because the catalogue holds no price in this currency.

خطاهایی که این نقطه پایانی می‌تواند برگرداند

401 · 403 · 404 · 422 · 429