Interactive query builder and docs ↗
GraphQL endpoint ↗
Postgraphile docs ↗
Notes:

Default ordering currently errors on collections (PRIMARY_KEY_ASC/DESC). So you have to specify a different order value, or an empty array. You can see examples in the queries below.

You can change your timezone by passing the Timezone header. e.g. { "Timezone": "Europe/London" }. This will localise any timestamps, as they are stored and converted to UTC.

Auth is handled via the Authorization header, as a bearer token. e.g. { "Authorization": "Bearer jwt_from_register_or_sign_in"}.

Register
Create a new account and return a JWT to use in the Authorization header as a bearer token.
Query:
mutation Register ($input: RegisterInput!) {
  register(input:$input) {
    result
  }
}
Variables:
{
  "input": {
    "displayName": "",
    "email": "",
    "password": ""
  }
}
Sign in
Authenticate and return a new JWT to use in the Authorization header as a bearer token.
Query:
mutation SignIn ($input: SignInInput!) {
  signIn(input:$input) {
    clientMutationId
    result
  }
}
Variables:
{
  "input": {
    "email": "member@test.com",
    "password": "member"
  }
}
Sign out
Removes the refresh token associated with your current JWT.
Query:
mutation signOut {
  signOut {
    clientMutationId
  }
}
Profile
Returns all relevant information regarding the authenticated user.
Query:
query Profile {
  currentPerson {
    id
    rowId
    displayName
    primaryEmail
    createdAt
  }
  currentAccount {
    suspendedAt
    suspendedEndsAt
    bannedAt
    role
  }
  currentRole
  currentDbRole
}
Translations
Example queries using custom database types to determine data structure, computed colums with optional inputs, and collection functions with custom inputs for filtering.
Query:
fragment ExTr on ExampleTranslated {
  rowId
  # the default translation db type
  name {
    en
    fr
    es
  }
  # computed column with optional argument
  nameTr(key:"es")
}

# example of deprecated fields
fragment Old on ExampleTranslated {
  oldName
}

query Translations {
  # fetching all
  all: exampleTranslateds(orderBy: []) {
    edges {
      node {
        ...ExTr
      }
    }
  }

  # fetching with filter
  filtered: exampleTranslateds(
    orderBy: []
    filter: { nameTr: { likeInsensitive: "nam%" } }
  ) {
    edges {
      node {
        ...ExTr
      }
    }
  }

  # custom server function that returns a set, filtered using postgres similarity
  similar: exampleTranslatedsBySimilarity(search: "nam") {
    edges {
      node {
        ...ExTr
        ...Old
        # another example of deprecated fields
        oldDescription
      }
    }
  }
}