type Query {
    productOptionGroups(filterTerm: String): [ProductOptionGroup!]!
    productOptionGroup(id: ID!): ProductOptionGroup
}

type Mutation {
    "Create a new ProductOptionGroup"
    createProductOptionGroup(input: CreateProductOptionGroupInput!): ProductOptionGroup!
    "Update an existing ProductOptionGroup"
    updateProductOptionGroup(input: UpdateProductOptionGroupInput!): ProductOptionGroup!
    "Create a new ProductOption within a ProductOptionGroup"
    createProductOption(input: CreateProductOptionInput!): ProductOption!
    "Create a new ProductOption within a ProductOptionGroup"
    updateProductOption(input: UpdateProductOptionInput!): ProductOption!
}

input ProductOptionGroupTranslationInput {
    id: ID
    languageCode: LanguageCode!
    name: String
}

input CreateProductOptionGroupInput {
    code: String!
    translations: [ProductOptionGroupTranslationInput!]!
    options: [CreateGroupOptionInput!]!
}

input UpdateProductOptionGroupInput {
    id: ID!
    code: String
    translations: [ProductOptionGroupTranslationInput!]
}

input ProductOptionTranslationInput {
    id: ID
    languageCode: LanguageCode!
    name: String
}

input CreateGroupOptionInput {
    code: String!
    translations: [ProductOptionGroupTranslationInput!]!
}

input CreateProductOptionInput {
    productOptionGroupId: ID!
    code: String!
    translations: [ProductOptionGroupTranslationInput!]!
}

input UpdateProductOptionInput {
    id: ID!
    code: String
    translations: [ProductOptionGroupTranslationInput!]
}
