ClientSphereDocs
API reference/Tasks

Get task stats

Returns task counts grouped by status, using the statuses this workspace has configured.

GET
/tasks/stats

Authorization

AuthorizationRequiredBearer <token>

API key as Bearer token: Authorization: Bearer sk_live_.... Use sk_live_ prefixed keys for production data and sk_test_ prefixed keys for sandbox/test data.

In: header

X-API-Key<token>

API key via header: X-API-Key: sk_live_.... Use sk_live_ prefixed keys for production data and sk_test_ prefixed keys for sandbox/test data.

In: header

curl -X GET "https://clientsphere.io/api/v1/tasks/stats" \
  -H "Authorization: Bearer <token>"

Task counts by status

{
  "data": {
    "total": 42,
    "statuses": [
      {
        "statusId": 0,
        "statusName": "In Progress",
        "statusColor": "#3B82F6",
        "count": 12
      }
    ]
  }
}