# Support Assistant API

> Ask Socialit support questions (failed posts, account connection, API usage). Answers are generated with Claude, grounded on the Socialit documentation and on the context you pass (post, account, failed request). Runs are asynchronous: poll the run or listen to support_run.completed.

Base URL: `https://api.socialit.com/v1`. Authenticate with `Authorization: Bearer <API key or OAuth token>`.

## List a thread's support answers

`GET /support/runs`

With thread_id: the whole thread, oldest first. Without: every run of the workspace, newest first.

Access: `read` · MCP tool: `list-support-runs` · Zernio: `GET /v1/support/runs`

### Query parameters

- `page` (integer; ≥ 1): Page number
- `limit` (integer; 1–100): Items per page (max 100)
- `sort` (string; one of created_at)
- `order` (string; one of asc, desc)
- `match` (string; one of all, or): Combine filters with AND (default) or OR
- `thread_id` (string; ≤ 80 characters)
- `status` (string)

```bash
curl "https://api.socialit.com/v1/support/runs" \
  -H "Authorization: Bearer $SOCIALIT_API_KEY"
```

Response 200:

```json
{
  "object": "list",
  "data": [
    {
      "object": "support_run",
      "id": "string",
      "thread_id": "string",
      "status": "queued",
      "stop_reason": "string",
      "question": "string",
      "answer": "string",
      "diagnosis": {
        "category": "account_connection",
        "cause": "string",
        "fix_steps": [
          "string"
        ],
        "docs_links": [
          "string"
        ],
        "who_must_act": "integrator"
      },
      "sources": [
        {
          "title": "string",
          "path": "string",
          "url": "https://example.com"
        }
      ],
      "context": {
        "post_id": "string",
        "account_id": "string",
        "profile_id": "string",
        "request_id": "string"
      },
      "model": "string",
      "usage": {
        "input_tokens": 1,
        "output_tokens": 1,
        "cache_read_tokens": 1,
        "cache_write_tokens": 1
      },
      "cost_usd": 1.5,
      "max_cost_usd": 1.5,
      "support_ticket": {
        "opened_at": "2026-10-13T09:00:00.000Z"
      },
      "poll_after_seconds": 1,
      "created_at": "2026-10-13T09:00:00.000Z",
      "started_at": "2026-10-13T09:00:00.000Z",
      "finished_at": "2026-10-13T09:00:00.000Z"
    }
  ],
  "page": 1,
  "limit": 1,
  "total": 1,
  "has_more": true,
  "next_page_url": "https://example.com",
  "previous_page_url": "https://example.com"
}
```

## Ask a support question

`POST /support/runs`

Returns 202 with a queued run. 503 support_unavailable when the server has no Anthropic API key; 409 support_run_in_progress (one active run per thread); 429 support_active_runs_limit (3 at once).

Access: `write` · MCP tool: `ask-support-question` · Zernio: `POST /v1/support/runs`

### Headers

- `Idempotency-Key` (string; ≤ 255 characters): Unique key (for example a UUID) that makes retries safe: a repeated request with the same key and body returns the first response (Idempotent-Replayed: true) for 24 hours.

### Body

- `message` (string; required; 1–10000 characters)
- `thread_id` (string; ≤ 80 characters)
- `context` (object)
  - `context.post_id` (string)
  - `context.account_id` (string)
  - `context.profile_id` (string)
  - `context.request_id` (string; ≤ 128 characters)
- `max_cost_usd` (number; 0.05–3)

```bash
curl -X POST "https://api.socialit.com/v1/support/runs" \
  -H "Authorization: Bearer $SOCIALIT_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "string",
    "thread_id": "string",
    "context": {
      "post_id": "string",
      "account_id": "string"
    },
    "max_cost_usd": 0.05
  }'
```

Response 202:

```json
{
  "object": "support_run",
  "id": "string",
  "thread_id": "string",
  "status": "queued",
  "stop_reason": "string",
  "question": "string",
  "answer": "string",
  "diagnosis": {
    "category": "account_connection",
    "cause": "string",
    "fix_steps": [
      "string"
    ],
    "docs_links": [
      "string"
    ],
    "who_must_act": "integrator"
  },
  "sources": [
    {
      "title": "string",
      "path": "string",
      "url": "https://example.com"
    }
  ],
  "context": {
    "post_id": "string",
    "account_id": "string",
    "profile_id": "string",
    "request_id": "string"
  },
  "model": "string",
  "usage": {
    "input_tokens": 1,
    "output_tokens": 1,
    "cache_read_tokens": 1,
    "cache_write_tokens": 1
  },
  "cost_usd": 1.5,
  "max_cost_usd": 1.5,
  "support_ticket": {
    "opened_at": "2026-10-13T09:00:00.000Z"
  },
  "poll_after_seconds": 1,
  "created_at": "2026-10-13T09:00:00.000Z",
  "started_at": "2026-10-13T09:00:00.000Z",
  "finished_at": "2026-10-13T09:00:00.000Z"
}
```

## Get a support answer

`GET /support/runs/{id}`

Access: `read` · MCP tool: `get-support-run` · Zernio: `GET /v1/support/runs/{runId}`

### Path parameters

- `id` (string; required; 1–80 characters): supportRun id (srun_…)

```bash
curl "https://api.socialit.com/v1/support/runs/srun_2Jx0Fq5Pz8vYkB3mN6rT1wQ9sLd" \
  -H "Authorization: Bearer $SOCIALIT_API_KEY"
```

Response 200:

```json
{
  "object": "support_run",
  "id": "string",
  "thread_id": "string",
  "status": "queued",
  "stop_reason": "string",
  "question": "string",
  "answer": "string",
  "diagnosis": {
    "category": "account_connection",
    "cause": "string",
    "fix_steps": [
      "string"
    ],
    "docs_links": [
      "string"
    ],
    "who_must_act": "integrator"
  },
  "sources": [
    {
      "title": "string",
      "path": "string",
      "url": "https://example.com"
    }
  ],
  "context": {
    "post_id": "string",
    "account_id": "string",
    "profile_id": "string",
    "request_id": "string"
  },
  "model": "string",
  "usage": {
    "input_tokens": 1,
    "output_tokens": 1,
    "cache_read_tokens": 1,
    "cache_write_tokens": 1
  },
  "cost_usd": 1.5,
  "max_cost_usd": 1.5,
  "support_ticket": {
    "opened_at": "2026-10-13T09:00:00.000Z"
  },
  "poll_after_seconds": 1,
  "created_at": "2026-10-13T09:00:00.000Z",
  "started_at": "2026-10-13T09:00:00.000Z",
  "finished_at": "2026-10-13T09:00:00.000Z"
}
```


---

Source: https://socialit.com/docs/api-reference/support-assistant/
