thefaqapp
API Reference

Webhooks

Manage webhooks

Manage webhooks

List webhooks

GET
/api/v1/{organizationSlug}/webhooks

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard under Settings > API Keys.

In: header

Path Parameters

organizationSlug*string

Response Body

application/json

curl -X GET "https://app.thefaq.app/api/v1/string/webhooks"
{
  "data": [
    {
      "id": "string",
      "url": "http://example.com",
      "events": [
        "string"
      ],
      "active": true,
      "description": "string",
      "deliveryCount": 0,
      "createdAt": "2019-08-24T14:15:22Z",
      "updatedAt": "2019-08-24T14:15:22Z"
    }
  ]
}
Empty

Create a webhook

POST
/api/v1/{organizationSlug}/webhooks

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard under Settings > API Keys.

In: header

Path Parameters

organizationSlug*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://app.thefaq.app/api/v1/string/webhooks" \  -H "Content-Type: application/json" \  -d '{    "url": "http://example.com",    "events": [      "question.created",      "question.updated"    ]  }'
{
  "data": {
    "id": "string",
    "url": "http://example.com",
    "events": [
      "string"
    ],
    "active": true,
    "description": "string",
    "secret": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z"
  }
}
Empty
Empty
Empty

Get webhook

GET
/api/v1/{organizationSlug}/webhooks/{id}

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard under Settings > API Keys.

In: header

Path Parameters

organizationSlug*string
id*string

Webhook ID

Response Body

application/json

curl -X GET "https://app.thefaq.app/api/v1/string/webhooks/string"
{
  "data": {
    "id": "string",
    "url": "http://example.com",
    "events": [
      "string"
    ],
    "active": true,
    "description": "string",
    "deliveryCount": 0,
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z"
  }
}
Empty
Empty

Update a webhook

PATCH
/api/v1/{organizationSlug}/webhooks/{id}

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard under Settings > API Keys.

In: header

Path Parameters

organizationSlug*string
id*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X PATCH "https://app.thefaq.app/api/v1/string/webhooks/string" \  -H "Content-Type: application/json" \  -d '{}'
{
  "data": {
    "id": "string",
    "url": "http://example.com",
    "events": [
      "string"
    ],
    "active": true,
    "description": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z"
  }
}
Empty
Empty
Empty

Delete a webhook

DELETE
/api/v1/{organizationSlug}/webhooks/{id}

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard under Settings > API Keys.

In: header

Path Parameters

organizationSlug*string
id*string

Response Body

application/json

curl -X DELETE "https://app.thefaq.app/api/v1/string/webhooks/string"
{
  "data": {
    "id": "string",
    "deleted": true
  }
}
Empty
Empty

Send test ping

POST
/api/v1/{organizationSlug}/webhooks/{id}/test

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard under Settings > API Keys.

In: header

Path Parameters

organizationSlug*string
id*string

Response Body

application/json

curl -X POST "https://app.thefaq.app/api/v1/string/webhooks/string/test"
{
  "data": {
    "deliveryId": "string",
    "event": "ping",
    "message": "string"
  }
}
Empty
Empty
Empty

List webhook deliveries

GET
/api/v1/{organizationSlug}/webhooks/{id}/deliveries

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard under Settings > API Keys.

In: header

Path Parameters

organizationSlug*string
id*string

Query Parameters

limit?|
Rangevalue <= 100
cursor?string

Cursor for next page

Response Body

application/json

curl -X GET "https://app.thefaq.app/api/v1/string/webhooks/string/deliveries"
{
  "data": [
    {
      "id": "string",
      "event": "string",
      "statusCode": 0,
      "responseMs": 0,
      "success": true,
      "error": "string",
      "attempt": 0,
      "maxAttempts": 0,
      "createdAt": "2019-08-24T14:15:22Z"
    }
  ],
  "meta": {
    "nextCursor": "string"
  }
}
Empty
Empty

Replay a delivery

POST
/api/v1/{organizationSlug}/webhooks/{id}/deliveries/{deliveryId}/replay

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard under Settings > API Keys.

In: header

Path Parameters

organizationSlug*string
id*string
deliveryId*string

Delivery ID to replay

Response Body

application/json

curl -X POST "https://app.thefaq.app/api/v1/string/webhooks/string/deliveries/string/replay"
{
  "data": {
    "deliveryId": "string",
    "message": "string"
  }
}
Empty
Empty
Empty