Overview
Retrieve a list of tasks based on filters such as responsible users and date range. This endpoint allows you to fetch tasks assigned to specific team members within a specified time period. Use this endpoint to build task management interfaces, dashboards, or integrate task data with external systems.Use Cases
- Task Dashboard: Display tasks for specific team members or the entire team
- Calendar Views: Show tasks by date range for calendar interfaces
- Team Management: Monitor task assignments and deadlines
- Reporting & Analytics: Generate task completion reports by team member
- Integration: Sync tasks with external project management tools
- Mobile Apps: Fetch tasks for mobile task management applications
Authentication
This endpoint requires authentication using an API key. Include your API key in the request header:Query Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
responsibleIds | string[] | Yes | - | Array of user IDs to filter tasks by responsible team members. Can be empty array for all users. |
fromDate | string | Yes | - | Start date for filtering tasks (ISO 8601 format: YYYY-MM-DD) |
toDate | string | Yes | - | End date for filtering tasks (ISO 8601 format: YYYY-MM-DD) |
includeTasksWithoutDates | boolean | No | true | Whether to include tasks that donβt have a due date in the results |
Response Structure
The endpoint returns an array of task objects:Task Object
| Field | Type | Description |
|---|---|---|
id | string (UUID) | Unique identifier for the task |
title | string | Task title |
description | string | Detailed description of the task |
due_timezone | string | null | Timezone for the due date (e.g., βAmerica/Santiagoβ) |
due_at | string | null | Due date and time (ISO 8601 format) |
is_all_day | boolean | Whether the task is an all-day task |
created_at | string | Task creation date (ISO 8601 format) |
ai_contact_id | string | null | Associated contact ID if applicable |
ai_customer_id | string | null | Associated customer ID if applicable |
task_status_config_id | string (UUID) | ID of the status configuration |
priority | string | Task priority: βlowβ, βmediumβ, or βhighβ |
creator_id | string (UUID) | ID of the user who created the task |
task_responsibles | array | Array of responsible user objects |
status_config | object | null | Custom status configuration object |
Task Responsible Object
| Field | Type | Description |
|---|---|---|
responsible_id | string (UUID) | ID of the responsible user |
Status Config Object
| Field | Type | Description |
|---|---|---|
id | string (UUID) | Status configuration ID |
name | string | Display name for the status |
color | string | Hex color code for the status (e.g., β#60a5faβ) |
type | string | Status type: βinitialβ, βin_progressβ, βdoneβ, or βmaster_doneβ |
order | number | Display order for status (lower numbers appear first) |
Example Request
Example Response
Common Use Cases
1. Fetch Tasks for a Team Member
2. Fetch Tasks for Multiple Team Members
3. Filter Overdue Tasks
4. Group Tasks by Priority
5. Build Task Calendar View
6. Calculate Task Completion Rate
7. Include or Exclude Tasks Without Due Dates
Response Characteristics
- Array Format: Always returns an array, even if empty
- Date Format: All dates are in ISO 8601 format
- Timezone Awareness: Tasks include timezone information for accurate due date handling
- Filtered by Organization: Only returns tasks from your organization
- Sorted: Tasks are ordered by priority (high to low), then by ID
- Tasks Without Dates: By default, tasks without due dates are included when
includeTasksWithoutDates=true(default)
Error Responses
| Status Code | Description |
|---|---|
| 400 | Bad Request - Invalid query parameters or date format |
| 401 | Unauthorized - Invalid or missing API key |
| 500 | Internal Server Error - Something went wrong |
Performance Tips
- Date Range: Use reasonable date ranges to avoid performance issues
- Multiple Agents: Fetching tasks for multiple agents at once is more efficient than individual requests
- Client-side Filtering: Consider fetching a broader date range and filtering on the client
- Pagination: For large result sets, consider implementing date-based pagination
- Caching: Cache results for a few minutes to reduce API calls
Related Endpoints
- POST /api/public/tasks - Create a new task
- PUT /api/public/tasks/ - Update an existing task
- DELETE /api/public/tasks/ - Delete a task
- GET /api/public/team-members/all - Get team members for responsibleIds
Notes
- Required Parameters:
responsibleIds,fromDate, andtoDateare required query parameters - Optional Parameters:
includeTasksWithoutDatesis optional and defaults totrue - Date Format: Use YYYY-MM-DD format for dates (e.g., β2025-10-01β)
- Array Parameters:
responsibleIdsis an array and should be passed asresponsibleIds[]=uuid1&responsibleIds[]=uuid2. An empty array will return tasks for all team members - Time Boundaries:
fromDatestarts at 00:00:00 andtoDateends at 23:59:59 in the server timezone - Status Config: Tasks use custom status configurations (
status_config) instead of simple βopen/doneβ status. Check thestatus_config.typefield for status information - Tasks Without Dates: When
includeTasksWithoutDates=true, tasks without due dates are included regardless of the date range filter
Query Parameters
Response
Returns an array of tasks matching the query criteria
The response is of type object[].
