Skip to navigation

Get a report

View as Markdown

This endpoint retrieves a report by its unique identifier (reportId). It provides detailed information about the report, including its name, URL, path, and other metadata.

Usage notes

  • The reportId parameter must be a valid UUID that uniquely identifies the report. Invalid or nonexistent IDs return an error. Retrieve the reportId by calling the /v2/reports endpoint.

Usage scenarios

  • Report search: Allows users to view all of their reports and locate a specific one, as well as filter by criteria such as if it is archived.
  • Data retrieval: Developers can use this endpoint to programmatically retrieve details about a specific report to display its content or metadata in a custom user interface.
  • Integration: Use this endpoint for integrations where other systems need to fetch report details based on an ID provided through another interface or workflow.

Best practices

  • Validate the reportId on the client side before making a request to avoid unnecessary server load caused by invalid requests.

Get the code representation of a report (Beta)

Beta: This documentation describes a public beta feature and is subject to the Beta features disclaimer.

You can use this endpoint to retrieve the code representation of a report. This representation of the report contents can be stored, modified, and used with the /v2/reports endpoint to create a new report with the contents defined in the representation.

To receive a code representation in the response, set the includeContents query parameter to true. For more information, see Manage reports as code

Usage notes for the code representation of a report

  • The default response format is JSON. To use YAML, add the header Accept: application/yaml.
  • To create a new report from code, use POST /reports with contents in the request body.
  • To update an existing report from code, use PUT /reports/{reportId}/contents.

Authentication

AuthorizationBearer

OAuth authentication of the form <token>.

Path parameters

reportIdstringRequired
Unique identifier of the report.

Query parameters

includeContentsbooleanOptional

Whether to include the report’s code representation (contents, documentVersion) in the response. Defaults to false.

Beta: This documentation describes a public beta feature and is subject to the Beta features disclaimer.

documentVersionintegerOptional

The document version to fetch. Applies only when includeContents=true. (Beta)

formatenumOptional

The response format. Defaults to json. (Beta)

Response

The response body.
reportIdstring
Unique identifier of the report.
reportUrlIdstring
namestring
urlstring
pathstring
latestVersiondouble
The most recently published document version of the report.
ownerIdstring
createdBystring
The identifier of the user who created this object.
updatedBystring
The identifier of the user or process that last updated this object.
createdAtdatetime
When the object was created.
updatedAtdatetime
When the object was last updated.
isArchivedbooleanOptional
tagslist of objectsOptional
descriptionstringOptional
documentVersiondoubleOptional

The document version of the report. Only present when includeContents=true is included in the request. (Beta)

contentsobjectOptional

The code representation of the report: its pages, elements, columns, sources, layout, and theme. Only present when includeContents=true is included in the request. To reproduce this report, submit this object as the contents field of a create or update request. Everything outside contents is report metadata that Sigma maintains, and is ignored when you write. (Beta)