Quickchat AI は、AI Agent の設定、Knowledge Base、Conversations、AI Actions などにプログラムからアクセスするための REST API を提供しています。
Authentication
Section titled “Authentication”すべての API エンドポイントは Bearer トークン認証を使用します。すべてのリクエストの Authorization ヘッダーに API トークンを含めてください:
Authorization: Bearer <API_TOKEN>トークンは Quickchat Dashboard の External Apps > API で作成します。各トークンは scenario_id を含む JWT であるため、追加の識別子ヘッダーは不要です。
- トークン有効期間:作成から 52 週間
- トークンは Dashboard からいつでも 無効化 できます
- 各トークンは単一の AI Agent(シナリオ)にスコープされます
- トークンの作成には Business プラン以上が必要です。下位のプランではこのオプションは無効化され、エンドポイントは
402 Payment Requiredを返します
Token Scopes
Section titled “Token Scopes”API トークンは次の 2 つのスコープのいずれかで作成されます:
| Scope | Access Level | Description |
|---|---|---|
read_all | Read-only | すべてのリソースを読み取れますが、作成・更新・削除はできません |
write_all | Read + Write | 書き込み操作を含む、すべてのエンドポイントへのフルアクセス |
- トークンは、Dashboard の External Apps > API で作成する際にスコープが割り当てられます
write_allスコープには、すべてのread_all権限が自動的に含まれますread_allトークンを書き込みエンドポイントで使用すると、"Insufficient token scope. Required: write_all"とともに403が返されます
エンドポイントグループごとのスコープ要件:
| Endpoint Group | Read Operations | Write Operations |
|---|---|---|
| Chatbot Settings | read_all | write_all |
| Knowledge Base Settings | read_all | write_all |
| Articles | read_all | write_all |
| Article Language URLs | read_all | write_all |
| Tags | read_all | — |
| File Upload | — | write_all |
| Import External Content | — | write_all |
| Intercom Knowledge Base | read_all | write_all |
| Widget Configuration | read_all | write_all |
| Conversations | read_all | — |
| Conversation Metadata | read_all | write_all |
| Handoff Configuration | read_all | write_all |
| Conversation Rating | read_all | write_all |
| AI Actions | read_all | write_all |
Base URL
Section titled “Base URL”| Endpoint Group | Base URL |
|---|---|
| Knowledge Base, AI Actions, File Upload, Import, Chatbot Settings, Widget, Handoff, Conversation Rating | https://app.quickchat.ai/v1/api/ |
| Conversations | https://app.quickchat.ai/v1/api_core/ |
| Realtime Chat | https://app.quickchat.ai/chat |
Rate Limits
Section titled “Rate Limits”レート制限はトークンごと、エンドポイントごとに適用されます。
| Tier | Limit | Applies To |
|---|---|---|
| READ | 120 requests/min | GET およびリスト操作 |
| WRITE | 60 requests/min | POST、PATCH、PUT、DELETE |
| HEAVY | 20 requests/min | ファイルアップロード、インポート、スクレイピング |
レート制限を超過すると、API は HTTP 429 Too Many Requests を返します。
Pagination
Section titled “Pagination”リストエンドポイントはクエリパラメータによるページネーションをサポートしています:
| Parameter | Description |
|---|---|
limit integer | 1 ページあたりのアイテム数 |
offset integer | スキップするアイテム数 |
ページネーションのレスポンスは次の構造に従います:
{ "items": [], "offset": 0, "limit": 10, "count": 100}Error Handling
Section titled “Error Handling”すべてのエラーは次の形式の JSON で返されます:
{ "errors": { "root": [ { "message": "Description of the error", "code": "ERROR_CODE" } ] }}| Status | Code | Description |
|---|---|---|
| 400 | BAD_REQUEST | 不正な入力、または必須フィールドの欠落 |
| 401 | PERMISSION_DENIED | 無効、期限切れ、または無効化されたトークン |
| 402 | PAYMENT_REQUIRED | 有効なサブスクリプションが必要 |
| 403 | PERMISSION_DENIED | トークンにこの操作に必要なスコープがありません |
| 404 | NOT_FOUND | リソースが見つかりません |
| 409 | CONFLICT | 競合する操作(例:同時変更) |
| 422 | VALIDATION_ERROR | リクエストボディがスキーマバリデーションに失敗 |
| 429 | TOO_MANY_REQUESTS | レート制限超過 |
| 500 | UNKNOWN | 内部サーバーエラー |
| 503 | SERVICE_UNAVAILABLE | 一時的な利用不可 |