type GroupResult {
    totalCount: Int
    count: Int
    nodes: [Group]
}

type Group implements DbModel {
    id: ID
    name: String

    shortUrls: [ShortUrl]
    roles: [Role]

    deleted: Boolean
    editor: User
    createdUtc: String
    updatedUtc: String
}

input GroupSort {
    id: SortOrder
    name: SortOrder

    deleted: SortOrder
    editorId: SortOrder
    createdUtc: SortOrder
    updatedUtc: SortOrder
}

input GroupFilter {
    id: IntFilter
    name: StringFilter

    deleted: BooleanFilter
    editor: IntFilter
    createdUtc: DateFilter
    updatedUtc: DateFilter
}

type GroupMutation {
    create(input: GroupCreateInput!): Group
    update(input: GroupUpdateInput!): Group
    delete(id: ID!): Boolean
    restore(id: ID!): Boolean
}

input GroupCreateInput {
    name: String!
    roles: [ID]
}

input GroupUpdateInput {
    id: ID!
    name: String
    roles: [ID]
}