List webhook origins

List the pipes and tables of an organization that own at least one webhook, including ones you are not a member of.

Before you begin

Use the GraphQL Playground to run the queries in this guide. If you are new to GraphQL, the Playground basics guide shows how to navigate it.

Prerequisites

  1. Authentication: use a Service Account token (Personal Access Tokens are deprecated).
  2. Permissions: your token must belong to an organization admin or super admin with manage_webhook permission. Other organization roles, including pipe and table admins, receive PERMISSION_DENIED.
  3. Organization ID: the organization to list webhook origins for.

Step 1: find your organization ID

Through the Pipefy UI

Open the organization in your browser. The URL includes the organization ID, the number after /organizations/: in https://app.pipefy.com/organizations/123456789 the ID is 123456789.

Through a GraphQL query

The Get resource IDs page lists other ways to find it.

Step 2: query webhook origins

Query webhookOrigins through the target organization to retrieve every pipe and table that owns at least one webhook. Results are ordered by pipe or table ID in ascending order.

Unlike pipes and tables, this field does not depend on your membership in each pipe or table, so an organization admin sees all of them. Use the returned IDs as repoIds in webhooksInventory to list the webhooks of one or more origins.

query ListWebhookOrigins(
  $organizationId: ID!
  $first: Int
  $after: String
  $nameSearch: String
  $withDeleted: Boolean
) {
  organization(id: $organizationId) {
    id
    webhookOrigins(
      first: $first
      after: $after
      nameSearch: $nameSearch
      withDeleted: $withDeleted
    ) {
      edges {
        node {
          id
          name
          scope
          deletedAt
        }
      }
      totalCount
      pageInfo {
        hasNextPage
        endCursor
      }
    }
  }
}

Variables

{
  "organizationId": "321",
  "first": 2,
  "after": null,
  "nameSearch": "sales",
  "withDeleted": false
}

nameSearch returns only pipes and tables whose name contains the given text. The match is case-insensitive, and % and _ are matched literally.

withDeleted defaults to false, and an explicit null also behaves as false. It has the same meaning as in webhooksInventory: when true, soft-deleted webhooks count too, so the result also includes pipes and tables whose webhooks are all soft-deleted. A soft-deleted pipe or table that still has a live webhook is returned either way, because its webhooks still appear in webhooksInventory.

Sample response

{
  "data": {
    "organization": {
      "id": "321",
      "webhookOrigins": {
        "edges": [
          {
            "node": {
              "id": "301",
              "name": "Sales Pipeline",
              "scope": "PIPE",
              "deletedAt": null
            }
          },
          {
            "node": {
              "id": "305",
              "name": "Sales Leads",
              "scope": "TABLE",
              "deletedAt": null
            }
          }
        ],
        "totalCount": 3,
        "pageInfo": {
          "hasNextPage": true,
          "endCursor": "Mg"
        }
      }
    }
  }
}

totalCount reports the number of pipes and tables that match the current filters, not only the number returned on this page.

Step 3: fetch the next page

Pass the previous pageInfo.endCursor as after while keeping the other filters unchanged:

{
  "organizationId": "321",
  "first": 2,
  "after": "Mg",
  "nameSearch": "sales",
  "withDeleted": false
}

Continue until pageInfo.hasNextPage is false. Each page can contain at most 50 pipes and tables.

Notes

  • Only organization admins and super admins with the manage_webhook permission can resolve this field. Other roles receive PERMISSION_DENIED: the organization object still resolves, and webhookOrigins is null.
  • scope is a WebhookOriginScope: PIPE or TABLE. Organization-scoped webhooks have no origin and are not listed here, so the enum has no ORGANIZATION value.
  • Soft-deleted pipes and tables come back with a non-null deletedAt. Pass the same withDeleted to webhookOrigins and webhooksInventory to get matching lists.
  • Sandbox and draft-version pipes are never returned.
  • Each origin exposes only id, name, scope, and deletedAt. Query the pipe or table directly for anything else.
  • Results are always ordered by ID in ascending order, so pagination is deterministic. Pages hold at most 50 origins, and a larger first still returns at most 50.