This is an old revision of the document!
enum PhotoCategory {
PORTRAIT
ACTION
TEST
}
Aliasing a query:
query {
alias : totalPets(status:AVAILABLE)
}
Neat link
Handling multiple behaviours for a single endpoint
Dont forget you can put two queries in one:
query{
query1{...}
query2{...}
}
graphql scalar type
Nullable vs non nullable
name: String!
description: String
Nullable list of nullable values
photos: [Photo]
non-Nullable list of nullable values
photos: [Photo]!
non-Nullable list of non-nullable values
photos: [Photo!]!
Mutations
type mutation{
get(): Boolean!
}
Things that arent gonna be a custom scalar, it will probably be an custom ENUM
scalar DateTime
type Photo {
created: DateTime!
updated: DateTime!
}