reseller

PUT /v1/reseller/prices

Set your own price for one plan.

Բոլոր reseller վերջնակետերը

Նույնականացում

Ուղարկեք API բանալին որպես bearer token: Բանալին պետք է ունենա reseller.manage թույլտվությունը. առանց դրա բանալին մերժվում է 403, և ոչ թե 404 կարգավիճակով:

Որտեղ տեղադրվում է ձեր կազմակերպության ID-ն

Այs վերջնակետը ընդունում է org_id-ը որպես հարցման պարամետր: Բաց թողեք այն, և կանչը կընդգրկի ձեր ամբողջ վարձակալության ենթածառը. ուղարկեք այն՝ կանչը մեկ կազմակերպության վրա սահմանափակելու համար:

Ձեր կազմակերպության ID-ն գտնվում է Ձեր ղեկավարման վահանակի API բանալիների էկրանին՝ բուն բանալու կողքին: Այն նույն ID-ն է Ձեր կատարած յուրաքանչյուր հարցման մեջ:

Փորձել

Փոխարինեք անկյունային փակագծերում գտնվող ցանկացած բան ձեր սեփական արժեքներով, և բանալու տեղապահը՝ ձեր վահանակի բանալիով:

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 վահանակը լրացնում է ձեր իրական կազմակերպության ID-ն և ձեր սեփական բանալին և գործարկում է հարցումը ուղիղ 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