compute
POST /v1/compute/eligibility
Submit an organisation for verification.
Упълномощаване
Изпратете API ключ като токен за носене. Ключът трябва да притежава разрешението billing.payment.manage; ключ без него се отхвърля с 403, а не с 404.
Където отива идентификаторът на вашата организация
Този ендпойнт приема org_id като параметър на заявката. Оставете го празен и извикването ще обхване цялото ви поддървано дърво; изпратете го, за да ограничите извикването до една организация.
ИД на вашата организация се намира на екрана с API ключове във вашето табло за управление, до самия ключ. Това е същият ИД във всяко заявка, която правите.
Опитайте
Заменете всичко в квадратни скоби със собствени стойности, а ключовия заместващ символ – с ключ от вашето табло за управление.
curl -X POST https://api.zinndigital.com/v1/compute/eligibility \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "legal_name": <string>, "country": <string>, "abuse_contact_email": <string> }'Влязохте ли в профила си? API конзолата във вашето табло за управление попълва действителното идентификационно число на вашата организация и вашия собствен ключ и изпълнява заявката спрямо реалното API, за да можете да видите действителния отговор. Отворете този крайpoint в API конзолата
Детайли
Moves the organisation to `pending` for a human to review. **202**, because the answer is a decision somebody makes rather than something this call performs. ⛔ An organisation that is already verified, or already pending, is refused `422` rather than silently re-queued: resubmitting would otherwise let a customer suspend their own verification, and let a rejected applicant re-enter the queue for ever. Requires `billing.payment.manage` — ⛔ **not** `billing.entitlement.manage`, a staff key no customer role holds, which is what this said until D10689.
Параметри
| Име | Тип | Задължително | Какво представлява |
|---|---|---|---|
org_id (query) | Uuid | Не | — |
Тяло на заявката
| Име | Тип | Задължително | Какво представлява |
|---|---|---|---|
legal_name | string | Да | — |
country | string | Да | — |
abuse_contact_email | string | Да | — |
company_number | string | Не | — |
intended_use | string | Не | — |
Отговор
| Име | Тип | Задължително | Какво представлява |
|---|---|---|---|
state | string<not_requested, pending, verified, rejected> | Да | ⛔ Four states, not a boolean. `not_requested` and `rejected` both refuse an order and the customer's next action differs completely: one is "tell us who you are", the other is "… |
may_order | boolean | Да | True only in `verified`. Read this rather than re-deriving it from `state`. |
legal_name | string | Да | The legal name of whoever is responsible for the machines. |
country | string | Да | ISO-3166-1 alpha-2 country of the person or the incorporation. |
company_number | string | Да | Company registration number, or `""` for an individual — a real answer. |
abuse_contact_email | string | Да | A monitored address an abuse report can be forwarded to and answered from. We are the account holder of record, so a complaint reaches us first and has to reach the customer wit… |
intended_use | string | Да | What the customer says the machines are for, in their own words. |
rejection_reason | string | Да | Shown to the customer **verbatim** when `state` is `rejected`. |
submitted_at | string | Да | — |
reviewed_at | string | Да | — |
Грешки, които този крайpoint може да върне
401 · 403 · 422 · 429