Автентифікація
Надішліть ключ API як маркер носія (bearer token). Ця кінцева точка не вказує конкретного дозволу в специфікації, тому надайте своєму ключу мінімально необхідні права та перевірте відповідь, замість того щоб припускати.
Де вказується ідентифікатор вашої організації
Цей ендпоінт приймає org_id як поле в тілі JSON.
Ідентифікатор вашої організації знаходиться на екрані API-ключів у вашій панелі керування, поруч із самим ключем. Це той самий ідентифікатор у кожному вашому запиті.
Спробувати
Замініть усе в кутових дужках власними значеннями, а заповнювач ключа — ключем із вашої панелі керування.
curl -X POST https://api.zinndigital.com/v1/agency/time/rates \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "scope": <string<task, project, client, org>>, "amount_minor": <integer>, "currency": <string>, "effective_from": <string> }'Увійшли в систему? Консоль API у вашій панелі керування автоматично підставляє ваш реальний ідентифікатор організації та ваш власний ключ, а також виконує запит до робочого API, щоб ви могли побачити справжню відповідь. Відкрийте цю кінцеву точку в консолі API
Деталі
`amount_minor` is the price of ONE HOUR for `kind: hourly`, and the price of the whole job for `kind: fixed`. ⛔ A fixed price is billed **once** for the task it is set on, however many hours are logged against it — the minutes are still recorded and reported, they simply do not each carry money. It is not "an hourly rate of zero".
Тіло запиту
| Назва | Тип | Обов'язкове | Що це таке |
|---|---|---|---|
scope | string<task, project, client, org> | Так | — |
scope_id | string | Ні | — |
kind | string<hourly, fixed> | Ні | — |
amount_minor | integer | Так | — |
currency | string | Так | — |
effective_from | string | Так | — |
org_id | string | Ні | — |
Відповідь
| Назва | Тип | Обов'язкове | Що це таке |
|---|---|---|---|
id | string | Так | — |
scope | string<task, project, client, org> | Так | — |
scope_id | string | Ні | The task/project/client this applies to. `null` exactly when scope is `org`. |
kind | string<hourly, fixed> | Так | — |
amount_minor | integer | Так | Minor units. For `hourly`, the price of ONE HOUR — ⛔ never a price per minute, and never divided by 60 anywhere on this API. |
currency | string | Так | — |
effective_from | string | Так | Applies to work done on or after this date. Resolution is against the **work's** date, never today, so a rate rise does not re-price last month. |
archived | boolean | Так | — |
Помилки, які може повертати ця кінцева точка
401 · 403 · 422