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

# List lineage for a report

`GET /v2/reports/{reportId}/lineage`

## Request

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

This endpoint lists the data elements in a report and their dependencies and relationships, providing a detailed view of how data is interconnected within a report.

  ### Usage notes
  - Retrieve the **reportId** by calling the [/v2/reports](https://help.sigmacomputing.com/reference/list-reports) endpoint.

  ### Usage scenarios
  - **Data governance:** Allows data managers to track how information is used and propagated through different report elements.
  - **Debugging and optimization:** Helps with identifying and resolving issues in data processing or report structure.
  - **Data source management**: Identify the dependencies of data sources in use in a specific report.

  ### Best practices
  - Integrate this information into documentation or data dictionaries to enhance transparency and understanding across teams.
  - Use this endpoint to regularly audit report structures, ensuring that all data connections and transformations are correct and optimized.

## Path parameters

- `reportId` string, required

## Query parameters

- `pageToken` string
- `pageSize` integer

## Response `200`

The response body.

- ReportsListReportLineageTreeResponse200
  - `entries` V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems[], required: Array of results returned by the endpoint
    - union
      - V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems0
        - `type` 'table' | 'dataset' | 'data-model' | 'element' | 'customSQL' | 'csv-upload' | 'semantic-view' | 'sql-document' | 'worksheet', required
        - `sourceIds` string[], nullable, required: List of direct sources for the element. Either element IDs or data source IDs.
        - `elementId` string, required: Unique identifier of the element
        - `dataSourceIds` string[], nullable, required: List of root sources for the element as data source IDs.
      - V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems1
        - `type` 'table' | 'dataset' | 'data-model' | 'element' | 'customSQL' | 'csv-upload' | 'semantic-view' | 'sql-document' | 'worksheet', required
        - `connectionId` string, nullable, required
        - `name` string, nullable, required
        - `dataModelId` string, required
      - V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems2
        - `type` 'table' | 'dataset' | 'data-model' | 'element' | 'customSQL' | 'csv-upload' | 'semantic-view' | 'sql-document' | 'worksheet', required
        - `connectionId` string, nullable, required
        - `name` string, nullable, required
        - `inodeId` string, required
      - V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems3
        - `type` 'table' | 'dataset' | 'data-model' | 'element' | 'customSQL' | 'csv-upload' | 'semantic-view' | 'sql-document' | 'worksheet', required
        - `connectionId` string, nullable, required
        - `name` string, nullable, required
        - `definition` string, required
      - V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems4
        - `type` 'table' | 'dataset' | 'data-model' | 'element' | 'customSQL' | 'csv-upload' | 'semantic-view' | 'sql-document' | 'worksheet', required
        - `connectionId` string, nullable, required
        - `name` string, nullable, required
        - `csvId` string, required: Unique identifier of the uploaded CSV file
      - V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems5
        - `type` 'table' | 'dataset' | 'data-model' | 'element' | 'customSQL' | 'csv-upload' | 'semantic-view' | 'sql-document' | 'worksheet', required
        - `connectionId` string, nullable, required
        - `name` string, nullable, required
        - `semanticViewId` string, required: Unique identifier of the semantic view
        - `semanticViewTable` string, required: Name of the table within the semantic view
      - V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems6
        - `type` 'table' | 'dataset' | 'data-model' | 'element' | 'customSQL' | 'csv-upload' | 'semantic-view' | 'sql-document' | 'worksheet', required
        - `connectionId` string, nullable, required
        - `name` string, nullable, required
        - `sqlDocumentId` string, required
      - V2ReportsReportIdLineageGetResponsesContentApplicationJsonSchemaEntriesItems7
        - `type` 'table' | 'dataset' | 'data-model' | 'element' | 'customSQL' | 'csv-upload' | 'semantic-view' | 'sql-document' | 'worksheet', required
        - `connectionId` string, nullable, required
        - `name` string, nullable, required
        - `worksheetId` string, required: Unique identifier of the worksheet
  - `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)
