---
agentTools:
  projectIndex: https://developers.pipefy.com/llms.txt
---

# Integrations Usage Details

Get a paginated, per-flow breakdown of an organization's integrations (ActivePieces) task usage.

### **Before You Begin**

* **GraphQL Playground**:
  🔗 All examples should be run in the [GraphQL Playground](https://app.pipefy.com/graphiql).
  ➡️ New to GraphQL? Review the [Playground Basics Guide](https://developers.pipefy.com/reference/exploring-the-playground).
* **Authentication**:
  🛠️ Use [Service Account tokens](https://developers.pipefy.com/reference/service-accounts) *(Personal Access Tokens are deprecated)*.

### **Prerequisites**

* A role with usage stats access (`Admin` / `Super Admin`) on the `Organization`.
* `Organization UUID`.

***

### **Step 1. Find the Organization UUID**

Find the organization UUID. You can retrieve it using this query:

```graphql
{
  organization(id: "<ORGANIZATION_ID>") {
    uuid
  }
}
```

The organization ID can be found on the home page url: `https://app.pipefy.com/organizations/<ORGANIZATION_ID>`

### **Step 2. Execute the query**

```graphql
query integrationsUsageDetails(
  $organizationUuid: ID!
  $period: PeriodFilter!
  $status: String
  $search: String
  $sort: SortCriteria
  $first: Int
  $after: String
) {
  integrationsUsageDetails(
    organizationUuid: $organizationUuid
    period: $period
    status: $status
    search: $search
    sort: $sort
    first: $first
    after: $after
  ) {
    totalFlows
    totalTasks
    edges {
      node {
        name
        project {
          name
          icon
          color
        }
        tasks
        runs
        percentOfTotal
        lastRunAt
        status
      }
    }
    pageInfo {
      hasNextPage
      endCursor
    }
  }
}
```

**Variables**:

```json
{
  "organizationUuid": "<ORGANIZATION_UUID>",
  "period": "current_month",
  "first": 20,
  "sort": { "by": "usage", "order": "desc" }
}
```

**Input Explanation**:

* **organizationUuid:** The UUID of the organization you want the per-flow details for.
* **period:** The time window to aggregate. One of `current_month`, `last_month`, or `last_3_months`.
* **status:** *(optional)* Filter by flow status (e.g. `"ENABLED"`, `"DISABLED"`).
* **search:** *(optional)* Free-text filter matched against the flow name and the project name.
* **sort:** *(optional)* Field and direction to sort by. `by` accepts `name`, `usage` (tasks consumed), or `status`; `order` accepts `asc` or `desc`. Any other field falls back to the default sort (`usage` descending).
* **first / after:** Standard cursor-based pagination arguments.

**Sample Response**:

```json
{
  "data": {
    "integrationsUsageDetails": {
      "totalFlows": 7,
      "totalTasks": 1280,
      "edges": [
        {
          "node": {
            "name": "Sync new leads to CRM",
            "project": {
              "name": "Sales Ops",
              "icon": "rocket",
              "color": "blue"
            },
            "tasks": 540,
            "runs": 90,
            "percentOfTotal": 42.19,
            "lastRunAt": "2026-06-16T17:49:02Z",
            "status": "ENABLED"
          }
        }
      ],
      "pageInfo": {
        "hasNextPage": true,
        "endCursor": "MQ"
      }
    }
  }
}
```

The response returns one node per flow with its `tasks` consumed, number of `runs`, `percentOfTotal`, `lastRunAt`, and `status`, plus the connection-level totals `totalFlows` and `totalTasks` aggregated across **all** pages.

***

## **Key Notes**

* **`totalFlows` and `totalTasks`** are computed over the full result set, not just the current page.
* **`percentOfTotal`** is the flow's share of the returned set's total tasks, as a percentage rounded to two decimals (so it matches `totalTasks` as the denominator). It is `0.0` when no flow consumed tasks.
* **Default sort** is `usage` (tasks consumed) descending when `sort` is omitted.
* **`status` and `search`** are applied before pagination, so the totals and page cursors reflect the filtered set.
* **`project.name`, `project.icon`, and `project.color`** reflect the pipe's live identity. All three are `null` when the flow's pipe can no longer be resolved (e.g. a deleted pipe), in which case the API returns no identity rather than a UUID placeholder.
* For the organization-level summary and usage time series, see [Integrations usage stats query](https://developers.pipefy.com/reference/integrations-usage-stats-query).