Integrations
Preview

Resume an integration

POST
/integrations/{provider}/resume
cookiebetter-auth.session_token<token>

Better Auth session cookie. Production uses the __Secure- prefixed name.

provider*string

The provider's name, such as github, slack, prometheus, servicenow or jira.

Length1 <= length <= 40
Idempotency-Key?string

Makes retries safe. A repeated key with the same request returns the first result and sets Idempotent-Replayed: true. The same key with a different request answers 409 idempotency.key_reused, and while the first request is still running 409 idempotency.in_progress. Results are kept for 24 hours. Server errors and refusals for lack of sign-in or permission are not kept, so a retry runs again.

Match^[A-Za-z0-9_.:-]+$
Length1 <= length <= 255

Response Body

The integration after the change.

application/json
  1. response
provider*string
configured*boolean

Whether this organization has the provider connected.

status*IntegrationStatus
Value in"not_configured""connected""degraded""down""paused"
lastEventAt*|
Formatdate-time
lastEventResult*|null
detail*

Provider specific counts. For github, installations, suspended and paused.

health?
usedBy?array<>

What depends on the integration, and whether it reads ok or wait now.

ifItFails?string

In a sentence, what happens while the provider is down.

canDisconnect?boolean
inbound?boolean

Whether the provider sends Wardn webhooks or clicks, so receipts are listed.

deliveries?
backlog?

Events still to go to the provider.

Example Request
curl -X POST 'https://wardn.example.com/api/v1/integrations/string/resume'
Example Response
{  "provider": "github",  "configured": true,  "status": "not_configured",  "lastEventAt": "2019-08-24T14:15:22Z",  "lastEventResult": "accepted",  "detail": {    "property1": 0,    "property2": 0  },  "health": {    "state": "not_configured",    "reason": "string",    "since": "2019-08-24T14:15:22Z",    "retryAt": "2019-08-24T14:15:22Z",    "lastSuccessAt": "2019-08-24T14:15:22Z",    "responseMs": 0,    "usualMs": 0,    "rulesWait": true  },  "usedBy": [    {      "label": "string",      "href": "string",      "reading": "ok",      "rule": true,      "count": 0    }  ],  "ifItFails": "string",  "canDisconnect": true,  "inbound": true,  "deliveries": {    "windowHours": 0,    "delivered": 0,    "retrying": 0,    "dead": 0,    "accepted": 0,    "rejected": 0  },  "backlog": {    "pending": 0,    "retrying": 0,    "dead": 0,    "oldestAt": "2019-08-24T14:15:22Z"  }}