Webhook Setting
6 operations. Call any of them with omada_call_operation (or, in full tool mode, as a tool named by its operationId).
| Operation | Method | Summary |
|---|---|---|
| getWebhookForGlobal | GET | Get global webhook setting list. |
| createWebhookForGlobal | POST | Create global webhook setting |
| deleteWebhookForGlobal | DELETE | Delete global webhook setting |
| modifyWebhookForGlobal | PATCH | Modify global webhook setting |
| testWebhookForGlobal | POST | Test global webhook setting |
| getWebhookLogsForGlobal | GET | Get global webhook dispatch log list |
getWebhookForGlobal
GET /openapi/v1/{omadacId}/webhook/settings
Get global webhook setting list.
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
omadacId | path | string | auto | Omada ID (filled in automatically) |
// omada_call_operation
{
"operationId": "getWebhookForGlobal"
}Details, permissions and error codes
Get all global webhook setting.The template of webhook message is display at Open API Access Guide#5.3.1 Webhook Message Template.
The interface requires one of the permissions:
Global Webhook Manager View Only
createWebhookForGlobal
POST /openapi/v1/{omadacId}/webhook/settings
Create global webhook setting
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
omadacId | path | string | auto | Omada ID (filled in automatically) |
Request body — application/json (required) — schema OpenApiWebhookSettingAddVO
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Webhook name. It should contain 1 to 128 characters. |
urlList | array<string> | yes | Webhook URL List. Up to 3 entries are allowed for the URL list |
retryPolicy | integer | yes | Webhook retry policy. It should be a value as follows: 0:None, 1:Important (Up to 5 retries over 60 minutes), 2:Critical (Up to 5 retries over 24 hours) |
shardedSecret | string | no | Webhook Sharded Secret. It should contain 0 to 128 characters. |
template | integer | yes | Webhook template, it should be a value as follow: 0:Omada template, 1:Google chat template. Example: 0. |
// omada_call_operation
{
"operationId": "createWebhookForGlobal",
"body": "{...}"
}Details, permissions and error codes
Create global webhook setting.The template of webhook message is display at Open API Access Guide#5.3.1 Webhook Message Template.
The interface requires one of the permissions:
Global Webhook Manager Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-44200 - The number of webhooks has reached the limit.
-44201 - This webhook name already exists.
-44203 - Webhook URL List should contain 1 to 3 URL entries. URL entries cannot be duplicated.
deleteWebhookForGlobal
DELETE /openapi/v1/{omadacId}/webhook/settings/{webhookId}
Delete global webhook setting
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
omadacId | path | string | auto | Omada ID (filled in automatically) |
webhookId | path | string | yes | webhook ID |
// omada_call_operation
{
"operationId": "deleteWebhookForGlobal",
"params": {
"webhookId": "<webhookId>"
}
}Details, permissions and error codes
Delete global webhook setting.The template of webhook message is display at Open API Access Guide#5.3.1 Webhook Message Template.
The interface requires one of the permissions:
Global Webhook Manager Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-44202 - This webhook entry does not exist.
modifyWebhookForGlobal
PATCH /openapi/v1/{omadacId}/webhook/settings/{webhookId}
Modify global webhook setting
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
omadacId | path | string | auto | Omada ID (filled in automatically) |
webhookId | path | string | yes | webhook ID |
Request body — application/json (required) — schema OpenApiWebhookSettingEditVO
| Field | Type | Required | Description |
|---|---|---|---|
urlList | array<string> | yes | Webhook URL List. Up to 3 entries are allowed for the URL list |
retryPolicy | integer | yes | Webhook retry policy. It should be a value as follows: 0:None, 1:Important (Up to 5 retries over 60 minutes), 2:Critical (Up to 5 retries over 24 hours) |
shardedSecret | string | no | Webhook Sharded Secret. It should contain 0 to 128 characters. |
template | integer | yes | Webhook template, it should be a value as follow: 0:Omada template, 1:Google chat template. Example: 0. |
// omada_call_operation
{
"operationId": "modifyWebhookForGlobal",
"params": {
"webhookId": "<webhookId>"
},
"body": "{...}"
}Details, permissions and error codes
Modify global webhook setting.The template of webhook message is display at Open API Access Guide#5.3.1 Webhook Message Template.
The interface requires one of the permissions:
Global Webhook Manager Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-44202 - This webhook entry does not exist.
-44203 - Webhook URL List should contain 1 to 3 URL entries. URL entries cannot be duplicated.
testWebhookForGlobal
POST /openapi/v1/{omadacId}/webhook/settings/{webhookId}
Test global webhook setting
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
omadacId | path | string | auto | Omada ID (filled in automatically) |
webhookId | path | string | yes | webhook ID |
Request body — application/json (required) — schema OpenApiWebhookSettingTestVO
| Field | Type | Required | Description |
|---|---|---|---|
name | string | yes | Webhook name. It should contain 1 to 128 characters. |
shardedSecret | string | no | Webhook Sharded Secret. It should contain 0 to 128 characters. |
urlList | array<string> | yes | Webhook URL List. Up to 3 entries are allowed for the URL list |
template | integer | yes | Webhook template, it should be a value as follow: 0:Omada template, 1:Google chat template. Example: 0. |
// omada_call_operation
{
"operationId": "testWebhookForGlobal",
"params": {
"webhookId": "<webhookId>"
},
"body": "{...}"
}Details, permissions and error codes
Test global webhook setting.The template of webhook message is display at Open API Access Guide#5.3.1 Webhook Message Template.
The interface requires one of the permissions:
Global Webhook Manager Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-44203 - Webhook URL List should contain 1 to 3 URL entries. URL entries cannot be duplicated.
getWebhookLogsForGlobal
GET /openapi/v1/{omadacId}/webhook/settings/dispatch-logs
Get global webhook dispatch log list
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
omadacId | path | string | auto | Omada ID (filled in automatically) |
page | query | integer | no | Start page number. Start from 1. (default 1) |
pageSize | query | integer | no | Number of entries per page. It should be within the range of 1–1000. (default 100) |
filters.webhookId | query | string | yes | Filter query parameters, support field d66aed17ea7238154ba610710d9a2890 |
filters.timeStart | query | integer | yes | Filter query parameters, support field 1679297710438 |
filters.timeEnd | query | integer | yes | Filter query parameters, support field 1681889710438 |
// omada_call_operation
{
"operationId": "getWebhookLogsForGlobal",
"params": {
"filters.webhookId": "<filters.webhookId>",
"filters.timeStart": "<filters.timeStart>",
"filters.timeEnd": "<filters.timeEnd>"
}
}Details, permissions and error codes
Get global webhook dispatch log list.The template of webhook message is display at Open API Access Guide#5.3.1 Webhook Message Template.
The interface requires one of the permissions:
Global Webhook Manager View Only