Skip to content

Calendar API

Manage calendar tasks and events.

Endpoints

MethodEndpointDescription
GET/api/agents/{id}/calendarList calendar tasks
POST/api/agents/{id}/calendarCreate calendar task
GET/api/agents/{id}/calendar/{taskId}Get task
PUT/api/agents/{id}/calendar/{taskId}Update task
DELETE/api/agents/{id}/calendar/{taskId}Delete task

List Tasks

bash
GET /api/agents/{id}/calendar?start=2024-12-01&end=2024-12-31

Query Parameters

ParameterTypeDescription
startstringStart date (ISO 8601)
endstringEnd date (ISO 8601)

Response

json
{
  "tasks": [
    {
      "id": "task-123",
      "title": "Team Standup",
      "start_time": "2024-12-15T09:00:00Z",
      "end_time": "2024-12-15T09:30:00Z",
      "recurrence": "weekly",
      "recurrence_days": [1, 2, 3, 4, 5],
      "workflow_id": "standup-workflow",
      "status": "pending"
    }
  ]
}

Create Task

bash
POST /api/agents/{id}/calendar
Content-Type: application/json

Request Body

json
{
  "title": "Team Standup",
  "description": "Daily team sync",
  "start_time": "2024-12-15T09:00:00Z",
  "end_time": "2024-12-15T09:30:00Z",
  "recurrence": "weekly",
  "recurrence_days": [1, 2, 3, 4, 5],
  "workflow_id": "standup-workflow"
}

Update Task

bash
PUT /api/agents/{id}/calendar/{taskId}

Delete Task

bash
DELETE /api/agents/{id}/calendar/{taskId}

Recurrence

PatternDescription
noneOne-time
dailyEvery day
weeklySpecific days
monthlySpecific dates

Released under the MIT License.