Вебхуки (підписки): методи API Bimp
Методи API Bimp для ресурсу «Вебхуки (підписки)» (/org2/webhooks/…): 3 методи. Базова адреса: https://app.bimpsoft.com. Усі запити, крім входу, передають токен компанії в заголовку access-token — див. Початок роботи з API.
| Метод | Що робить |
|---|---|
POST /org2/webhooks/destinations/list | |
POST /org2/webhooks/destinations/upsert | |
POST /org2/webhooks/destinations/delete |
destinations/list
POST /org2/webhooks/destinations/list
Тіло запиту (JSON)
| Поле | Тип | Обов’язкове | Опис |
|---|---|---|---|
eventKind | string (“inventory_balance”) | string (“product_upsert”) | string (“order_status”) | так |
Відповідь: поле data
| Поле | Тип | Опис |
|---|---|---|
[].id | string (uuid) | |
[].companyId | string (uuid) | |
[].eventKind | string | |
[].name | string | null | |
[].url | string | |
[].enabled | integer | |
[].orgId | string (uuid) | null | |
[].warehouseId | string (uuid) | null | |
[].extraHeaders | string | null | |
[].hasSecret | boolean |
curl -X POST 'https://app.bimpsoft.com/org2/webhooks/destinations/list' \
-H 'access-token: <токен компанії>' \
-H 'Content-Type: application/json' \
-d '{"eventKind":"string"}'
destinations/upsert
POST /org2/webhooks/destinations/upsert
Тіло запиту (JSON)
| Поле | Тип | Обов’язкове | Опис |
|---|---|---|---|
eventKind | string (“inventory_balance”) | string (“product_upsert”) | string (“order_status”) | так | |
id | string (uuid) | ||
name | string | null | ||
url | string | так | |
secret | string | null | ||
enabled | boolean | ||
orgId | string (uuid) | null | ||
warehouseId | string (uuid) | null | ||
extraHeaders | object |
Відповідь: поле data
| Поле | Тип | Опис |
|---|---|---|
id | string (uuid) |
curl -X POST 'https://app.bimpsoft.com/org2/webhooks/destinations/upsert' \
-H 'access-token: <токен компанії>' \
-H 'Content-Type: application/json' \
-d '{"eventKind":"string","url":"string"}'
destinations/delete
POST /org2/webhooks/destinations/delete
Тіло запиту (JSON)
| Поле | Тип | Обов’язкове | Опис |
|---|---|---|---|
eventKind | string (“inventory_balance”) | string (“product_upsert”) | string (“order_status”) | так | |
id | string (uuid) | так |
Відповідь: поле data
| Поле | Тип | Опис |
|---|---|---|
deleted | boolean |
curl -X POST 'https://app.bimpsoft.com/org2/webhooks/destinations/delete' \
-H 'access-token: <токен компанії>' \
-H 'Content-Type: application/json' \
-d '{"eventKind":"string","id":"00000000-0000-0000-0000-000000000000"}'
Інтерактивна документація з можливістю надіслати тестовий запит: https://app.bimpsoft.com/docs. Специфікація OpenAPI оновлюється разом із Bimp; ця сторінка згенерована з неї автоматично.