---
title: "List columns for a report element"
method: GET
path: "/v2/reports/{reportId}/elements/{elementId}/columns"
tags: ["Reports"]
---

# List columns for a report element

`GET /v2/reports/{reportId}/elements/{elementId}/columns`

## Request

- Base URL: `https://api.sigmacomputing.com`
- URL: `https://api.sigmacomputing.com/v2/reports/{reportId}/elements/{elementId}/columns`
- Auth: HTTP bearer

This endpoint retrieves a list of columns associated with a specific element within a report. It provides metadata about each column, such as name and formula, which can be essential for understanding the data structure and for further data manipulation or analysis.

  ### Usage notes
  - Retrieve the **reportId** by calling the [/v2/reports](https://help.sigmacomputing.com/reference/list-reports) endpoint.
  - Retrieve the **elementId** by first calling the [/v2/reports/{reportId}/pages](listreportpages) endpoint, then calling the [/v2/reports/{reportId}/pages/{pageId}/elements](listreportpageelements) endpoint.
  - The element that you request must be a data element, such as a table, pivot table, or visualization. Requesting a UI or control element returns an error.
  - To retrieve element columns from a version-tagged report, pass the `tagName` query parameter with the tag name. Retrieve the tag name by calling the [/v2/reports](https://help.sigmacomputing.com/reference/list-reports) endpoint and using the `tags.tagName` field in the response.

  ### Usage scenarios
  - **Data exploration:** Helps users explore the data structure of a report element, facilitating deeper analysis and understanding.
  - **Integration tasks:** Useful for developers integrating Sigma with other tools that need to know the data structure to map data accurately.

  ### Best practices
  - Validate the **elementId** to make sure it corresponds to the correct report element before querying.
  - Leverage this endpoint when setting up interfaces that require specific knowledge about the data structure.

## Path parameters

- `reportId` string, required
- `elementId` string, required

## Query parameters

- `pageToken` string
- `pageSize` integer
- `tagName` string

## Response `200`

The response body.

- ReportsListReportElementColumnsResponse200
  - `entries` V2ReportsReportIdElementsElementIdColumnsGetResponsesContentApplicationJsonSchemaEntriesItems[], required: Array of results returned by the endpoint
    - `columnId` string, required: Column ID
    - `label` string, required: Column name
    - `formula` string, required: Column formula
    - `type` V2ReportsReportIdElementsElementIdColumnsGetResponsesContentApplicationJsonSchemaEntriesItemsType, required: The column's data type, represented as a recursive type object.
  - `nextPageToken` string: A string that can be passed to the `pageToken` parameter in the next request to fetch the next page of results. Not present in the last page of results. **Must be treated as an opaque string.**

---

[API](https://skmtc.dev/sigmacomputing/apis/sigma-rest-api.md) - [All operations](https://skmtc.dev/sigmacomputing/apis/sigma-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/sigmacomputing/apis/sigma-rest-api/revisions/fb6036208c49?raw)
