enum OrderBy { ASCENDING DESCENDING } # Sort and order results by a specific field and order. # e.g - { sortBy: "date", orderBy: "DESCENDING" } input Sort { # Field to sort by. e.g - "date" sortBy: String! # ASCENDING or DESCENDING order. e.g - "DESCENDING" orderBy: OrderBy! } input Pagination { # Sort and order objects by a specific field in a specific order. sort: Sort # Do not return the first x objects. skip: Int # Limit the number of objects to return. limit: Int } input Fields { id: ID groupId: ID html: String # field defs generated from .md front-matter will be injected by pkg here. } type ContentItem { # Mandatory - a unique id must exist for every .md file. id: ID! # Mandatory - a non unique groupId must exist for every .md file. If you do not # wish to manually set you can use the generateGroupIdByFolder option check pkg Readme. groupId: ID! # The html generated from parsing the .md contents. html: String # field defs generated from .md front-matter will be injected by pkg here. } input FilterFields { # Query ContentItems by any fields using logical AND condition. AND: Fields # Query ContentItems by any fields using logical OR condition. OR: [Fields!] } type Query { contentItemById(id: ID!): ContentItem contentItemsByIds(ids: [ID!]!, pagination: Pagination): [ContentItem!] contentItemsByGroupId(groupId: ID!, pagination: Pagination): [ContentItem!] # Query for contentItems by any field contentItems(filter: FilterFields!, pagination: Pagination): [ContentItem!] }