1524

We released a new API mutation called updateFieldsValues that will allow users to update up to 30 fields in a single API call. This new mutation will improve the overall developer experience when handling batch updates and will significantly improve the speed of batch updates, by reducing the number of API calls.

Incremental updates

This new API mutation also allows developers to update fields that contain multiple data by just adding a new value or removing an existing value.
For example, to add a label to a label field, previously developers would need to do two API calls, an API call to get all existing labels, use this list to append the new label and then send to Pipefy in another API call the new list of all the labels. With the new mutation updateFieldsValues, developers can send an API mutation telling Pipefy to only add a new label to the existing list of labels in a​ field, the same applies to assignees, connections and checklists fields.

Sample GraphQL mutation

Updating two fields of a Card, replacing the what_s_your_name value and adding a new assignee to the who_s_responsible_for_approving assignee field.

mutation {
  updateFieldsValues(input: {
    nodeId: 1234
    values: [
      { fieldId: "what_s_your_name" value: "John Doe" },
      { fieldId: "who_s_responsible_for_approving" value: [123] operation: ADD },
    ]
  }) {
    success
    userErrors { field message }
    updatedNode {
      ... on Card {
        id
        fields {
          name
          value
        }
      }
    }
  }
}

👍

You can check the GraphQL specification of the new mutation here:

https://api-docs.pipefy.com/reference/mutations/updateFieldsValues/

We added support to retrieve card attachments -- we will return both attachments attached through the card and by the fields of type attachment. We added a new type called Attachment and we also added the attachments attribute inside the Card type.

Sample query:

{
  card(id: ID) {
    attachments {
      url
      createdAt
      createdBy {
        id
      }
    }
  }
}

Changelog

  • added: Attachment type
  • added: attachments attribute inside the Card type

We are happy to announce that now we support to filter and query card by the updated_at field inside the allCards query. This new feature will avoid the need to look through all cards to find the last updated ones for example.

Sample query:

query allCardUpdatedYesterday {
  allCards(first: 20, pipeId: 123,filter: { field: "updated_at", operator: gt, value: "2018-08-01T23:50:11-03:00"}) {
    edges {
      node {
        id
        title
      }
    }
  }
}

Changelog

  • added: updated_at filter inside allCards root query