Skip to main content

Listing files

List all files​

GET https://<service_host>/file/v2/orgs/<org_id>/workspaces/<workspace_id>/files?created_at=<created_at>&author=<author_id>&file_name=<file_name>

You can list all files in a workspace using the "list files" endpoint. This endpoint accepts a few filters which can help when searching:

  • created_at: an ISO 8601 formatted timestamp in the UTC (Z) timezone. Supports date operators: gt, gte, lt, lte. Example: created_at=gte:2023-03-10T04:25:03Z.
  • author_id: UUID of the user that created the file.
  • file_name: file path and name.

When listing files, the response will always include the latest version of each file.

Pagination links (self, prev, and next) preserve the supplied filters and sorting. For both workspace and organisation listings, if deleted is omitted from the request, it is also omitted from these links, and the listing continues to return non-deleted files by default. Explicit deleted=true or deleted=false values are retained. The deleted parameter is described as a nullable boolean in OpenAPI. Omit it to use the default non-deleted listing; deleted=null and an empty deleted= are not valid boolean query values.

import requests

limit = 5000
offset = 0

url = f"https://<service_host>/file/v2/orgs/{org_id}/workspaces/{workspace_id}/files?limit={limit}&offset={offset}"
result = requests.get(url, headers={ "Authorization": "Bearer [yourtokenhere]" }).json()

Was this page helpful?