Skip to main content
The GraphQL API Mapping function type maps functions to GraphQL API endpoints. It is defined like this:

Format

  • query – The GraphQL query or mutation string
  • variables – Variables mapping for the GraphQL query
  • responseMapping – Mapping to transform the GraphQL response

Variables

  • credentials – Authentication credentials from the current connection
  • parameters – Function-level and collection-level parameters combined
  • Function-specific input variables
For responseMapping:
  • response.data – GraphQL response data
  • response.errors – GraphQL response errors (if any)
  • response.extensions – GraphQL response extensions (if any)

Using in Connector Files

When used in connector files, the mapping is written in a separate file named <function-name>.graphql.yml. For example: