Definition

Your organization in Pipefy is your company’s account. It's a virtual representation of your company's structure.
It encompasses all your processes and team members.

Hierarchy and Relations

An organization:
Accessible through: Pipes, Tables
Objects organizations can access directly: Members, Pipes, Database Tables, Organization Webhooks

Organizations in our API

Through our API you can fetch information about an organization using a query. To create, update and delete an organization, you should use a mutation.

Organization Query

In the code block below, there is an example of a query which retrieves information about an organization. Replace '12345' with the ID of the organization you'd like to query for. The organization ID can be retrieved on the interface by either looking at the URL of the main organization dash page when logging into Pipefy,

667

or by executing the organizations query on our GraphQL Console

{
  organizations{
    id
    name
  }
}
{
  organizations(ids:[28, 456, 789]){
    pipes{
      id
      name
    }
    tables{
      edges{
        node{
          id
          name
        }
      }
    }
    members{
      role_name
      user{
        id
        name
      }
    }
    webhooks{
      id
      name
    }
  }
}

After retrieving the organization's ID, you can search for it's attributes by executing the organization query with the attributes you need. Check our GraphQL Console to see all other attributes that are available for use.

{
  organization(id:12345) {
    id
    name
    planName
    createdAt
  }
}
{
  organization(id:123){
    pipes{
      id
      name
    }
    tables{
      edges{
        node{
          id
          name
        }
      }
    }
    members{
      role_name
      user{
        id
        name
      }
    }
    webhooks{
      id
      name
    }
  }
}

Organization Mutations

Below are examples of mutations that you can use to create, update and delete an organization.

createOrganization mutation:

Add a name for the new organization in the name parameter and the industry for which this organization is most focused towards within the industry parameter. Valid industries include:

  • construction
  • consulting
  • education
  • energy
  • financial_services
  • health
  • legal_services
  • manufacturing
  • marketing
  • non_profit_organization
  • public_sector
  • retail
  • tourism
  • technology
  • telecommunications
  • transportation
  • others
updateOrganization:

Change the id to the id of your organization, and fill in the information that you need to update. In the example below, the organization's name is being updated.

deleteOrganization:

Fill in the id of the organization you wish to delete.

mutation{
  createOrganization(input:{
    name:"New Organization"
    industry:"financial_services"
  })
}
mutation{
  updateOrganization(input:{
    id:12345
    name:"New Name"
  })
}
mutation{
  deleteOrganization(input:{
    id:12345
  })
}

Common Uses

Since the most accessible piece of information all users within a company will have is the organization's id, you will most likely use the organization query to find information about the children objects of that specific organization. For example, if you want to find all of your tables and pipes and some of their attributes, it won't be necessary to manually open each resource on the graphical interface to do so. Here are some examples:

Find Tables
{
  organization(id:12345) {
    id
    tables {
      edges {
        node {
          id
          name
          internal_id
        }
      }
    }
  }
}
Find Pipes
{
  organization(id:12345) {
    id
    name
    pipes {
      id
      name
    }
  }
}
Find Organization Members
{
  organization(id:12345) {
    id
    name
    members{
      role_name
      user {
        id
        email
      }
    }
  }
}

Testing our API

When querying for organizations, there's much more information available than the ones in the examples of the query shown in the Organization Query section.
Also, keep in mind that our API has a lot of queries and mutations available, not just regarding organizations.

For a full list of our GraphQL capabilities, you can access our GraphQL playground and play around with it.

📘

API authentication

Our API is protected, so you have to provide your access token to be able to complete the requests to our API.
You can read more about our Authentication and how to get your access token in our Authentication section.

Once you have the token in hands, within our playground you'll have to add a key in the headers named "Authorization", and the value must be the name "Bearer" followed by your token, like in the image below.

930

🚧

Be aware that running a mutation in our playground will change the Data inside Pipefy.