> This page is for API.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.eon.io/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.eon.io/_mcp/server.

# Get Query Result

GET https://%7Baccount-domain%7D.console.eon.io/api/v1/projects/{projectId}/queries/{queryId}/results

Retrieves the results of a query.

This method requires a query ID, which you can get only from the [Run Query](./run-query) response.

This method can be used only when a query has completed.
You can check a query's status by calling [Get Query Status](./get-query-status).


Reference: https://docs.eon.io/api/api-reference/query-databases/get-query-result

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Request

### Path parameters

- `projectId` (string, required) — ID of the project that contains the query you want to retrieve. You can see your project ID in the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
- `queryId` (string, required) — Query ID returned by [Run Query](./run-query).

### Query parameters

- `pageSize` (integer, optional, default: 500) — Maximum number of items to return in the response.
- `pageToken` (string, optional) — Cursor that points to the first record of the next page of results. Get this value from the previous response.

## Response

### 200

Query results retrieved.

- `columns` (list of string, required) — List of the column names in the returned records.
- `records` (list of list of string, required) — List of records, returned as an array of arrays. The inner array contains the values of the columns in the same order as returned in `columns`.
- `nextToken` (string, required, nullable) — Cursor that points to the first record of the next page of results. Pass this value in the next request.

## Errors

### 404 Not Found Error

Query wasn't found.

- `any`

## Examples

**Response**

```json
{
  "columns": [
    "id",
    "name",
    "age"
  ],
  "records": [
    [
      "1",
      "John",
      "25"
    ],
    [
      "2",
      "Jane",
      "30"
    ]
  ],
  "nextToken": "string"
}
```

**SDK Code**

```python
import requests

url = "https://{account-domain}.console.eon.io/api/v1/projects/330e9e09-6cb8-52af-b532-a476f598cf94/queries/330e9e09-6cb8-52af-b532-a476f598cf94%3A3fdf3419-366b-5e58-847d-c4671f79ce8f/results"

querystring = {"pageSize":"10"}

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers, params=querystring)

print(response.json())
```

```javascript
const url = 'https://{account-domain}.console.eon.io/api/v1/projects/330e9e09-6cb8-52af-b532-a476f598cf94/queries/330e9e09-6cb8-52af-b532-a476f598cf94%3A3fdf3419-366b-5e58-847d-c4671f79ce8f/results?pageSize=10';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://{account-domain}.console.eon.io/api/v1/projects/330e9e09-6cb8-52af-b532-a476f598cf94/queries/330e9e09-6cb8-52af-b532-a476f598cf94%3A3fdf3419-366b-5e58-847d-c4671f79ce8f/results?pageSize=10")
  .header("Authorization", "Bearer <token>")
  .asString();
```