TODO for AI Logo
TODOforAI API

TODO

Endpoint:/api/v1

Todo management operations


Todo by ID

GET
/api/v1
/todos/{todoId}

Returns a single todo by ID

Todo by IDpath Parameters

  • todoIdstring · required

    ID of the todo to retrieve

Todo by ID Responses

Successful operation

  • idstring
    Example: todo-123
  • projectIdstring
    Example: project-123
  • statusstring · enum
    Enum values:
    LISTENING
    THINKING
    DONE
    FAILED
    CANCELLED
    SCHEDULED
    Example: LISTENING
  • contentstring
    Example: TODO description
  • messagesobject[]
  • createdAtinteger · int64
    Example: 1625097600000
  • lastActivityAtinteger · int64
    Example: 1625097600000
  • scheduledTimestampinteger · int64
    Example: 1625097600000

Update todo

PUT
/api/v1
/todos/{todoId}

Updates a todo with the provided data

Update todopath Parameters

  • todoIdstring · required

    ID of the todo to update

Update todo Request Body

  • statusstring · enum · required
    Enum values:
    LISTENING
    THINKING
    DONE
    FAILED
    CANCELLED
    SCHEDULED
    Example: LISTENING
  • agentSettingsIdstring · required
    Example: agent-123

Update todo Responses

Todo updated successfully

  • successboolean
    Example: true
  • messagestring
    Example: Operation completed successfully

Delete a todo

DELETE
/api/v1
/todos/{todoId}

Deletes a todo by ID

Delete a todopath Parameters

  • todoIdstring · required

    ID of the todo to delete

Delete a todo Responses

Todo deleted successfully

  • successboolean
    Example: true
  • messagestring
    Example: Operation completed successfully

Send message

POST
/api/v1
/todos/{todoId}/messages

Adds a new message to an existing todo

Send messagepath Parameters

  • todoIdstring · required

    ID of the todo

Send message Request Body

  • contentstring · required
    Example: Additional content
  • attachmentsobject[]

Send message Responses

Message added successfully

  • idstring
    Example: message-123
  • contentstring
    Example: Message content
  • rolestring
    Example: user
  • createdAtinteger · int64
    Example: 1625097600000
  • blockTypesstring[]
    Example: ["TEXT","CODE"]
  • blocksstring
    Example: serialized-blocks
  • itokinteger
    Example: 100
  • otokinteger
    Example: 500
  • cache_writeinteger
    Example: 10
  • cache_readinteger
    Example: 5
  • pricenumber · float
    Example: 0.05
  • elapsedinteger
    Example: 2500
  • scheduledTimestampinteger · int64
    Example: 1625097600000
  • attachmentsobject[]
  • attachmentsPricenumber · float
    Example: 0.01
  • attachmentsElapsedinteger
    Example: 500

Update waiting message

PATCH
/api/v1
/todos/{todoId}/messages/{messageId}

Updates a scheduled message

Update waiting messagepath Parameters

  • todoIdstring · required

    ID of the todo

  • messageIdstring · required

    ID of the message

Update waiting message Request Body

  • contentstring
    Example: Updated content
  • attachmentsobject[]
  • scheduledTimestampinteger · int64
    Example: 1625097600000

Update waiting message Responses

Message updated successfully

  • successboolean
    Example: true
  • messagestring
    Example: Operation completed successfully

Update status

PATCH
/api/v1
/todos/{todoId}/status

Updates the status of a todo

Update statuspath Parameters

  • todoIdstring · required

    ID of the todo

Update status Request Body

  • statusstring · enum · required
    Enum values:
    LISTENING
    THINKING
    DONE
    FAILED
    CANCELLED
    SCHEDULED
    Example: DONE

Update status Responses

Todo status updated successfully

  • successboolean
    Example: true
  • messagestring
    Example: Operation completed successfully

Update schedule

PATCH
/api/v1
/todos/{todoId}/schedule

Updates the scheduled timestamp of a todo

Update schedulepath Parameters

  • todoIdstring · required

    ID of the todo

Update schedule Request Body

  • scheduledTimestampinteger · int64 · required
    Example: 1625097600000
  • messageIdstring · required
    Example: message-123
  • agentSettingsIdstring · required
    Example: agent-123

Update schedule Responses

Todo schedule updated successfully

  • successboolean
    Example: true
  • messagestring
    Example: Operation completed successfully

Start waiting Todo

POST
/api/v1
/todos/{todoId}/start

Starts processing a todo immediately

Start waiting Todopath Parameters

  • todoIdstring · required

    ID of the todo

Start waiting Todo Request Body

  • messageIdstring · required
    Example: message-123
  • agentSettingsIdstring · required
    Example: agent-123

Start waiting Todo Responses

Todo started successfully

  • successboolean
    Example: true
  • messagestring
    Example: Operation completed successfully

Update and start a todo

POST
/api/v1
/todos/{todoId}/update-start

Updates a todo and starts processing it immediately

Update and start a todopath Parameters

  • todoIdstring · required

    ID of the todo

Update and start a todo Request Body

  • messageIdstring · required
    Example: message-123
  • agentSettingsIdstring · required
    Example: agent-123
  • attachmentsobject[]
  • contentstring
    Example: Updated content

Update and start a todo Responses

Todo updated and started successfully

  • successboolean
    Example: true
  • messagestring
    Example: Operation completed successfully

Create todo

POST
/api/v1
/projects/{projectId}/todos

Creates a new todo for a specific project

Create todopath Parameters

  • projectIdstring · required

    ID of the project

Create todo Request Body

  • todoIdstring · required
    Example: todo-123
  • projectIdstring · required
    Example: project-123
  • contentstring · required
    Example: TODO content
  • rolestring · required
    Example: user
  • agentSettingsIdstring · required
    Example: agent-123
  • attachmentsobject[] · required
  • scheduledTimestampinteger · int64
    Example: 1625097600000

Create todo Responses

Todo created successfully

  • idstring
    Example: todo-123
  • projectIdstring
    Example: project-123
  • statusstring · enum
    Enum values:
    LISTENING
    THINKING
    DONE
    FAILED
    CANCELLED
    SCHEDULED
    Example: LISTENING
  • contentstring
    Example: TODO description
  • messagesobject[]
  • createdAtinteger · int64
    Example: 1625097600000
  • lastActivityAtinteger · int64
    Example: 1625097600000
  • scheduledTimestampinteger · int64
    Example: 1625097600000