localization
GET /v1/session/offering
The currencies and languages this viewer may be shown.
Упълномощаване
Изпратете API ключ като носител (bearer token). Тази точка за достъп не указва конкретно разрешение в спецификацията, затова дайте на ключа си най-малкото необходимо и проверете отговора, вместо да правите предположения.
Този ендпойнт не изисква идентификатор на организация. Вашият ключ вече идентифицира организацията, към която принадлежи, и отговорът е ограничен до нея.
Опитайте
Заменете всичко в квадратни скоби със собствени стойности, а ключовия заместващ символ – с ключ от вашето табло за управление.
curl -X GET https://api.zinndigital.com/v1/session/offering \
-H "Authorization: Bearer zdk_live_…"Влязохте ли в профила си? API конзолата във вашето табло за управление попълва действителното идентификационно число на вашата организация и вашия собствен ключ и изпълнява заявката спрямо реалното API, за да можете да видите действителния отговор. Отворете този крайpoint в API конзолата
Детайли
What a storefront, checkout or panel shell may offer the person looking at it, already resolved through their provider's policy. The viewer is identified two ways, in this order: **who they are**, when they are signed in; otherwise **where they are standing**, from the reseller panel hostname in the browser's `Origin`. So an anonymous visitor on a reseller's branded panel gets that reseller's offering, and everybody else — an anonymous visitor to Zinn®, an unrecognised origin, a hostname we no longer serve — gets the platform answer: every currency we can charge and every language we ship. Signing in always wins over the origin, because pricing follows the organisation the rest of the API scopes your reads by. `restricted` says a reseller stands between this viewer and Zinn®; read it rather than inferring one from list lengths, because a reseller who has narrowed nothing returns exactly the same lists as no reseller at all. `currency_switcher: false` means render no control, not a disabled one. Never cached.
Отговор
| Име | Тип | Задължително | Какво представлява |
|---|---|---|---|
currencies | string[] | Да | The currencies this viewer may be quoted in. Never empty. |
default_currency | string | Да | Always a member of `currencies`. |
currency_switcher | boolean | Да | `false` means render no currency control at all — not a disabled one. |
locales | string[] | Да | The languages this viewer may read the panel in. Never empty. |
default_locale | string | Да | Always a member of `locales`. |
language_switcher | boolean | Да | `false` means render no language control at all. |
restricted | boolean | Да | A reseller stands between this viewer and Zinn®. Explicit rather than inferred: a reseller who has narrowed nothing returns identical lists to no reseller at all. |
Грешки, които този крайpoint може да върне
429