## Query Task Workflow

**get** `/tasks/{task_id}/query/{query_name}`

Query a Temporal workflow associated with a task for its current state.

### Path Parameters

- `task_id: string`

- `query_name: string`

### Example

```http
curl http://localhost:5003/tasks/$TASK_ID/query/$QUERY_NAME \
    -H "Authorization: Bearer $AGENTEX_SDK_API_KEY"
```

#### Response

```json
{
  "foo": "bar"
}
```
