Doğrulama
API açarını bearer token kimi göndərin. Açar reseller.manage icazəsinə malik olmalıdır; bu icazəsi olmayan açar 404 deyil, 403 xətası ilə rədd edilir.
Təşkilatınızın identifikatorunun yerləşdiyi yer
Bu son nöqtə sorğu parametri kimi org_id qəbul edir. Onu buraxın və sorğu bütün kirayə alt ağacınızı əhatə etsin; sorğunu bir təşkilatla məhdudlaşdırmaq üçün onu göndərin.
Təşkilatınızın identifikatoru idarə panelinizdəki API açarları ekranında, açarın özünün yanında yerləşir. Bu, etdiyiniz hər bir sorğuda eyni identifikatordur.
Sınaqdan keçir
Bucaqlı mötərizələrdə olan hór şeyi öz qiymətlərinizlə, açar yertutucusunu isə idarə panelinizdən bir açarla əvəz edin.
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> }'Sistemə daxil olmusunuz? İdarə panelinizdəki API konsolu real təşkilatınızın identifikatorunu və öz açarınızı avtomatik doldurur, sorğunu canlı API-yə qarşı icra edir ki, siz faktiki cavabı görə biləsiniz. Bu son nöqtəni API konsolunda açın
Təfərrüatlar
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`.
Parametrlər
| Ad | Tip | Tələb olunur | Nədir |
|---|---|---|---|
org_id (query) | Uuid | Xeyr | 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… |
Sorğu gövdəsi
| Ad | Tip | Tələb olunur | Nədir |
|---|---|---|---|
plan_id | Uuid | Bəli | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
interval | string | Bəli | — |
currency | string | Bəli | — |
amount_minor | integer | Bəli | — |
is_active | boolean | Xeyr | — |
Cavab
| Ad | Tip | Tələb olunur | Nədir |
|---|---|---|---|
id | Uuid | null | Xeyr | Null when you have not authored this row yet. |
plan_id | Uuid | Bəli | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
plan_code | string | Bəli | — |
plan_name | string | Bəli | — |
interval | string | Bəli | — |
currency | string | Bəli | — |
amount_minor | integer | Bəli | What YOUR client pays, in minor units. |
is_active | boolean | Bəli | — |
list_amount_minor | object | Xeyr | Zinn®'s list price for the same plan. |
wholesale_amount_minor | object | Xeyr | What the plan costs YOU after your wholesale discount. |
wholesale_discount_bps | integer | Xeyr | — |
price_source | string<price_list, markup, unpriced> | Bəli | 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. |
Bu son nöqtənin qaytara biləcəyi xətalar
401 · 403 · 404 · 422 · 429