List Activities
Query task-type activities visible to your integration.
GET /api/integration/activities/tasks
Returns a paginated list of task-type activities visible to your integration's API key, from one project or from the whole tenant (see Required header).
Authentication: Required — permission activity:view
Required header
| Header | Value |
|---|---|
x-api-key | YOUR_API_KEY |
x-project-id is optional: this is a project-optional endpoint. With a tenant key or a user token, sending the header narrows the list to that project; without it, the list covers every project of the tenant, and each activity carries its projectId. A project key always lists the activities of its own project. A header that is sent is validated — see Project errors.
Query parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
page | number | No | Page number (default: 1) |
per_page | number | No | Results per page (default: 25, max: 100) |
status | string | No | Filter by activity status (see Activity States). Filterable values: READY, RETRYING, DISPATCHED, COMPLETED, CANCELED, FAILED |
result_status | string | No | Filter by result status (see Activity States). Filterable values: COMPLETED, NOT_EXECUTED |
channel | string | No | Filter by channel (SALESMAN, CALLCENTER, etc.) |
external_commerce_id | string | No | Filter by commerce external ID |
external_operator_id | string | No | Filter by operator external ID |
scheduled_from | string | No | Minimum scheduled date (ISO 8601) |
scheduled_to | string | No | Maximum scheduled date (ISO 8601) |
Example
curl -X GET "BASE_URL/api/integration/activities/tasks?page=1&per_page=10&status=READY" \
-H "x-api-key: YOUR_API_KEY"const params = new URLSearchParams({
page: "1",
per_page: "10",
status: "READY",
});
const response = await fetch(
`${BASE_URL}/api/integration/activities/tasks?${params}`,
{
headers: {
"x-api-key": "YOUR_API_KEY",
},
}
);
const data = await response.json();import requests
response = requests.get(
f"{BASE_URL}/api/integration/activities/tasks",
headers={
"x-api-key": "YOUR_API_KEY",
},
params={
"page": 1,
"per_page": 10,
"status": "READY",
},
)
data = response.json()Response 200 OK
The following is an illustrative example of the response shape. Values for fields such as id, scheduledAt, status, lifecycleStatus, etc., vary depending on the actual state of each activity. For the complete catalog of possible status and lifecycleStatus values, see Activity States.
{
"data": [
{
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"activityOrigin": "ACTIVITY",
"projectId": "3f6c2b1a-8d4e-4f7a-9b2c-5e1d0a7f6c34",
"type": "TASK",
"intentCategory": "SALES",
"formId": "3f6c2a9e-8b41-4d7a-9c15-2e7f0b6d4a81",
"status": "READY",
"score": 85,
"channel": "SALESMAN",
"scheduledAt": "2026-04-10T18:00:00.000Z",
"occurredAt": null,
"createdAt": "2026-04-10T14:30:00.000Z",
"lifecycleStatus": "READY",
"lifecycleStatusLabel": "Lista",
"lifecycleStatusDetail": null,
"canForceRetryDispatch": false,
"commerceExternalId": "COM-001",
"commerceName": "Farmacia Central",
"reason": {
"code": "CHURN_RISK",
"label": "Riesgo de fuga"
},
"originReasons": [
{
"code": "repurchase",
"description": "Recompra: compra cada 15 días"
}
],
"userStatus": null,
"commerceAssignment": {
"commerceExternalId": "COM-001",
"assignmentReason": "Asignación por ruta",
"commerce": {
"externalId": "COM-001",
"name": "Farmacia Central"
}
},
"activityDetails": {
"type": "TASK",
"assignedRouteCode": "RUTA-NORTE-01",
"assignedOperatorExternalId": "OP-042",
"assignedRoute": {
"code": "RUTA-NORTE-01",
"name": "Ruta Norte"
},
"assignedOperator": {
"externalId": "OP-042",
"name": "Carlos Pérez",
"type": "SALESMAN"
}
},
"activityResult": null
}
],
"pagination": {
"page": 1,
"per_page": 10,
"total": 47,
"total_pages": 5,
"has_next": true,
"has_previous": false
}
}Standalone execution example
Items with activityOrigin: "STANDALONE" come from a result registered as a standalone execution, without a preceding activity: scheduledAt repeats the result's occurredAt, and activityResult is always populated. A populated activityResult also appears on ACTIVITY items once they have been handled.
Only the item is shown below — the surrounding pagination envelope is identical to the one above.
{
"id": "b2c3d4e5-f6a7-8901-bcde-f23456789012",
"activityOrigin": "STANDALONE",
"projectId": "3f6c2b1a-8d4e-4f7a-9b2c-5e1d0a7f6c34",
"type": null,
"intentCategory": null,
"formId": null,
"reason": null,
"originReasons": [],
"userStatus": null,
"status": null,
"score": null,
"scheduledAt": "2026-04-12T16:45:00.000Z",
"occurredAt": "2026-04-12T16:45:00.000Z",
"createdAt": "2026-04-12T16:47:00.000Z",
"lifecycleStatus": null,
"lifecycleStatusLabel": null,
"lifecycleStatusDetail": null,
"canForceRetryDispatch": false,
"channel": "SALESMAN",
"commerceExternalId": "COM-001",
"commerceName": "Farmacia Central",
"commerceAssignment": null,
"activityResult": {
"id": "b2c3d4e5-f6a7-8901-bcde-f23456789012",
"resultStatus": "COMPLETED",
"source": "STANDALONE",
"origin": "PLATFORM",
"channel": "SALESMAN",
"occurredAt": "2026-04-12T16:45:00.000Z",
"createdAt": "2026-04-12T16:47:00.000Z",
"resultDetails": {
"type": "TASK",
"result": {
"code": "RESCHEDULE",
"label": "Reprogramar visita"
},
"comment": null,
"requiresFutureScheduledAt": true,
"externalOperatorId": "OP-042",
"operator": {
"externalId": "OP-042",
"name": "Carlos Pérez"
},
"isEffective": true,
"modality": null,
"futureScheduledAt": "2026-04-20",
"formId": null,
"formVersion": null,
"answers": null
}
},
"activityDetails": {
"type": "TASK",
"assignedRouteCode": null,
"assignedOperatorExternalId": "OP-042",
"assignedRoute": null,
"assignedOperator": {
"externalId": "OP-042",
"name": "Carlos Pérez",
"type": "SALESMAN"
}
}
}Activity fields
| Field | Type | Description |
|---|---|---|
id | string | Unique activity identifier |
activityOrigin | "ACTIVITY" | "STANDALONE" | Activity origin |
projectId | string | Project the activity belongs to |
type | string | null | Activity type (e.g., "TASK") |
intentCategory | string | null | Category of the activity, fixed when it is created: one of the intentCategory values of a form. It is always the category of the form of its formId, and it does not serve to choose a form: several forms can share a category. null only on STANDALONE items |
formId | string | null | Id of the result form the activity is answered with. The item does not carry the version: the form does. null on STANDALONE items and on a task created before result forms existed, which is answered only with the current format |
status | string | null | Current activity status — see Activity States for the complete catalog |
score | number | null | Activity priority score (set at creation) |
channel | string | null | Activity channel (SALESMAN, CALLCENTER, etc.) |
scheduledAt | string | null | Scheduled date (ISO 8601) |
occurredAt | string | null | Date when the activity was handled (ISO 8601) |
createdAt | string | null | Creation date (ISO 8601) |
lifecycleStatus | string | null | Lifecycle status for display (read-only, computed) — see Activity States |
lifecycleStatusLabel | string | null | Human-readable lifecycle status label |
lifecycleStatusDetail | string | null | Additional status detail |
canForceRetryDispatch | boolean | Indicates whether a re-dispatch can be forced |
commerceExternalId | string | External ID of the associated commerce |
commerceName | string | Commerce name |
reason | object | null | Activity reason (code, label) |
originReasons | array | Origin reasons the activity was created with (code, description), in the order they were sent. [] on an activity created without them and on STANDALONE items |
userStatus | object | null | Custom user status (code, label) |
commerceAssignment | object | null | Commerce assignment information |
activityDetails | object | null | Type-specific activity details |
activityResult | object | null | Activity result (if exists) |
activityDetails fields (TASK type)
| Field | Type | Description |
|---|---|---|
type | "TASK" | Type discriminator |
assignedRouteCode | string | null | Assigned route code |
assignedOperatorExternalId | string | null | Assigned operator external ID |
assignedRoute | object | null | Assigned route (code, name) |
assignedOperator | object | null | Assigned operator (externalId, name, type) |
activityResult fields
| Field | Type | Description |
|---|---|---|
id | string | Result identifier |
resultStatus | string | Result status — see Activity States §resultStatus |
source | string | Result source |
origin | string | Origin channel |
channel | string | null | Result channel |
occurredAt | string | Date when it occurred (ISO 8601) |
createdAt | string | Creation date (ISO 8601) |
resultDetails | object | null | Task result details |
resultDetails fields (TASK type)
| Field | Type | Description |
|---|---|---|
type | "TASK" | Type discriminator |
result | object | Result (code, label). In a result submitted with answers, label is the label of the chosen option in the version of the form that was answered, and it does not change if the form changes later. In a result without answers, it is the label of the tenant's result type. In an auto-close, code is NOT_EXECUTED and label is null |
comment | string | null | Comment submitted along with the result |
requiresFutureScheduledAt | boolean | Indicates whether the submitted result type requires a future_scheduled_at date. In a result submitted with answers, it is the flag that code has among the tenant's result types, active or not, and false if the tenant does not have that code. An integration that sends answers does not need it: the form says it, with the future_scheduled_at question |
externalOperatorId | string | null | External ID of the operator who submitted the result |
operator | object | null | Operator who submitted the result (externalId, name) |
isEffective | boolean | Whether the result counts as an effective contact |
modality | string | null | visit or remote: the answer to the modality question. null when the result was not submitted with answers, or the modality question was not answered or is not in the form |
futureScheduledAt | string | null | Scheduled date as YYYY-MM-DD. With answers, exactly as it was answered; without answers, the day of the stored date and time in the tenant's time zone |
formId | string | null | Form the result was validated against. null when the result did not come from a submission with answers: one sent in the current format, an auto-close, or a standalone execution |
formVersion | number | null | Version of the form the result was validated against. null in the same cases as formId |
answers | array | null | Every answer of the submission, in the order of the form, with the shape of the response of the submission: key, keyLabel, value and valueLabel. null in the same cases as formId |
The item and resultDetails each carry a formId: the one of the item is the form the activity is answered with; the one of resultDetails, the form its result was validated against.
The resultDetails of a result submitted with answers:
{
"type": "TASK",
"result": {
"code": "call_rescheduled",
"label": "Pide que lo llamen otro día"
},
"comment": "Pide que lo llamen la próxima semana.",
"requiresFutureScheduledAt": true,
"externalOperatorId": "OP-042",
"operator": {
"externalId": "OP-042",
"name": "Carlos Pérez"
},
"isEffective": true,
"modality": "remote",
"futureScheduledAt": "2026-11-12",
"formId": "3f6c2a9e-8b41-4d7a-9c15-2e7f0b6d4a81",
"formVersion": 3,
"answers": [
{
"key": "modality",
"keyLabel": "¿Cómo hiciste esta gestión?",
"value": "remote",
"valueLabel": "Llamado o mensaje"
},
{
"key": "contact",
"keyLabel": "¿Hubo contacto con el cliente?",
"value": "yes",
"valueLabel": "Sí"
},
{
"key": "code",
"keyLabel": "¿Cómo terminó la gestión?",
"value": "call_rescheduled",
"valueLabel": "Pide que lo llamen otro día"
},
{
"key": "future_scheduled_at",
"keyLabel": "¿Para cuándo queda agendada?",
"value": "2026-11-12"
},
{
"key": "comment",
"keyLabel": "Comentarios",
"value": "Pide que lo llamen la próxima semana."
}
]
}Errors
| Status | Description |
|---|---|
401 | Invalid, revoked or expired API key, or its owner is inactive (see Errors) |
403 | The key does not have the activity:view permission |
400 / 403 / 404 | The x-project-id that was sent is not valid — see Project errors |