Agents API
エージェントはタスクを実行し、データを分析し、ワークフローを自動化できるカスタマイズ可能な AI アシスタントです。Agents API を使用して、組織のエージェントをプログラムで作成および管理します。
ベース URL: https://us.teamday.ai/api/v1/agents
認証: Personal Access Token 必須
エンドポイント概要
| メソッド | エンドポイント | 説明 | 状態 |
|---|---|---|---|
| GET | /agents | すべてのエージェントをリスト表示 | ✅ 動作 |
| POST | /agents | 新しいエージェントを作成 | ✅ 動作 |
| GET | /agents/[id] | エージェントの詳細を取得 | ✅ 動作 |
| PATCH | /agents/[id] | エージェントを更新 | ✅ 動作 |
| DELETE | /agents/[id] | エージェントを削除 | ✅ 動作 |
| POST | /agents/[id]/execute | エージェントを実行 | 🔴 破損 (500 エラー) |
テスト結果: 5/6 エンドポイントが動作中 (83%)
エージェントオブジェクト
プロパティ
{
id: string // エージェント ID (形式: agent_xxx)
name: string // 表示名
role: string // エージェントのロール/目的
systemPrompt: string // システム命令
visibility: string // "private" | "organization" | "public"
organizationId: string // 所有組織
userId: string // 作成者ユーザー ID
createdAt: string // ISO 8601 タイムスタンプ
updatedAt: string // ISO 8601 タイムスタンプ
deletedAt?: string // ソフト削除タイムスタンプ (削除時)
}
オブジェクト例
{
"id": "agent_abc123",
"name": "Research Assistant",
"role": "Research and data analysis",
"systemPrompt": "You are a helpful research assistant specializing in data analysis and summarization.",
"visibility": "private",
"organizationId": "org_xyz789",
"userId": "user_456",
"createdAt": "2025-12-09T10:30:00Z",
"updatedAt": "2025-12-09T10:30:00Z"
}
エージェントをリスト表示
組織のすべてのエージェントを取得します。
リクエスト
GET /api/v1/agents
ヘッダー:
Authorization: Bearer td_xxxxx...
クエリパラメータ: なし
詳細については、Agents API を参照してください。