任务 API
任务表示可以分配给代理或用户的工作项。使用任务 API 来管理工作流、跟踪进度并在组织中协调工作。
基础 URL: https://us.teamday.ai/api/v1/tasks
身份验证: 需要个人访问令牌
端点概述
| 方法 | 端点 | 描述 | 状态 |
|---|---|---|---|
| GET | /tasks | 列出任务 | 🟡 未测试 |
| POST | /tasks | 创建新任务 | 🟡 未测试 |
实现状态: 完成但未在生产中测试
任务对象
属性
{
id: string // 任务 ID(格式:task_xxx)
title: string // 任务标题
description: string // 详细描述
status: string // "pending" | "in_progress" | "completed" | "cancelled"
priority: string // "low" | "medium" | "high" | "urgent"
assignedTo?: string // 代理或用户 ID
assigneeType: string // "agent" | "user"
spaceId?: string // 关联的工作区
organizationId: string // 所有者组织
createdBy: string // 创建者用户 ID
createdAt: string // ISO 8601 时间戳
updatedAt: string // ISO 8601 时间戳
dueDate?: string // ISO 8601 时间戳
completedAt?: string // ISO 8601 时间戳
metadata: object // 其他任务上下文
}
示例对象
{
"id": "task_abc123",
"title": "Analyze Q4 sales data",
"description": "Review Q4 sales performance and identify trends",
"status": "in_progress",
"priority": "high",
"assignedTo": "agent_xyz789",
"assigneeType": "agent",
"spaceId": "space_456",
"organizationId": "org_123",
"createdBy": "user_789",
"createdAt": "2025-12-09T09:00:00Z",
"updatedAt": "2025-12-09T10:30:00Z",
"dueDate": "2025-12-10T17:00:00Z",
"metadata": {
"tags": ["sales", "analytics", "quarterly"],
"source": "api"
}
}
列出任务
检索组织的任务,支持可选的筛选。