v2
latestOpenAPI 3.1.02026-07-3171165552.0 KBAssistant
Get Assistant Task
Poll the status and results of an assistant task. Call this endpoint repeatedly until the status is SUCCESS.
Task States
| Status | Description |
|---|---|
| PENDING | Task is queued, not yet started |
| STARTED | Task is actively processing — info contains progress details |
| SUCCESS | Task completed — result contains the full response |
| FAILURE | Task failed — error contains the error message |
| CANCELLED | Task was cancelled via the cancel endpoint |
| REVOKED | Task was revoked |
Progress Info (during STARTED)
While the task is running, the info field provides real-time progress:
{
"id": "abc123",
"status": "STARTED",
"info": {
"step": "EXECUTING_SEARCHES",
"stepNumber": 3,
"response": "partial response text...",
"searches": ["query 1", "query 2"],
"publicationsUsed": ["10.1234/example"],
"publicationsConsulting": ["Author et al., Title, Journal, 2024"],
"currentSearch": "current query being executed"
}
}
Processing steps in order:
- SCHEDULING_ASSISTANT — task queued
- GENERATING_SEARCH_STRATEGY — AI generating search queries
- EXECUTING_SEARCHES — running queries against Elasticsearch
- RETRIEVING_UPLOADED_DOCUMENTS — loading reference check documents (if applicable)
- RETRIEVING_PRIMARY_SOURCES — enriching with primary source data
- COMPOSING_RESPONSE — preparing context for LLM
- GENERATING_RESPONSE — LLM generating the answer
Success Result
{
"id": "abc123",
"status": "SUCCESS",
"result": {
"title": "How does protein structure affect function?",
"sessionId": 42,
"slug": "how-does-protein-structure-affect-function-xK9mP",
"turns": [...],
"lastUpdated": "2025-01-15",
"createdAt": "2025-01-15",
"tooManySessions": false
}
}
Turn Structure
Each assistant turn in the turns array contains:
| Field | Type | Description |
|---|---|---|
| role | str | "user" or "assistant" |
| content | str | Response text with numbered citation markers like [1], [2] |
| structuredResponse | list or null | Structured response data (when useStructuredResponse was true) |
| references | list | Cited references (see below) |
| searchStrategy | list[str] or null | Search queries that were used |
| warning | str or null | Warning message if applicable |
| model | str or null | The model that generated this response |
| settings | dict or null | Settings applied (e.g., AI-suggested rankBy, yearFrom, yearTo) |
| publicationsConsulted | list[dict] or null | All publications considered (including unused ones) |
Reference Structure
Each reference in the references array:
| Field | Type | Description |
|---|---|---|
| answer | str | The relevant text passage (citation statement or abstract excerpt) |
| texts | list[str] | Text passages used |
| context | str | Surrounding context of the passage |
| title | str | Paper title |
| doi | str | Paper DOI |
| link | str | Link to the scite report page |
| type | str | "abstract" or "citation_statement" |
| paper | object | Full paper metadata (title, authors, journal, year, date, abstract, tally, DOI, etc.) |
| patent | object or null | Patent data if from patent search |
| refCheckId | str or null | Reference check task ID if from uploaded document |
get/api_partner/assistant/tasks/{task_id}
Path parameters
task_idstring required
Headers
authorizationstring
Set to Bearer <token> to pass token for authorization.
Set to Bearer <token> to pass token for authorization.
Response
Successful Response