Subskrypcje webhooków
Manage outbound webhook subscriptions. exoCortex POSTs a signed JSON event to your HTTPS endpoint whenever a subscribed event occurs (see Webhooks). These endpoints require an administrator session (Core → Integrations → Webhooks uses the same API).
Lista subskrypcji
Dział zatytułowany „Lista subskrypcji”GET /api/webhooks/{tenant}/subscriptions
Uwierzytelnianie: Sesja administratora exoCortex Core
Parametry
Dział zatytułowany „Parametry”| Nazwa | Miejsce | Typ | Wymagany | Opis |
|---|---|---|---|---|
tenant |
ścieżka | string | tak | Tenant code (case-insensitive). |
Odpowiedzi
Dział zatytułowany „Odpowiedzi”| Status | Opis |
|---|---|
200 |
Subscriptions of the tenant (secrets are masked). |
401 |
Not authenticated. |
403 |
Authenticated but not allowed (role, tenant or key). |
Przykład 200
{ "ok": true, "hooks": [ { "id": "wh_mhf2k1a9x3", "url": "https://hooks.example.com/exocortex", "events": [ "ticket.created", "ticket.status_changed" ], "format": "json", "enabled": true, "headers": {}, "secret": "***set***", "created_at": "2026-11-01T08:00:00.000Z", "created_by": "jane.doe" } ]}Przykład z curl
Dział zatytułowany „Przykład z curl”curl -X GET "https://exocortex-api.ai-exo-cortex.com/api/webhooks/ACME/subscriptions" \ -H "Authorization: Bearer $EXO_ADMIN_SESSION"Utworzenie lub zmiana subskrypcji
Dział zatytułowany „Utworzenie lub zmiana subskrypcji”POST /api/webhooks/{tenant}/subscriptions
Without id, this creates a new subscription. With id, it updates that subscription.
If you don’t send a secret on creation, exoCortex generates one and returns it
once in the secret response field. Store it to verify signatures.
Uwierzytelnianie: Sesja administratora exoCortex Core
Parametry
Dział zatytułowany „Parametry”| Nazwa | Miejsce | Typ | Wymagany | Opis |
|---|---|---|---|---|
tenant |
ścieżka | string | tak | Tenant code (case-insensitive). |
Treść żądania
Dział zatytułowany „Treść żądania”application/json
| Nazwa | Typ | Wymagany | Opis |
|---|---|---|---|
id |
string | nie | Send it to update an existing subscription. Omit it to create one. |
url |
string (uri) | tak | HTTPS endpoint that receives the events. |
events |
array<string> | nie | Event types to receive. * means all. Defaults to ["*"]. Besides the ticket catalog, notification-center events defined by the tenant’s notification rules (for example approval_requested) can be subscribed by name. |
format |
string (json, datadog, pagerduty, slack-block) |
nie | |
secret |
string | nie | Signing secret. Generated if omitted on creation. |
enabled |
boolean | nie | |
headers |
object | nie | Extra static headers added to every delivery (for example an auth header for your gateway). |
{ "url": "https://hooks.example.com/exocortex", "events": [ "ticket.created", "ticket.status_changed", "ticket.resolved" ], "format": "json"}Odpowiedzi
Dział zatytułowany „Odpowiedzi”| Status | Opis |
|---|---|
200 |
Subscription saved. |
400 |
Invalid request. |
401 |
Not authenticated. |
403 |
Authenticated but not allowed (role, tenant or key). |
Przykład 200
{ "ok": true, "id": "wh_mhf2k1a9x3", "count": 1, "secret": "whsec_4b9e1f0c7d2a8e6b3c5f9a1d0e7b2c4a"}Przykład z curl
Dział zatytułowany „Przykład z curl”curl -X POST "https://exocortex-api.ai-exo-cortex.com/api/webhooks/ACME/subscriptions" \ -H "Authorization: Bearer $EXO_ADMIN_SESSION" \ -H "Content-Type: application/json" \ --data '{"url":"https://hooks.example.com/exocortex","events":["ticket.created","ticket.status_changed","ticket.resolved"],"format":"json"}'Usunięcie subskrypcji
Dział zatytułowany „Usunięcie subskrypcji”DELETE /api/webhooks/{tenant}/subscriptions/{id}
Uwierzytelnianie: Sesja administratora exoCortex Core
Parametry
Dział zatytułowany „Parametry”| Nazwa | Miejsce | Typ | Wymagany | Opis |
|---|---|---|---|---|
tenant |
ścieżka | string | tak | Tenant code (case-insensitive). |
id |
ścieżka | string | tak |
Odpowiedzi
Dział zatytułowany „Odpowiedzi”| Status | Opis |
|---|---|
200 |
Deleted (removed is 0 if the id did not exist). |
401 |
Not authenticated. |
403 |
Authenticated but not allowed (role, tenant or key). |
Przykład 200
{ "ok": true, "removed": 1}Przykład z curl
Dział zatytułowany „Przykład z curl”curl -X DELETE "https://exocortex-api.ai-exo-cortex.com/api/webhooks/ACME/subscriptions/wh_mhf2k1a9x3" \ -H "Authorization: Bearer $EXO_ADMIN_SESSION"Wysłanie zdarzenia testowego
Dział zatytułowany „Wysłanie zdarzenia testowego”POST /api/webhooks/{tenant}/subscriptions/{id}/test
Sends a signed webhook.test event to the subscription URL and reports the HTTP status returned by your endpoint.
Uwierzytelnianie: Sesja administratora exoCortex Core
Parametry
Dział zatytułowany „Parametry”| Nazwa | Miejsce | Typ | Wymagany | Opis |
|---|---|---|---|---|
tenant |
ścieżka | string | tak | Tenant code (case-insensitive). |
id |
ścieżka | string | tak |
Odpowiedzi
Dział zatytułowany „Odpowiedzi”| Status | Opis |
|---|---|
200 |
Delivery result (ok reflects your endpoint’s response). |
401 |
Not authenticated. |
403 |
Authenticated but not allowed (role, tenant or key). |
Przykład 200
{ "ok": true, "status": 204}Przykład z curl
Dział zatytułowany „Przykład z curl”curl -X POST "https://exocortex-api.ai-exo-cortex.com/api/webhooks/ACME/subscriptions/wh_mhf2k1a9x3/test" \ -H "Authorization: Bearer $EXO_ADMIN_SESSION"Lista typów zdarzeń
Dział zatytułowany „Lista typów zdarzeń”GET /api/webhooks/{tenant}/event-types
Uwierzytelnianie: Sesja administratora exoCortex Core
Parametry
Dział zatytułowany „Parametry”| Nazwa | Miejsce | Typ | Wymagany | Opis |
|---|---|---|---|---|
tenant |
ścieżka | string | tak | Tenant code (case-insensitive). |
Odpowiedzi
Dział zatytułowany „Odpowiedzi”| Status | Opis |
|---|---|
200 |
Event catalog. |
401 |
Not authenticated. |
403 |
Authenticated but not allowed (role, tenant or key). |
Przykład 200
{ "ok": true, "wildcard": "*", "event_types": [ "ticket.created", "ticket.comment_added", "ticket.field_changed", "ticket.assignee_changed", "ticket.status_changed", "ticket.sla_warning", "ticket.sla_breach", "ticket.resolved", "ticket.closed", "ticket.reopened", "ticket.priority_changed", "routing.no_match", "routing.manual_routed", "ticket.link_created", "ticket.link_deleted" ]}Przykład z curl
Dział zatytułowany „Przykład z curl”curl -X GET "https://exocortex-api.ai-exo-cortex.com/api/webhooks/ACME/event-types" \ -H "Authorization: Bearer $EXO_ADMIN_SESSION"Strona wygenerowana ze specyfikacji OpenAPI API integracji, wersja 1.1.0.