---
title: "Get All Flows"
method: GET
path: "/flows"
tags: ["Flows"]
---

# Get All Flows

`GET /flows`

## Request

- Base URL: `https://dataops.nexla.io/nexla-api`
- URL: `https://dataops.nexla.io/nexla-api/flows`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/nexla/apis/nexla-rest-api/docs/flows/get.ts> (a function with typed inputs; its response is checked against the schema)

Returns all flows accessible to the authenticated user.

## Query parameters

- `flows_only` 1: By default, flows responses include sub-lists of the resources included in the `flows`, such as `data_sources`, `data_sets` and `data_sinks`. If you do not need resource details and just need flow chain, include the `flows_only` query parameter in your request. This option can improve request response time significantly.
- `include_run_metrics` 1: By default, flows responses do not include run metrics. If you want to include run metrics in the response, include the `include_run_metrics` query parameter in your request.
- `page` integer: Add this parameter to a resource fetch request to fetch a specific page of data.
- `per_page` integer: Add this parameter to a resource fetch request to set the number of items that should be returned in each request.
- `access_role` 'collaborator' | 'operator' | 'admin' | 'owner': Add this query parameter to a request to view resources for which the authenticated user has permission. 1. `collaborator`: Resources to which the user has access via the collaborator or higher permissions. 2. `operator`: Resources to which the user has access via the operator or higher permissions. 3. `admin`: Resources to which the user has access via the administrator or owner permissions. 4. `owner`: Resources created by the user. Note that the absence of this property in the request is treated as `owner`, so you do not need to set `access_role=owner` in the query.

## Headers

- `Accept` 'application/vnd.nexla.api.v1+json' | 'application/json': Setting to `application/vnd.nexla.api.v1+json` is recommended.

## Response `200`

Success

- object
  - `flows` FlowOriginNode[]
    - `id` integer
    - `parent_node_id` integer: Flow id of the parent flow node if this node is not the root node in the flow chain. This will usually be `null` as most flow definitions will originate in the node for `data_source`.
    - `origin_node_id` integer: Flow id of the root node in the flow chain.
    - `data_source_id` integer: The ID of the data source this flow node is linked to if this is a flow node for a data source.
    - `data_set_id` integer: The ID of the Nexset this flow node is linked to if this is flow node for a Nexset.
    - `data_sink_id` integer: The ID of the data sink this flow node is linked to if this is a flow node for a data sink.
    - `shared_origin_node_id` integer
    - `status` string
    - `project_id` integer
    - `flow_type` string
    - `ingestion_mode` string
    - `name` string
    - `description` string
    - `children` FlowChildNode[]: Each element of this array is a flow node that is directly linked to this flow node.
      - `id` integer
      - `parent_node_id` integer: The flow id of the flow node this node is a direct descendant of.
      - `origin_node_id` integer: The flow id of the flow node at the root of this flow chain.
      - `data_source_id` integer: The ID of the data source this flow node is linked to if this is a flow node for a data source.
      - `data_set_id` integer: The ID of the Nexset this flow node is linked to if this is flow node for a Nexset.
      - `data_sink_id` integer: The ID of the data sink this flow node is linked to if this is a flow node for a data sink.
      - `children` unknown[]: Each element is a flow node that is directly linked to this node.
        - unknown
  - `code_containers` object[]: All code containers that are linked to flow nodes in this response.
    - `id` integer
    - `owner_id` integer
    - `org_id` integer
    - `name` string
    - `description` unknown
    - `data_credentials_id` unknown
    - `public` boolean
    - `managed` boolean
    - `reusable` boolean
    - `resource_type` string
    - `output_type` string
    - `code_type` string
    - `code_encoding` string
    - `access_roles` unknown[]
      - unknown
    - `tags` unknown[]
      - unknown
    - `copied_from_id` integer
    - `created_at` string, date-time
    - `updated_at` string, date-time
  - `data_sources` object[]: All data sources that are linked to flow nodes in this response.
    - `id` integer
    - `owner_id` integer
    - `org_id` integer
    - `flow_node_id` integer
    - `origin_node_id` integer
    - `name` string
    - `description` unknown
    - `status` string
    - `data_credentials_id` integer, nullable
    - `data_sink_id` integer, nullable
    - `auto_generated` boolean
    - `managed` boolean
    - `source_type` string
    - `connector_type` string
    - `connection_type` string
    - `template_config` object
    - `vendor` unknown
    - `access_roles` unknown[]
      - unknown
    - `tags` unknown[]
      - unknown
    - `copied_from_id` integer, nullable
    - `created_at` string, date-time
    - `updated_at` string, date-time
  - `data_sets` object[]: All Nexsets that are linked to flow nodes in this response.
    - `id` integer
    - `owner_id` integer
    - `org_id` integer
    - `flow_node_id` integer
    - `origin_node_id` integer
    - `name` string
    - `description` string
    - `status` string
    - `data_source_id` integer, nullable
    - `parent_data_set_id` integer, nullable
    - `code_container_id` integer, nullable
    - `data_sink_ids` unknown[]
      - unknown
    - `public` boolean
    - `managed` boolean
    - `access_roles` unknown[]
      - unknown
    - `tags` unknown[]
      - unknown
    - `copied_from_id` integer, nullable
    - `created_at` string, date-time
    - `updated_at` string, date-time
  - `data_sinks` object[]: All data sinks that are linked to flow nodes in this response.
    - `id` integer
    - `owner_id` integer
    - `org_id` integer
    - `flow_node_id` integer
    - `origin_node_id` integer
    - `name` string
    - `description` unknown
    - `status` string
    - `data_credentials_id` integer
    - `data_set_id` integer
    - `data_source_id` integer, nullable
    - `managed` boolean
    - `sink_type` string
    - `connector_type` string
    - `connection_type` string
    - `template_config` object
    - `vendor` unknown
    - `access_roles` unknown[]
      - unknown
    - `tags` unknown[]
      - unknown
    - `copied_from_id` unknown
    - `created_at` string, date-time
    - `updated_at` string, date-time
  - `data_credentials` object[]: All credentials that are referenced by flow nodes in this response.
    - `id` integer
    - `owner_id` integer
    - `org_id` integer
    - `name` string
    - `description` unknown
    - `credentials_type` string
    - `verified_status` string
    - `managed` boolean
    - `template_config` object
    - `vendor` unknown
    - `access_roles` unknown[]
      - unknown
    - `tags` unknown[]
      - unknown
    - `copied_from_id` unknown
    - `created_at` string, date-time
    - `updated_at` string, date-time
  - `shared_data_sets` unknown[]: Metadata about the parent Nexset any relevant origin flow node is a descendant of. This is only relevant for flow nodes that originate in a shared Nexset instead of a data source.
    - unknown
  - `orgs` Org[]
    - `id` integer
    - `name` string
    - `email_domain` string
    - `email` unknown
    - `client_identifier` unknown
  - `users` Owner[]
    - `id` integer
    - `full_name` string
    - `email` string, email
  - `projects` object[]: All projects that any of the flows in this flow response are linked to.
    - `id` integer
    - `owner_id` integer
    - `org_id` integer
    - `name` string
    - `description` string
    - `access_roles` unknown[]
      - unknown
  - `metrics` object[]
    - `origin_node_id` integer
    - `records` integer
    - `size` integer
    - `errors` integer
    - `reporting_date` string, date-time
    - `run_id` integer

## Other responses

- `403`: Forbidden
- `404`: Not found

---

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