thefaqapp
API Reference

A P I Keys

Manage API keys

Manage API keys

List API keys

GET
/api/v1/{organizationSlug}/api-keys

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/api-keys"
{
  "data": [
    {
      "id": "string",
      "name": "string",
      "scopes": [
        "read"
      ],
      "lastUsedAt": "2019-08-24T14:15:22Z",
      "createdAt": "2019-08-24T14:15:22Z",
      "expiresAt": "2019-08-24T14:15:22Z"
    }
  ]
}
Empty

Create an API key

POST
/api/v1/{organizationSlug}/api-keys

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/api-keys" \  -H "Content-Type: application/json" \  -d '{    "name": "string",    "scopes": [      "read"    ]  }'
{
  "data": {
    "id": "string",
    "name": "string",
    "scopes": [
      "read"
    ],
    "createdAt": "2019-08-24T14:15:22Z",
    "expiresAt": "2019-08-24T14:15:22Z",
    "key": "string"
  }
}
Empty
Empty

Revoke an API key

DELETE
/api/v1/{organizationSlug}/api-keys/{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

API key ID

Response Body

application/json

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