Skip to content

Integrations

Integrations connect Noctuary to external alerting tools. Currently supported: PagerDuty.

GET /v1/integrations

List all integrations.

curl https://api.noctuary.io/v1/integrations \
  -H "Authorization: Bearer noc_ro_your_key"

Response: 200 OK

[
  {
    "id": "d91f3a2b-...",
    "tenant_id": "5f0bfa6c-...",
    "type": "pagerduty",
    "direction": "bidirectional",
    "token": "tok_abc123...",
    "config": {},
    "created_at": "2026-05-31T10:00:00Z",
    "webhook_url": "https://api.noctuary.io/webhooks/pagerduty/tok_abc123..."
  }
]

POST /v1/integrations

Create a new integration.

curl -X POST https://api.noctuary.io/v1/integrations \
  -H "Authorization: Bearer noc_ro_your_key" \
  -H "Content-Type: application/json" \
  -d '{"type": "pagerduty", "direction": "bidirectional"}'

Response: 201 Created

Request body

Field Type Required Description
type string Yes Integration type. Currently: pagerduty
direction string Yes inbound, outbound, or bidirectional

The webhook_url in the response is the URL to configure in PagerDuty's webhook settings.


PUT /v1/integrations/{id}

Update integration configuration (e.g. set a PagerDuty API token for outbound posting).

curl -X PUT https://api.noctuary.io/v1/integrations/{id} \
  -H "Authorization: Bearer noc_ro_your_key" \
  -H "Content-Type: application/json" \
  -d '{"config": {"pagerduty_token": "your-pd-token"}}'

Response: 200 OK — updated integration object.


DELETE /v1/integrations/{id}

Delete an integration. The webhook URL stops working immediately.

curl -X DELETE https://api.noctuary.io/v1/integrations/{id} \
  -H "Authorization: Bearer noc_ro_your_key"

Response: 204 No Content


POST /v1/integrations/{id}/rotate-token

Rotate the webhook token. The old URL becomes invalid immediately; a new one is returned.

curl -X POST https://api.noctuary.io/v1/integrations/{id}/rotate-token \
  -H "Authorization: Bearer noc_ro_your_key"

Response: 200 OK — updated integration object with new token and webhook_url.

Warning

After rotating, update the webhook URL in PagerDuty immediately or inbound alerts will stop being received.