diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 313de590..1d8f62b5 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -19,7 +19,7 @@ jobs: run: pnpm lint - name: Check types run: pnpm check-types - - name: Check for changes in generated GraphQL files + - name: Check for changes in generated files run: | pnpm generate git diff --name-status --exit-code . diff --git a/.graphqlrc.yml b/.graphqlrc.yml deleted file mode 100644 index db0c659f..00000000 --- a/.graphqlrc.yml +++ /dev/null @@ -1,22 +0,0 @@ -schema: graphql/schema.graphql -documents: [graphql/**/*.graphql, src/**/*.ts, src/**/*.tsx] -extensions: - codegen: - overwrite: true - generates: - generated/graphql.ts: - config: - dedupeFragments: true - # Reduces bundle size - enumsAsTypes: true - plugins: - - typescript - - typescript-operations - - urql-introspection - - typescript-urql: - documentVariablePrefix: "Untyped" - fragmentVariablePrefix: "Untyped" - - typed-document-node - generated/schema.graphql: - plugins: - - schema-ast diff --git a/README.md b/README.md index 9c3a9911..3af7f12a 100644 --- a/README.md +++ b/README.md @@ -90,9 +90,14 @@ You can also install application using GQL or command line. Follow the guide [ho ### Generated schema and typings -Command `generate` would generate schema and typed functions using Saleor's GraphQL endpoint. Commit the `generated` folder to your repo as they are necessary for queries and keeping track of the schema changes. +This project uses a `generate` npm script command to: -[Learn more](https://www.graphql-code-generator.com/) about GraphQL code generation. +- Generate GraphQL schema and typed functions from Saleor's GraphQL endpoint. +- Generate types for Saleor sync webhook responses from JSON schema + +Commit the `generated` folder to your repo as they are necessary for queries and keeping track of the GraphQL / JSON schema changes. + +To generate GraphQL types we are using [GraphQL Codegen](https://www.graphql-code-generator.com/). For generating types from JSON schema we use [json-schema-to-typescript](https://www.npmjs.com/package/json-schema-to-typescript). ### Storing registration data - APL diff --git a/codegen.ts b/codegen.ts new file mode 100644 index 00000000..1b25c191 --- /dev/null +++ b/codegen.ts @@ -0,0 +1,54 @@ +import { CodegenConfig } from "@graphql-codegen/cli"; + +const config: CodegenConfig = { + schema: "./graphql/schema.graphql", + documents: ["./graphql/**/*.graphql"], + generates: { + "./generated/graphql.ts": { + plugins: [ + { + add: { + content: + "type JSONValue = string | number | boolean | null | { [key: string]: JSONValue } | JSONValue[];", + }, + }, + "typescript", + "typescript-operations", + "urql-introspection", + { + "typescript-urql": { + documentVariablePrefix: "Untyped", + fragmentVariablePrefix: "Untyped", + }, + }, + "typed-document-node", + ], + config: { + dedupeFragments: true, + defaultScalarType: "unknown", + immutableTypes: true, + strictScalars: true, + skipTypename: true, + scalars: { + _Any: "unknown", + Date: "string", + DateTime: "string", + Decimal: "number", + Minute: "number", + GenericScalar: "JSONValue", + JSON: "JSONValue", + JSONString: "string", + Metadata: "Record", + PositiveDecimal: "number", + Upload: "unknown", + UUID: "string", + WeightScalar: "number", + Day: "string", + Hour: "number", + }, + }, + }, + }, +}; + +export default config; diff --git a/generated/app-webhooks-types/order-filter-shipping-methods.ts b/generated/app-webhooks-types/order-filter-shipping-methods.ts new file mode 100644 index 00000000..369ec5c7 --- /dev/null +++ b/generated/app-webhooks-types/order-filter-shipping-methods.ts @@ -0,0 +1,18 @@ +/* eslint-disable */ +/** + * This file was automatically generated by json-schema-to-typescript. + * DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file, + * and run json-schema-to-typescript to regenerate this file. + */ + +export type Id = string; +export type Reason = string; +export type ExcludedMethods = ExcludedShippingMethodSchema[]; + +export interface FilterShippingMethods { + excluded_methods?: ExcludedMethods; +} +export interface ExcludedShippingMethodSchema { + id: Id; + reason?: Reason; +} diff --git a/generated/graphql.ts b/generated/graphql.ts index 2dde90f0..556aaffd 100644 --- a/generated/graphql.ts +++ b/generated/graphql.ts @@ -1,6 +1,7 @@ import gql from 'graphql-tag'; import * as Urql from 'urql'; import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/core'; +type JSONValue = string | number | boolean | null | { [key: string]: JSONValue } | JSONValue[]; export type Maybe = T | null; export type InputMaybe = Maybe; export type Exact = { [K in keyof T]: T[K] }; @@ -19,30 +20,32 @@ export type Scalars = { * value as specified by * [iso8601](https://en.wikipedia.org/wiki/ISO_8601). */ - Date: any; + Date: string; /** * The `DateTime` scalar type represents a DateTime * value as specified by * [iso8601](https://en.wikipedia.org/wiki/ISO_8601). */ - DateTime: any; + DateTime: string; /** The `Day` scalar type represents number of days by integer value. */ - Day: any; + Day: string; /** * Custom Decimal implementation. * * Returns Decimal as a float in the API, * parses float to the Decimal on the way back. */ - Decimal: any; + Decimal: number; /** * The `GenericScalar` scalar type represents a generic * GraphQL scalar value that could be: * String, Boolean, Int, Float, List or Object. */ - GenericScalar: any; - JSON: any; - JSONString: any; + GenericScalar: JSONValue; + /** The `Hour` scalar type represents number of hours by integer value. */ + Hour: number; + JSON: JSONValue; + JSONString: string; /** * Metadata is a map of key-value pairs, both keys and values are `String`. * @@ -54,21 +57,21 @@ export type Scalars = { * } * ``` */ - Metadata: any; + Metadata: Record; /** The `Minute` scalar type represents number of minutes by integer value. */ - Minute: any; + Minute: number; /** * Nonnegative Decimal scalar implementation. * * Should be used in places where value must be nonnegative (0 or greater). */ - PositiveDecimal: any; - UUID: any; + PositiveDecimal: number; + UUID: string; /** Variables of this type must be set to null in mutations. They will be replaced with a filename from a following multipart part containing a binary file. See: https://github.com/jaydenseric/graphql-multipart-request-spec. */ - Upload: any; - WeightScalar: any; + Upload: unknown; + WeightScalar: number; /** _Any value scalar as defined by Federation spec. */ - _Any: any; + _Any: unknown; }; /** @@ -81,13 +84,12 @@ export type Scalars = { * - ADDRESS_CREATED (async): An address was created. */ export type AccountAddressCreate = { - __typename?: 'AccountAddressCreate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - address?: Maybe
; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly address?: Maybe
; + readonly errors: ReadonlyArray; /** A user instance for which the address was created. */ - user?: Maybe; + readonly user?: Maybe; }; /** @@ -97,13 +99,12 @@ export type AccountAddressCreate = { * - ADDRESS_DELETED (async): An address was deleted. */ export type AccountAddressDelete = { - __typename?: 'AccountAddressDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - address?: Maybe
; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly address?: Maybe
; + readonly errors: ReadonlyArray; /** A user instance for which the address was deleted. */ - user?: Maybe; + readonly user?: Maybe; }; /** @@ -113,96 +114,80 @@ export type AccountAddressDelete = { * - ADDRESS_UPDATED (async): An address was updated. */ export type AccountAddressUpdate = { - __typename?: 'AccountAddressUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - address?: Maybe
; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly address?: Maybe
; + readonly errors: ReadonlyArray; /** A user object for which the address was edited. */ - user?: Maybe; + readonly user?: Maybe; }; -/** - * Event sent when account change email is requested. - * - * Added in Saleor 3.15. - */ +/** Event sent when account change email is requested. */ export type AccountChangeEmailRequested = Event & { - __typename?: 'AccountChangeEmailRequested'; /** The channel data. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The new email address the user wants to change to. */ - newEmail?: Maybe; + readonly newEmail?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The URL to redirect the user after he accepts the request. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** The token required to confirm request. */ - token?: Maybe; + readonly token?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when account confirmation requested. This event is always sent. enableAccountConfirmationByEmail flag set to True is not required. - * - * Added in Saleor 3.15. - */ +/** Event sent when account confirmation requested. This event is always sent. enableAccountConfirmationByEmail flag set to True is not required. */ export type AccountConfirmationRequested = Event & { - __typename?: 'AccountConfirmationRequested'; /** The channel data. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The URL to redirect the user after he accepts the request. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** The token required to confirm request. */ - token?: Maybe; + readonly token?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when account is confirmed. - * - * Added in Saleor 3.15. - */ +/** Event sent when account is confirmed. */ export type AccountConfirmed = Event & { - __typename?: 'AccountConfirmed'; /** The channel data. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The URL to redirect the user after he accepts the request. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** The token required to confirm request. */ - token?: Maybe; + readonly token?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -214,166 +199,149 @@ export type AccountConfirmed = Event & { * - ACCOUNT_DELETED (async): Account was deleted. */ export type AccountDelete = { - __typename?: 'AccountDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; - user?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly user?: Maybe; }; -/** - * Event sent when account delete is requested. - * - * Added in Saleor 3.15. - */ +/** Event sent when account delete is requested. */ export type AccountDeleteRequested = Event & { - __typename?: 'AccountDeleteRequested'; /** The channel data. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The URL to redirect the user after he accepts the request. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** The token required to confirm request. */ - token?: Maybe; + readonly token?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when account is deleted. - * - * Added in Saleor 3.15. - */ +/** Event sent when account is deleted. */ export type AccountDeleted = Event & { - __typename?: 'AccountDeleted'; /** The channel data. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The URL to redirect the user after he accepts the request. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** The token required to confirm request. */ - token?: Maybe; + readonly token?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when account email is changed. - * - * Added in Saleor 3.15. - */ +/** Event sent when account email is changed. */ export type AccountEmailChanged = Event & { - __typename?: 'AccountEmailChanged'; /** The channel data. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The new email address. */ - newEmail?: Maybe; + readonly newEmail?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The URL to redirect the user after he accepts the request. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** The token required to confirm request. */ - token?: Maybe; + readonly token?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Represents errors in account mutations. */ export type AccountError = { - __typename?: 'AccountError'; /** A type of address that causes the error. */ - addressType?: Maybe; + readonly addressType?: Maybe; /** The error code. */ - code: AccountErrorCode; + readonly code: AccountErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; -}; - -/** An enumeration. */ -export type AccountErrorCode = - | 'ACCOUNT_NOT_CONFIRMED' - | 'ACTIVATE_OWN_ACCOUNT' - | 'ACTIVATE_SUPERUSER_ACCOUNT' - | 'CHANNEL_INACTIVE' - | 'DEACTIVATE_OWN_ACCOUNT' - | 'DEACTIVATE_SUPERUSER_ACCOUNT' - | 'DELETE_NON_STAFF_USER' - | 'DELETE_OWN_ACCOUNT' - | 'DELETE_STAFF_ACCOUNT' - | 'DELETE_SUPERUSER_ACCOUNT' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INACTIVE' - | 'INVALID' - | 'INVALID_CREDENTIALS' - | 'INVALID_PASSWORD' - | 'JWT_DECODE_ERROR' - | 'JWT_INVALID_CSRF_TOKEN' - | 'JWT_INVALID_TOKEN' - | 'JWT_MISSING_TOKEN' - | 'JWT_SIGNATURE_EXPIRED' - | 'LEFT_NOT_MANAGEABLE_PERMISSION' - | 'LOGIN_ATTEMPT_DELAYED' - | 'MISSING_CHANNEL_SLUG' - | 'NOT_FOUND' - | 'OUT_OF_SCOPE_GROUP' - | 'OUT_OF_SCOPE_PERMISSION' - | 'OUT_OF_SCOPE_USER' - | 'PASSWORD_ENTIRELY_NUMERIC' - | 'PASSWORD_RESET_ALREADY_REQUESTED' - | 'PASSWORD_TOO_COMMON' - | 'PASSWORD_TOO_SHORT' - | 'PASSWORD_TOO_SIMILAR' - | 'REQUIRED' - | 'UNIQUE' - | 'UNKNOWN_IP_ADDRESS'; + readonly message?: Maybe; +}; + +export enum AccountErrorCode { + AccountNotConfirmed = 'ACCOUNT_NOT_CONFIRMED', + ActivateOwnAccount = 'ACTIVATE_OWN_ACCOUNT', + ActivateSuperuserAccount = 'ACTIVATE_SUPERUSER_ACCOUNT', + ChannelInactive = 'CHANNEL_INACTIVE', + DeactivateOwnAccount = 'DEACTIVATE_OWN_ACCOUNT', + DeactivateSuperuserAccount = 'DEACTIVATE_SUPERUSER_ACCOUNT', + DeleteNonStaffUser = 'DELETE_NON_STAFF_USER', + DeleteOwnAccount = 'DELETE_OWN_ACCOUNT', + DeleteStaffAccount = 'DELETE_STAFF_ACCOUNT', + DeleteSuperuserAccount = 'DELETE_SUPERUSER_ACCOUNT', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Inactive = 'INACTIVE', + Invalid = 'INVALID', + InvalidCredentials = 'INVALID_CREDENTIALS', + InvalidPassword = 'INVALID_PASSWORD', + JwtDecodeError = 'JWT_DECODE_ERROR', + JwtInvalidCsrfToken = 'JWT_INVALID_CSRF_TOKEN', + JwtInvalidToken = 'JWT_INVALID_TOKEN', + JwtMissingToken = 'JWT_MISSING_TOKEN', + JwtSignatureExpired = 'JWT_SIGNATURE_EXPIRED', + LeftNotManageablePermission = 'LEFT_NOT_MANAGEABLE_PERMISSION', + LoginAttemptDelayed = 'LOGIN_ATTEMPT_DELAYED', + MissingChannelSlug = 'MISSING_CHANNEL_SLUG', + NotFound = 'NOT_FOUND', + OutOfScopeGroup = 'OUT_OF_SCOPE_GROUP', + OutOfScopePermission = 'OUT_OF_SCOPE_PERMISSION', + OutOfScopeUser = 'OUT_OF_SCOPE_USER', + PasswordEntirelyNumeric = 'PASSWORD_ENTIRELY_NUMERIC', + PasswordResetAlreadyRequested = 'PASSWORD_RESET_ALREADY_REQUESTED', + PasswordTooCommon = 'PASSWORD_TOO_COMMON', + PasswordTooShort = 'PASSWORD_TOO_SHORT', + PasswordTooSimilar = 'PASSWORD_TOO_SIMILAR', + Required = 'REQUIRED', + Unique = 'UNIQUE', + UnknownIpAddress = 'UNKNOWN_IP_ADDRESS' +} /** Fields required to update the user. */ export type AccountInput = { /** Billing address of the customer. */ - defaultBillingAddress?: InputMaybe; + readonly defaultBillingAddress?: InputMaybe; /** Shipping address of the customer. */ - defaultShippingAddress?: InputMaybe; + readonly defaultShippingAddress?: InputMaybe; /** Given name. */ - firstName?: InputMaybe; + readonly firstName?: InputMaybe; /** User language code. */ - languageCode?: InputMaybe; + readonly languageCode?: InputMaybe; /** Family name. */ - lastName?: InputMaybe; + readonly lastName?: InputMaybe; /** - * Fields required to update the user metadata. + * Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; }; /** @@ -385,33 +353,36 @@ export type AccountInput = { * - ACCOUNT_CONFIRMATION_REQUESTED (async): An user confirmation was requested. This event is always sent regardless of settings. */ export type AccountRegister = { - __typename?: 'AccountRegister'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Informs whether users need to confirm their email address. */ - requiresConfirmation?: Maybe; - user?: Maybe; + readonly requiresConfirmation?: Maybe; + readonly user?: Maybe; }; /** Fields required to create a user. */ export type AccountRegisterInput = { /** Slug of a channel which will be used to notify users. Optional when only one channel exists. */ - channel?: InputMaybe; + readonly channel?: InputMaybe; /** The email address of the user. */ - email: Scalars['String']; + readonly email: Scalars['String']; /** Given name. */ - firstName?: InputMaybe; + readonly firstName?: InputMaybe; /** User language code. */ - languageCode?: InputMaybe; + readonly languageCode?: InputMaybe; /** Family name. */ - lastName?: InputMaybe; - /** User public metadata. */ - metadata?: InputMaybe>; + readonly lastName?: InputMaybe; + /** + * User public metadata. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly metadata?: InputMaybe>; /** Password. */ - password: Scalars['String']; + readonly password: Scalars['String']; /** Base of frontend URL that will be needed to create confirmation URL. Required when account confirmation is enabled. */ - redirectUrl?: InputMaybe; + readonly redirectUrl?: InputMaybe; }; /** @@ -424,10 +395,9 @@ export type AccountRegisterInput = { * - ACCOUNT_DELETE_REQUESTED (async): An account delete requested. */ export type AccountRequestDeletion = { - __typename?: 'AccountRequestDeletion'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -439,39 +409,33 @@ export type AccountRequestDeletion = { * - CUSTOMER_UPDATED (async): A customer's address was updated. */ export type AccountSetDefaultAddress = { - __typename?: 'AccountSetDefaultAddress'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** An updated user instance. */ - user?: Maybe; + readonly user?: Maybe; }; -/** - * Event sent when setting a new password is requested. - * - * Added in Saleor 3.15. - */ +/** Event sent when setting a new password is requested. */ export type AccountSetPasswordRequested = Event & { - __typename?: 'AccountSetPasswordRequested'; /** The channel data. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The URL to redirect the user after he accepts the request. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** The token required to confirm request. */ - token?: Maybe; + readonly token?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -484,84 +448,62 @@ export type AccountSetPasswordRequested = Event & { * - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. */ export type AccountUpdate = { - __typename?: 'AccountUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; - user?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly user?: Maybe; }; /** Represents user address data. */ export type Address = Node & ObjectWithMetadata & { - __typename?: 'Address'; /** The city of the address. */ - city: Scalars['String']; + readonly city: Scalars['String']; /** The district of the address. */ - cityArea: Scalars['String']; + readonly cityArea: Scalars['String']; /** Company or organization name. */ - companyName: Scalars['String']; + readonly companyName: Scalars['String']; /** The country of the address. */ - country: CountryDisplay; + readonly country: CountryDisplay; /** The country area of the address. */ - countryArea: Scalars['String']; + readonly countryArea: Scalars['String']; /** The given name of the address. */ - firstName: Scalars['String']; + readonly firstName: Scalars['String']; /** The ID of the address. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Address is user's default billing address. */ - isDefaultBillingAddress?: Maybe; + readonly isDefaultBillingAddress?: Maybe; /** Address is user's default shipping address. */ - isDefaultShippingAddress?: Maybe; + readonly isDefaultShippingAddress?: Maybe; /** The family name of the address. */ - lastName: Scalars['String']; - /** - * List of public metadata items. Can be accessed without permissions. - * - * Added in Saleor 3.10. - */ - metadata: Array; + readonly lastName: Scalars['String']; + /** List of public metadata items. Can be accessed without permissions. */ + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.10. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.10. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** The phone number assigned the address. */ - phone?: Maybe; + readonly phone?: Maybe; /** The postal code of the address. */ - postalCode: Scalars['String']; - /** - * List of private metadata items. Requires staff permissions to access. - * - * Added in Saleor 3.10. - */ - privateMetadata: Array; + readonly postalCode: Scalars['String']; + /** List of private metadata items. Requires staff permissions to access. */ + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.10. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.10. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** The first line of the address. */ - streetAddress1: Scalars['String']; + readonly streetAddress1: Scalars['String']; /** The second line of the address. */ - streetAddress2: Scalars['String']; + readonly streetAddress2: Scalars['String']; }; @@ -573,7 +515,7 @@ export type AddressMetafieldArgs = { /** Represents user address data. */ export type AddressMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -585,7 +527,7 @@ export type AddressPrivateMetafieldArgs = { /** Represents user address data. */ export type AddressPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** @@ -597,32 +539,26 @@ export type AddressPrivateMetafieldsArgs = { * - ADDRESS_CREATED (async): A new address was created. */ export type AddressCreate = { - __typename?: 'AddressCreate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - address?: Maybe
; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly address?: Maybe
; + readonly errors: ReadonlyArray; /** A user instance for which the address was created. */ - user?: Maybe; + readonly user?: Maybe; }; -/** - * Event sent when new address is created. - * - * Added in Saleor 3.5. - */ +/** Event sent when new address is created. */ export type AddressCreated = Event & { - __typename?: 'AddressCreated'; /** The address the event relates to. */ - address?: Maybe
; + readonly address?: Maybe
; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -634,63 +570,57 @@ export type AddressCreated = Event & { * - ADDRESS_DELETED (async): An address was deleted. */ export type AddressDelete = { - __typename?: 'AddressDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - address?: Maybe
; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly address?: Maybe
; + readonly errors: ReadonlyArray; /** A user instance for which the address was deleted. */ - user?: Maybe; + readonly user?: Maybe; }; -/** - * Event sent when address is deleted. - * - * Added in Saleor 3.5. - */ +/** Event sent when address is deleted. */ export type AddressDeleted = Event & { - __typename?: 'AddressDeleted'; /** The address the event relates to. */ - address?: Maybe
; + readonly address?: Maybe
; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type AddressInput = { /** City. */ - city?: InputMaybe; + readonly city?: InputMaybe; /** District. */ - cityArea?: InputMaybe; + readonly cityArea?: InputMaybe; /** Company or organization. */ - companyName?: InputMaybe; + readonly companyName?: InputMaybe; /** Country. */ - country?: InputMaybe; + readonly country?: InputMaybe; /** State or province. */ - countryArea?: InputMaybe; + readonly countryArea?: InputMaybe; /** Given name. */ - firstName?: InputMaybe; + readonly firstName?: InputMaybe; /** Family name. */ - lastName?: InputMaybe; + readonly lastName?: InputMaybe; /** - * Address public metadata. + * Address public metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.15. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** * Phone number. * * Phone numbers are validated with Google's [libphonenumber](https://github.com/google/libphonenumber) library. */ - phone?: InputMaybe; + readonly phone?: InputMaybe; /** Postal code. */ - postalCode?: InputMaybe; + readonly postalCode?: InputMaybe; /** * Determine if the address should be validated. By default, Saleor accepts only address inputs matching ruleset from [Google Address Data]{https://chromium-i18n.appspot.com/ssl-address), using [i18naddress](https://github.com/mirumee/google-i18n-address) library. Some mutations may require additional permissions to use the the field. More info about permissions can be found in relevant mutation. * @@ -698,11 +628,11 @@ export type AddressInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - skipValidation?: InputMaybe; + readonly skipValidation?: InputMaybe; /** Address. */ - streetAddress1?: InputMaybe; + readonly streetAddress1?: InputMaybe; /** Address. */ - streetAddress2?: InputMaybe; + readonly streetAddress2?: InputMaybe; }; /** @@ -714,18 +644,17 @@ export type AddressInput = { * - CUSTOMER_UPDATED (async): A customer was updated. */ export type AddressSetDefault = { - __typename?: 'AddressSetDefault'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** An updated user instance. */ - user?: Maybe; + readonly user?: Maybe; }; -/** An enumeration. */ -export type AddressTypeEnum = - | 'BILLING' - | 'SHIPPING'; +export enum AddressTypeEnum { + Billing = 'BILLING', + Shipping = 'SHIPPING' +} /** * Updates an address. @@ -736,37 +665,30 @@ export type AddressTypeEnum = * - ADDRESS_UPDATED (async): An address was updated. */ export type AddressUpdate = { - __typename?: 'AddressUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - address?: Maybe
; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly address?: Maybe
; + readonly errors: ReadonlyArray; /** A user object for which the address was edited. */ - user?: Maybe; + readonly user?: Maybe; }; -/** - * Event sent when address is updated. - * - * Added in Saleor 3.5. - */ +/** Event sent when address is updated. */ export type AddressUpdated = Event & { - __typename?: 'AddressUpdated'; /** The address the event relates to. */ - address?: Maybe
; + readonly address?: Maybe
; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Represents address validation rules for a country. */ export type AddressValidationData = { - __typename?: 'AddressValidationData'; /** * The address format of the address validation rule. * @@ -783,7 +705,7 @@ export type AddressValidationData = { * * [Click here for more information.](https://github.com/google/libaddressinput/wiki/AddressValidationMetadata) */ - addressFormat: Scalars['String']; + readonly addressFormat: Scalars['String']; /** * The latin address format of the address validation rule. * @@ -800,56 +722,55 @@ export type AddressValidationData = { * * [Click here for more information.](https://github.com/google/libaddressinput/wiki/AddressValidationMetadata) */ - addressLatinFormat: Scalars['String']; + readonly addressLatinFormat: Scalars['String']; /** The allowed fields to use in address. */ - allowedFields: Array; + readonly allowedFields: ReadonlyArray; /** The available choices for the city area of the address validation rule. */ - cityAreaChoices: Array; + readonly cityAreaChoices: ReadonlyArray; /** The formal name of the city area of the address validation rule. */ - cityAreaType: Scalars['String']; + readonly cityAreaType: Scalars['String']; /** The available choices for the city of the address validation rule. */ - cityChoices: Array; + readonly cityChoices: ReadonlyArray; /** The formal name of the city of the address validation rule. */ - cityType: Scalars['String']; + readonly cityType: Scalars['String']; /** The available choices for the country area of the address validation rule. */ - countryAreaChoices: Array; + readonly countryAreaChoices: ReadonlyArray; /** The formal name of the county area of the address validation rule. */ - countryAreaType: Scalars['String']; + readonly countryAreaType: Scalars['String']; /** The country code of the address validation rule. */ - countryCode: Scalars['String']; + readonly countryCode: Scalars['String']; /** The country name of the address validation rule. */ - countryName: Scalars['String']; + readonly countryName: Scalars['String']; /** The example postal code of the address validation rule. */ - postalCodeExamples: Array; + readonly postalCodeExamples: ReadonlyArray; /** The regular expression for postal code validation. */ - postalCodeMatchers: Array; + readonly postalCodeMatchers: ReadonlyArray; /** The postal code prefix of the address validation rule. */ - postalCodePrefix: Scalars['String']; + readonly postalCodePrefix: Scalars['String']; /** The formal name of the postal code of the address validation rule. */ - postalCodeType: Scalars['String']; + readonly postalCodeType: Scalars['String']; /** The required fields to create a valid address. */ - requiredFields: Array; + readonly requiredFields: ReadonlyArray; /** The list of fields that should be in upper case for address validation rule. */ - upperFields: Array; + readonly upperFields: ReadonlyArray; }; /** Represents allocation. */ export type Allocation = Node & { - __typename?: 'Allocation'; /** The ID of allocation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Quantity allocated for orders. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** * The warehouse were items were allocated. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. */ - warehouse: Warehouse; + readonly warehouse: Warehouse; }; /** @@ -860,127 +781,107 @@ export type Allocation = Node & { * * PRIORITIZE_HIGH_STOCK - allocate stock in a warehouse with the most stock */ -export type AllocationStrategyEnum = - | 'PRIORITIZE_HIGH_STOCK' - | 'PRIORITIZE_SORTING_ORDER'; +export enum AllocationStrategyEnum { + PrioritizeHighStock = 'PRIORITIZE_HIGH_STOCK', + PrioritizeSortingOrder = 'PRIORITIZE_SORTING_ORDER' +} /** Represents app data. */ export type App = Node & ObjectWithMetadata & { - __typename?: 'App'; /** Description of this app. */ - aboutApp?: Maybe; + readonly aboutApp?: Maybe; /** JWT token used to authenticate by third-party app. */ - accessToken?: Maybe; + readonly accessToken?: Maybe; /** URL to iframe with the app. */ - appUrl?: Maybe; + readonly appUrl?: Maybe; + /** The App's author name. */ + readonly author?: Maybe; + /** App's brand data. */ + readonly brand?: Maybe; /** - * The App's author name. - * - * Added in Saleor 3.13. + * Circuit breaker last state change date. * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. + * Added in Saleor 3.21. */ - author?: Maybe; + readonly breakerLastStateChange?: Maybe; /** - * App's brand data. - * - * Added in Saleor 3.14. + * Circuit breaker state, if open, sync webhooks operation is disrupted. * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. + * Added in Saleor 3.21. */ - brand?: Maybe; + readonly breakerState: CircuitBreakerStateEnum; /** * URL to iframe with the configuration for the app. - * @deprecated This field will be removed in Saleor 4.0. Use `appUrl` instead. + * @deprecated Use `appUrl` instead. */ - configurationUrl?: Maybe; + readonly configurationUrl?: Maybe; /** The date and time when the app was created. */ - created?: Maybe; + readonly created?: Maybe; /** * Description of the data privacy defined for this app. - * @deprecated This field will be removed in Saleor 4.0. Use `dataPrivacyUrl` instead. + * @deprecated Use `dataPrivacyUrl` instead. */ - dataPrivacy?: Maybe; + readonly dataPrivacy?: Maybe; /** URL to details about the privacy policy on the app owner page. */ - dataPrivacyUrl?: Maybe; - /** - * App's dashboard extensions. - * - * Added in Saleor 3.1. - */ - extensions: Array; + readonly dataPrivacyUrl?: Maybe; + /** App's dashboard extensions. */ + readonly extensions: ReadonlyArray; /** Homepage of the app. */ - homepageUrl?: Maybe; + readonly homepageUrl?: Maybe; /** The ID of the app. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Canonical app ID from the manifest * * Added in Saleor 3.19. */ - identifier?: Maybe; + readonly identifier?: Maybe; /** Determine if app will be set active or not. */ - isActive?: Maybe; - /** - * URL to manifest used during app's installation. - * - * Added in Saleor 3.5. - */ - manifestUrl?: Maybe; + readonly isActive?: Maybe; + /** URL to manifest used during app's installation. */ + readonly manifestUrl?: Maybe; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Name of the app. */ - name?: Maybe; + readonly name?: Maybe; /** List of the app's permissions. */ - permissions?: Maybe>; + readonly permissions?: Maybe>; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Support page for the app. */ - supportUrl?: Maybe; + readonly supportUrl?: Maybe; /** * Last 4 characters of the tokens. * * Requires one of the following permissions: MANAGE_APPS, OWNER. */ - tokens?: Maybe>; + readonly tokens?: Maybe>; /** Type of the app. */ - type?: Maybe; + readonly type?: Maybe; /** Version number of the app. */ - version?: Maybe; + readonly version?: Maybe; /** * List of webhooks assigned to this app. * * Requires one of the following permissions: MANAGE_APPS, OWNER. */ - webhooks?: Maybe>; + readonly webhooks?: Maybe>; }; @@ -992,7 +893,7 @@ export type AppMetafieldArgs = { /** Represents app data. */ export type AppMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -1004,7 +905,7 @@ export type AppPrivateMetafieldArgs = { /** Represents app data. */ export type AppPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** @@ -1016,79 +917,44 @@ export type AppPrivateMetafieldsArgs = { * - APP_STATUS_CHANGED (async): An app was activated. */ export type AppActivate = { - __typename?: 'AppActivate'; - app?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - errors: Array; + readonly app?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** - * Represents the app's brand data. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the app's brand data. */ export type AppBrand = { - __typename?: 'AppBrand'; - /** - * App's logos details. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - logo: AppBrandLogo; + /** App's logos details. */ + readonly logo: AppBrandLogo; }; -/** - * Represents the app's brand logo data. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the app's brand logo data. */ export type AppBrandLogo = { - __typename?: 'AppBrandLogo'; - /** - * URL to the default logo image. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - default: Scalars['String']; + /** URL to the default logo image. */ + readonly default: Scalars['String']; }; -/** - * Represents the app's brand logo data. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the app's brand logo data. */ export type AppBrandLogoDefaultArgs = { format?: InputMaybe; size?: InputMaybe; }; export type AppCountableConnection = { - __typename?: 'AppCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type AppCountableEdge = { - __typename?: 'AppCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: App; + readonly node: App; }; /** @@ -1098,13 +964,12 @@ export type AppCountableEdge = { * - APP_INSTALLED (async): An app was installed. */ export type AppCreate = { - __typename?: 'AppCreate'; - app?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; + readonly app?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; /** The newly created authentication token. */ - authToken?: Maybe; - errors: Array; + readonly authToken?: Maybe; + readonly errors: ReadonlyArray; }; /** @@ -1116,11 +981,10 @@ export type AppCreate = { * - APP_STATUS_CHANGED (async): An app was deactivated. */ export type AppDeactivate = { - __typename?: 'AppDeactivate'; - app?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - errors: Array; + readonly app?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -1132,11 +996,10 @@ export type AppDeactivate = { * - APP_DELETED (async): An app was deleted. */ export type AppDelete = { - __typename?: 'AppDelete'; - app?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - errors: Array; + readonly app?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -1145,122 +1008,113 @@ export type AppDelete = { * Requires one of the following permissions: MANAGE_APPS. */ export type AppDeleteFailedInstallation = { - __typename?: 'AppDeleteFailedInstallation'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - appInstallation?: Maybe; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly appInstallation?: Maybe; + readonly errors: ReadonlyArray; }; -/** - * Event sent when app is deleted. - * - * Added in Saleor 3.4. - */ +/** Event sent when app is deleted. */ export type AppDeleted = Event & { - __typename?: 'AppDeleted'; /** The application the event relates to. */ - app?: Maybe; + readonly app?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type AppError = { - __typename?: 'AppError'; /** The error code. */ - code: AppErrorCode; + readonly code: AppErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of permissions which causes the error. */ - permissions?: Maybe>; -}; - -/** An enumeration. */ -export type AppErrorCode = - | 'FORBIDDEN' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_CUSTOM_HEADERS' - | 'INVALID_MANIFEST_FORMAT' - | 'INVALID_PERMISSION' - | 'INVALID_STATUS' - | 'INVALID_URL_FORMAT' - | 'MANIFEST_URL_CANT_CONNECT' - | 'NOT_FOUND' - | 'OUT_OF_SCOPE_APP' - | 'OUT_OF_SCOPE_PERMISSION' - | 'REQUIRED' - | 'UNIQUE' - | 'UNSUPPORTED_SALEOR_VERSION'; + readonly permissions?: Maybe>; +}; + +export enum AppErrorCode { + Forbidden = 'FORBIDDEN', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidCustomHeaders = 'INVALID_CUSTOM_HEADERS', + InvalidManifestFormat = 'INVALID_MANIFEST_FORMAT', + InvalidPermission = 'INVALID_PERMISSION', + InvalidStatus = 'INVALID_STATUS', + InvalidUrlFormat = 'INVALID_URL_FORMAT', + ManifestUrlCantConnect = 'MANIFEST_URL_CANT_CONNECT', + NotFound = 'NOT_FOUND', + OutOfScopeApp = 'OUT_OF_SCOPE_APP', + OutOfScopePermission = 'OUT_OF_SCOPE_PERMISSION', + Required = 'REQUIRED', + Unique = 'UNIQUE', + UnsupportedSaleorVersion = 'UNSUPPORTED_SALEOR_VERSION' +} /** Represents app data. */ export type AppExtension = Node & { - __typename?: 'AppExtension'; /** JWT token used to authenticate by third-party app extension. */ - accessToken?: Maybe; + readonly accessToken?: Maybe; /** The app assigned to app extension. */ - app: App; + readonly app: App; /** The ID of the app extension. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Label of the extension to show in the dashboard. */ - label: Scalars['String']; + readonly label: Scalars['String']; /** Place where given extension will be mounted. */ - mount: AppExtensionMountEnum; + readonly mount: AppExtensionMountEnum; /** List of the app extension's permissions. */ - permissions: Array; + readonly permissions: ReadonlyArray; /** Type of way how app extension will be opened. */ - target: AppExtensionTargetEnum; + readonly target: AppExtensionTargetEnum; /** URL of a view where extension's iframe is placed. */ - url: Scalars['String']; + readonly url: Scalars['String']; }; export type AppExtensionCountableConnection = { - __typename?: 'AppExtensionCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type AppExtensionCountableEdge = { - __typename?: 'AppExtensionCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: AppExtension; + readonly node: AppExtension; }; export type AppExtensionFilterInput = { - mount?: InputMaybe>; - target?: InputMaybe; + readonly mount?: InputMaybe>; + readonly target?: InputMaybe; }; /** All places where app extension can be mounted. */ -export type AppExtensionMountEnum = - | 'CUSTOMER_DETAILS_MORE_ACTIONS' - | 'CUSTOMER_OVERVIEW_CREATE' - | 'CUSTOMER_OVERVIEW_MORE_ACTIONS' - | 'NAVIGATION_CATALOG' - | 'NAVIGATION_CUSTOMERS' - | 'NAVIGATION_DISCOUNTS' - | 'NAVIGATION_ORDERS' - | 'NAVIGATION_PAGES' - | 'NAVIGATION_TRANSLATIONS' - | 'ORDER_DETAILS_MORE_ACTIONS' - | 'ORDER_OVERVIEW_CREATE' - | 'ORDER_OVERVIEW_MORE_ACTIONS' - | 'PRODUCT_DETAILS_MORE_ACTIONS' - | 'PRODUCT_OVERVIEW_CREATE' - | 'PRODUCT_OVERVIEW_MORE_ACTIONS'; +export enum AppExtensionMountEnum { + CustomerDetailsMoreActions = 'CUSTOMER_DETAILS_MORE_ACTIONS', + CustomerOverviewCreate = 'CUSTOMER_OVERVIEW_CREATE', + CustomerOverviewMoreActions = 'CUSTOMER_OVERVIEW_MORE_ACTIONS', + NavigationCatalog = 'NAVIGATION_CATALOG', + NavigationCustomers = 'NAVIGATION_CUSTOMERS', + NavigationDiscounts = 'NAVIGATION_DISCOUNTS', + NavigationOrders = 'NAVIGATION_ORDERS', + NavigationPages = 'NAVIGATION_PAGES', + NavigationTranslations = 'NAVIGATION_TRANSLATIONS', + OrderDetailsMoreActions = 'ORDER_DETAILS_MORE_ACTIONS', + OrderOverviewCreate = 'ORDER_OVERVIEW_CREATE', + OrderOverviewMoreActions = 'ORDER_OVERVIEW_MORE_ACTIONS', + ProductDetailsMoreActions = 'PRODUCT_DETAILS_MORE_ACTIONS', + ProductOverviewCreate = 'PRODUCT_OVERVIEW_CREATE', + ProductOverviewMoreActions = 'PRODUCT_OVERVIEW_MORE_ACTIONS' +} /** * All available ways of opening an app extension. @@ -1268,9 +1122,10 @@ export type AppExtensionMountEnum = * POPUP - app's extension will be mounted as a popup window * APP_PAGE - redirect to app's page */ -export type AppExtensionTargetEnum = - | 'APP_PAGE' - | 'POPUP'; +export enum AppExtensionTargetEnum { + AppPage = 'APP_PAGE', + Popup = 'POPUP' +} /** * Fetch and validate manifest. @@ -1278,18 +1133,17 @@ export type AppExtensionTargetEnum = * Requires one of the following permissions: MANAGE_APPS. */ export type AppFetchManifest = { - __typename?: 'AppFetchManifest'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** The validated manifest. */ - manifest?: Maybe; + readonly manifest?: Maybe; }; export type AppFilterInput = { - isActive?: InputMaybe; - search?: InputMaybe; - type?: InputMaybe; + readonly isActive?: InputMaybe; + readonly search?: InputMaybe; + readonly type?: InputMaybe; }; export type AppInput = { @@ -1298,176 +1152,131 @@ export type AppInput = { * * Added in Saleor 3.19. */ - identifier?: InputMaybe; + readonly identifier?: InputMaybe; /** Name of the app. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** List of permission code names to assign to this app. */ - permissions?: InputMaybe>; + readonly permissions?: InputMaybe>; }; /** Install new app by using app manifest. Requires the following permissions: AUTHENTICATED_STAFF_USER and MANAGE_APPS. */ export type AppInstall = { - __typename?: 'AppInstall'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - appInstallation?: Maybe; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly appInstallation?: Maybe; + readonly errors: ReadonlyArray; }; export type AppInstallInput = { /** Determine if app will be set active or not. */ - activateAfterInstallation?: InputMaybe; + readonly activateAfterInstallation?: InputMaybe; /** Name of the app to install. */ - appName?: InputMaybe; + readonly appName?: InputMaybe; /** URL to app's manifest in JSON format. */ - manifestUrl?: InputMaybe; + readonly manifestUrl?: InputMaybe; /** List of permission code names to assign to this app. */ - permissions?: InputMaybe>; + readonly permissions?: InputMaybe>; }; /** Represents ongoing installation of app. */ export type AppInstallation = Job & Node & { - __typename?: 'AppInstallation'; /** The name of the app installation. */ - appName: Scalars['String']; - /** - * App's brand data. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - brand?: Maybe; + readonly appName: Scalars['String']; + /** App's brand data. */ + readonly brand?: Maybe; /** Created date time of job in ISO 8601 format. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** The ID of the app installation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The URL address of manifest for the app installation. */ - manifestUrl: Scalars['String']; + readonly manifestUrl: Scalars['String']; /** Job message. */ - message?: Maybe; + readonly message?: Maybe; /** Job status. */ - status: JobStatusEnum; + readonly status: JobStatusEnum; /** Date time of job last update in ISO 8601 format. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; }; -/** - * Event sent when new app is installed. - * - * Added in Saleor 3.4. - */ +/** Event sent when new app is installed. */ export type AppInstalled = Event & { - __typename?: 'AppInstalled'; /** The application the event relates to. */ - app?: Maybe; + readonly app?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Represents the app's manifest brand data. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the app's manifest brand data. */ export type AppManifestBrand = { - __typename?: 'AppManifestBrand'; - /** - * App's logos details. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - logo: AppManifestBrandLogo; + /** App's logos details. */ + readonly logo: AppManifestBrandLogo; }; -/** - * Represents the app's manifest brand data. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the app's manifest brand data. */ export type AppManifestBrandLogo = { - __typename?: 'AppManifestBrandLogo'; - /** - * Data URL with a base64 encoded logo image. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - default: Scalars['String']; + /** Data URL with a base64 encoded logo image. */ + readonly default: Scalars['String']; }; -/** - * Represents the app's manifest brand data. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the app's manifest brand data. */ export type AppManifestBrandLogoDefaultArgs = { format?: InputMaybe; size?: InputMaybe; }; export type AppManifestExtension = { - __typename?: 'AppManifestExtension'; /** Label of the extension to show in the dashboard. */ - label: Scalars['String']; + readonly label: Scalars['String']; /** Place where given extension will be mounted. */ - mount: AppExtensionMountEnum; + readonly mount: AppExtensionMountEnum; /** List of the app extension's permissions. */ - permissions: Array; + readonly permissions: ReadonlyArray; /** Type of way how app extension will be opened. */ - target: AppExtensionTargetEnum; + readonly target: AppExtensionTargetEnum; /** URL of a view where extension's iframe is placed. */ - url: Scalars['String']; + readonly url: Scalars['String']; }; export type AppManifestRequiredSaleorVersion = { - __typename?: 'AppManifestRequiredSaleorVersion'; - /** - * Required Saleor version as semver range. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - constraint: Scalars['String']; - /** - * Informs if the Saleor version matches the required one. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - satisfied: Scalars['Boolean']; + /** Required Saleor version as semver range. */ + readonly constraint: Scalars['String']; + /** Informs if the Saleor version matches the required one. */ + readonly satisfied: Scalars['Boolean']; }; export type AppManifestWebhook = { - __typename?: 'AppManifestWebhook'; /** The asynchronous events that webhook wants to subscribe. */ - asyncEvents?: Maybe>; + readonly asyncEvents?: Maybe>; /** The name of the webhook. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Subscription query of a webhook */ - query: Scalars['String']; + readonly query: Scalars['String']; /** The synchronous events that webhook wants to subscribe. */ - syncEvents?: Maybe>; + readonly syncEvents?: Maybe>; /** The url to receive the payload. */ - targetUrl: Scalars['String']; + readonly targetUrl: Scalars['String']; +}; + +/** + * Re-enable sync webhooks for provided app. Can be used to manually re-enable sync webhooks for the app before the cooldown period ends. + * + * Added in Saleor 3.21. + * + * Requires one of the following permissions: MANAGE_APPS. + */ +export type AppReenableSyncWebhooks = { + /** App for which sync webhooks were re-enabled. */ + readonly app?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -1479,54 +1288,48 @@ export type AppManifestWebhook = { * - APP_INSTALLED (async): An app was installed. */ export type AppRetryInstall = { - __typename?: 'AppRetryInstall'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - appInstallation?: Maybe; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly appInstallation?: Maybe; + readonly errors: ReadonlyArray; }; -export type AppSortField = +export enum AppSortField { /** Sort apps by creation date. */ - | 'CREATION_DATE' + CreationDate = 'CREATION_DATE', /** Sort apps by name. */ - | 'NAME'; + Name = 'NAME' +} export type AppSortingInput = { /** Specifies the direction in which to sort apps. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort apps by the selected field. */ - field: AppSortField; + readonly field: AppSortField; }; -/** - * Event sent when app status has changed. - * - * Added in Saleor 3.4. - */ +/** Event sent when app status has changed. */ export type AppStatusChanged = Event & { - __typename?: 'AppStatusChanged'; /** The application the event relates to. */ - app?: Maybe; + readonly app?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Represents token data. */ export type AppToken = Node & { - __typename?: 'AppToken'; /** Last 4 characters of the token. */ - authToken?: Maybe; + readonly authToken?: Maybe; /** The ID of the app token. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the authenticated token. */ - name?: Maybe; + readonly name?: Maybe; }; /** @@ -1535,13 +1338,12 @@ export type AppToken = Node & { * Requires one of the following permissions: MANAGE_APPS. */ export type AppTokenCreate = { - __typename?: 'AppTokenCreate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - appToken?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly appToken?: Maybe; /** The newly created authentication token. */ - authToken?: Maybe; - errors: Array; + readonly authToken?: Maybe; + readonly errors: ReadonlyArray; }; /** @@ -1550,36 +1352,35 @@ export type AppTokenCreate = { * Requires one of the following permissions: MANAGE_APPS. */ export type AppTokenDelete = { - __typename?: 'AppTokenDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - appToken?: Maybe; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly appToken?: Maybe; + readonly errors: ReadonlyArray; }; export type AppTokenInput = { /** ID of app. */ - app: Scalars['ID']; + readonly app: Scalars['ID']; /** Name of the token. */ - name?: InputMaybe; + readonly name?: InputMaybe; }; /** Verify provided app token. */ export type AppTokenVerify = { - __typename?: 'AppTokenVerify'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Determine if token is valid or not. */ - valid: Scalars['Boolean']; + readonly valid: Scalars['Boolean']; }; /** Enum determining type of your App. */ -export type AppTypeEnum = +export enum AppTypeEnum { /** Local Saleor App. The app is fully manageable from dashboard. You can change assigned permissions, add webhooks, or authentication token */ - | 'LOCAL' + Local = 'LOCAL', /** Third party external App. Installation is fully automated. Saleor uses a defined App manifest to gather all required information. */ - | 'THIRDPARTY'; + Thirdparty = 'THIRDPARTY' +} /** * Updates an existing app. @@ -1590,42 +1391,36 @@ export type AppTypeEnum = * - APP_UPDATED (async): An app was updated. */ export type AppUpdate = { - __typename?: 'AppUpdate'; - app?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - appErrors: Array; - errors: Array; + readonly app?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly appErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** - * Event sent when app is updated. - * - * Added in Saleor 3.4. - */ +/** Event sent when app is updated. */ export type AppUpdated = Event & { - __typename?: 'AppUpdated'; /** The application the event relates to. */ - app?: Maybe; + readonly app?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; -}; - -/** An enumeration. */ -export type AreaUnitsEnum = - | 'SQ_CM' - | 'SQ_DM' - | 'SQ_FT' - | 'SQ_INCH' - | 'SQ_KM' - | 'SQ_M' - | 'SQ_MM' - | 'SQ_YD'; + readonly version?: Maybe; +}; + +export enum AreaUnitsEnum { + SqCm = 'SQ_CM', + SqDm = 'SQ_DM', + SqFt = 'SQ_FT', + SqInch = 'SQ_INCH', + SqKm = 'SQ_KM', + SqM = 'SQ_M', + SqMm = 'SQ_MM', + SqYd = 'SQ_YD' +} /** * Assigns storefront's navigation menus. @@ -1633,113 +1428,90 @@ export type AreaUnitsEnum = * Requires one of the following permissions: MANAGE_MENUS, MANAGE_SETTINGS. */ export type AssignNavigation = { - __typename?: 'AssignNavigation'; - errors: Array; + readonly errors: ReadonlyArray; /** Assigned navigation menu. */ - menu?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; + readonly menu?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; }; -/** - * Represents assigned attribute to variant with variant selection attached. - * - * Added in Saleor 3.1. - */ +/** Represents assigned attribute to variant with variant selection attached. */ export type AssignedVariantAttribute = { - __typename?: 'AssignedVariantAttribute'; /** Attribute assigned to variant. */ - attribute: Attribute; + readonly attribute: Attribute; /** Determines, whether assigned attribute is allowed for variant selection. Supported variant types for variant selection are: ['dropdown', 'boolean', 'swatch', 'numeric'] */ - variantSelection: Scalars['Boolean']; + readonly variantSelection: Scalars['Boolean']; }; /** Custom attribute of a product. Attributes can be assigned to products and variants at the product type level. */ export type Attribute = Node & ObjectWithMetadata & { - __typename?: 'Attribute'; /** * Whether the attribute can be displayed in the admin product list. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - availableInGrid: Scalars['Boolean']; + readonly availableInGrid: Scalars['Boolean']; /** List of attribute's values. */ - choices?: Maybe; + readonly choices?: Maybe; /** The entity type which can be used as a reference. */ - entityType?: Maybe; - /** - * External ID of this attribute. - * - * Added in Saleor 3.10. - */ - externalReference?: Maybe; + readonly entityType?: Maybe; + /** External ID of this attribute. */ + readonly externalReference?: Maybe; /** Whether the attribute can be filtered in dashboard. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - filterableInDashboard: Scalars['Boolean']; + readonly filterableInDashboard: Scalars['Boolean']; /** * Whether the attribute can be filtered in storefront. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - filterableInStorefront: Scalars['Boolean']; + readonly filterableInStorefront: Scalars['Boolean']; /** The ID of the attribute. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The input type to use for entering attribute values in the dashboard. */ - inputType?: Maybe; + readonly inputType?: Maybe; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Name of an attribute displayed in the interface. */ - name?: Maybe; + readonly name?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** A list of product types that use this attribute as a product attribute. */ - productTypes: ProductTypeCountableConnection; + readonly productTypes: ProductTypeCountableConnection; /** A list of product types that use this attribute as a product variant attribute. */ - productVariantTypes: ProductTypeCountableConnection; + readonly productVariantTypes: ProductTypeCountableConnection; /** Internal representation of an attribute name. */ - slug?: Maybe; + readonly slug?: Maybe; /** * The position of the attribute in the storefront navigation (0 by default). Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - storefrontSearchPosition: Scalars['Int']; + readonly storefrontSearchPosition: Scalars['Int']; /** Returns translated attribute fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** The attribute type. */ - type?: Maybe; + readonly type?: Maybe; /** The unit of attribute values. */ - unit?: Maybe; + readonly unit?: Maybe; /** Whether the attribute requires values to be passed or not. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - valueRequired: Scalars['Boolean']; + readonly valueRequired: Scalars['Boolean']; /** Whether the attribute should be visible or not in storefront. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - visibleInStorefront: Scalars['Boolean']; + readonly visibleInStorefront: Scalars['Boolean']; /** Flag indicating that attribute has predefined choices. */ - withChoices: Scalars['Boolean']; + readonly withChoices: Scalars['Boolean']; }; @@ -1762,7 +1534,7 @@ export type AttributeMetafieldArgs = { /** Custom attribute of a product. Attributes can be assigned to products and variants at the product type level. */ export type AttributeMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -1774,7 +1546,7 @@ export type AttributePrivateMetafieldArgs = { /** Custom attribute of a product. Attributes can be assigned to products and variants at the product type level. */ export type AttributePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -1804,50 +1576,43 @@ export type AttributeTranslationArgs = { /** * Creates attributes. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Triggers the following webhook events: * - ATTRIBUTE_CREATED (async): An attribute was created. */ export type AttributeBulkCreate = { - __typename?: 'AttributeBulkCreate'; /** Returns how many objects were created. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the created attributes. */ - results: Array; + readonly results: ReadonlyArray; }; export type AttributeBulkCreateError = { - __typename?: 'AttributeBulkCreateError'; /** The error code. */ - code: AttributeBulkCreateErrorCode; + readonly code: AttributeBulkCreateErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; -}; - -/** An enumeration. */ -export type AttributeBulkCreateErrorCode = - | 'ALREADY_EXISTS' - | 'BLANK' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'MAX_LENGTH' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; + readonly path?: Maybe; +}; + +export enum AttributeBulkCreateErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + Blank = 'BLANK', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + MaxLength = 'MAX_LENGTH', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type AttributeBulkCreateResult = { - __typename?: 'AttributeBulkCreateResult'; /** Attribute data. */ - attribute?: Maybe; + readonly attribute?: Maybe; /** List of errors occurred on create attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; }; /** @@ -1859,149 +1624,133 @@ export type AttributeBulkCreateResult = { * - ATTRIBUTE_DELETED (async): An attribute was deleted. */ export type AttributeBulkDelete = { - __typename?: 'AttributeBulkDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; /** * Creates/updates translations for attributes. * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type AttributeBulkTranslate = { - __typename?: 'AttributeBulkTranslate'; /** Returns how many translations were created/updated. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the translations. */ - results: Array; + readonly results: ReadonlyArray; }; export type AttributeBulkTranslateError = { - __typename?: 'AttributeBulkTranslateError'; /** The error code. */ - code: AttributeTranslateErrorCode; + readonly code: AttributeTranslateErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; + readonly path?: Maybe; }; export type AttributeBulkTranslateInput = { /** External reference of an attribute. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** Attribute ID. */ - id?: InputMaybe; + readonly id?: InputMaybe; /** Translation language code. */ - languageCode: LanguageCodeEnum; + readonly languageCode: LanguageCodeEnum; /** Translation fields. */ - translationFields: NameTranslationInput; + readonly translationFields: NameTranslationInput; }; export type AttributeBulkTranslateResult = { - __typename?: 'AttributeBulkTranslateResult'; /** List of errors occurred on translation attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; /** Attribute translation data. */ - translation?: Maybe; + readonly translation?: Maybe; }; /** * Updates attributes. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Triggers the following webhook events: * - ATTRIBUTE_UPDATED (async): An attribute was updated. Optionally called when new attribute value was created or deleted. * - ATTRIBUTE_VALUE_CREATED (async): Called optionally when an attribute value was created. * - ATTRIBUTE_VALUE_DELETED (async): Called optionally when an attribute value was deleted. */ export type AttributeBulkUpdate = { - __typename?: 'AttributeBulkUpdate'; /** Returns how many objects were updated. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the updated attributes. */ - results: Array; + readonly results: ReadonlyArray; }; export type AttributeBulkUpdateError = { - __typename?: 'AttributeBulkUpdateError'; /** The error code. */ - code: AttributeBulkUpdateErrorCode; + readonly code: AttributeBulkUpdateErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; -}; - -/** An enumeration. */ -export type AttributeBulkUpdateErrorCode = - | 'ALREADY_EXISTS' - | 'BLANK' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'MAX_LENGTH' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; + readonly path?: Maybe; +}; + +export enum AttributeBulkUpdateErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + Blank = 'BLANK', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + MaxLength = 'MAX_LENGTH', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type AttributeBulkUpdateInput = { /** External ID of this attribute. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** Fields to update. */ - fields: AttributeUpdateInput; + readonly fields: AttributeUpdateInput; /** ID of an attribute to update. */ - id?: InputMaybe; + readonly id?: InputMaybe; }; export type AttributeBulkUpdateResult = { - __typename?: 'AttributeBulkUpdateResult'; /** Attribute data. */ - attribute?: Maybe; + readonly attribute?: Maybe; /** List of errors occurred on update attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; }; -export type AttributeChoicesSortField = +export enum AttributeChoicesSortField { /** Sort attribute choice by name. */ - | 'NAME' + Name = 'NAME', /** Sort attribute choice by slug. */ - | 'SLUG'; + Slug = 'SLUG' +} export type AttributeChoicesSortingInput = { /** Specifies the direction in which to sort attribute choices. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort attribute choices by the selected field. */ - field: AttributeChoicesSortField; + readonly field: AttributeChoicesSortField; }; export type AttributeCountableConnection = { - __typename?: 'AttributeCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type AttributeCountableEdge = { - __typename?: 'AttributeCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Attribute; + readonly node: Attribute; }; /** @@ -2011,11 +1760,10 @@ export type AttributeCountableEdge = { * - ATTRIBUTE_CREATED (async): An attribute was created. */ export type AttributeCreate = { - __typename?: 'AttributeCreate'; - attribute?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; - errors: Array; + readonly attribute?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -2026,69 +1774,57 @@ export type AttributeCreate = { export type AttributeCreateInput = { /** * Whether the attribute can be displayed in the admin product list. - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - availableInGrid?: InputMaybe; + readonly availableInGrid?: InputMaybe; /** The entity type which can be used as a reference. */ - entityType?: InputMaybe; - /** - * External ID of this attribute. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly entityType?: InputMaybe; + /** External ID of this attribute. */ + readonly externalReference?: InputMaybe; /** Whether the attribute can be filtered in dashboard. */ - filterableInDashboard?: InputMaybe; + readonly filterableInDashboard?: InputMaybe; /** * Whether the attribute can be filtered in storefront. - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - filterableInStorefront?: InputMaybe; + readonly filterableInStorefront?: InputMaybe; /** The input type to use for entering attribute values in the dashboard. */ - inputType?: InputMaybe; + readonly inputType?: InputMaybe; /** Whether the attribute is for variants only. */ - isVariantOnly?: InputMaybe; + readonly isVariantOnly?: InputMaybe; /** Name of an attribute displayed in the interface. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Internal representation of an attribute name. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** * The position of the attribute in the storefront navigation (0 by default). - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - storefrontSearchPosition?: InputMaybe; + readonly storefrontSearchPosition?: InputMaybe; /** The attribute type. */ - type: AttributeTypeEnum; + readonly type: AttributeTypeEnum; /** The unit of attribute values. */ - unit?: InputMaybe; + readonly unit?: InputMaybe; /** Whether the attribute requires values to be passed or not. */ - valueRequired?: InputMaybe; + readonly valueRequired?: InputMaybe; /** List of attribute's values. */ - values?: InputMaybe>; + readonly values?: InputMaybe>; /** Whether the attribute should be visible or not in storefront. */ - visibleInStorefront?: InputMaybe; + readonly visibleInStorefront?: InputMaybe; }; -/** - * Event sent when new attribute is created. - * - * Added in Saleor 3.5. - */ +/** Event sent when new attribute is created. */ export type AttributeCreated = Event & { - __typename?: 'AttributeCreated'; /** The attribute the event relates to. */ - attribute?: Maybe; + readonly attribute?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -2100,120 +1836,112 @@ export type AttributeCreated = Event & { * - ATTRIBUTE_DELETED (async): An attribute was deleted. */ export type AttributeDelete = { - __typename?: 'AttributeDelete'; - attribute?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; - errors: Array; + readonly attribute?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** - * Event sent when attribute is deleted. - * - * Added in Saleor 3.5. - */ +/** Event sent when attribute is deleted. */ export type AttributeDeleted = Event & { - __typename?: 'AttributeDeleted'; /** The attribute the event relates to. */ - attribute?: Maybe; + readonly attribute?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** An enumeration. */ -export type AttributeEntityTypeEnum = - | 'PAGE' - | 'PRODUCT' - | 'PRODUCT_VARIANT'; +export enum AttributeEntityTypeEnum { + Page = 'PAGE', + Product = 'PRODUCT', + ProductVariant = 'PRODUCT_VARIANT' +} export type AttributeEntityTypeEnumFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; }; export type AttributeError = { - __typename?: 'AttributeError'; /** The error code. */ - code: AttributeErrorCode; + readonly code: AttributeErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type AttributeErrorCode = - | 'ALREADY_EXISTS' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; +export enum AttributeErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type AttributeFilterInput = { - availableInGrid?: InputMaybe; + readonly availableInGrid?: InputMaybe; /** * Specifies the channel by which the data should be filtered. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - */ - channel?: InputMaybe; - filterableInDashboard?: InputMaybe; - filterableInStorefront?: InputMaybe; - ids?: InputMaybe>; - inCategory?: InputMaybe; - inCollection?: InputMaybe; - isVariantOnly?: InputMaybe; - metadata?: InputMaybe>; - search?: InputMaybe; - slugs?: InputMaybe>; - type?: InputMaybe; - valueRequired?: InputMaybe; - visibleInStorefront?: InputMaybe; + * @deprecated Use root-level channel argument instead. + */ + readonly channel?: InputMaybe; + readonly filterableInDashboard?: InputMaybe; + readonly filterableInStorefront?: InputMaybe; + readonly ids?: InputMaybe>; + readonly inCategory?: InputMaybe; + readonly inCollection?: InputMaybe; + readonly isVariantOnly?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; + readonly type?: InputMaybe; + readonly valueRequired?: InputMaybe; + readonly visibleInStorefront?: InputMaybe; }; export type AttributeInput = { /** The boolean value of the attribute. */ - boolean?: InputMaybe; + readonly boolean?: InputMaybe; /** The date range that the returned values should be in. In case of date/time attributes, the UTC midnight of the given date is used. */ - date?: InputMaybe; + readonly date?: InputMaybe; /** The date/time range that the returned values should be in. */ - dateTime?: InputMaybe; + readonly dateTime?: InputMaybe; /** Internal representation of an attribute name. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; /** Internal representation of a value (unique per attribute). */ - values?: InputMaybe>; + readonly values?: InputMaybe>; /** The range that the returned values should be in. */ - valuesRange?: InputMaybe; -}; - -/** An enumeration. */ -export type AttributeInputTypeEnum = - | 'BOOLEAN' - | 'DATE' - | 'DATE_TIME' - | 'DROPDOWN' - | 'FILE' - | 'MULTISELECT' - | 'NUMERIC' - | 'PLAIN_TEXT' - | 'REFERENCE' - | 'RICH_TEXT' - | 'SWATCH'; + readonly valuesRange?: InputMaybe; +}; + +export enum AttributeInputTypeEnum { + Boolean = 'BOOLEAN', + Date = 'DATE', + DateTime = 'DATE_TIME', + Dropdown = 'DROPDOWN', + File = 'FILE', + Multiselect = 'MULTISELECT', + Numeric = 'NUMERIC', + PlainText = 'PLAIN_TEXT', + Reference = 'REFERENCE', + RichText = 'RICH_TEXT', + Swatch = 'SWATCH' +} export type AttributeInputTypeEnumFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; }; /** @@ -2226,61 +1954,56 @@ export type AttributeInputTypeEnumFilterInput = { * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ export type AttributeReorderValues = { - __typename?: 'AttributeReorderValues'; /** Attribute from which values are reordered. */ - attribute?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; - errors: Array; + readonly attribute?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -export type AttributeSortField = +export enum AttributeSortField { /** Sort attributes based on whether they can be displayed or not in a product grid. */ - | 'AVAILABLE_IN_GRID' + AvailableInGrid = 'AVAILABLE_IN_GRID', /** Sort attributes by the filterable in dashboard flag */ - | 'FILTERABLE_IN_DASHBOARD' + FilterableInDashboard = 'FILTERABLE_IN_DASHBOARD', /** Sort attributes by the filterable in storefront flag */ - | 'FILTERABLE_IN_STOREFRONT' + FilterableInStorefront = 'FILTERABLE_IN_STOREFRONT', /** Sort attributes by the variant only flag */ - | 'IS_VARIANT_ONLY' + IsVariantOnly = 'IS_VARIANT_ONLY', /** Sort attributes by name */ - | 'NAME' + Name = 'NAME', /** Sort attributes by slug */ - | 'SLUG' + Slug = 'SLUG', /** Sort attributes by their position in storefront */ - | 'STOREFRONT_SEARCH_POSITION' + StorefrontSearchPosition = 'STOREFRONT_SEARCH_POSITION', /** Sort attributes by the value required flag */ - | 'VALUE_REQUIRED' + ValueRequired = 'VALUE_REQUIRED', /** Sort attributes by visibility in the storefront */ - | 'VISIBLE_IN_STOREFRONT'; + VisibleInStorefront = 'VISIBLE_IN_STOREFRONT' +} export type AttributeSortingInput = { /** Specifies the direction in which to sort attributes. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort attributes by the selected field. */ - field: AttributeSortField; + readonly field: AttributeSortField; }; /** Represents attribute's original translatable fields and related translations. */ export type AttributeTranslatableContent = Node & { - __typename?: 'AttributeTranslatableContent'; /** * Custom attribute of a product. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. - */ - attribute?: Maybe; - /** - * The ID of the attribute to translate. - * - * Added in Saleor 3.14. + * @deprecated Get model fields from the root level queries. */ - attributeId: Scalars['ID']; + readonly attribute?: Maybe; + /** The ID of the attribute to translate. */ + readonly attributeId: Scalars['ID']; /** The ID of the attribute translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the attribute to translate. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Returns translated attribute fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -2295,47 +2018,41 @@ export type AttributeTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type AttributeTranslate = { - __typename?: 'AttributeTranslate'; - attribute?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly attribute?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; -/** An enumeration. */ -export type AttributeTranslateErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum AttributeTranslateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} /** Represents attribute translations. */ export type AttributeTranslation = Node & { - __typename?: 'AttributeTranslation'; /** The ID of the attribute translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated attribute name. */ - name: Scalars['String']; - /** - * Represents the attribute fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly name: Scalars['String']; + /** Represents the attribute fields to translate. */ + readonly translatableContent?: Maybe; }; -/** An enumeration. */ -export type AttributeTypeEnum = - | 'PAGE_TYPE' - | 'PRODUCT_TYPE'; +export enum AttributeTypeEnum { + PageType = 'PAGE_TYPE', + ProductType = 'PRODUCT_TYPE' +} export type AttributeTypeEnumFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; }; /** @@ -2347,11 +2064,10 @@ export type AttributeTypeEnumFilterInput = { * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ export type AttributeUpdate = { - __typename?: 'AttributeUpdate'; - attribute?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; - errors: Array; + readonly attribute?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -2361,107 +2077,90 @@ export type AttributeUpdate = { */ export type AttributeUpdateInput = { /** New values to be created for this attribute. */ - addValues?: InputMaybe>; + readonly addValues?: InputMaybe>; /** * Whether the attribute can be displayed in the admin product list. - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - availableInGrid?: InputMaybe; - /** - * External ID of this product. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly availableInGrid?: InputMaybe; + /** External ID of this product. */ + readonly externalReference?: InputMaybe; /** Whether the attribute can be filtered in dashboard. */ - filterableInDashboard?: InputMaybe; + readonly filterableInDashboard?: InputMaybe; /** * Whether the attribute can be filtered in storefront. - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - filterableInStorefront?: InputMaybe; + readonly filterableInStorefront?: InputMaybe; /** Whether the attribute is for variants only. */ - isVariantOnly?: InputMaybe; + readonly isVariantOnly?: InputMaybe; /** Name of an attribute displayed in the interface. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** IDs of values to be removed from this attribute. */ - removeValues?: InputMaybe>; + readonly removeValues?: InputMaybe>; /** Internal representation of an attribute name. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** * The position of the attribute in the storefront navigation (0 by default). - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - storefrontSearchPosition?: InputMaybe; + readonly storefrontSearchPosition?: InputMaybe; /** The unit of attribute values. */ - unit?: InputMaybe; + readonly unit?: InputMaybe; /** Whether the attribute requires values to be passed or not. */ - valueRequired?: InputMaybe; + readonly valueRequired?: InputMaybe; /** Whether the attribute should be visible or not in storefront. */ - visibleInStorefront?: InputMaybe; + readonly visibleInStorefront?: InputMaybe; }; -/** - * Event sent when attribute is updated. - * - * Added in Saleor 3.5. - */ +/** Event sent when attribute is updated. */ export type AttributeUpdated = Event & { - __typename?: 'AttributeUpdated'; /** The attribute the event relates to. */ - attribute?: Maybe; + readonly attribute?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Represents a value of an attribute. */ export type AttributeValue = Node & { - __typename?: 'AttributeValue'; /** Represents the boolean value of the attribute value. */ - boolean?: Maybe; + readonly boolean?: Maybe; /** Represents the date value of the attribute value. */ - date?: Maybe; + readonly date?: Maybe; /** Represents the date/time value of the attribute value. */ - dateTime?: Maybe; - /** - * External ID of this attribute value. - * - * Added in Saleor 3.10. - */ - externalReference?: Maybe; + readonly dateTime?: Maybe; + /** External ID of this attribute value. */ + readonly externalReference?: Maybe; /** Represents file URL and content type (if attribute value is a file). */ - file?: Maybe; + readonly file?: Maybe; /** The ID of the attribute value. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The input type to use for entering attribute values in the dashboard. */ - inputType?: Maybe; + readonly inputType?: Maybe; /** Name of a value displayed in the interface. */ - name?: Maybe; + readonly name?: Maybe; /** Represents the text of the attribute value, plain text without formatting. */ - plainText?: Maybe; + readonly plainText?: Maybe; /** The ID of the attribute reference. */ - reference?: Maybe; + readonly reference?: Maybe; /** * Represents the text of the attribute value, includes formatting. * * Rich text format. For reference see https://editorjs.io/ */ - richText?: Maybe; + readonly richText?: Maybe; /** Internal representation of a value (unique per attribute). */ - slug?: Maybe; + readonly slug?: Maybe; /** Returns translated attribute value fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** Represent value of the attribute value (e.g. color values for swatch attributes). */ - value?: Maybe; + readonly value?: Maybe; }; @@ -2480,76 +2179,66 @@ export type AttributeValueTranslationArgs = { * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ export type AttributeValueBulkDelete = { - __typename?: 'AttributeValueBulkDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; /** * Creates/updates translations for attributes values. * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type AttributeValueBulkTranslate = { - __typename?: 'AttributeValueBulkTranslate'; /** Returns how many translations were created/updated. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the translations. */ - results: Array; + readonly results: ReadonlyArray; }; export type AttributeValueBulkTranslateError = { - __typename?: 'AttributeValueBulkTranslateError'; /** The error code. */ - code: AttributeValueTranslateErrorCode; + readonly code: AttributeValueTranslateErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; + readonly path?: Maybe; }; export type AttributeValueBulkTranslateInput = { /** External reference of an attribute value. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** Attribute value ID. */ - id?: InputMaybe; + readonly id?: InputMaybe; /** Translation language code. */ - languageCode: LanguageCodeEnum; + readonly languageCode: LanguageCodeEnum; /** Translation fields. */ - translationFields: AttributeValueTranslationInput; + readonly translationFields: AttributeValueTranslationInput; }; export type AttributeValueBulkTranslateResult = { - __typename?: 'AttributeValueBulkTranslateResult'; /** List of errors occurred on translation attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; /** Attribute value translation data. */ - translation?: Maybe; + readonly translation?: Maybe; }; export type AttributeValueCountableConnection = { - __typename?: 'AttributeValueCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type AttributeValueCountableEdge = { - __typename?: 'AttributeValueCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: AttributeValue; + readonly node: AttributeValue; }; /** @@ -2562,63 +2251,51 @@ export type AttributeValueCountableEdge = { * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ export type AttributeValueCreate = { - __typename?: 'AttributeValueCreate'; /** The updated attribute. */ - attribute?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; - attributeValue?: Maybe; - errors: Array; + readonly attribute?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; + readonly attributeValue?: Maybe; + readonly errors: ReadonlyArray; }; export type AttributeValueCreateInput = { /** File content type. */ - contentType?: InputMaybe; - /** - * External ID of this attribute value. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly contentType?: InputMaybe; + /** External ID of this attribute value. */ + readonly externalReference?: InputMaybe; /** URL of the file attribute. Every time, a new value is created. */ - fileUrl?: InputMaybe; + readonly fileUrl?: InputMaybe; /** Name of a value displayed in the interface. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** * Represents the text of the attribute value, plain text without formatting. - * - * DEPRECATED: this field will be removed in Saleor 4.0.The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. + * @deprecated The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. */ - plainText?: InputMaybe; + readonly plainText?: InputMaybe; /** * Represents the text of the attribute value, includes formatting. * * Rich text format. For reference see https://editorjs.io/ - * - * DEPRECATED: this field will be removed in Saleor 4.0.The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. + * @deprecated The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. */ - richText?: InputMaybe; + readonly richText?: InputMaybe; /** Represent value of the attribute value (e.g. color values for swatch attributes). */ - value?: InputMaybe; + readonly value?: InputMaybe; }; -/** - * Event sent when new attribute value is created. - * - * Added in Saleor 3.5. - */ +/** Event sent when new attribute value is created. */ export type AttributeValueCreated = Event & { - __typename?: 'AttributeValueCreated'; /** The attribute value the event relates to. */ - attributeValue?: Maybe; + readonly attributeValue?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -2631,91 +2308,68 @@ export type AttributeValueCreated = Event & { * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ export type AttributeValueDelete = { - __typename?: 'AttributeValueDelete'; /** The updated attribute. */ - attribute?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; - attributeValue?: Maybe; - errors: Array; + readonly attribute?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; + readonly attributeValue?: Maybe; + readonly errors: ReadonlyArray; }; -/** - * Event sent when attribute value is deleted. - * - * Added in Saleor 3.5. - */ +/** Event sent when attribute value is deleted. */ export type AttributeValueDeleted = Event & { - __typename?: 'AttributeValueDeleted'; /** The attribute value the event relates to. */ - attributeValue?: Maybe; + readonly attributeValue?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type AttributeValueFilterInput = { - ids?: InputMaybe>; - search?: InputMaybe; - slugs?: InputMaybe>; + readonly ids?: InputMaybe>; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; }; export type AttributeValueInput = { /** Represents the boolean value of the attribute value. */ - boolean?: InputMaybe; + readonly boolean?: InputMaybe; /** File content type. */ - contentType?: InputMaybe; + readonly contentType?: InputMaybe; /** Represents the date value of the attribute value. */ - date?: InputMaybe; + readonly date?: InputMaybe; /** Represents the date/time value of the attribute value. */ - dateTime?: InputMaybe; - /** - * Attribute value ID or external reference. - * - * Added in Saleor 3.9. - */ - dropdown?: InputMaybe; - /** - * External ID of this attribute. - * - * Added in Saleor 3.14. - */ - externalReference?: InputMaybe; + readonly dateTime?: InputMaybe; + /** Attribute value ID or external reference. */ + readonly dropdown?: InputMaybe; + /** External ID of this attribute. */ + readonly externalReference?: InputMaybe; /** URL of the file attribute. Every time, a new value is created. */ - file?: InputMaybe; + readonly file?: InputMaybe; /** ID of the selected attribute. */ - id?: InputMaybe; - /** - * List of attribute value IDs or external references. - * - * Added in Saleor 3.9. - */ - multiselect?: InputMaybe>; - /** - * Numeric value of an attribute. - * - * Added in Saleor 3.9. - */ - numeric?: InputMaybe; + readonly id?: InputMaybe; + /** List of attribute value IDs or external references. */ + readonly multiselect?: InputMaybe>; + /** Numeric value of an attribute. */ + readonly numeric?: InputMaybe; /** Plain text content. */ - plainText?: InputMaybe; + readonly plainText?: InputMaybe; /** List of entity IDs that will be used as references. */ - references?: InputMaybe>; + readonly references?: InputMaybe>; /** Text content in JSON format. */ - richText?: InputMaybe; + readonly richText?: InputMaybe; + /** Attribute value ID or external reference. */ + readonly swatch?: InputMaybe; /** - * Attribute value ID or external reference. - * - * Added in Saleor 3.9. + * The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. + * @deprecated Field no longer supported */ - swatch?: InputMaybe; - /** The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. This field will be removed in Saleor 4.0. */ - values?: InputMaybe>; + readonly values?: InputMaybe>; }; /** @@ -2724,56 +2378,41 @@ export type AttributeValueInput = { * 2. If externalReference is provided, then attribute value will be resolved by external reference. * 3. If value is provided, then attribute value will be resolved by value. If this attribute value doesn't exist, then it will be created. * 4. If externalReference and value is provided then new attribute value will be created. - * - * Added in Saleor 3.9. */ export type AttributeValueSelectableTypeInput = { - /** - * External reference of an attribute value. - * - * Added in Saleor 3.14. - */ - externalReference?: InputMaybe; + /** External reference of an attribute value. */ + readonly externalReference?: InputMaybe; /** ID of an attribute value. */ - id?: InputMaybe; + readonly id?: InputMaybe; /** The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. */ - value?: InputMaybe; + readonly value?: InputMaybe; }; /** Represents attribute value's original translatable fields and related translations. */ export type AttributeValueTranslatableContent = Node & { - __typename?: 'AttributeValueTranslatableContent'; - /** - * Associated attribute that can be translated. - * - * Added in Saleor 3.9. - */ - attribute?: Maybe; + /** Associated attribute that can be translated. */ + readonly attribute?: Maybe; /** * Represents a value of an attribute. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. - */ - attributeValue?: Maybe; - /** - * The ID of the attribute value to translate. - * - * Added in Saleor 3.14. + * @deprecated Get model fields from the root level queries. */ - attributeValueId: Scalars['ID']; + readonly attributeValue?: Maybe; + /** The ID of the attribute value to translate. */ + readonly attributeValueId: Scalars['ID']; /** The ID of the attribute value translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the attribute value to translate. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Attribute plain text value. */ - plainText?: Maybe; + readonly plainText?: Maybe; /** * Attribute value. * * Rich text format. For reference see https://editorjs.io/ */ - richText?: Maybe; + readonly richText?: Maybe; /** Returns translated attribute value fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -2788,55 +2427,49 @@ export type AttributeValueTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type AttributeValueTranslate = { - __typename?: 'AttributeValueTranslate'; - attributeValue?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly attributeValue?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; -/** An enumeration. */ -export type AttributeValueTranslateErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum AttributeValueTranslateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} /** Represents attribute value translations. */ export type AttributeValueTranslation = Node & { - __typename?: 'AttributeValueTranslation'; /** The ID of the attribute value translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated attribute value name. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Translated plain text attribute value . */ - plainText?: Maybe; + readonly plainText?: Maybe; /** * Translated rich-text attribute value. * * Rich text format. For reference see https://editorjs.io/ */ - richText?: Maybe; - /** - * Represents the attribute value fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly richText?: Maybe; + /** Represents the attribute value fields to translate. */ + readonly translatableContent?: Maybe; }; export type AttributeValueTranslationInput = { - name?: InputMaybe; + readonly name?: InputMaybe; /** Translated text. */ - plainText?: InputMaybe; + readonly plainText?: InputMaybe; /** * Translated text. * * Rich text format. For reference see https://editorjs.io/ */ - richText?: InputMaybe; + readonly richText?: InputMaybe; }; /** @@ -2849,345 +2482,254 @@ export type AttributeValueTranslationInput = { * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ export type AttributeValueUpdate = { - __typename?: 'AttributeValueUpdate'; /** The updated attribute. */ - attribute?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - attributeErrors: Array; - attributeValue?: Maybe; - errors: Array; + readonly attribute?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly attributeErrors: ReadonlyArray; + readonly attributeValue?: Maybe; + readonly errors: ReadonlyArray; }; export type AttributeValueUpdateInput = { /** File content type. */ - contentType?: InputMaybe; - /** - * External ID of this attribute value. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly contentType?: InputMaybe; + /** External ID of this attribute value. */ + readonly externalReference?: InputMaybe; /** URL of the file attribute. Every time, a new value is created. */ - fileUrl?: InputMaybe; + readonly fileUrl?: InputMaybe; /** Name of a value displayed in the interface. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** * Represents the text of the attribute value, plain text without formatting. - * - * DEPRECATED: this field will be removed in Saleor 4.0.The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. + * @deprecated The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. */ - plainText?: InputMaybe; + readonly plainText?: InputMaybe; /** * Represents the text of the attribute value, includes formatting. * * Rich text format. For reference see https://editorjs.io/ - * - * DEPRECATED: this field will be removed in Saleor 4.0.The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. + * @deprecated The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. */ - richText?: InputMaybe; + readonly richText?: InputMaybe; /** Represent value of the attribute value (e.g. color values for swatch attributes). */ - value?: InputMaybe; + readonly value?: InputMaybe; }; -/** - * Event sent when attribute value is updated. - * - * Added in Saleor 3.5. - */ +/** Event sent when attribute value is updated. */ export type AttributeValueUpdated = Event & { - __typename?: 'AttributeValueUpdated'; /** The attribute value the event relates to. */ - attributeValue?: Maybe; + readonly attributeValue?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Where filtering options. - * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Where filtering options. */ export type AttributeWhereInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; - entityType?: InputMaybe; - filterableInDashboard?: InputMaybe; - ids?: InputMaybe>; - inCategory?: InputMaybe; - inCollection?: InputMaybe; - inputType?: InputMaybe; - metadata?: InputMaybe>; - name?: InputMaybe; - slug?: InputMaybe; - type?: InputMaybe; - unit?: InputMaybe; - valueRequired?: InputMaybe; - visibleInStorefront?: InputMaybe; - withChoices?: InputMaybe; + readonly OR?: InputMaybe>; + readonly entityType?: InputMaybe; + readonly filterableInDashboard?: InputMaybe; + readonly ids?: InputMaybe>; + readonly inCategory?: InputMaybe; + readonly inCollection?: InputMaybe; + readonly inputType?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly name?: InputMaybe; + readonly slug?: InputMaybe; + readonly type?: InputMaybe; + readonly unit?: InputMaybe; + readonly valueRequired?: InputMaybe; + readonly visibleInStorefront?: InputMaybe; + readonly withChoices?: InputMaybe; }; export type BulkAttributeValueInput = { /** The boolean value of an attribute to resolve. If the passed value is non-existent, it will be created. */ - boolean?: InputMaybe; - /** - * File content type. - * - * Added in Saleor 3.12. - */ - contentType?: InputMaybe; - /** - * Represents the date value of the attribute value. - * - * Added in Saleor 3.12. - */ - date?: InputMaybe; - /** - * Represents the date/time value of the attribute value. - * - * Added in Saleor 3.12. - */ - dateTime?: InputMaybe; - /** - * Attribute value ID. - * - * Added in Saleor 3.12. - */ - dropdown?: InputMaybe; - /** - * External ID of this attribute. - * - * Added in Saleor 3.14. - */ - externalReference?: InputMaybe; - /** - * URL of the file attribute. Every time, a new value is created. - * - * Added in Saleor 3.12. - */ - file?: InputMaybe; + readonly boolean?: InputMaybe; + /** File content type. */ + readonly contentType?: InputMaybe; + /** Represents the date value of the attribute value. */ + readonly date?: InputMaybe; + /** Represents the date/time value of the attribute value. */ + readonly dateTime?: InputMaybe; + /** Attribute value ID. */ + readonly dropdown?: InputMaybe; + /** External ID of this attribute. */ + readonly externalReference?: InputMaybe; + /** URL of the file attribute. Every time, a new value is created. */ + readonly file?: InputMaybe; /** ID of the selected attribute. */ - id?: InputMaybe; - /** - * List of attribute value IDs. - * - * Added in Saleor 3.12. - */ - multiselect?: InputMaybe>; - /** - * Numeric value of an attribute. - * - * Added in Saleor 3.12. - */ - numeric?: InputMaybe; - /** - * Plain text content. - * - * Added in Saleor 3.12. - */ - plainText?: InputMaybe; - /** - * List of entity IDs that will be used as references. - * - * Added in Saleor 3.12. - */ - references?: InputMaybe>; - /** - * Text content in JSON format. - * - * Added in Saleor 3.12. - */ - richText?: InputMaybe; + readonly id?: InputMaybe; + /** List of attribute value IDs. */ + readonly multiselect?: InputMaybe>; + /** Numeric value of an attribute. */ + readonly numeric?: InputMaybe; + /** Plain text content. */ + readonly plainText?: InputMaybe; + /** List of entity IDs that will be used as references. */ + readonly references?: InputMaybe>; + /** Text content in JSON format. */ + readonly richText?: InputMaybe; + /** Attribute value ID. */ + readonly swatch?: InputMaybe; /** - * Attribute value ID. - * - * Added in Saleor 3.12. + * The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. + * @deprecated Field no longer supported */ - swatch?: InputMaybe; - /** The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created.This field will be removed in Saleor 4.0. */ - values?: InputMaybe>; + readonly values?: InputMaybe>; }; export type BulkProductError = { - __typename?: 'BulkProductError'; /** List of attributes IDs which causes the error. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** List of channel IDs which causes the error. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** The error code. */ - code: ProductErrorCode; + readonly code: ProductErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** Index of an input list item that caused the error. */ - index?: Maybe; + readonly index?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of attribute values IDs which causes the error. */ - values?: Maybe>; + readonly values?: Maybe>; /** List of warehouse IDs which causes the error. */ - warehouses?: Maybe>; + readonly warehouses?: Maybe>; }; export type BulkStockError = { - __typename?: 'BulkStockError'; /** List of attributes IDs which causes the error. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** The error code. */ - code: ProductErrorCode; + readonly code: ProductErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** Index of an input list item that caused the error. */ - index?: Maybe; + readonly index?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of attribute values IDs which causes the error. */ - values?: Maybe>; + readonly values?: Maybe>; }; -/** - * Synchronous webhook for calculating checkout/order taxes. - * - * Added in Saleor 3.7. - */ +/** Synchronous webhook for calculating checkout/order taxes. */ export type CalculateTaxes = Event & { - __typename?: 'CalculateTaxes'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; - taxBase: TaxableObject; + readonly recipient?: Maybe; + readonly taxBase: TaxableObject; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type CardInput = { /** Payment method nonce, a token returned by the appropriate provider's SDK. */ - code: Scalars['String']; + readonly code: Scalars['String']; /** Card security code. */ - cvc?: InputMaybe; + readonly cvc?: InputMaybe; /** Information about currency and amount. */ - money: MoneyInput; + readonly money: MoneyInput; }; export type CatalogueInput = { /** Categories related to the discount. */ - categories?: InputMaybe>; + readonly categories?: InputMaybe>; /** Collections related to the discount. */ - collections?: InputMaybe>; + readonly collections?: InputMaybe>; /** Products related to the discount. */ - products?: InputMaybe>; - /** - * Product variant related to the discount. - * - * Added in Saleor 3.1. - */ - variants?: InputMaybe>; + readonly products?: InputMaybe>; + /** Product variant related to the discount. */ + readonly variants?: InputMaybe>; }; export type CataloguePredicateInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; + readonly OR?: InputMaybe>; /** Defines the category conditions to be met. */ - categoryPredicate?: InputMaybe; + readonly categoryPredicate?: InputMaybe; /** Defines the collection conditions to be met. */ - collectionPredicate?: InputMaybe; + readonly collectionPredicate?: InputMaybe; /** Defines the product conditions to be met. */ - productPredicate?: InputMaybe; + readonly productPredicate?: InputMaybe; /** Defines the product variant conditions to be met. */ - variantPredicate?: InputMaybe; + readonly variantPredicate?: InputMaybe; }; /** Represents a single category of products. Categories allow to organize products in a tree-hierarchies which can be used for navigation in the storefront. */ export type Category = Node & ObjectWithMetadata & { - __typename?: 'Category'; /** List of ancestors of the category. */ - ancestors?: Maybe; + readonly ancestors?: Maybe; /** Background image of the category. */ - backgroundImage?: Maybe; + readonly backgroundImage?: Maybe; /** List of children of the category. */ - children?: Maybe; + readonly children?: Maybe; /** * Description of the category. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Description of the category. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. + * @deprecated Use the `description` field instead. */ - descriptionJson?: Maybe; + readonly descriptionJson?: Maybe; /** The ID of the category. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Level of the category. */ - level: Scalars['Int']; + readonly level: Scalars['Int']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Name of category */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Parent category. */ - parent?: Maybe; + readonly parent?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** List of products in the category. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - products?: Maybe; + readonly products?: Maybe; /** SEO description of category. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** SEO title of category. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; /** Slug of the category. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; /** Returns translated category fields for the given language code. */ - translation?: Maybe; - /** - * The date and time when the category was last updated. - * - * Added in Saleor 3.17. - */ - updatedAt: Scalars['DateTime']; + readonly translation?: Maybe; + /** The date and time when the category was last updated. */ + readonly updatedAt: Scalars['DateTime']; }; @@ -3224,7 +2766,7 @@ export type CategoryMetafieldArgs = { /** Represents a single category of products. Categories allow to organize products in a tree-hierarchies which can be used for navigation in the storefront. */ export type CategoryMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -3236,7 +2778,7 @@ export type CategoryPrivateMetafieldArgs = { /** Represents a single category of products. Categories allow to organize products in a tree-hierarchies which can be used for navigation in the storefront. */ export type CategoryPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -3264,29 +2806,26 @@ export type CategoryTranslationArgs = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CategoryBulkDelete = { - __typename?: 'CategoryBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; export type CategoryCountableConnection = { - __typename?: 'CategoryCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type CategoryCountableEdge = { - __typename?: 'CategoryCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Category; + readonly node: Category; }; /** @@ -3295,30 +2834,24 @@ export type CategoryCountableEdge = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CategoryCreate = { - __typename?: 'CategoryCreate'; - category?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly category?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -/** - * Event sent when new category is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new category is created. */ export type CategoryCreated = Event & { - __typename?: 'CategoryCreated'; /** The category the event relates to. */ - category?: Maybe; + readonly category?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -3327,134 +2860,125 @@ export type CategoryCreated = Event & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CategoryDelete = { - __typename?: 'CategoryDelete'; - category?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly category?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -/** - * Event sent when category is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when category is deleted. */ export type CategoryDeleted = Event & { - __typename?: 'CategoryDeleted'; /** The category the event relates to. */ - category?: Maybe; + readonly category?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type CategoryFilterInput = { - ids?: InputMaybe>; - metadata?: InputMaybe>; - search?: InputMaybe; - slugs?: InputMaybe>; - /** - * Filter by when was the most recent update. - * - * Added in Saleor 3.17. - */ - updatedAt?: InputMaybe; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; + /** Filter by when was the most recent update. */ + readonly updatedAt?: InputMaybe; }; export type CategoryInput = { /** Background image file. */ - backgroundImage?: InputMaybe; + readonly backgroundImage?: InputMaybe; /** Alt text for a product media. */ - backgroundImageAlt?: InputMaybe; + readonly backgroundImageAlt?: InputMaybe; /** * Category description. * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; + readonly description?: InputMaybe; /** - * Fields required to update the category metadata. + * Fields required to update the category metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Category name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** - * Fields required to update the category private metadata. + * Fields required to update the category private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** Search engine optimization fields. */ - seo?: InputMaybe; + readonly seo?: InputMaybe; /** Category slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; -export type CategorySortField = +export enum CategorySortField { /** Sort categories by name. */ - | 'NAME' + Name = 'NAME', /** Sort categories by product count. */ - | 'PRODUCT_COUNT' + ProductCount = 'PRODUCT_COUNT', /** Sort categories by subcategory count. */ - | 'SUBCATEGORY_COUNT'; + SubcategoryCount = 'SUBCATEGORY_COUNT' +} export type CategorySortingInput = { /** * Specifies the channel in which to sort the data. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. + * @deprecated Use root-level channel argument instead. */ - channel?: InputMaybe; + readonly channel?: InputMaybe; /** Specifies the direction in which to sort categories. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort categories by the selected field. */ - field: CategorySortField; + readonly field: CategorySortField; }; /** Represents category original translatable fields and related translations. */ export type CategoryTranslatableContent = Node & { - __typename?: 'CategoryTranslatableContent'; /** * Represents a single category of products. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. - */ - category?: Maybe; - /** - * The ID of the category to translate. - * - * Added in Saleor 3.14. + * @deprecated Get model fields from the root level queries. */ - categoryId: Scalars['ID']; + readonly category?: Maybe; + /** The ID of the category to translate. */ + readonly categoryId: Scalars['ID']; /** * Category description to translate. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Description of the category. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. + * @deprecated Use the `description` field instead. */ - descriptionJson?: Maybe; + readonly descriptionJson?: Maybe; /** The ID of the category translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the category translatable content. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** SEO description to translate. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** SEO title to translate. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; + /** + * Slug to translate. + * + * Added in Saleor 3.21. + */ + readonly slug?: Maybe; /** Returns translated category fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -3469,45 +2993,45 @@ export type CategoryTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type CategoryTranslate = { - __typename?: 'CategoryTranslate'; - category?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly category?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; /** Represents category translations. */ export type CategoryTranslation = Node & { - __typename?: 'CategoryTranslation'; /** * Translated description of the category. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Translated description of the category. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. + * @deprecated Use the `description` field instead. */ - descriptionJson?: Maybe; + readonly descriptionJson?: Maybe; /** The ID of the category translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated category name. */ - name?: Maybe; + readonly name?: Maybe; /** Translated SEO description. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** Translated SEO title. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; /** - * Represents the category fields to translate. + * Translated category slug. * - * Added in Saleor 3.14. + * Added in Saleor 3.21. */ - translatableContent?: Maybe; + readonly slug?: Maybe; + /** Represents the category fields to translate. */ + readonly translatableContent?: Maybe; }; /** @@ -3516,168 +3040,119 @@ export type CategoryTranslation = Node & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CategoryUpdate = { - __typename?: 'CategoryUpdate'; - category?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly category?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -/** - * Event sent when category is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when category is updated. */ export type CategoryUpdated = Event & { - __typename?: 'CategoryUpdated'; /** The category the event relates to. */ - category?: Maybe; + readonly category?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type CategoryWhereInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; - ids?: InputMaybe>; - metadata?: InputMaybe>; + readonly OR?: InputMaybe>; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; }; /** Represents channel. */ export type Channel = Node & ObjectWithMetadata & { - __typename?: 'Channel'; - /** - * Shipping methods that are available for the channel. - * - * Added in Saleor 3.6. - */ - availableShippingMethodsPerCountry?: Maybe>; + /** Shipping methods that are available for the channel. */ + readonly availableShippingMethodsPerCountry?: Maybe>; /** * Channel-specific checkout settings. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_CHANNELS, MANAGE_CHECKOUTS. */ - checkoutSettings: CheckoutSettings; - /** - * List of shippable countries for the channel. - * - * Added in Saleor 3.6. - */ - countries?: Maybe>; + readonly checkoutSettings: CheckoutSettings; + /** List of shippable countries for the channel. */ + readonly countries?: Maybe>; /** * A currency that is assigned to the channel. * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - currencyCode: Scalars['String']; + readonly currencyCode: Scalars['String']; /** * Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - defaultCountry: CountryDisplay; + readonly defaultCountry: CountryDisplay; /** * Whether a channel has associated orders. * * Requires one of the following permissions: MANAGE_CHANNELS. */ - hasOrders: Scalars['Boolean']; + readonly hasOrders: Scalars['Boolean']; /** The ID of the channel. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Whether the channel is active. * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - isActive: Scalars['Boolean']; - /** - * List of public metadata items. Can be accessed without permissions. - * - * Added in Saleor 3.15. - */ - metadata: Array; + readonly isActive: Scalars['Boolean']; + /** List of public metadata items. Can be accessed without permissions. */ + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.15. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.15. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** * Name of the channel. * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** * Channel-specific order settings. * - * Added in Saleor 3.12. - * * Requires one of the following permissions: MANAGE_CHANNELS, MANAGE_ORDERS. */ - orderSettings: OrderSettings; + readonly orderSettings: OrderSettings; /** * Channel-specific payment settings. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_CHANNELS, HANDLE_PAYMENTS. */ - paymentSettings: PaymentSettings; - /** - * List of private metadata items. Requires staff permissions to access. - * - * Added in Saleor 3.15. - */ - privateMetadata: Array; + readonly paymentSettings: PaymentSettings; + /** List of private metadata items. Requires staff permissions to access. */ + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.15. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.15. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Slug of the channel. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; /** * Define the stock setting for this channel. * - * Added in Saleor 3.7. - * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - stockSettings: StockSettings; + readonly stockSettings: StockSettings; /** * Channel specific tax configuration. * @@ -3685,21 +3160,19 @@ export type Channel = Node & ObjectWithMetadata & { * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxConfiguration: TaxConfiguration; + readonly taxConfiguration: TaxConfiguration; /** * List of warehouses assigned to this channel. * - * Added in Saleor 3.5. - * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - warehouses: Array; + readonly warehouses: ReadonlyArray; }; /** Represents channel. */ export type ChannelAvailableShippingMethodsPerCountryArgs = { - countries?: InputMaybe>; + countries?: InputMaybe>; }; @@ -3711,7 +3184,7 @@ export type ChannelMetafieldArgs = { /** Represents channel. */ export type ChannelMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -3723,7 +3196,7 @@ export type ChannelPrivateMetafieldArgs = { /** Represents channel. */ export type ChannelPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** @@ -3735,12 +3208,11 @@ export type ChannelPrivateMetafieldsArgs = { * - CHANNEL_STATUS_CHANGED (async): A channel was activated. */ export type ChannelActivate = { - __typename?: 'ChannelActivate'; /** Activated channel. */ - channel?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - channelErrors: Array; - errors: Array; + readonly channel?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly channelErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -3752,95 +3224,61 @@ export type ChannelActivate = { * - CHANNEL_CREATED (async): A channel was created. */ export type ChannelCreate = { - __typename?: 'ChannelCreate'; - channel?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - channelErrors: Array; - errors: Array; + readonly channel?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly channelErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; export type ChannelCreateInput = { /** List of shipping zones to assign to the channel. */ - addShippingZones?: InputMaybe>; - /** - * List of warehouses to assign to the channel. - * - * Added in Saleor 3.5. - */ - addWarehouses?: InputMaybe>; - /** - * The channel checkout settings - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - checkoutSettings?: InputMaybe; + readonly addShippingZones?: InputMaybe>; + /** List of warehouses to assign to the channel. */ + readonly addWarehouses?: InputMaybe>; + /** The channel checkout settings */ + readonly checkoutSettings?: InputMaybe; /** Currency of the channel. */ - currencyCode: Scalars['String']; - /** - * Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. - * - * Added in Saleor 3.1. - */ - defaultCountry: CountryCode; + readonly currencyCode: Scalars['String']; + /** Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. */ + readonly defaultCountry: CountryCode; /** Determine if channel will be set active or not. */ - isActive?: InputMaybe; + readonly isActive?: InputMaybe; /** - * Channel public metadata. + * Channel public metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.15. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Name of the channel. */ - name: Scalars['String']; - /** - * The channel order settings - * - * Added in Saleor 3.12. - */ - orderSettings?: InputMaybe; - /** - * The channel payment settings - * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - paymentSettings?: InputMaybe; + readonly name: Scalars['String']; + /** The channel order settings */ + readonly orderSettings?: InputMaybe; + /** The channel payment settings */ + readonly paymentSettings?: InputMaybe; /** - * Channel private metadata. + * Channel private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.15. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** Slug of the channel. */ - slug: Scalars['String']; - /** - * The channel stock settings. - * - * Added in Saleor 3.7. - */ - stockSettings?: InputMaybe; + readonly slug: Scalars['String']; + /** The channel stock settings. */ + readonly stockSettings?: InputMaybe; }; -/** - * Event sent when new channel is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new channel is created. */ export type ChannelCreated = Event & { - __typename?: 'ChannelCreated'; /** The channel the event relates to. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -3852,12 +3290,11 @@ export type ChannelCreated = Event & { * - CHANNEL_STATUS_CHANGED (async): A channel was deactivated. */ export type ChannelDeactivate = { - __typename?: 'ChannelDeactivate'; /** Deactivated channel. */ - channel?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - channelErrors: Array; - errors: Array; + readonly channel?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly channelErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -3869,124 +3306,106 @@ export type ChannelDeactivate = { * - CHANNEL_DELETED (async): A channel was deleted. */ export type ChannelDelete = { - __typename?: 'ChannelDelete'; - channel?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - channelErrors: Array; - errors: Array; + readonly channel?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly channelErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; export type ChannelDeleteInput = { - /** ID of channel to migrate orders from origin channel. */ - channelId: Scalars['ID']; + /** ID of a channel to migrate orders from the origin channel. Target channel has to have the same currency as the origin. */ + readonly channelId: Scalars['ID']; }; -/** - * Event sent when channel is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when channel is deleted. */ export type ChannelDeleted = Event & { - __typename?: 'ChannelDeleted'; /** The channel the event relates to. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type ChannelError = { - __typename?: 'ChannelError'; /** The error code. */ - code: ChannelErrorCode; + readonly code: ChannelErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of shipping zone IDs which causes the error. */ - shippingZones?: Maybe>; + readonly shippingZones?: Maybe>; /** List of warehouses IDs which causes the error. */ - warehouses?: Maybe>; -}; - -/** An enumeration. */ -export type ChannelErrorCode = - | 'ALREADY_EXISTS' - | 'CHANNELS_CURRENCY_MUST_BE_THE_SAME' - | 'CHANNEL_WITH_ORDERS' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; + readonly warehouses?: Maybe>; +}; + +export enum ChannelErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + ChannelsCurrencyMustBeTheSame = 'CHANNELS_CURRENCY_MUST_BE_THE_SAME', + ChannelWithOrders = 'CHANNEL_WITH_ORDERS', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type ChannelListingUpdateInput = { /** ID of a channel listing. */ - channelListing: Scalars['ID']; + readonly channelListing: Scalars['ID']; /** Cost price of the variant in channel. */ - costPrice?: InputMaybe; + readonly costPrice?: InputMaybe; /** The threshold for preorder variant in channel. */ - preorderThreshold?: InputMaybe; + readonly preorderThreshold?: InputMaybe; /** Price of the particular variant in channel. */ - price?: InputMaybe; + readonly price?: InputMaybe; + /** Price of the variant before discount. */ + readonly priorPrice?: InputMaybe; }; -/** - * Event sent when channel metadata is updated. - * - * Added in Saleor 3.15. - */ +/** Event sent when channel metadata is updated. */ export type ChannelMetadataUpdated = Event & { - __typename?: 'ChannelMetadataUpdated'; /** The channel the event relates to. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Reorder the warehouses of a channel. * - * Added in Saleor 3.7. - * * Requires one of the following permissions: MANAGE_CHANNELS. */ export type ChannelReorderWarehouses = { - __typename?: 'ChannelReorderWarehouses'; /** Channel within the warehouses are reordered. */ - channel?: Maybe; - errors: Array; + readonly channel?: Maybe; + readonly errors: ReadonlyArray; }; -/** - * Event sent when channel status has changed. - * - * Added in Saleor 3.2. - */ +/** Event sent when channel status has changed. */ export type ChannelStatusChanged = Event & { - __typename?: 'ChannelStatusChanged'; /** The channel the event relates to. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -4002,245 +3421,179 @@ export type ChannelStatusChanged = Event & { * - CHANNEL_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. */ export type ChannelUpdate = { - __typename?: 'ChannelUpdate'; - channel?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - channelErrors: Array; - errors: Array; + readonly channel?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly channelErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; export type ChannelUpdateInput = { /** List of shipping zones to assign to the channel. */ - addShippingZones?: InputMaybe>; - /** - * List of warehouses to assign to the channel. - * - * Added in Saleor 3.5. - */ - addWarehouses?: InputMaybe>; - /** - * The channel checkout settings - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - checkoutSettings?: InputMaybe; - /** - * Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. - * - * Added in Saleor 3.1. - */ - defaultCountry?: InputMaybe; + readonly addShippingZones?: InputMaybe>; + /** List of warehouses to assign to the channel. */ + readonly addWarehouses?: InputMaybe>; + /** The channel checkout settings */ + readonly checkoutSettings?: InputMaybe; + /** Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. */ + readonly defaultCountry?: InputMaybe; /** Determine if channel will be set active or not. */ - isActive?: InputMaybe; + readonly isActive?: InputMaybe; /** - * Channel public metadata. + * Channel public metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.15. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Name of the channel. */ - name?: InputMaybe; + readonly name?: InputMaybe; + /** The channel order settings */ + readonly orderSettings?: InputMaybe; + /** The channel payment settings */ + readonly paymentSettings?: InputMaybe; /** - * The channel order settings + * Channel private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.12. + * Warning: never store sensitive information, including financial data such as credit card details. */ - orderSettings?: InputMaybe; - /** - * The channel payment settings - * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - paymentSettings?: InputMaybe; - /** - * Channel private metadata. - * - * Added in Saleor 3.15. - */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** List of shipping zones to unassign from the channel. */ - removeShippingZones?: InputMaybe>; - /** - * List of warehouses to unassign from the channel. - * - * Added in Saleor 3.5. - */ - removeWarehouses?: InputMaybe>; + readonly removeShippingZones?: InputMaybe>; + /** List of warehouses to unassign from the channel. */ + readonly removeWarehouses?: InputMaybe>; /** Slug of the channel. */ - slug?: InputMaybe; - /** - * The channel stock settings. - * - * Added in Saleor 3.7. - */ - stockSettings?: InputMaybe; + readonly slug?: InputMaybe; + /** The channel stock settings. */ + readonly stockSettings?: InputMaybe; }; -/** - * Event sent when channel is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when channel is updated. */ export type ChannelUpdated = Event & { - __typename?: 'ChannelUpdated'; /** The channel the event relates to. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Checkout object. */ export type Checkout = Node & ObjectWithMetadata & { - __typename?: 'Checkout'; /** * The authorize status of the checkout. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Triggers the following webhook events: * - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. */ - authorizeStatus: CheckoutAuthorizeStatusEnum; - /** - * Collection points that can be used for this order. - * - * Added in Saleor 3.1. - */ - availableCollectionPoints: Array; + readonly authorizeStatus: CheckoutAuthorizeStatusEnum; + /** Collection points that can be used for this order. */ + readonly availableCollectionPoints: ReadonlyArray; /** * List of available payment gateways. * * Triggers the following webhook events: * - PAYMENT_LIST_GATEWAYS (sync): Fetch payment gateways available for checkout. */ - availablePaymentGateways: Array; + readonly availablePaymentGateways: ReadonlyArray; /** * Shipping methods that can be used with this checkout. * * Triggers the following webhook events: * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. * - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. - * @deprecated This field will be removed in Saleor 4.0. Use `shippingMethods` instead. + * @deprecated Use `shippingMethods` instead. */ - availableShippingMethods: Array; + readonly availableShippingMethods: ReadonlyArray; /** The billing address of the checkout. */ - billingAddress?: Maybe
; + readonly billingAddress?: Maybe
; /** The channel for which checkout was created. */ - channel: Channel; + readonly channel: Channel; /** * The charge status of the checkout. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Triggers the following webhook events: * - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. */ - chargeStatus: CheckoutChargeStatusEnum; + readonly chargeStatus: CheckoutChargeStatusEnum; /** The date and time when the checkout was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** - * The delivery method selected for this checkout. + * The customer note for the checkout. * - * Added in Saleor 3.1. + * Added in Saleor 3.21. + */ + readonly customerNote: Scalars['String']; + /** + * The delivery method selected for this checkout. * * Triggers the following webhook events: * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. * - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. */ - deliveryMethod?: Maybe; + readonly deliveryMethod?: Maybe; /** The total discount applied to the checkout. Note: Only discount created via voucher are included in this field. */ - discount?: Maybe; + readonly discount?: Maybe; /** The name of voucher assigned to the checkout. */ - discountName?: Maybe; - /** - * Determines whether displayed prices should include taxes. - * - * Added in Saleor 3.9. - */ - displayGrossPrices: Scalars['Boolean']; + readonly discountName?: Maybe; + /** Determines whether displayed prices should include taxes. */ + readonly displayGrossPrices: Scalars['Boolean']; /** Email of a customer. */ - email?: Maybe; + readonly email?: Maybe; /** List of gift cards associated with this checkout. */ - giftCards: Array; + readonly giftCards: ReadonlyArray; /** The ID of the checkout. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Returns True, if checkout requires shipping. */ - isShippingRequired: Scalars['Boolean']; + readonly isShippingRequired: Scalars['Boolean']; /** Checkout language code. */ - languageCode: LanguageCodeEnum; - /** @deprecated This field will be removed in Saleor 4.0. Use `updatedAt` instead. */ - lastChange: Scalars['DateTime']; + readonly languageCode: LanguageCodeEnum; + /** @deprecated Use `updatedAt` instead. */ + readonly lastChange: Scalars['DateTime']; /** A list of checkout lines, each containing information about an item in the checkout. */ - lines: Array; + readonly lines: ReadonlyArray; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. + * The note for the checkout. + * @deprecated Use `customerNote` instead. */ - metafields?: Maybe; - /** The note for the checkout. */ - note: Scalars['String']; + readonly note: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; - /** - * List of problems with the checkout. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - problems?: Maybe>; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** List of problems with the checkout. */ + readonly problems?: Maybe>; /** The number of items purchased. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** The shipping address of the checkout. */ - shippingAddress?: Maybe
; + readonly shippingAddress?: Maybe
; /** * The shipping method related with checkout. * * Triggers the following webhook events: * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. * - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. - * @deprecated This field will be removed in Saleor 4.0. Use `deliveryMethod` instead. + * @deprecated Use `deliveryMethod` instead. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; /** * Shipping methods that can be used with this checkout. * @@ -4248,79 +3601,51 @@ export type Checkout = Node & ObjectWithMetadata & { * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. * - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. */ - shippingMethods: Array; + readonly shippingMethods: ReadonlyArray; /** * The price of the shipping, with all the taxes included. Set to 0 when no delivery method is selected. * * Triggers the following webhook events: * - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. */ - shippingPrice: TaxedMoney; - /** - * Date when oldest stock reservation for this checkout expires or null if no stock is reserved. - * - * Added in Saleor 3.1. - */ - stockReservationExpires?: Maybe; - /** - * List of user's stored payment methods that can be used in this checkout session. It uses the channel that the checkout was created in. When `amount` is not provided, `checkout.total` will be used as a default value. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - storedPaymentMethods?: Maybe>; + readonly shippingPrice: TaxedMoney; + /** Date when oldest stock reservation for this checkout expires or null if no stock is reserved. */ + readonly stockReservationExpires?: Maybe; + /** List of user's stored payment methods that can be used in this checkout session. It uses the channel that the checkout was created in. When `amount` is not provided, `checkout.total` will be used as a default value. */ + readonly storedPaymentMethods?: Maybe>; /** * The price of the checkout before shipping, with taxes included. * * Triggers the following webhook events: * - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. */ - subtotalPrice: TaxedMoney; - /** - * Returns True if checkout has to be exempt from taxes. - * - * Added in Saleor 3.8. - */ - taxExemption: Scalars['Boolean']; + readonly subtotalPrice: TaxedMoney; + /** Returns True if checkout has to be exempt from taxes. */ + readonly taxExemption: Scalars['Boolean']; /** The checkout's token. */ - token: Scalars['UUID']; + readonly token: Scalars['UUID']; /** * The difference between the paid and the checkout total amount. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Triggers the following webhook events: * - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. */ - totalBalance: Money; + readonly totalBalance: Money; /** * The sum of the checkout line prices, with all the taxes,shipping costs, and discounts included. * * Triggers the following webhook events: * - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. */ - totalPrice: TaxedMoney; - /** - * List of transactions for the checkout. Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS. - * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - transactions?: Maybe>; + readonly totalPrice: TaxedMoney; + /** List of transactions for the checkout. Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS. */ + readonly transactions?: Maybe>; /** Translation of the discountName field in the language set in Checkout.languageCode field.Note: this field is set automatically when Checkout.languageCode is defined; otherwise it's null */ - translatedDiscountName?: Maybe; - /** - * Time of last modification of the given checkout. - * - * Added in Saleor 3.13. - */ - updatedAt: Scalars['DateTime']; + readonly translatedDiscountName?: Maybe; + /** Time of last modification of the given checkout. */ + readonly updatedAt: Scalars['DateTime']; /** The user assigned to the checkout. Requires one of the following permissions: MANAGE_USERS, HANDLE_PAYMENTS, OWNER. */ - user?: Maybe; + readonly user?: Maybe; /** * The voucher assigned to the checkout. * @@ -4328,9 +3653,9 @@ export type Checkout = Node & ObjectWithMetadata & { * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - voucher?: Maybe; + readonly voucher?: Maybe; /** The code of voucher assigned to the checkout. */ - voucherCode?: Maybe; + readonly voucherCode?: Maybe; }; @@ -4342,7 +3667,7 @@ export type CheckoutMetafieldArgs = { /** Checkout object. */ export type CheckoutMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -4354,7 +3679,7 @@ export type CheckoutPrivateMetafieldArgs = { /** Checkout object. */ export type CheckoutPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -4370,21 +3695,20 @@ export type CheckoutStoredPaymentMethodsArgs = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutAddPromoCode = { - __typename?: 'CheckoutAddPromoCode'; /** The checkout with the added gift card or voucher. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; export type CheckoutAddressValidationRules = { /** Determines if an error should be raised when the provided address doesn't match the expected format. Example: using letters for postal code when the numbers are expected. */ - checkFieldsFormat?: InputMaybe; + readonly checkFieldsFormat?: InputMaybe; /** Determines if an error should be raised when the provided address doesn't have all the required fields. The list of required fields is dynamic and depends on the country code (use the `addressValidationRules` query to fetch them). Note: country code is mandatory for all addresses regardless of the rules provided in this input. */ - checkRequiredFields?: InputMaybe; + readonly checkRequiredFields?: InputMaybe; /** Determines if Saleor should apply normalization on address fields. Example: converting city field to uppercase letters. */ - enableFieldsNormalization?: InputMaybe; + readonly enableFieldsNormalization?: InputMaybe; }; /** @@ -4401,10 +3725,11 @@ export type CheckoutAddressValidationRules = { * PARTIAL - the cover funds don't cover fully the checkout's total * FULL - the cover funds covers the checkout's total */ -export type CheckoutAuthorizeStatusEnum = - | 'FULL' - | 'NONE' - | 'PARTIAL'; +export enum CheckoutAuthorizeStatusEnum { + Full = 'FULL', + None = 'NONE', + Partial = 'PARTIAL' +} /** * Update billing address in the existing checkout. @@ -4413,12 +3738,11 @@ export type CheckoutAuthorizeStatusEnum = * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutBillingAddressUpdate = { - __typename?: 'CheckoutBillingAddressUpdate'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -4437,11 +3761,12 @@ export type CheckoutBillingAddressUpdate = { * FULL - the funds that are charged fully cover the checkout's total * OVERCHARGED - the charged funds are bigger than checkout's total */ -export type CheckoutChargeStatusEnum = - | 'FULL' - | 'NONE' - | 'OVERCHARGED' - | 'PARTIAL'; +export enum CheckoutChargeStatusEnum { + Full = 'FULL', + None = 'NONE', + Overcharged = 'OVERCHARGED', + Partial = 'PARTIAL' +} /** * Completes the checkout. As a result a new order is created. The mutation allows to create the unpaid order when setting `orderSettings.allowUnpaidOrders` for given `Channel` is set to `true`. When `orderSettings.allowUnpaidOrders` is set to `false`, checkout can be completed only when attached `Payment`/`TransactionItem`s fully cover the checkout's total. When processing the checkout with `Payment`, in case of required additional confirmation step like 3D secure, the `confirmationNeeded` flag will be set to True and no order will be created until payment is confirmed with second call of this mutation. @@ -4459,33 +3784,30 @@ export type CheckoutChargeStatusEnum = * - ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. */ export type CheckoutComplete = { - __typename?: 'CheckoutComplete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; /** Confirmation data used to process additional authorization steps. */ - confirmationData?: Maybe; + readonly confirmationData?: Maybe; /** Set to true if payment needs to be confirmed before checkout is complete. */ - confirmationNeeded: Scalars['Boolean']; - errors: Array; + readonly confirmationNeeded: Scalars['Boolean']; + readonly errors: ReadonlyArray; /** Placed order. */ - order?: Maybe; + readonly order?: Maybe; }; export type CheckoutCountableConnection = { - __typename?: 'CheckoutCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type CheckoutCountableEdge = { - __typename?: 'CheckoutCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Checkout; + readonly node: Checkout; }; /** @@ -4497,111 +3819,122 @@ export type CheckoutCountableEdge = { * - CHECKOUT_CREATED (async): A checkout was created. */ export type CheckoutCreate = { - __typename?: 'CheckoutCreate'; - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; /** * Whether the checkout was created or the current active one was returned. Refer to checkoutLinesAdd and checkoutLinesUpdate to merge a cart with an active checkout. - * @deprecated This field will be removed in Saleor 4.0. Always returns `true`. + * @deprecated Always returns `true`. */ - created?: Maybe; - errors: Array; + readonly created?: Maybe; + readonly errors: ReadonlyArray; }; -/** - * Create new checkout from existing order. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Create new checkout from existing order. */ export type CheckoutCreateFromOrder = { - __typename?: 'CheckoutCreateFromOrder'; /** Created checkout. */ - checkout?: Maybe; - errors: Array; + readonly checkout?: Maybe; + readonly errors: ReadonlyArray; /** Variants that were not attached to the checkout. */ - unavailableVariants?: Maybe>; + readonly unavailableVariants?: Maybe>; }; export type CheckoutCreateFromOrderError = { - __typename?: 'CheckoutCreateFromOrderError'; /** The error code. */ - code: CheckoutCreateFromOrderErrorCode; + readonly code: CheckoutCreateFromOrderErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type CheckoutCreateFromOrderErrorCode = - | 'CHANNEL_INACTIVE' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'ORDER_NOT_FOUND' - | 'TAX_ERROR'; +export enum CheckoutCreateFromOrderErrorCode { + ChannelInactive = 'CHANNEL_INACTIVE', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + OrderNotFound = 'ORDER_NOT_FOUND', + TaxError = 'TAX_ERROR' +} export type CheckoutCreateFromOrderUnavailableVariant = { - __typename?: 'CheckoutCreateFromOrderUnavailableVariant'; /** The error code. */ - code: CheckoutCreateFromOrderUnavailableVariantErrorCode; + readonly code: CheckoutCreateFromOrderUnavailableVariantErrorCode; /** Order line ID that is unavailable. */ - lineId: Scalars['ID']; + readonly lineId: Scalars['ID']; /** The error message. */ - message: Scalars['String']; + readonly message: Scalars['String']; /** Variant ID that is unavailable. */ - variantId: Scalars['ID']; + readonly variantId: Scalars['ID']; }; -/** An enumeration. */ -export type CheckoutCreateFromOrderUnavailableVariantErrorCode = - | 'INSUFFICIENT_STOCK' - | 'NOT_FOUND' - | 'PRODUCT_NOT_PUBLISHED' - | 'PRODUCT_UNAVAILABLE_FOR_PURCHASE' - | 'QUANTITY_GREATER_THAN_LIMIT' - | 'UNAVAILABLE_VARIANT_IN_CHANNEL'; +export enum CheckoutCreateFromOrderUnavailableVariantErrorCode { + InsufficientStock = 'INSUFFICIENT_STOCK', + NotFound = 'NOT_FOUND', + ProductNotPublished = 'PRODUCT_NOT_PUBLISHED', + ProductUnavailableForPurchase = 'PRODUCT_UNAVAILABLE_FOR_PURCHASE', + QuantityGreaterThanLimit = 'QUANTITY_GREATER_THAN_LIMIT', + UnavailableVariantInChannel = 'UNAVAILABLE_VARIANT_IN_CHANNEL' +} export type CheckoutCreateInput = { /** Billing address of the customer. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. */ - billingAddress?: InputMaybe; + readonly billingAddress?: InputMaybe; /** Slug of a channel in which to create a checkout. */ - channel?: InputMaybe; + readonly channel?: InputMaybe; /** The customer's email address. */ - email?: InputMaybe; + readonly email?: InputMaybe; /** Checkout language code. */ - languageCode?: InputMaybe; + readonly languageCode?: InputMaybe; /** A list of checkout lines, each containing information about an item in the checkout. */ - lines: Array; - /** The mailing address to where the checkout will be shipped. Note: the address will be ignored if the checkout doesn't contain shippable items. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. */ - shippingAddress?: InputMaybe; + readonly lines: ReadonlyArray; + /** + * Checkout public metadata. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + * + * Added in Saleor 3.21. + */ + readonly metadata?: InputMaybe>; + /** + * Checkout private metadata. Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_CHECKOUTS + * + * Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + * + * Added in Saleor 3.21. + */ + readonly privateMetadata?: InputMaybe>; /** - * The checkout validation rules that can be changed. + * Indicates whether the billing address should be saved to the user’s address book upon checkout completion. Can only be set when a billing address is provided. If not specified along with the address, the default behavior is to save the address. * - * Added in Saleor 3.5. + * Added in Saleor 3.21. */ - validationRules?: InputMaybe; + readonly saveBillingAddress?: InputMaybe; + /** + * Indicates whether the shipping address should be saved to the user’s address book upon checkout completion.Can only be set when a shipping address is provided. If not specified along with the address, the default behavior is to save the address. + * + * Added in Saleor 3.21. + */ + readonly saveShippingAddress?: InputMaybe; + /** The mailing address to where the checkout will be shipped. Note: the address will be ignored if the checkout doesn't contain shippable items. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. */ + readonly shippingAddress?: InputMaybe; + /** The checkout validation rules that can be changed. */ + readonly validationRules?: InputMaybe; }; -/** - * Event sent when new checkout is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new checkout is created. */ export type CheckoutCreated = Event & { - __typename?: 'CheckoutCreated'; /** The checkout the event relates to. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -4613,12 +3946,11 @@ export type CheckoutCreated = Event & { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutCustomerAttach = { - __typename?: 'CheckoutCustomerAttach'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -4630,28 +3962,40 @@ export type CheckoutCustomerAttach = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutCustomerDetach = { - __typename?: 'CheckoutCustomerDetach'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** - * Updates the delivery method (shipping method or pick up point) of the checkout. Updates the checkout shipping_address for click and collect delivery for a warehouse address. + * Updates customer note in the existing checkout object. * - * Added in Saleor 3.1. + * Added in Saleor 3.21. + * + * Triggers the following webhook events: + * - CHECKOUT_UPDATED (async): A checkout was updated. + */ +export type CheckoutCustomerNoteUpdate = { + /** An updated checkout. */ + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; +}; + +/** + * Updates the delivery method (shipping method or pick up point) of the checkout. Updates the checkout shipping_address for click and collect delivery for a warehouse address. * * Triggers the following webhook events: * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout delivery method with the external one. * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutDeliveryMethodUpdate = { - __typename?: 'CheckoutDeliveryMethodUpdate'; /** An updated checkout. */ - checkout?: Maybe; - errors: Array; + readonly checkout?: Maybe; + readonly errors: ReadonlyArray; }; /** @@ -4661,119 +4005,102 @@ export type CheckoutDeliveryMethodUpdate = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutEmailUpdate = { - __typename?: 'CheckoutEmailUpdate'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; export type CheckoutError = { - __typename?: 'CheckoutError'; /** A type of address that causes the error. */ - addressType?: Maybe; + readonly addressType?: Maybe; /** The error code. */ - code: CheckoutErrorCode; + readonly code: CheckoutErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** List of line Ids which cause the error. */ - lines?: Maybe>; + readonly lines?: Maybe>; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of variant IDs which causes the error. */ - variants?: Maybe>; -}; - -/** An enumeration. */ -export type CheckoutErrorCode = - | 'BILLING_ADDRESS_NOT_SET' - | 'CHANNEL_INACTIVE' - | 'CHECKOUT_NOT_FULLY_PAID' - | 'DELIVERY_METHOD_NOT_APPLICABLE' - | 'EMAIL_NOT_SET' - | 'GIFT_CARD_NOT_APPLICABLE' - | 'GRAPHQL_ERROR' - | 'INACTIVE_PAYMENT' - | 'INSUFFICIENT_STOCK' - | 'INVALID' - | 'INVALID_SHIPPING_METHOD' - | 'MISSING_CHANNEL_SLUG' - | 'NON_EDITABLE_GIFT_LINE' - | 'NON_REMOVABLE_GIFT_LINE' - | 'NOT_FOUND' - | 'NO_LINES' - | 'PAYMENT_ERROR' - | 'PRODUCT_NOT_PUBLISHED' - | 'PRODUCT_UNAVAILABLE_FOR_PURCHASE' - | 'QUANTITY_GREATER_THAN_LIMIT' - | 'REQUIRED' - | 'SHIPPING_ADDRESS_NOT_SET' - | 'SHIPPING_CHANGE_FORBIDDEN' - | 'SHIPPING_METHOD_NOT_APPLICABLE' - | 'SHIPPING_METHOD_NOT_SET' - | 'SHIPPING_NOT_REQUIRED' - | 'TAX_ERROR' - | 'UNAVAILABLE_VARIANT_IN_CHANNEL' - | 'UNIQUE' - | 'VOUCHER_NOT_APPLICABLE' - | 'ZERO_QUANTITY'; + readonly variants?: Maybe>; +}; + +export enum CheckoutErrorCode { + BillingAddressNotSet = 'BILLING_ADDRESS_NOT_SET', + ChannelInactive = 'CHANNEL_INACTIVE', + CheckoutNotFullyPaid = 'CHECKOUT_NOT_FULLY_PAID', + DeliveryMethodNotApplicable = 'DELIVERY_METHOD_NOT_APPLICABLE', + EmailNotSet = 'EMAIL_NOT_SET', + GiftCardNotApplicable = 'GIFT_CARD_NOT_APPLICABLE', + GraphqlError = 'GRAPHQL_ERROR', + InactivePayment = 'INACTIVE_PAYMENT', + InsufficientStock = 'INSUFFICIENT_STOCK', + Invalid = 'INVALID', + InvalidShippingMethod = 'INVALID_SHIPPING_METHOD', + MissingAddressData = 'MISSING_ADDRESS_DATA', + MissingChannelSlug = 'MISSING_CHANNEL_SLUG', + NonEditableGiftLine = 'NON_EDITABLE_GIFT_LINE', + NonRemovableGiftLine = 'NON_REMOVABLE_GIFT_LINE', + NotFound = 'NOT_FOUND', + NoLines = 'NO_LINES', + PaymentError = 'PAYMENT_ERROR', + ProductNotPublished = 'PRODUCT_NOT_PUBLISHED', + ProductUnavailableForPurchase = 'PRODUCT_UNAVAILABLE_FOR_PURCHASE', + QuantityGreaterThanLimit = 'QUANTITY_GREATER_THAN_LIMIT', + Required = 'REQUIRED', + ShippingAddressNotSet = 'SHIPPING_ADDRESS_NOT_SET', + ShippingChangeForbidden = 'SHIPPING_CHANGE_FORBIDDEN', + ShippingMethodNotApplicable = 'SHIPPING_METHOD_NOT_APPLICABLE', + ShippingMethodNotSet = 'SHIPPING_METHOD_NOT_SET', + ShippingNotRequired = 'SHIPPING_NOT_REQUIRED', + TaxError = 'TAX_ERROR', + UnavailableVariantInChannel = 'UNAVAILABLE_VARIANT_IN_CHANNEL', + Unique = 'UNIQUE', + VoucherNotApplicable = 'VOUCHER_NOT_APPLICABLE', + ZeroQuantity = 'ZERO_QUANTITY' +} export type CheckoutFilterInput = { - authorizeStatus?: InputMaybe>; - channels?: InputMaybe>; - chargeStatus?: InputMaybe>; - created?: InputMaybe; - customer?: InputMaybe; - metadata?: InputMaybe>; - search?: InputMaybe; - updatedAt?: InputMaybe; + readonly authorizeStatus?: InputMaybe>; + readonly channels?: InputMaybe>; + readonly chargeStatus?: InputMaybe>; + readonly created?: InputMaybe; + readonly customer?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; + readonly updatedAt?: InputMaybe; }; -/** - * Filter shipping methods for checkout. - * - * Added in Saleor 3.6. - */ +/** Filter shipping methods for checkout. */ export type CheckoutFilterShippingMethods = Event & { - __typename?: 'CheckoutFilterShippingMethods'; /** The checkout the event relates to. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; - /** - * Shipping methods that can be used with this checkout. - * - * Added in Saleor 3.6. - */ - shippingMethods?: Maybe>; + readonly recipient?: Maybe; + /** Shipping methods that can be used with this checkout. */ + readonly shippingMethods?: Maybe>; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when checkout is fully paid with transactions. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when checkout is fully paid with transactions. The checkout is considered as fully paid when the checkout `charge_status` is `FULL` or `OVERCHARGED`. The event is not sent when the checkout authorization flow strategy is used. */ export type CheckoutFullyPaid = Event & { - __typename?: 'CheckoutFullyPaid'; /** The checkout the event relates to. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -4783,19 +4110,17 @@ export type CheckoutFullyPaid = Event & { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutLanguageCodeUpdate = { - __typename?: 'CheckoutLanguageCodeUpdate'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** Represents an item in the checkout. */ export type CheckoutLine = Node & ObjectWithMetadata & { - __typename?: 'CheckoutLine'; /** The ID of the checkout line. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Determine if the line is a gift. * @@ -4803,79 +4128,65 @@ export type CheckoutLine = Node & ObjectWithMetadata & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - isGift?: Maybe; - /** - * List of public metadata items. Can be accessed without permissions. - * - * Added in Saleor 3.5. - */ - metadata: Array; + readonly isGift?: Maybe; + /** List of public metadata items. Can be accessed without permissions. */ + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.5. */ - metafield?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. + * The sum of the checkout line price prior to promotion. * - * Added in Saleor 3.5. + * Added in Saleor 3.21. */ - metafields?: Maybe; + readonly priorTotalPrice?: Maybe; /** - * List of private metadata items. Requires staff permissions to access. + * The unit price of the checkout line prior to promotion. * - * Added in Saleor 3.5. + * Added in Saleor 3.21. */ - privateMetadata: Array; + readonly priorUnitPrice?: Maybe; + /** List of private metadata items. Requires staff permissions to access. */ + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.5. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.5. - */ - privateMetafields?: Maybe; - /** - * List of problems with the checkout line. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - problems?: Maybe>; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** List of problems with the checkout line. */ + readonly problems?: Maybe>; /** The quantity of product variant assigned to the checkout line. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Indicates whether the item need to be delivered. */ - requiresShipping: Scalars['Boolean']; + readonly requiresShipping: Scalars['Boolean']; /** * The sum of the checkout line price, taxes and discounts. * * Triggers the following webhook events: * - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. */ - totalPrice: TaxedMoney; + readonly totalPrice: TaxedMoney; /** The sum of the checkout line price, without discounts. */ - undiscountedTotalPrice: Money; + readonly undiscountedTotalPrice: Money; /** The unit price of the checkout line, without discounts. */ - undiscountedUnitPrice: Money; + readonly undiscountedUnitPrice: Money; /** * The unit price of the checkout line, with taxes and discounts. * * Triggers the following webhook events: * - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. */ - unitPrice: TaxedMoney; + readonly unitPrice: TaxedMoney; /** The product variant from which the checkout line was created. */ - variant: ProductVariant; + readonly variant: ProductVariant; }; @@ -4887,7 +4198,7 @@ export type CheckoutLineMetafieldArgs = { /** Represents an item in the checkout. */ export type CheckoutLineMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -4899,24 +4210,22 @@ export type CheckoutLinePrivateMetafieldArgs = { /** Represents an item in the checkout. */ export type CheckoutLinePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; export type CheckoutLineCountableConnection = { - __typename?: 'CheckoutLineCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type CheckoutLineCountableEdge = { - __typename?: 'CheckoutLineCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: CheckoutLine; + readonly node: CheckoutLine; }; /** @@ -4926,99 +4235,69 @@ export type CheckoutLineCountableEdge = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutLineDelete = { - __typename?: 'CheckoutLineDelete'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; export type CheckoutLineInput = { + /** Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. */ + readonly forceNewLine?: InputMaybe; /** - * Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. + * Fields required to update the object's metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.6. + * Warning: never store sensitive information, including financial data such as credit card details. */ - forceNewLine?: InputMaybe; - /** - * Fields required to update the object's metadata. - * - * Added in Saleor 3.8. - */ - metadata?: InputMaybe>; - /** - * Custom price of the item. Can be set only by apps with `HANDLE_CHECKOUTS` permission. When the line with the same variant will be provided multiple times, the last price will be used. - * - * Added in Saleor 3.1. - */ - price?: InputMaybe; + readonly metadata?: InputMaybe>; + /** Custom price of the item. Can be set only by apps with `HANDLE_CHECKOUTS` permission. When the line with the same variant will be provided multiple times, the last price will be used. */ + readonly price?: InputMaybe; /** The number of items purchased. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** ID of the product variant. */ - variantId: Scalars['ID']; + readonly variantId: Scalars['ID']; }; -/** - * Represents an problem in the checkout line. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents an problem in the checkout line. */ export type CheckoutLineProblem = CheckoutLineProblemInsufficientStock | CheckoutLineProblemVariantNotAvailable; -/** - * Indicates insufficient stock for a given checkout line.Placing the order will not be possible until solving this problem. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Indicates insufficient stock for a given checkout line.Placing the order will not be possible until solving this problem. */ export type CheckoutLineProblemInsufficientStock = { - __typename?: 'CheckoutLineProblemInsufficientStock'; /** Available quantity of a variant. */ - availableQuantity?: Maybe; + readonly availableQuantity?: Maybe; /** The line that has variant with insufficient stock. */ - line: CheckoutLine; + readonly line: CheckoutLine; /** The variant with insufficient stock. */ - variant: ProductVariant; + readonly variant: ProductVariant; }; -/** - * The variant assigned to the checkout line is not available.Placing the order will not be possible until solving this problem. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** The variant assigned to the checkout line is not available.Placing the order will not be possible until solving this problem. */ export type CheckoutLineProblemVariantNotAvailable = { - __typename?: 'CheckoutLineProblemVariantNotAvailable'; /** The line that has variant that is not available. */ - line: CheckoutLine; + readonly line: CheckoutLine; }; export type CheckoutLineUpdateInput = { + /** ID of the line. */ + readonly lineId?: InputMaybe; /** - * ID of the line. + * Checkout line public metadata. Will add and update keys. To delete keys use deleteMetadata mutation. * - * Added in Saleor 3.6. - */ - lineId?: InputMaybe; - /** - * Custom price of the item. Can be set only by apps with `HANDLE_CHECKOUTS` permission. When the line with the same variant will be provided multiple times, the last price will be used. + * Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.1. + * Warning: never store sensitive information, including financial data such as credit card details. */ - price?: InputMaybe; + readonly metadata?: InputMaybe>; + /** Custom price of the item. Can be set only by apps with `HANDLE_CHECKOUTS` permission. When the line with the same variant will be provided multiple times, the last price will be used. */ + readonly price?: InputMaybe; /** The number of items purchased. Optional for apps, required for any other users. */ - quantity?: InputMaybe; + readonly quantity?: InputMaybe; /** * ID of the product variant. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `lineId` instead. + * @deprecated Use `lineId` instead. */ - variantId?: InputMaybe; + readonly variantId?: InputMaybe; }; /** @@ -5028,12 +4307,11 @@ export type CheckoutLineUpdateInput = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutLinesAdd = { - __typename?: 'CheckoutLinesAdd'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -5043,10 +4321,9 @@ export type CheckoutLinesAdd = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutLinesDelete = { - __typename?: 'CheckoutLinesDelete'; /** An updated checkout. */ - checkout?: Maybe; - errors: Array; + readonly checkout?: Maybe; + readonly errors: ReadonlyArray; }; /** @@ -5056,52 +4333,39 @@ export type CheckoutLinesDelete = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutLinesUpdate = { - __typename?: 'CheckoutLinesUpdate'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** - * Event sent when checkout metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when checkout metadata is updated. */ export type CheckoutMetadataUpdated = Event & { - __typename?: 'CheckoutMetadataUpdated'; /** The checkout the event relates to. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Create a new payment for given checkout. */ export type CheckoutPaymentCreate = { - __typename?: 'CheckoutPaymentCreate'; /** Related checkout object. */ - checkout?: Maybe; - errors: Array; + readonly checkout?: Maybe; + readonly errors: ReadonlyArray; /** A newly created payment. */ - payment?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - paymentErrors: Array; + readonly payment?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly paymentErrors: ReadonlyArray; }; -/** - * Represents an problem in the checkout. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents an problem in the checkout. */ export type CheckoutProblem = CheckoutLineProblemInsufficientStock | CheckoutLineProblemVariantNotAvailable; /** @@ -5111,40 +4375,37 @@ export type CheckoutProblem = CheckoutLineProblemInsufficientStock | CheckoutLin * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutRemovePromoCode = { - __typename?: 'CheckoutRemovePromoCode'; /** The checkout with the removed gift card or voucher. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** - * Represents the channel-specific checkout settings. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the channel-specific checkout settings. */ export type CheckoutSettings = { - __typename?: 'CheckoutSettings'; /** - * Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. + * Default `false`. Determines if the paid checkouts should be automatically completed. This setting applies only to checkouts where payment was processed through transactions.When enabled, the checkout will be automatically completed once the checkout `charge_status` reaches `FULL`. This occurs when the total sum of charged and authorized transaction amounts equals or exceeds the checkout's total amount. * - * Added in Saleor 3.15.This field will be removed in Saleor 4.0. + * Added in Saleor 3.20. */ - useLegacyErrorFlow: Scalars['Boolean']; + readonly automaticallyCompleteFullyPaidCheckouts: Scalars['Boolean']; + /** Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. */ + readonly useLegacyErrorFlow: Scalars['Boolean']; }; export type CheckoutSettingsInput = { /** - * Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. - * - * Added in Saleor 3.15. + * Default `false`. Determines if the paid checkouts should be automatically completed. This setting applies only to checkouts where payment was processed through transactions.When enabled, the checkout will be automatically completed once the checkout `charge_status` reaches `FULL`. This occurs when the total sum of charged and authorized transaction amounts equals or exceeds the checkout's total amount. * - * DEPRECATED: this field will be removed in Saleor 4.0. + * Added in Saleor 3.20. + */ + readonly automaticallyCompleteFullyPaidCheckouts?: InputMaybe; + /** + * Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. + * @deprecated Field no longer supported */ - useLegacyErrorFlow?: InputMaybe; + readonly useLegacyErrorFlow?: InputMaybe; }; /** @@ -5154,12 +4415,11 @@ export type CheckoutSettingsInput = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutShippingAddressUpdate = { - __typename?: 'CheckoutShippingAddressUpdate'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -5170,135 +4430,126 @@ export type CheckoutShippingAddressUpdate = { * - CHECKOUT_UPDATED (async): A checkout was updated. */ export type CheckoutShippingMethodUpdate = { - __typename?: 'CheckoutShippingMethodUpdate'; /** An updated checkout. */ - checkout?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - checkoutErrors: Array; - errors: Array; + readonly checkout?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly checkoutErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -export type CheckoutSortField = +export enum CheckoutSortField { /** Sort checkouts by creation date. */ - | 'CREATION_DATE' + CreationDate = 'CREATION_DATE', /** Sort checkouts by customer. */ - | 'CUSTOMER' + Customer = 'CUSTOMER', /** Sort checkouts by payment. */ - | 'PAYMENT'; + Payment = 'PAYMENT' +} export type CheckoutSortingInput = { /** Specifies the direction in which to sort checkouts. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort checkouts by the selected field. */ - field: CheckoutSortField; + readonly field: CheckoutSortField; }; -/** - * Event sent when checkout is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when checkout is updated. */ export type CheckoutUpdated = Event & { - __typename?: 'CheckoutUpdated'; /** The checkout the event relates to. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type CheckoutValidationRules = { /** The validation rules that can be applied to provided billing address data. */ - billingAddress?: InputMaybe; + readonly billingAddress?: InputMaybe; /** The validation rules that can be applied to provided shipping address data. */ - shippingAddress?: InputMaybe; + readonly shippingAddress?: InputMaybe; }; export type ChoiceValue = { - __typename?: 'ChoiceValue'; /** The raw name of the choice. */ - raw?: Maybe; + readonly raw?: Maybe; /** The verbose name of the choice. */ - verbose?: Maybe; + readonly verbose?: Maybe; }; +/** Enum determining the state of a circuit breaker. */ +export enum CircuitBreakerStateEnum { + /** The breaker is conducting (requests are passing through). */ + Closed = 'CLOSED', + /** The breaker is in a trial period (to close or open). Note that unlike classic breaker patterns, this is not a state where we are throttling the number of requests, it's a state similar to CLOSED but with different thresholds. */ + HalfOpen = 'HALF_OPEN', + /** The breaker is tripped (no requests are passing). Breaker will enter half-open state after cooldown period. */ + Open = 'OPEN' +} + /** Represents a collection of products. */ export type Collection = Node & ObjectWithMetadata & { - __typename?: 'Collection'; /** Background image of the collection. */ - backgroundImage?: Maybe; + readonly backgroundImage?: Maybe; /** Channel given to retrieve this collection. Also used by federation gateway to resolve this object in a federated query. */ - channel?: Maybe; + readonly channel?: Maybe; /** * List of channels in which the collection is available. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - channelListings?: Maybe>; + readonly channelListings?: Maybe>; /** * Description of the collection. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Description of the collection. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. + * @deprecated Use the `description` field instead. */ - descriptionJson?: Maybe; + readonly descriptionJson?: Maybe; /** The ID of the collection. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Name of the collection. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** List of products in this collection. */ - products?: Maybe; + readonly products?: Maybe; /** SEO description of the collection. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** SEO title of the collection. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; /** Slug of the collection. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; /** Returns translated collection fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -5317,7 +4568,7 @@ export type CollectionMetafieldArgs = { /** Represents a collection of products. */ export type CollectionMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -5329,7 +4580,7 @@ export type CollectionPrivateMetafieldArgs = { /** Represents a collection of products. */ export type CollectionPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -5356,12 +4607,11 @@ export type CollectionTranslationArgs = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CollectionAddProducts = { - __typename?: 'CollectionAddProducts'; /** Collection to which products will be added. */ - collection?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - collectionErrors: Array; - errors: Array; + readonly collection?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly collectionErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -5370,47 +4620,40 @@ export type CollectionAddProducts = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CollectionBulkDelete = { - __typename?: 'CollectionBulkDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - collectionErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly collectionErrors: ReadonlyArray; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; /** Represents collection channel listing. */ export type CollectionChannelListing = Node & { - __typename?: 'CollectionChannelListing'; /** The channel to which the collection belongs. */ - channel: Channel; + readonly channel: Channel; /** The ID of the collection channel listing. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Indicates if the collection is published in the channel. */ - isPublished: Scalars['Boolean']; - /** @deprecated This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date. */ - publicationDate?: Maybe; - /** - * The collection publication date. - * - * Added in Saleor 3.3. - */ - publishedAt?: Maybe; + readonly isPublished: Scalars['Boolean']; + /** @deprecated Use the `publishedAt` field to fetch the publication date. */ + readonly publicationDate?: Maybe; + /** The collection publication date. */ + readonly publishedAt?: Maybe; }; export type CollectionChannelListingError = { - __typename?: 'CollectionChannelListingError'; /** List of attributes IDs which causes the error. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** List of channels IDs which causes the error. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** The error code. */ - code: ProductErrorCode; + readonly code: ProductErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of attribute values IDs which causes the error. */ - values?: Maybe>; + readonly values?: Maybe>; }; /** @@ -5419,37 +4662,34 @@ export type CollectionChannelListingError = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CollectionChannelListingUpdate = { - __typename?: 'CollectionChannelListingUpdate'; /** An updated collection instance. */ - collection?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - collectionChannelListingErrors: Array; - errors: Array; + readonly collection?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly collectionChannelListingErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; export type CollectionChannelListingUpdateInput = { /** List of channels to which the collection should be assigned. */ - addChannels?: InputMaybe>; + readonly addChannels?: InputMaybe>; /** List of channels from which the collection should be unassigned. */ - removeChannels?: InputMaybe>; + readonly removeChannels?: InputMaybe>; }; /** Represents a connection to a list of collections. */ export type CollectionCountableConnection = { - __typename?: 'CollectionCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type CollectionCountableEdge = { - __typename?: 'CollectionCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Collection; + readonly node: Collection; }; /** @@ -5458,79 +4698,68 @@ export type CollectionCountableEdge = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CollectionCreate = { - __typename?: 'CollectionCreate'; - collection?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - collectionErrors: Array; - errors: Array; + readonly collection?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly collectionErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; export type CollectionCreateInput = { /** Background image file. */ - backgroundImage?: InputMaybe; + readonly backgroundImage?: InputMaybe; /** Alt text for an image. */ - backgroundImageAlt?: InputMaybe; + readonly backgroundImageAlt?: InputMaybe; /** * Description of the collection. * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; + readonly description?: InputMaybe; /** Informs whether a collection is published. */ - isPublished?: InputMaybe; + readonly isPublished?: InputMaybe; /** - * Fields required to update the collection metadata. + * Fields required to update the collection metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Name of the collection. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** - * Fields required to update the collection private metadata. + * Fields required to update the collection private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** List of products to be added to the collection. */ - products?: InputMaybe>; + readonly products?: InputMaybe>; /** * Publication date. ISO 8601 standard. - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - publicationDate?: InputMaybe; + readonly publicationDate?: InputMaybe; /** Search engine optimization fields. */ - seo?: InputMaybe; + readonly seo?: InputMaybe; /** Slug of the collection. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; -/** - * Event sent when new collection is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new collection is created. */ export type CollectionCreated = Event & { - __typename?: 'CollectionCreated'; /** The collection the event relates to. */ - collection?: Maybe; + readonly collection?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when new collection is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new collection is created. */ export type CollectionCreatedCollectionArgs = { channel?: InputMaybe; }; @@ -5541,149 +4770,128 @@ export type CollectionCreatedCollectionArgs = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CollectionDelete = { - __typename?: 'CollectionDelete'; - collection?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - collectionErrors: Array; - errors: Array; + readonly collection?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly collectionErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** - * Event sent when collection is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when collection is deleted. */ export type CollectionDeleted = Event & { - __typename?: 'CollectionDeleted'; /** The collection the event relates to. */ - collection?: Maybe; + readonly collection?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when collection is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when collection is deleted. */ export type CollectionDeletedCollectionArgs = { channel?: InputMaybe; }; export type CollectionError = { - __typename?: 'CollectionError'; /** The error code. */ - code: CollectionErrorCode; + readonly code: CollectionErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of products IDs which causes the error. */ - products?: Maybe>; + readonly products?: Maybe>; }; -/** An enumeration. */ -export type CollectionErrorCode = - | 'CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; +export enum CollectionErrorCode { + CannotManageProductWithoutVariant = 'CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type CollectionFilterInput = { /** * Specifies the channel by which the data should be filtered. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. + * @deprecated Use root-level channel argument instead. */ - channel?: InputMaybe; - ids?: InputMaybe>; - metadata?: InputMaybe>; - published?: InputMaybe; - search?: InputMaybe; - slugs?: InputMaybe>; + readonly channel?: InputMaybe; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; + readonly published?: InputMaybe; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; }; export type CollectionInput = { /** Background image file. */ - backgroundImage?: InputMaybe; + readonly backgroundImage?: InputMaybe; /** Alt text for an image. */ - backgroundImageAlt?: InputMaybe; + readonly backgroundImageAlt?: InputMaybe; /** * Description of the collection. * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; + readonly description?: InputMaybe; /** Informs whether a collection is published. */ - isPublished?: InputMaybe; + readonly isPublished?: InputMaybe; /** - * Fields required to update the collection metadata. + * Fields required to update the collection metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Name of the collection. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** - * Fields required to update the collection private metadata. + * Fields required to update the collection private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** * Publication date. ISO 8601 standard. - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - publicationDate?: InputMaybe; + readonly publicationDate?: InputMaybe; /** Search engine optimization fields. */ - seo?: InputMaybe; + readonly seo?: InputMaybe; /** Slug of the collection. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; -/** - * Event sent when collection metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when collection metadata is updated. */ export type CollectionMetadataUpdated = Event & { - __typename?: 'CollectionMetadataUpdated'; /** The collection the event relates to. */ - collection?: Maybe; + readonly collection?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when collection metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when collection metadata is updated. */ export type CollectionMetadataUpdatedCollectionArgs = { channel?: InputMaybe; }; -export type CollectionPublished = - | 'HIDDEN' - | 'PUBLISHED'; +export enum CollectionPublished { + Hidden = 'HIDDEN', + Published = 'PUBLISHED' +} /** * Remove products from a collection. @@ -5691,12 +4899,11 @@ export type CollectionPublished = * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CollectionRemoveProducts = { - __typename?: 'CollectionRemoveProducts'; /** Collection from which products will be removed. */ - collection?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - collectionErrors: Array; - errors: Array; + readonly collection?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly collectionErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** @@ -5705,88 +4912,88 @@ export type CollectionRemoveProducts = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CollectionReorderProducts = { - __typename?: 'CollectionReorderProducts'; /** Collection from which products are reordered. */ - collection?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - collectionErrors: Array; - errors: Array; + readonly collection?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly collectionErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -export type CollectionSortField = +export enum CollectionSortField { /** * Sort collections by availability. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'AVAILABILITY' + Availability = 'AVAILABILITY', /** Sort collections by name. */ - | 'NAME' + Name = 'NAME', /** Sort collections by product count. */ - | 'PRODUCT_COUNT' + ProductCount = 'PRODUCT_COUNT', /** * Sort collections by publication date. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'PUBLICATION_DATE' + PublicationDate = 'PUBLICATION_DATE', /** * Sort collections by publication date. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'PUBLISHED_AT'; + PublishedAt = 'PUBLISHED_AT' +} export type CollectionSortingInput = { /** * Specifies the channel in which to sort the data. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. + * @deprecated Use root-level channel argument instead. */ - channel?: InputMaybe; + readonly channel?: InputMaybe; /** Specifies the direction in which to sort collections. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort collections by the selected field. */ - field: CollectionSortField; + readonly field: CollectionSortField; }; /** Represents collection's original translatable fields and related translations. */ export type CollectionTranslatableContent = Node & { - __typename?: 'CollectionTranslatableContent'; /** * Represents a collection of products. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. + * @deprecated Get model fields from the root level queries. */ - collection?: Maybe; - /** - * The ID of the collection to translate. - * - * Added in Saleor 3.14. - */ - collectionId: Scalars['ID']; + readonly collection?: Maybe; + /** The ID of the collection to translate. */ + readonly collectionId: Scalars['ID']; /** * Collection's description to translate. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Description of the collection. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. + * @deprecated Use the `description` field instead. */ - descriptionJson?: Maybe; + readonly descriptionJson?: Maybe; /** The ID of the collection translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Collection's name to translate. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** SEO description to translate. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** SEO title to translate. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; + /** + * Slug to translate + * + * Added in Saleor 3.21. + */ + readonly slug?: Maybe; /** Returns translated collection fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -5801,45 +5008,45 @@ export type CollectionTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type CollectionTranslate = { - __typename?: 'CollectionTranslate'; - collection?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly collection?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; /** Represents collection translations. */ export type CollectionTranslation = Node & { - __typename?: 'CollectionTranslation'; /** * Translated description of the collection. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Translated description of the collection. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. + * @deprecated Use the `description` field instead. */ - descriptionJson?: Maybe; + readonly descriptionJson?: Maybe; /** The ID of the collection translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated collection name. */ - name?: Maybe; + readonly name?: Maybe; /** Translated SEO description. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** Translated SEO title. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; /** - * Represents the collection fields to translate. + * Translated collection slug. * - * Added in Saleor 3.14. + * Added in Saleor 3.21. */ - translatableContent?: Maybe; + readonly slug?: Maybe; + /** Represents the collection fields to translate. */ + readonly translatableContent?: Maybe; }; /** @@ -5848,82 +5055,71 @@ export type CollectionTranslation = Node & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type CollectionUpdate = { - __typename?: 'CollectionUpdate'; - collection?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - collectionErrors: Array; - errors: Array; + readonly collection?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly collectionErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** - * Event sent when collection is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when collection is updated. */ export type CollectionUpdated = Event & { - __typename?: 'CollectionUpdated'; /** The collection the event relates to. */ - collection?: Maybe; + readonly collection?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when collection is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when collection is updated. */ export type CollectionUpdatedCollectionArgs = { channel?: InputMaybe; }; export type CollectionWhereInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; - ids?: InputMaybe>; - metadata?: InputMaybe>; + readonly OR?: InputMaybe>; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; }; /** Stores information about a single configuration field. */ export type ConfigurationItem = { - __typename?: 'ConfigurationItem'; /** Help text for the field. */ - helpText?: Maybe; + readonly helpText?: Maybe; /** Label for the field. */ - label?: Maybe; + readonly label?: Maybe; /** Name of the field. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Type of the field. */ - type?: Maybe; + readonly type?: Maybe; /** Current value of the field. */ - value?: Maybe; + readonly value?: Maybe; }; export type ConfigurationItemInput = { /** Name of the field to update. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Value of the given field to update. */ - value?: InputMaybe; + readonly value?: InputMaybe; }; -/** An enumeration. */ -export type ConfigurationTypeFieldEnum = - | 'BOOLEAN' - | 'MULTILINE' - | 'OUTPUT' - | 'PASSWORD' - | 'SECRET' - | 'SECRETMULTILINE' - | 'STRING'; +export enum ConfigurationTypeFieldEnum { + Boolean = 'BOOLEAN', + Multiline = 'MULTILINE', + Output = 'OUTPUT', + Password = 'PASSWORD', + Secret = 'SECRET', + Secretmultiline = 'SECRETMULTILINE', + String = 'STRING' +} /** * Confirm user account with token sent by email during registration. @@ -5932,12 +5128,11 @@ export type ConfigurationTypeFieldEnum = * - ACCOUNT_CONFIRMED (async): Account was confirmed. */ export type ConfirmAccount = { - __typename?: 'ConfirmAccount'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** An activated user account. */ - user?: Maybe; + readonly user?: Maybe; }; /** @@ -5951,12 +5146,11 @@ export type ConfirmAccount = { * - ACCOUNT_EMAIL_CHANGED (async): An account email was changed. */ export type ConfirmEmailChange = { - __typename?: 'ConfirmEmailChange'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** A user instance with a new email. */ - user?: Maybe; + readonly user?: Maybe; }; /** @@ -5964,318 +5158,316 @@ export type ConfirmEmailChange = { * * The `EU` value is DEPRECATED and will be removed in Saleor 3.21. */ -export type CountryCode = - | 'AD' - | 'AE' - | 'AF' - | 'AG' - | 'AI' - | 'AL' - | 'AM' - | 'AO' - | 'AQ' - | 'AR' - | 'AS' - | 'AT' - | 'AU' - | 'AW' - | 'AX' - | 'AZ' - | 'BA' - | 'BB' - | 'BD' - | 'BE' - | 'BF' - | 'BG' - | 'BH' - | 'BI' - | 'BJ' - | 'BL' - | 'BM' - | 'BN' - | 'BO' - | 'BQ' - | 'BR' - | 'BS' - | 'BT' - | 'BV' - | 'BW' - | 'BY' - | 'BZ' - | 'CA' - | 'CC' - | 'CD' - | 'CF' - | 'CG' - | 'CH' - | 'CI' - | 'CK' - | 'CL' - | 'CM' - | 'CN' - | 'CO' - | 'CR' - | 'CU' - | 'CV' - | 'CW' - | 'CX' - | 'CY' - | 'CZ' - | 'DE' - | 'DJ' - | 'DK' - | 'DM' - | 'DO' - | 'DZ' - | 'EC' - | 'EE' - | 'EG' - | 'EH' - | 'ER' - | 'ES' - | 'ET' - | 'EU' - | 'FI' - | 'FJ' - | 'FK' - | 'FM' - | 'FO' - | 'FR' - | 'GA' - | 'GB' - | 'GD' - | 'GE' - | 'GF' - | 'GG' - | 'GH' - | 'GI' - | 'GL' - | 'GM' - | 'GN' - | 'GP' - | 'GQ' - | 'GR' - | 'GS' - | 'GT' - | 'GU' - | 'GW' - | 'GY' - | 'HK' - | 'HM' - | 'HN' - | 'HR' - | 'HT' - | 'HU' - | 'ID' - | 'IE' - | 'IL' - | 'IM' - | 'IN' - | 'IO' - | 'IQ' - | 'IR' - | 'IS' - | 'IT' - | 'JE' - | 'JM' - | 'JO' - | 'JP' - | 'KE' - | 'KG' - | 'KH' - | 'KI' - | 'KM' - | 'KN' - | 'KP' - | 'KR' - | 'KW' - | 'KY' - | 'KZ' - | 'LA' - | 'LB' - | 'LC' - | 'LI' - | 'LK' - | 'LR' - | 'LS' - | 'LT' - | 'LU' - | 'LV' - | 'LY' - | 'MA' - | 'MC' - | 'MD' - | 'ME' - | 'MF' - | 'MG' - | 'MH' - | 'MK' - | 'ML' - | 'MM' - | 'MN' - | 'MO' - | 'MP' - | 'MQ' - | 'MR' - | 'MS' - | 'MT' - | 'MU' - | 'MV' - | 'MW' - | 'MX' - | 'MY' - | 'MZ' - | 'NA' - | 'NC' - | 'NE' - | 'NF' - | 'NG' - | 'NI' - | 'NL' - | 'NO' - | 'NP' - | 'NR' - | 'NU' - | 'NZ' - | 'OM' - | 'PA' - | 'PE' - | 'PF' - | 'PG' - | 'PH' - | 'PK' - | 'PL' - | 'PM' - | 'PN' - | 'PR' - | 'PS' - | 'PT' - | 'PW' - | 'PY' - | 'QA' - | 'RE' - | 'RO' - | 'RS' - | 'RU' - | 'RW' - | 'SA' - | 'SB' - | 'SC' - | 'SD' - | 'SE' - | 'SG' - | 'SH' - | 'SI' - | 'SJ' - | 'SK' - | 'SL' - | 'SM' - | 'SN' - | 'SO' - | 'SR' - | 'SS' - | 'ST' - | 'SV' - | 'SX' - | 'SY' - | 'SZ' - | 'TC' - | 'TD' - | 'TF' - | 'TG' - | 'TH' - | 'TJ' - | 'TK' - | 'TL' - | 'TM' - | 'TN' - | 'TO' - | 'TR' - | 'TT' - | 'TV' - | 'TW' - | 'TZ' - | 'UA' - | 'UG' - | 'UM' - | 'US' - | 'UY' - | 'UZ' - | 'VA' - | 'VC' - | 'VE' - | 'VG' - | 'VI' - | 'VN' - | 'VU' - | 'WF' - | 'WS' - | 'YE' - | 'YT' - | 'ZA' - | 'ZM' - | 'ZW'; +export enum CountryCode { + Ad = 'AD', + Ae = 'AE', + Af = 'AF', + Ag = 'AG', + Ai = 'AI', + Al = 'AL', + Am = 'AM', + Ao = 'AO', + Aq = 'AQ', + Ar = 'AR', + As = 'AS', + At = 'AT', + Au = 'AU', + Aw = 'AW', + Ax = 'AX', + Az = 'AZ', + Ba = 'BA', + Bb = 'BB', + Bd = 'BD', + Be = 'BE', + Bf = 'BF', + Bg = 'BG', + Bh = 'BH', + Bi = 'BI', + Bj = 'BJ', + Bl = 'BL', + Bm = 'BM', + Bn = 'BN', + Bo = 'BO', + Bq = 'BQ', + Br = 'BR', + Bs = 'BS', + Bt = 'BT', + Bv = 'BV', + Bw = 'BW', + By = 'BY', + Bz = 'BZ', + Ca = 'CA', + Cc = 'CC', + Cd = 'CD', + Cf = 'CF', + Cg = 'CG', + Ch = 'CH', + Ci = 'CI', + Ck = 'CK', + Cl = 'CL', + Cm = 'CM', + Cn = 'CN', + Co = 'CO', + Cr = 'CR', + Cu = 'CU', + Cv = 'CV', + Cw = 'CW', + Cx = 'CX', + Cy = 'CY', + Cz = 'CZ', + De = 'DE', + Dj = 'DJ', + Dk = 'DK', + Dm = 'DM', + Do = 'DO', + Dz = 'DZ', + Ec = 'EC', + Ee = 'EE', + Eg = 'EG', + Eh = 'EH', + Er = 'ER', + Es = 'ES', + Et = 'ET', + Eu = 'EU', + Fi = 'FI', + Fj = 'FJ', + Fk = 'FK', + Fm = 'FM', + Fo = 'FO', + Fr = 'FR', + Ga = 'GA', + Gb = 'GB', + Gd = 'GD', + Ge = 'GE', + Gf = 'GF', + Gg = 'GG', + Gh = 'GH', + Gi = 'GI', + Gl = 'GL', + Gm = 'GM', + Gn = 'GN', + Gp = 'GP', + Gq = 'GQ', + Gr = 'GR', + Gs = 'GS', + Gt = 'GT', + Gu = 'GU', + Gw = 'GW', + Gy = 'GY', + Hk = 'HK', + Hm = 'HM', + Hn = 'HN', + Hr = 'HR', + Ht = 'HT', + Hu = 'HU', + Id = 'ID', + Ie = 'IE', + Il = 'IL', + Im = 'IM', + In = 'IN', + Io = 'IO', + Iq = 'IQ', + Ir = 'IR', + Is = 'IS', + It = 'IT', + Je = 'JE', + Jm = 'JM', + Jo = 'JO', + Jp = 'JP', + Ke = 'KE', + Kg = 'KG', + Kh = 'KH', + Ki = 'KI', + Km = 'KM', + Kn = 'KN', + Kp = 'KP', + Kr = 'KR', + Kw = 'KW', + Ky = 'KY', + Kz = 'KZ', + La = 'LA', + Lb = 'LB', + Lc = 'LC', + Li = 'LI', + Lk = 'LK', + Lr = 'LR', + Ls = 'LS', + Lt = 'LT', + Lu = 'LU', + Lv = 'LV', + Ly = 'LY', + Ma = 'MA', + Mc = 'MC', + Md = 'MD', + Me = 'ME', + Mf = 'MF', + Mg = 'MG', + Mh = 'MH', + Mk = 'MK', + Ml = 'ML', + Mm = 'MM', + Mn = 'MN', + Mo = 'MO', + Mp = 'MP', + Mq = 'MQ', + Mr = 'MR', + Ms = 'MS', + Mt = 'MT', + Mu = 'MU', + Mv = 'MV', + Mw = 'MW', + Mx = 'MX', + My = 'MY', + Mz = 'MZ', + Na = 'NA', + Nc = 'NC', + Ne = 'NE', + Nf = 'NF', + Ng = 'NG', + Ni = 'NI', + Nl = 'NL', + No = 'NO', + Np = 'NP', + Nr = 'NR', + Nu = 'NU', + Nz = 'NZ', + Om = 'OM', + Pa = 'PA', + Pe = 'PE', + Pf = 'PF', + Pg = 'PG', + Ph = 'PH', + Pk = 'PK', + Pl = 'PL', + Pm = 'PM', + Pn = 'PN', + Pr = 'PR', + Ps = 'PS', + Pt = 'PT', + Pw = 'PW', + Py = 'PY', + Qa = 'QA', + Re = 'RE', + Ro = 'RO', + Rs = 'RS', + Ru = 'RU', + Rw = 'RW', + Sa = 'SA', + Sb = 'SB', + Sc = 'SC', + Sd = 'SD', + Se = 'SE', + Sg = 'SG', + Sh = 'SH', + Si = 'SI', + Sj = 'SJ', + Sk = 'SK', + Sl = 'SL', + Sm = 'SM', + Sn = 'SN', + So = 'SO', + Sr = 'SR', + Ss = 'SS', + St = 'ST', + Sv = 'SV', + Sx = 'SX', + Sy = 'SY', + Sz = 'SZ', + Tc = 'TC', + Td = 'TD', + Tf = 'TF', + Tg = 'TG', + Th = 'TH', + Tj = 'TJ', + Tk = 'TK', + Tl = 'TL', + Tm = 'TM', + Tn = 'TN', + To = 'TO', + Tr = 'TR', + Tt = 'TT', + Tv = 'TV', + Tw = 'TW', + Tz = 'TZ', + Ua = 'UA', + Ug = 'UG', + Um = 'UM', + Us = 'US', + Uy = 'UY', + Uz = 'UZ', + Va = 'VA', + Vc = 'VC', + Ve = 'VE', + Vg = 'VG', + Vi = 'VI', + Vn = 'VN', + Vu = 'VU', + Wf = 'WF', + Ws = 'WS', + Ye = 'YE', + Yt = 'YT', + Za = 'ZA', + Zm = 'ZM', + Zw = 'ZW' +} export type CountryDisplay = { - __typename?: 'CountryDisplay'; /** Country code. */ - code: Scalars['String']; + readonly code: Scalars['String']; /** Country name. */ - country: Scalars['String']; + readonly country: Scalars['String']; /** * Country tax. - * @deprecated This field will be removed in Saleor 4.0. Always returns `null`. Use `TaxClassCountryRate` type to manage tax rates per country. + * @deprecated Always returns `null`. Use `TaxClassCountryRate` type to manage tax rates per country. */ - vat?: Maybe; + readonly vat?: Maybe; }; export type CountryFilterInput = { /** Boolean for filtering countries by having shipping zone assigned.If 'true', return countries with shipping zone assigned.If 'false', return countries without any shipping zone assigned.If the argument is not provided (null), return all countries. */ - attachedToShippingZones?: InputMaybe; + readonly attachedToShippingZones?: InputMaybe; }; export type CountryRateInput = { /** Country in which this rate applies. */ - countryCode: CountryCode; + readonly countryCode: CountryCode; /** Tax rate value provided as percentage. Example: provide `23` to represent `23%` tax rate. */ - rate: Scalars['Float']; + readonly rate: Scalars['Float']; }; export type CountryRateUpdateInput = { /** Country in which this rate applies. */ - countryCode: CountryCode; + readonly countryCode: CountryCode; /** Tax rate value provided as percentage. Example: provide `23` to represent `23%` tax rate. Provide `null` to remove the particular rate. */ - rate?: InputMaybe; + readonly rate?: InputMaybe; }; /** Create JWT token. */ export type CreateToken = { - __typename?: 'CreateToken'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; /** CSRF token required to re-generate access token. */ - csrfToken?: Maybe; - errors: Array; + readonly csrfToken?: Maybe; + readonly errors: ReadonlyArray; /** JWT refresh token, required to re-generate access token. */ - refreshToken?: Maybe; + readonly refreshToken?: Maybe; /** JWT token, required to authenticate. */ - token?: Maybe; + readonly token?: Maybe; /** A user instance. */ - user?: Maybe; + readonly user?: Maybe; }; export type CreditCard = { - __typename?: 'CreditCard'; /** Card brand. */ - brand: Scalars['String']; + readonly brand: Scalars['String']; /** Two-digit number representing the card’s expiration month. */ - expMonth?: Maybe; + readonly expMonth?: Maybe; /** Four-digit number representing the card’s expiration year. */ - expYear?: Maybe; + readonly expYear?: Maybe; /** First 4 digits of the card number. */ - firstDigits?: Maybe; + readonly firstDigits?: Maybe; /** Last 4 digits of the card number. */ - lastDigits: Scalars['String']; + readonly lastDigits: Scalars['String']; }; /** @@ -6287,29 +5479,23 @@ export type CreditCard = { * - CUSTOMER_DELETED (async): A customer account was deleted. */ export type CustomerBulkDelete = { - __typename?: 'CustomerBulkDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; export type CustomerBulkResult = { - __typename?: 'CustomerBulkResult'; /** Customer data. */ - customer?: Maybe; + readonly customer?: Maybe; /** List of errors that occurred during the update attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; }; /** * Updates customers. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_USERS. * * Triggers the following webhook events: @@ -6317,42 +5503,40 @@ export type CustomerBulkResult = { * - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. */ export type CustomerBulkUpdate = { - __typename?: 'CustomerBulkUpdate'; /** Returns how many objects were created. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the updated customers. */ - results: Array; + readonly results: ReadonlyArray; }; export type CustomerBulkUpdateError = { - __typename?: 'CustomerBulkUpdateError'; /** The error code. */ - code: CustomerBulkUpdateErrorCode; + readonly code: CustomerBulkUpdateErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; -}; - -/** An enumeration. */ -export type CustomerBulkUpdateErrorCode = - | 'BLANK' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'MAX_LENGTH' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; + readonly path?: Maybe; +}; + +export enum CustomerBulkUpdateErrorCode { + Blank = 'BLANK', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + MaxLength = 'MAX_LENGTH', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type CustomerBulkUpdateInput = { /** External ID of a customer to update. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** ID of a customer to update. */ - id?: InputMaybe; + readonly id?: InputMaybe; /** Fields required to update a customer. */ - input: CustomerInput; + readonly input: CustomerInput; }; /** @@ -6367,30 +5551,24 @@ export type CustomerBulkUpdateInput = { * - ACCOUNT_SET_PASSWORD_REQUESTED (async): Setting a new password for the account is requested. */ export type CustomerCreate = { - __typename?: 'CustomerCreate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; - user?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly user?: Maybe; }; -/** - * Event sent when new customer user is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new customer user is created. */ export type CustomerCreated = Event & { - __typename?: 'CustomerCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -6402,129 +5580,110 @@ export type CustomerCreated = Event & { * - CUSTOMER_DELETED (async): A customer account was deleted. */ export type CustomerDelete = { - __typename?: 'CustomerDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; - user?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly user?: Maybe; }; /** History log of the customer. */ export type CustomerEvent = Node & { - __typename?: 'CustomerEvent'; /** App that performed the action. */ - app?: Maybe; + readonly app?: Maybe; /** Number of objects concerned by the event. */ - count?: Maybe; + readonly count?: Maybe; /** Date when event happened at in ISO 8601 format. */ - date?: Maybe; + readonly date?: Maybe; /** The ID of the customer event. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Content of the event. */ - message?: Maybe; + readonly message?: Maybe; /** The concerned order. */ - order?: Maybe; + readonly order?: Maybe; /** The concerned order line. */ - orderLine?: Maybe; + readonly orderLine?: Maybe; /** Customer event type. */ - type?: Maybe; + readonly type?: Maybe; /** User who performed the action. */ - user?: Maybe; -}; - -/** An enumeration. */ -export type CustomerEventsEnum = - | 'ACCOUNT_ACTIVATED' - | 'ACCOUNT_CREATED' - | 'ACCOUNT_DEACTIVATED' - | 'CUSTOMER_DELETED' - | 'DIGITAL_LINK_DOWNLOADED' - | 'EMAIL_ASSIGNED' - | 'EMAIL_CHANGED' - | 'EMAIL_CHANGED_REQUEST' - | 'NAME_ASSIGNED' - | 'NOTE_ADDED' - | 'NOTE_ADDED_TO_ORDER' - | 'PASSWORD_CHANGED' - | 'PASSWORD_RESET' - | 'PASSWORD_RESET_LINK_SENT' - | 'PLACED_ORDER'; + readonly user?: Maybe; +}; + +export enum CustomerEventsEnum { + AccountActivated = 'ACCOUNT_ACTIVATED', + AccountCreated = 'ACCOUNT_CREATED', + AccountDeactivated = 'ACCOUNT_DEACTIVATED', + CustomerDeleted = 'CUSTOMER_DELETED', + DigitalLinkDownloaded = 'DIGITAL_LINK_DOWNLOADED', + EmailAssigned = 'EMAIL_ASSIGNED', + EmailChanged = 'EMAIL_CHANGED', + EmailChangedRequest = 'EMAIL_CHANGED_REQUEST', + NameAssigned = 'NAME_ASSIGNED', + NoteAdded = 'NOTE_ADDED', + NoteAddedToOrder = 'NOTE_ADDED_TO_ORDER', + PasswordChanged = 'PASSWORD_CHANGED', + PasswordReset = 'PASSWORD_RESET', + PasswordResetLinkSent = 'PASSWORD_RESET_LINK_SENT', + PlacedOrder = 'PLACED_ORDER' +} export type CustomerFilterInput = { - dateJoined?: InputMaybe; - /** - * Filter by ids. - * - * Added in Saleor 3.8. - */ - ids?: InputMaybe>; - metadata?: InputMaybe>; - numberOfOrders?: InputMaybe; - placedOrders?: InputMaybe; - search?: InputMaybe; - updatedAt?: InputMaybe; + readonly dateJoined?: InputMaybe; + /** Filter by ids. */ + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; + readonly numberOfOrders?: InputMaybe; + readonly placedOrders?: InputMaybe; + readonly search?: InputMaybe; + readonly updatedAt?: InputMaybe; }; export type CustomerInput = { /** Billing address of the customer. */ - defaultBillingAddress?: InputMaybe; + readonly defaultBillingAddress?: InputMaybe; /** Shipping address of the customer. */ - defaultShippingAddress?: InputMaybe; + readonly defaultShippingAddress?: InputMaybe; /** The unique email address of the user. */ - email?: InputMaybe; - /** - * External ID of the customer. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly email?: InputMaybe; + /** External ID of the customer. */ + readonly externalReference?: InputMaybe; /** Given name. */ - firstName?: InputMaybe; + readonly firstName?: InputMaybe; /** User account is active. */ - isActive?: InputMaybe; - /** - * User account is confirmed. - * - * Added in Saleor 3.15. - */ - isConfirmed?: InputMaybe; + readonly isActive?: InputMaybe; + /** User account is confirmed. */ + readonly isConfirmed?: InputMaybe; /** User language code. */ - languageCode?: InputMaybe; + readonly languageCode?: InputMaybe; /** Family name. */ - lastName?: InputMaybe; + readonly lastName?: InputMaybe; /** - * Fields required to update the user metadata. + * Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** A note about the user. */ - note?: InputMaybe; + readonly note?: InputMaybe; /** - * Fields required to update the user private metadata. + * Fields required to update the user private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; }; -/** - * Event sent when customer user metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when customer user metadata is updated. */ export type CustomerMetadataUpdated = Event & { - __typename?: 'CustomerMetadataUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -6537,60 +5696,48 @@ export type CustomerMetadataUpdated = Event & { * - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. */ export type CustomerUpdate = { - __typename?: 'CustomerUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; - user?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly user?: Maybe; }; -/** - * Event sent when customer user is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when customer user is updated. */ export type CustomerUpdated = Event & { - __typename?: 'CustomerUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type DateRangeInput = { /** Start date. */ - gte?: InputMaybe; + readonly gte?: InputMaybe; /** End date. */ - lte?: InputMaybe; + readonly lte?: InputMaybe; }; -/** - * Define the filtering options for date time fields. - * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Define the filtering options for date time fields. */ export type DateTimeFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; /** The value in range. */ - range?: InputMaybe; + readonly range?: InputMaybe; }; export type DateTimeRangeInput = { /** Start date. */ - gte?: InputMaybe; + readonly gte?: InputMaybe; /** End date. */ - lte?: InputMaybe; + readonly lte?: InputMaybe; }; /** @@ -6599,111 +5746,85 @@ export type DateTimeRangeInput = { * Requires one of the following permissions: AUTHENTICATED_USER. */ export type DeactivateAllUserTokens = { - __typename?: 'DeactivateAllUserTokens'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** - * Define the filtering options for decimal fields. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Define the filtering options for decimal fields. */ export type DecimalFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; /** The value in range. */ - range?: InputMaybe; + readonly range?: InputMaybe; }; export type DecimalRangeInput = { /** Decimal value greater than or equal to. */ - gte?: InputMaybe; + readonly gte?: InputMaybe; /** Decimal value less than or equal to. */ - lte?: InputMaybe; + readonly lte?: InputMaybe; }; /** Delete metadata of an object. To use it, you need to have access to the modified object. */ export type DeleteMetadata = { - __typename?: 'DeleteMetadata'; - errors: Array; - item?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - metadataErrors: Array; + readonly errors: ReadonlyArray; + readonly item?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly metadataErrors: ReadonlyArray; }; /** Delete object's private metadata. To use it, you need to be an authenticated staff user or an app and have access to the modified object. */ export type DeletePrivateMetadata = { - __typename?: 'DeletePrivateMetadata'; - errors: Array; - item?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - metadataErrors: Array; + readonly errors: ReadonlyArray; + readonly item?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly metadataErrors: ReadonlyArray; }; -/** - * Represents a delivery method chosen for the checkout. `Warehouse` type is used when checkout is marked as "click and collect" and `ShippingMethod` otherwise. - * - * Added in Saleor 3.1. - */ +/** Represents a delivery method chosen for the checkout. `Warehouse` type is used when checkout is marked as "click and collect" and `ShippingMethod` otherwise. */ export type DeliveryMethod = ShippingMethod | Warehouse; /** Represents digital content associated with a product variant. */ export type DigitalContent = Node & ObjectWithMetadata & { - __typename?: 'DigitalContent'; /** Indicator for automatic fulfillment of digital content. */ - automaticFulfillment: Scalars['Boolean']; + readonly automaticFulfillment: Scalars['Boolean']; /** File associated with digital content. */ - contentFile: Scalars['String']; + readonly contentFile: Scalars['String']; /** The ID of the digital content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Maximum number of allowed downloads for the digital content. */ - maxDownloads?: Maybe; + readonly maxDownloads?: Maybe; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Product variant assigned to digital content. */ - productVariant: ProductVariant; + readonly productVariant: ProductVariant; /** Number of days the URL for the digital content remains valid. */ - urlValidDays?: Maybe; + readonly urlValidDays?: Maybe; /** List of URLs for the digital variant. */ - urls?: Maybe>; + readonly urls?: Maybe>; /** Default settings indicator for digital content. */ - useDefaultSettings: Scalars['Boolean']; + readonly useDefaultSettings: Scalars['Boolean']; }; @@ -6715,7 +5836,7 @@ export type DigitalContentMetafieldArgs = { /** Represents digital content associated with a product variant. */ export type DigitalContentMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -6727,25 +5848,23 @@ export type DigitalContentPrivateMetafieldArgs = { /** Represents digital content associated with a product variant. */ export type DigitalContentPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** A connection to a list of digital content items. */ export type DigitalContentCountableConnection = { - __typename?: 'DigitalContentCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type DigitalContentCountableEdge = { - __typename?: 'DigitalContentCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: DigitalContent; + readonly node: DigitalContent; }; /** @@ -6754,12 +5873,11 @@ export type DigitalContentCountableEdge = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type DigitalContentCreate = { - __typename?: 'DigitalContentCreate'; - content?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - variant?: Maybe; + readonly content?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly variant?: Maybe; }; /** @@ -6768,34 +5886,33 @@ export type DigitalContentCreate = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type DigitalContentDelete = { - __typename?: 'DigitalContentDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - variant?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly variant?: Maybe; }; export type DigitalContentInput = { /** Overwrite default automatic_fulfillment setting for variant. */ - automaticFulfillment?: InputMaybe; + readonly automaticFulfillment?: InputMaybe; /** Determines how many times a download link can be accessed by a customer. */ - maxDownloads?: InputMaybe; + readonly maxDownloads?: InputMaybe; /** - * Fields required to update the digital content metadata. + * Fields required to update the digital content metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** - * Fields required to update the digital content private metadata. + * Fields required to update the digital content private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** Determines for how many days a download link is active since it was generated. */ - urlValidDays?: InputMaybe; + readonly urlValidDays?: InputMaybe; /** Use default digital content settings for this product. */ - useDefaultSettings: Scalars['Boolean']; + readonly useDefaultSettings: Scalars['Boolean']; }; /** @@ -6804,54 +5921,52 @@ export type DigitalContentInput = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type DigitalContentUpdate = { - __typename?: 'DigitalContentUpdate'; - content?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - variant?: Maybe; + readonly content?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly variant?: Maybe; }; export type DigitalContentUploadInput = { /** Overwrite default automatic_fulfillment setting for variant. */ - automaticFulfillment?: InputMaybe; + readonly automaticFulfillment?: InputMaybe; /** Represents an file in a multipart request. */ - contentFile: Scalars['Upload']; + readonly contentFile: Scalars['Upload']; /** Determines how many times a download link can be accessed by a customer. */ - maxDownloads?: InputMaybe; + readonly maxDownloads?: InputMaybe; /** - * Fields required to update the digital content metadata. + * Fields required to update the digital content metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** - * Fields required to update the digital content private metadata. + * Fields required to update the digital content private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** Determines for how many days a download link is active since it was generated. */ - urlValidDays?: InputMaybe; + readonly urlValidDays?: InputMaybe; /** Use default digital content settings for this product. */ - useDefaultSettings: Scalars['Boolean']; + readonly useDefaultSettings: Scalars['Boolean']; }; /** Represents a URL for digital content. */ export type DigitalContentUrl = Node & { - __typename?: 'DigitalContentUrl'; /** Digital content associated with the URL. */ - content: DigitalContent; + readonly content: DigitalContent; /** Date and time when the digital content URL was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** Number of times digital content has been downloaded. */ - downloadNum: Scalars['Int']; + readonly downloadNum: Scalars['Int']; /** The ID of the digital content URL. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** UUID of digital content. */ - token: Scalars['UUID']; + readonly token: Scalars['UUID']; /** URL for digital content. */ - url?: Maybe; + readonly url?: Maybe; }; /** @@ -6860,90 +5975,89 @@ export type DigitalContentUrl = Node & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type DigitalContentUrlCreate = { - __typename?: 'DigitalContentUrlCreate'; - digitalContentUrl?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly digitalContentUrl?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; export type DigitalContentUrlCreateInput = { /** Digital content ID which URL will belong to. */ - content: Scalars['ID']; + readonly content: Scalars['ID']; }; export type DiscountError = { - __typename?: 'DiscountError'; /** List of channels IDs which causes the error. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** The error code. */ - code: DiscountErrorCode; + readonly code: DiscountErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of products IDs which causes the error. */ - products?: Maybe>; + readonly products?: Maybe>; /** * List of voucher codes which causes the error. * * Added in Saleor 3.18. */ - voucherCodes?: Maybe>; + readonly voucherCodes?: Maybe>; }; -/** An enumeration. */ -export type DiscountErrorCode = - | 'ALREADY_EXISTS' - | 'CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE' - | 'VOUCHER_ALREADY_USED'; +export enum DiscountErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + CannotManageProductWithoutVariant = 'CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE', + VoucherAlreadyUsed = 'VOUCHER_ALREADY_USED' +} -export type DiscountStatusEnum = - | 'ACTIVE' - | 'EXPIRED' - | 'SCHEDULED'; +export enum DiscountStatusEnum { + Active = 'ACTIVE', + Expired = 'EXPIRED', + Scheduled = 'SCHEDULED' +} -export type DiscountValueTypeEnum = - | 'FIXED' - | 'PERCENTAGE'; +export enum DiscountValueTypeEnum { + Fixed = 'FIXED', + Percentage = 'PERCENTAGE' +} export type DiscountedObjectWhereInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; + readonly OR?: InputMaybe>; /** Filter by the base subtotal price. */ - baseSubtotalPrice?: InputMaybe; + readonly baseSubtotalPrice?: InputMaybe; /** Filter by the base total price. */ - baseTotalPrice?: InputMaybe; -}; - -/** An enumeration. */ -export type DistanceUnitsEnum = - | 'CM' - | 'DM' - | 'FT' - | 'INCH' - | 'KM' - | 'M' - | 'MM' - | 'YD'; + readonly baseTotalPrice?: InputMaybe; +}; + +export enum DistanceUnitsEnum { + Cm = 'CM', + Dm = 'DM', + Ft = 'FT', + Inch = 'INCH', + Km = 'KM', + M = 'M', + Mm = 'MM', + Yd = 'YD' +} /** Represents API domain. */ export type Domain = { - __typename?: 'Domain'; /** The host name of the domain. */ - host: Scalars['String']; + readonly host: Scalars['String']; /** Inform if SSL is enabled. */ - sslEnabled: Scalars['Boolean']; + readonly sslEnabled: Scalars['Boolean']; /** The absolute URL of the API. */ - url: Scalars['String']; + readonly url: Scalars['String']; }; /** @@ -6952,12 +6066,11 @@ export type Domain = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type DraftOrderBulkDelete = { - __typename?: 'DraftOrderBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; /** @@ -6966,12 +6079,11 @@ export type DraftOrderBulkDelete = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type DraftOrderComplete = { - __typename?: 'DraftOrderComplete'; - errors: Array; + readonly errors: ReadonlyArray; /** Completed order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; /** @@ -6980,67 +6092,94 @@ export type DraftOrderComplete = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type DraftOrderCreate = { - __typename?: 'DraftOrderCreate'; - errors: Array; - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly errors: ReadonlyArray; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type DraftOrderCreateInput = { /** Billing address of the customer. */ - billingAddress?: InputMaybe; + readonly billingAddress?: InputMaybe; /** ID of the channel associated with the order. */ - channelId?: InputMaybe; + readonly channelId?: InputMaybe; /** A note from a customer. Visible by customers in the order summary. */ - customerNote?: InputMaybe; - /** Discount amount for the order. */ - discount?: InputMaybe; + readonly customerNote?: InputMaybe; /** - * External ID of this order. + * Discount amount for the order. + * @deprecated Providing a value for the field has no effect. Use `orderDiscountAdd` mutation instead. + */ + readonly discount?: InputMaybe; + /** External ID of this order. */ + readonly externalReference?: InputMaybe; + /** + * Order language code. * - * Added in Saleor 3.10. + * Added in Saleor 3.21. */ - externalReference?: InputMaybe; + readonly languageCode?: InputMaybe; /** Variant line input consisting of variant ID and quantity of products. */ - lines?: InputMaybe>; + readonly lines?: InputMaybe>; + /** + * Order public metadata. + * + * Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly metadata?: InputMaybe>; + /** + * Order private metadata. + * + * Added in Saleor 3.21. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly privateMetadata?: InputMaybe>; /** URL of a view where users should be redirected to see the order details. URL in RFC 1808 format. */ - redirectUrl?: InputMaybe; + readonly redirectUrl?: InputMaybe; + /** + * Indicates whether the billing address should be saved to the user’s address book upon draft order completion. Can only be set when a billing address is provided. If not specified along with the address, the default behavior is to not save the address. + * + * Added in Saleor 3.21. + */ + readonly saveBillingAddress?: InputMaybe; + /** + * Indicates whether the shipping address should be saved to the user’s address book upon draft order completion.Can only be set when a shipping address is provided. If not specified along with the address, the default behavior is to not save the address. + * + * Added in Saleor 3.21. + */ + readonly saveShippingAddress?: InputMaybe; /** Shipping address of the customer. */ - shippingAddress?: InputMaybe; + readonly shippingAddress?: InputMaybe; /** ID of a selected shipping method. */ - shippingMethod?: InputMaybe; + readonly shippingMethod?: InputMaybe; /** Customer associated with the draft order. */ - user?: InputMaybe; + readonly user?: InputMaybe; /** Email address of the customer. */ - userEmail?: InputMaybe; + readonly userEmail?: InputMaybe; /** ID of the voucher associated with the order. */ - voucher?: InputMaybe; + readonly voucher?: InputMaybe; /** * A code of the voucher associated with the order. * * Added in Saleor 3.18. */ - voucherCode?: InputMaybe; + readonly voucherCode?: InputMaybe; }; -/** - * Event sent when new draft order is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new draft order is created. */ export type DraftOrderCreated = Event & { - __typename?: 'DraftOrderCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -7049,65 +6188,92 @@ export type DraftOrderCreated = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type DraftOrderDelete = { - __typename?: 'DraftOrderDelete'; - errors: Array; - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly errors: ReadonlyArray; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; -/** - * Event sent when draft order is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when draft order is deleted. */ export type DraftOrderDeleted = Event & { - __typename?: 'DraftOrderDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type DraftOrderInput = { /** Billing address of the customer. */ - billingAddress?: InputMaybe; + readonly billingAddress?: InputMaybe; /** ID of the channel associated with the order. */ - channelId?: InputMaybe; + readonly channelId?: InputMaybe; /** A note from a customer. Visible by customers in the order summary. */ - customerNote?: InputMaybe; - /** Discount amount for the order. */ - discount?: InputMaybe; + readonly customerNote?: InputMaybe; + /** + * Discount amount for the order. + * @deprecated Providing a value for the field has no effect. Use `orderDiscountAdd` mutation instead. + */ + readonly discount?: InputMaybe; + /** External ID of this order. */ + readonly externalReference?: InputMaybe; /** - * External ID of this order. + * Order language code. * - * Added in Saleor 3.10. + * Added in Saleor 3.21. */ - externalReference?: InputMaybe; + readonly languageCode?: InputMaybe; + /** + * Order public metadata. + * + * Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly metadata?: InputMaybe>; + /** + * Order private metadata. + * + * Added in Saleor 3.21. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly privateMetadata?: InputMaybe>; /** URL of a view where users should be redirected to see the order details. URL in RFC 1808 format. */ - redirectUrl?: InputMaybe; + readonly redirectUrl?: InputMaybe; + /** + * Indicates whether the billing address should be saved to the user’s address book upon draft order completion. Can only be set when a billing address is provided. If not specified along with the address, the default behavior is to not save the address. + * + * Added in Saleor 3.21. + */ + readonly saveBillingAddress?: InputMaybe; + /** + * Indicates whether the shipping address should be saved to the user’s address book upon draft order completion.Can only be set when a shipping address is provided. If not specified along with the address, the default behavior is to not save the address. + * + * Added in Saleor 3.21. + */ + readonly saveShippingAddress?: InputMaybe; /** Shipping address of the customer. */ - shippingAddress?: InputMaybe; + readonly shippingAddress?: InputMaybe; /** ID of a selected shipping method. */ - shippingMethod?: InputMaybe; + readonly shippingMethod?: InputMaybe; /** Customer associated with the draft order. */ - user?: InputMaybe; + readonly user?: InputMaybe; /** Email address of the customer. */ - userEmail?: InputMaybe; + readonly userEmail?: InputMaybe; /** ID of the voucher associated with the order. */ - voucher?: InputMaybe; + readonly voucher?: InputMaybe; /** * A code of the voucher associated with the order. * * Added in Saleor 3.18. */ - voucherCode?: InputMaybe; + readonly voucherCode?: InputMaybe; }; /** @@ -7116,12 +6282,11 @@ export type DraftOrderInput = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type DraftOrderLinesBulkDelete = { - __typename?: 'DraftOrderLinesBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; /** @@ -7130,66 +6295,60 @@ export type DraftOrderLinesBulkDelete = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type DraftOrderUpdate = { - __typename?: 'DraftOrderUpdate'; - errors: Array; - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly errors: ReadonlyArray; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; -/** - * Event sent when draft order is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when draft order is updated. */ export type DraftOrderUpdated = Event & { - __typename?: 'DraftOrderUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -export type ErrorPolicyEnum = +export enum ErrorPolicyEnum { /** Save what is possible within a single row. If there are errors in an input data row, try to save it partially and skip the invalid part. */ - | 'IGNORE_FAILED' + IgnoreFailed = 'IGNORE_FAILED', /** Reject all rows if there is at least one error in any of them. */ - | 'REJECT_EVERYTHING' + RejectEverything = 'REJECT_EVERYTHING', /** Reject rows with errors. */ - | 'REJECT_FAILED_ROWS'; + RejectFailedRows = 'REJECT_FAILED_ROWS' +} export type Event = { /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Event delivery. */ export type EventDelivery = Node & { - __typename?: 'EventDelivery'; /** Event delivery attempts. */ - attempts?: Maybe; + readonly attempts?: Maybe; /** Creation time of an event delivery. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** Webhook event type. */ - eventType: WebhookEventTypeEnum; + readonly eventType: WebhookEventTypeEnum; /** The ID of an event delivery. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Event payload. */ - payload?: Maybe; + readonly payload?: Maybe; /** Event delivery status. */ - status: EventDeliveryStatusEnum; + readonly status: EventDeliveryStatusEnum; }; @@ -7204,75 +6363,71 @@ export type EventDeliveryAttemptsArgs = { /** Event delivery attempts. */ export type EventDeliveryAttempt = Node & { - __typename?: 'EventDeliveryAttempt'; /** Event delivery creation date and time. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** Delivery attempt duration. */ - duration?: Maybe; + readonly duration?: Maybe; /** The ID of Event Delivery Attempt. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Request headers for delivery attempt. */ - requestHeaders?: Maybe; + readonly requestHeaders?: Maybe; /** Delivery attempt response content. */ - response?: Maybe; + readonly response?: Maybe; /** Response headers for delivery attempt. */ - responseHeaders?: Maybe; + readonly responseHeaders?: Maybe; /** Delivery attempt response status code. */ - responseStatusCode?: Maybe; + readonly responseStatusCode?: Maybe; /** Event delivery status. */ - status: EventDeliveryStatusEnum; + readonly status: EventDeliveryStatusEnum; /** Task id for delivery attempt. */ - taskId?: Maybe; + readonly taskId?: Maybe; }; export type EventDeliveryAttemptCountableConnection = { - __typename?: 'EventDeliveryAttemptCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type EventDeliveryAttemptCountableEdge = { - __typename?: 'EventDeliveryAttemptCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: EventDeliveryAttempt; + readonly node: EventDeliveryAttempt; }; -export type EventDeliveryAttemptSortField = +export enum EventDeliveryAttemptSortField { /** Sort event delivery attempts by created at. */ - | 'CREATED_AT'; + CreatedAt = 'CREATED_AT' +} export type EventDeliveryAttemptSortingInput = { /** Specifies the direction in which to sort attempts. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort attempts by the selected field. */ - field: EventDeliveryAttemptSortField; + readonly field: EventDeliveryAttemptSortField; }; export type EventDeliveryCountableConnection = { - __typename?: 'EventDeliveryCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type EventDeliveryCountableEdge = { - __typename?: 'EventDeliveryCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: EventDelivery; + readonly node: EventDelivery; }; export type EventDeliveryFilterInput = { - eventType?: InputMaybe; - status?: InputMaybe; + readonly eventType?: InputMaybe; + readonly status?: InputMaybe; }; /** @@ -7281,137 +6436,132 @@ export type EventDeliveryFilterInput = { * Requires one of the following permissions: MANAGE_APPS. */ export type EventDeliveryRetry = { - __typename?: 'EventDeliveryRetry'; /** Event delivery. */ - delivery?: Maybe; - errors: Array; + readonly delivery?: Maybe; + readonly errors: ReadonlyArray; }; -export type EventDeliverySortField = +export enum EventDeliverySortField { /** Sort event deliveries by created at. */ - | 'CREATED_AT'; + CreatedAt = 'CREATED_AT' +} export type EventDeliverySortingInput = { /** Specifies the direction in which to sort deliveries. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort deliveries by the selected field. */ - field: EventDeliverySortField; + readonly field: EventDeliverySortField; }; -export type EventDeliveryStatusEnum = - | 'FAILED' - | 'PENDING' - | 'SUCCESS'; +export enum EventDeliveryStatusEnum { + Failed = 'FAILED', + Pending = 'PENDING', + Success = 'SUCCESS' +} export type ExportError = { - __typename?: 'ExportError'; /** The error code. */ - code: ExportErrorCode; + readonly code: ExportErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type ExportErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum ExportErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} /** History log of export file. */ export type ExportEvent = Node & { - __typename?: 'ExportEvent'; /** App which performed the action. Requires one of the following permissions: OWNER, MANAGE_APPS. */ - app?: Maybe; + readonly app?: Maybe; /** Date when event happened at in ISO 8601 format. */ - date: Scalars['DateTime']; + readonly date: Scalars['DateTime']; /** The ID of the object. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Content of the event. */ - message: Scalars['String']; + readonly message: Scalars['String']; /** Export event type. */ - type: ExportEventsEnum; + readonly type: ExportEventsEnum; /** User who performed the action. Requires one of the following permissions: OWNER, MANAGE_STAFF. */ - user?: Maybe; + readonly user?: Maybe; }; -/** An enumeration. */ -export type ExportEventsEnum = - | 'EXPORTED_FILE_SENT' - | 'EXPORT_DELETED' - | 'EXPORT_FAILED' - | 'EXPORT_FAILED_INFO_SENT' - | 'EXPORT_PENDING' - | 'EXPORT_SUCCESS'; +export enum ExportEventsEnum { + ExportedFileSent = 'EXPORTED_FILE_SENT', + ExportDeleted = 'EXPORT_DELETED', + ExportFailed = 'EXPORT_FAILED', + ExportFailedInfoSent = 'EXPORT_FAILED_INFO_SENT', + ExportPending = 'EXPORT_PENDING', + ExportSuccess = 'EXPORT_SUCCESS' +} /** Represents a job data of exported file. */ export type ExportFile = Job & Node & { - __typename?: 'ExportFile'; /** The app which requests file export. */ - app?: Maybe; + readonly app?: Maybe; /** Created date time of job in ISO 8601 format. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** List of events associated with the export. */ - events?: Maybe>; + readonly events?: Maybe>; /** The ID of the export file. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Job message. */ - message?: Maybe; + readonly message?: Maybe; /** Job status. */ - status: JobStatusEnum; + readonly status: JobStatusEnum; /** Date time of job last update in ISO 8601 format. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; /** The URL of field to download. */ - url?: Maybe; + readonly url?: Maybe; /** The user who requests file export. */ - user?: Maybe; + readonly user?: Maybe; }; export type ExportFileCountableConnection = { - __typename?: 'ExportFileCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type ExportFileCountableEdge = { - __typename?: 'ExportFileCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: ExportFile; + readonly node: ExportFile; }; export type ExportFileFilterInput = { - app?: InputMaybe; - createdAt?: InputMaybe; - status?: InputMaybe; - updatedAt?: InputMaybe; - user?: InputMaybe; -}; - -export type ExportFileSortField = - | 'CREATED_AT' - | 'LAST_MODIFIED_AT' - | 'STATUS' - | 'UPDATED_AT'; + readonly app?: InputMaybe; + readonly createdAt?: InputMaybe; + readonly status?: InputMaybe; + readonly updatedAt?: InputMaybe; + readonly user?: InputMaybe; +}; + +export enum ExportFileSortField { + CreatedAt = 'CREATED_AT', + LastModifiedAt = 'LAST_MODIFIED_AT', + Status = 'STATUS', + UpdatedAt = 'UPDATED_AT' +} export type ExportFileSortingInput = { /** Specifies the direction in which to sort export file. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort export file by the selected field. */ - field: ExportFileSortField; + readonly field: ExportFileSortField; }; /** * Export gift cards to csv file. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: @@ -7419,32 +6569,31 @@ export type ExportFileSortingInput = { * - GIFT_CARD_EXPORT_COMPLETED (async): A notification for the exported file. */ export type ExportGiftCards = { - __typename?: 'ExportGiftCards'; - errors: Array; + readonly errors: ReadonlyArray; /** The newly created export file job which is responsible for export data. */ - exportFile?: Maybe; + readonly exportFile?: Maybe; }; export type ExportGiftCardsInput = { /** Type of exported file. */ - fileType: FileTypesEnum; + readonly fileType: FileTypesEnum; /** Filtering options for gift cards. */ - filter?: InputMaybe; + readonly filter?: InputMaybe; /** List of gift cards IDs to export. */ - ids?: InputMaybe>; + readonly ids?: InputMaybe>; /** Determine which gift cards should be exported. */ - scope: ExportScope; + readonly scope: ExportScope; }; export type ExportInfoInput = { /** List of attribute ids witch should be exported. */ - attributes?: InputMaybe>; + readonly attributes?: InputMaybe>; /** List of channels ids which should be exported. */ - channels?: InputMaybe>; + readonly channels?: InputMaybe>; /** List of product fields witch should be exported. */ - fields?: InputMaybe>; + readonly fields?: InputMaybe>; /** List of warehouse ids witch should be exported. */ - warehouses?: InputMaybe>; + readonly warehouses?: InputMaybe>; }; /** @@ -7457,34 +6606,34 @@ export type ExportInfoInput = { * - PRODUCT_EXPORT_COMPLETED (async): A notification for the exported file. */ export type ExportProducts = { - __typename?: 'ExportProducts'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - exportErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly exportErrors: ReadonlyArray; /** The newly created export file job which is responsible for export data. */ - exportFile?: Maybe; + readonly exportFile?: Maybe; }; export type ExportProductsInput = { /** Input with info about fields which should be exported. */ - exportInfo?: InputMaybe; + readonly exportInfo?: InputMaybe; /** Type of exported file. */ - fileType: FileTypesEnum; + readonly fileType: FileTypesEnum; /** Filtering options for products. */ - filter?: InputMaybe; + readonly filter?: InputMaybe; /** List of products IDs to export. */ - ids?: InputMaybe>; + readonly ids?: InputMaybe>; /** Determine which products should be exported. */ - scope: ExportScope; + readonly scope: ExportScope; }; -export type ExportScope = +export enum ExportScope { /** Export all products. */ - | 'ALL' + All = 'ALL', /** Export the filtered products. */ - | 'FILTER' + Filter = 'FILTER', /** Export products with given ids. */ - | 'IDS'; + Ids = 'IDS' +} /** * Export voucher codes to csv/xlsx file. @@ -7499,144 +6648,130 @@ export type ExportScope = * - VOUCHER_CODE_EXPORT_COMPLETED (async): A notification for the exported file. */ export type ExportVoucherCodes = { - __typename?: 'ExportVoucherCodes'; - errors: Array; + readonly errors: ReadonlyArray; /** The newly created export file job which is responsible for export data. */ - exportFile?: Maybe; + readonly exportFile?: Maybe; }; export type ExportVoucherCodesInput = { /** Type of exported file. */ - fileType: FileTypesEnum; + readonly fileType: FileTypesEnum; /** List of voucher code IDs to export. */ - ids?: InputMaybe>; + readonly ids?: InputMaybe>; /** The ID of the voucher. If provided, exports all codes belonging to the voucher. */ - voucherId?: InputMaybe; + readonly voucherId?: InputMaybe; }; /** External authentication plugin. */ export type ExternalAuthentication = { - __typename?: 'ExternalAuthentication'; /** ID of external authentication plugin. */ - id: Scalars['String']; + readonly id: Scalars['String']; /** Name of external authentication plugin. */ - name?: Maybe; + readonly name?: Maybe; }; /** Prepare external authentication URL for user by custom plugin. */ export type ExternalAuthenticationUrl = { - __typename?: 'ExternalAuthenticationUrl'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; /** The data returned by authentication plugin. */ - authenticationData?: Maybe; - errors: Array; + readonly authenticationData?: Maybe; + readonly errors: ReadonlyArray; }; /** Logout user by custom plugin. */ export type ExternalLogout = { - __typename?: 'ExternalLogout'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** The data returned by authentication plugin. */ - logoutData?: Maybe; + readonly logoutData?: Maybe; }; export type ExternalNotificationError = { - __typename?: 'ExternalNotificationError'; /** The error code. */ - code: ExternalNotificationErrorCodes; + readonly code: ExternalNotificationErrorCodes; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type ExternalNotificationErrorCodes = - | 'CHANNEL_INACTIVE' - | 'INVALID_MODEL_TYPE' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum ExternalNotificationErrorCodes { + ChannelInactive = 'CHANNEL_INACTIVE', + InvalidModelType = 'INVALID_MODEL_TYPE', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} -/** - * Trigger sending a notification with the notify plugin method. Serializes nodes provided as ids parameter and includes this data in the notification payload. - * - * Added in Saleor 3.1. - */ +/** Trigger sending a notification with the notify plugin method. Serializes nodes provided as ids parameter and includes this data in the notification payload. */ export type ExternalNotificationTrigger = { - __typename?: 'ExternalNotificationTrigger'; - errors: Array; + readonly errors: ReadonlyArray; }; export type ExternalNotificationTriggerInput = { /** External event type. This field is passed to a plugin as an event type. */ - externalEventType: Scalars['String']; + readonly externalEventType: Scalars['String']; /** Additional payload that will be merged with the one based on the business object ID. */ - extraPayload?: InputMaybe; + readonly extraPayload?: InputMaybe; /** The list of customers or orders node IDs that will be serialized and included in the notification payload. */ - ids: Array; + readonly ids: ReadonlyArray; }; /** Obtain external access tokens for user by custom plugin. */ export type ExternalObtainAccessTokens = { - __typename?: 'ExternalObtainAccessTokens'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; /** CSRF token required to re-generate external access token. */ - csrfToken?: Maybe; - errors: Array; + readonly csrfToken?: Maybe; + readonly errors: ReadonlyArray; /** The refresh token, required to re-generate external access token. */ - refreshToken?: Maybe; + readonly refreshToken?: Maybe; /** The token, required to authenticate. */ - token?: Maybe; + readonly token?: Maybe; /** A user instance. */ - user?: Maybe; + readonly user?: Maybe; }; /** Refresh user's access by custom plugin. */ export type ExternalRefresh = { - __typename?: 'ExternalRefresh'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; /** CSRF token required to re-generate external access token. */ - csrfToken?: Maybe; - errors: Array; + readonly csrfToken?: Maybe; + readonly errors: ReadonlyArray; /** The refresh token, required to re-generate external access token. */ - refreshToken?: Maybe; + readonly refreshToken?: Maybe; /** The token, required to authenticate. */ - token?: Maybe; + readonly token?: Maybe; /** A user instance. */ - user?: Maybe; + readonly user?: Maybe; }; /** Verify external authentication data by plugin. */ export type ExternalVerify = { - __typename?: 'ExternalVerify'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Determine if authentication data is valid or not. */ - isValid: Scalars['Boolean']; + readonly isValid: Scalars['Boolean']; /** User assigned to data. */ - user?: Maybe; + readonly user?: Maybe; /** External data. */ - verifyData?: Maybe; + readonly verifyData?: Maybe; }; export type File = { - __typename?: 'File'; /** Content type of the file. */ - contentType?: Maybe; + readonly contentType?: Maybe; /** The URL of the file. */ - url: Scalars['String']; + readonly url: Scalars['String']; }; -/** An enumeration. */ -export type FileTypesEnum = - | 'CSV' - | 'XLSX'; +export enum FileTypesEnum { + Csv = 'CSV', + Xlsx = 'XLSX' +} /** * Upload a file. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec @@ -7644,76 +6779,54 @@ export type FileTypesEnum = * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ export type FileUpload = { - __typename?: 'FileUpload'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - uploadErrors: Array; - uploadedFile?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly uploadErrors: ReadonlyArray; + readonly uploadedFile?: Maybe; }; /** Represents order fulfillment. */ export type Fulfillment = Node & ObjectWithMetadata & { - __typename?: 'Fulfillment'; /** Date and time when fulfillment was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** Sequence in which the fulfillments were created for an order. */ - fulfillmentOrder: Scalars['Int']; + readonly fulfillmentOrder: Scalars['Int']; /** ID of the fulfillment. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of lines for the fulfillment. */ - lines?: Maybe>; + readonly lines?: Maybe>; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; - /** - * Amount of refunded shipping price. - * - * Added in Saleor 3.14. */ - shippingRefundedAmount?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** Amount of refunded shipping price. */ + readonly shippingRefundedAmount?: Maybe; /** Status of fulfillment. */ - status: FulfillmentStatus; + readonly status: FulfillmentStatus; /** User-friendly fulfillment status. */ - statusDisplay?: Maybe; - /** - * Total refunded amount assigned to this fulfillment. - * - * Added in Saleor 3.14. - */ - totalRefundedAmount?: Maybe; + readonly statusDisplay?: Maybe; + /** Total refunded amount assigned to this fulfillment. */ + readonly totalRefundedAmount?: Maybe; /** Fulfillment tracking number. */ - trackingNumber: Scalars['String']; + readonly trackingNumber: Scalars['String']; /** Warehouse from fulfillment was fulfilled. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; @@ -7725,7 +6838,7 @@ export type FulfillmentMetafieldArgs = { /** Represents order fulfillment. */ export type FulfillmentMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -7737,55 +6850,43 @@ export type FulfillmentPrivateMetafieldArgs = { /** Represents order fulfillment. */ export type FulfillmentPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** * Approve existing fulfillment. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_ORDERS. * * Triggers the following webhook events: * - FULFILLMENT_APPROVED (async): Fulfillment is approved. */ export type FulfillmentApprove = { - __typename?: 'FulfillmentApprove'; - errors: Array; + readonly errors: ReadonlyArray; /** An approved fulfillment. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Order which fulfillment was approved. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; -/** - * Event sent when fulfillment is approved. - * - * Added in Saleor 3.7. - */ +/** Event sent when fulfillment is approved. */ export type FulfillmentApproved = Event & { - __typename?: 'FulfillmentApproved'; /** The fulfillment the event relates to. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; - /** - * If true, send a notification to the customer. - * - * Added in Saleor 3.16. - */ - notifyCustomer: Scalars['Boolean']; + readonly issuingPrincipal?: Maybe; + /** If true, send a notification to the customer. */ + readonly notifyCustomer: Scalars['Boolean']; /** The order the fulfillment belongs to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -7794,99 +6895,78 @@ export type FulfillmentApproved = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type FulfillmentCancel = { - __typename?: 'FulfillmentCancel'; - errors: Array; + readonly errors: ReadonlyArray; /** A canceled fulfillment. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Order which fulfillment was cancelled. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type FulfillmentCancelInput = { /** ID of a warehouse where items will be restocked. Optional when fulfillment is in WAITING_FOR_APPROVAL state. */ - warehouseId?: InputMaybe; + readonly warehouseId?: InputMaybe; }; -/** - * Event sent when fulfillment is canceled. - * - * Added in Saleor 3.4. - */ +/** Event sent when fulfillment is canceled. */ export type FulfillmentCanceled = Event & { - __typename?: 'FulfillmentCanceled'; /** The fulfillment the event relates to. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the fulfillment belongs to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when new fulfillment is created. - * - * Added in Saleor 3.4. - */ +/** Event sent when new fulfillment is created. */ export type FulfillmentCreated = Event & { - __typename?: 'FulfillmentCreated'; /** The fulfillment the event relates to. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; - /** - * If true, the app should send a notification to the customer. - * - * Added in Saleor 3.16. - */ - notifyCustomer: Scalars['Boolean']; + readonly issuingPrincipal?: Maybe; + /** If true, the app should send a notification to the customer. */ + readonly notifyCustomer: Scalars['Boolean']; /** The order the fulfillment belongs to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Represents line of the fulfillment. */ export type FulfillmentLine = Node & { - __typename?: 'FulfillmentLine'; /** ID of the fulfillment line. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The order line to which the fulfillment line is related. */ - orderLine?: Maybe; + readonly orderLine?: Maybe; /** The number of items included in the fulfillment line. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; }; -/** - * Event sent when fulfillment metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when fulfillment metadata is updated. */ export type FulfillmentMetadataUpdated = Event & { - __typename?: 'FulfillmentMetadataUpdated'; /** The fulfillment the event relates to. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the fulfillment belongs to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -7895,14 +6975,13 @@ export type FulfillmentMetadataUpdated = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type FulfillmentRefundProducts = { - __typename?: 'FulfillmentRefundProducts'; - errors: Array; + readonly errors: ReadonlyArray; /** A refunded fulfillment. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Order which fulfillment was refunded. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; /** @@ -7911,49 +6990,43 @@ export type FulfillmentRefundProducts = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type FulfillmentReturnProducts = { - __typename?: 'FulfillmentReturnProducts'; - errors: Array; + readonly errors: ReadonlyArray; /** Order which fulfillment was returned. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; /** A replace fulfillment. */ - replaceFulfillment?: Maybe; + readonly replaceFulfillment?: Maybe; /** A draft order which was created for products with replace flag. */ - replaceOrder?: Maybe; + readonly replaceOrder?: Maybe; /** A return fulfillment. */ - returnFulfillment?: Maybe; + readonly returnFulfillment?: Maybe; }; -/** An enumeration. */ -export type FulfillmentStatus = - | 'CANCELED' - | 'FULFILLED' - | 'REFUNDED' - | 'REFUNDED_AND_RETURNED' - | 'REPLACED' - | 'RETURNED' - | 'WAITING_FOR_APPROVAL'; +export enum FulfillmentStatus { + Canceled = 'CANCELED', + Fulfilled = 'FULFILLED', + Refunded = 'REFUNDED', + RefundedAndReturned = 'REFUNDED_AND_RETURNED', + Replaced = 'REPLACED', + Returned = 'RETURNED', + WaitingForApproval = 'WAITING_FOR_APPROVAL' +} -/** - * Event sent when the tracking number is updated. - * - * Added in Saleor 3.16. - */ +/** Event sent when the tracking number is updated. */ export type FulfillmentTrackingNumberUpdated = Event & { - __typename?: 'FulfillmentTrackingNumberUpdated'; /** The fulfillment the event relates to. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the fulfillment belongs to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -7965,167 +7038,128 @@ export type FulfillmentTrackingNumberUpdated = Event & { * - FULFILLMENT_TRACKING_NUMBER_UPDATED (async): Fulfillment tracking number is updated. */ export type FulfillmentUpdateTracking = { - __typename?: 'FulfillmentUpdateTracking'; - errors: Array; + readonly errors: ReadonlyArray; /** A fulfillment with updated tracking. */ - fulfillment?: Maybe; + readonly fulfillment?: Maybe; /** Order for which fulfillment was updated. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type FulfillmentUpdateTrackingInput = { /** If true, send an email notification to the customer. */ - notifyCustomer?: InputMaybe; + readonly notifyCustomer?: InputMaybe; /** Fulfillment tracking number. */ - trackingNumber?: InputMaybe; + readonly trackingNumber?: InputMaybe; }; /** Payment gateway client configuration key and value pair. */ export type GatewayConfigLine = { - __typename?: 'GatewayConfigLine'; /** Gateway config key. */ - field: Scalars['String']; + readonly field: Scalars['String']; /** Gateway config value for key. */ - value?: Maybe; + readonly value?: Maybe; }; /** A gift card is a prepaid electronic payment card accepted in stores. They can be used during checkout by providing a valid gift card codes. */ export type GiftCard = Node & ObjectWithMetadata & { - __typename?: 'GiftCard'; /** * App which created the gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_APPS, OWNER. */ - app?: Maybe; - /** - * Slug of the channel where the gift card was bought. - * - * Added in Saleor 3.1. - */ - boughtInChannel?: Maybe; + readonly app?: Maybe; + /** Slug of the channel where the gift card was bought. */ + readonly boughtInChannel?: Maybe; /** * Gift card code. It can be fetched both by a staff member with 'MANAGE_GIFT_CARD' when gift card hasn't been used yet or a user who bought or issued the gift card. * * Requires one of the following permissions: MANAGE_GIFT_CARD, OWNER. */ - code: Scalars['String']; + readonly code: Scalars['String']; /** Date and time when gift card was created. */ - created: Scalars['DateTime']; - /** - * The user who bought or issued a gift card. - * - * Added in Saleor 3.1. - */ - createdBy?: Maybe; + readonly created: Scalars['DateTime']; + /** The user who bought or issued a gift card. */ + readonly createdBy?: Maybe; /** * Email address of the user who bought or issued gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_USERS, OWNER. */ - createdByEmail?: Maybe; - currentBalance: Money; + readonly createdByEmail?: Maybe; + readonly currentBalance: Money; /** Code in format which allows displaying in a user interface. */ - displayCode: Scalars['String']; + readonly displayCode: Scalars['String']; /** * End date of gift card. - * @deprecated This field will be removed in Saleor 4.0. Use `expiryDate` field instead. + * @deprecated Use `expiryDate` field instead. */ - endDate?: Maybe; + readonly endDate?: Maybe; /** * List of events associated with the gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. */ - events: Array; + readonly events: ReadonlyArray; /** Expiry date of the gift card. */ - expiryDate?: Maybe; + readonly expiryDate?: Maybe; /** ID of the gift card. */ - id: Scalars['ID']; - initialBalance: Money; - isActive: Scalars['Boolean']; + readonly id: Scalars['ID']; + readonly initialBalance: Money; + readonly isActive: Scalars['Boolean']; /** Last 4 characters of gift card code. */ - last4CodeChars: Scalars['String']; + readonly last4CodeChars: Scalars['String']; /** Date and time when gift card was last used. */ - lastUsedOn?: Maybe; + readonly lastUsedOn?: Maybe; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; - /** - * Related gift card product. - * - * Added in Saleor 3.1. */ - product?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** Related gift card product. */ + readonly product?: Maybe; /** * Start date of gift card. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - startDate?: Maybe; + readonly startDate?: Maybe; /** * The gift card tag. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. */ - tags: Array; + readonly tags: ReadonlyArray; /** * The customer who used a gift card. - * - * Added in Saleor 3.1. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - usedBy?: Maybe; + readonly usedBy?: Maybe; /** * Email address of the customer who used a gift card. - * - * Added in Saleor 3.1. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - usedByEmail?: Maybe; + readonly usedByEmail?: Maybe; /** * The customer who bought a gift card. - * @deprecated This field will be removed in Saleor 4.0. Use `createdBy` field instead. + * @deprecated Use `createdBy` field instead. */ - user?: Maybe; + readonly user?: Maybe; }; @@ -8143,7 +7177,7 @@ export type GiftCardMetafieldArgs = { /** A gift card is a prepaid electronic payment card accepted in stores. They can be used during checkout by providing a valid gift card codes. */ export type GiftCardMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -8155,7 +7189,7 @@ export type GiftCardPrivateMetafieldArgs = { /** A gift card is a prepaid electronic payment card accepted in stores. They can be used during checkout by providing a valid gift card codes. */ export type GiftCardPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** @@ -8167,60 +7201,51 @@ export type GiftCardPrivateMetafieldsArgs = { * - GIFT_CARD_STATUS_CHANGED (async): A gift card was activated. */ export type GiftCardActivate = { - __typename?: 'GiftCardActivate'; - errors: Array; + readonly errors: ReadonlyArray; /** Activated gift card. */ - giftCard?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - giftCardErrors: Array; + readonly giftCard?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly giftCardErrors: ReadonlyArray; }; /** * Adds note to the gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_UPDATED (async): A gift card was updated. */ export type GiftCardAddNote = { - __typename?: 'GiftCardAddNote'; - errors: Array; + readonly errors: ReadonlyArray; /** Gift card note created. */ - event?: Maybe; + readonly event?: Maybe; /** Gift card with the note added. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; }; export type GiftCardAddNoteInput = { /** Note message. */ - message: Scalars['String']; + readonly message: Scalars['String']; }; /** * Activate gift cards. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_STATUS_CHANGED (async): A gift card was activated. */ export type GiftCardBulkActivate = { - __typename?: 'GiftCardBulkActivate'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; /** * Create gift cards. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: @@ -8228,76 +7253,67 @@ export type GiftCardBulkActivate = { * - NOTIFY_USER (async): A notification for created gift card. */ export type GiftCardBulkCreate = { - __typename?: 'GiftCardBulkCreate'; /** Returns how many objects were created. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of created gift cards. */ - giftCards: Array; + readonly giftCards: ReadonlyArray; }; export type GiftCardBulkCreateInput = { /** Balance of the gift card. */ - balance: PriceInput; + readonly balance: PriceInput; /** The number of cards to issue. */ - count: Scalars['Int']; + readonly count: Scalars['Int']; /** The gift card expiry date. */ - expiryDate?: InputMaybe; + readonly expiryDate?: InputMaybe; /** Determine if gift card is active. */ - isActive: Scalars['Boolean']; + readonly isActive: Scalars['Boolean']; /** The gift card tags. */ - tags?: InputMaybe>; + readonly tags?: InputMaybe>; }; /** * Deactivate gift cards. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_STATUS_CHANGED (async): A gift card was deactivated. */ export type GiftCardBulkDeactivate = { - __typename?: 'GiftCardBulkDeactivate'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; /** * Delete gift cards. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_DELETED (async): A gift card was deleted. */ export type GiftCardBulkDelete = { - __typename?: 'GiftCardBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; export type GiftCardCountableConnection = { - __typename?: 'GiftCardCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type GiftCardCountableEdge = { - __typename?: 'GiftCardCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: GiftCard; + readonly node: GiftCard; }; /** @@ -8310,85 +7326,72 @@ export type GiftCardCountableEdge = { * - NOTIFY_USER (async): A notification for created gift card. */ export type GiftCardCreate = { - __typename?: 'GiftCardCreate'; - errors: Array; - giftCard?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - giftCardErrors: Array; + readonly errors: ReadonlyArray; + readonly giftCard?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly giftCardErrors: ReadonlyArray; }; export type GiftCardCreateInput = { - /** - * The gift card tags to add. - * - * Added in Saleor 3.1. - */ - addTags?: InputMaybe>; + /** The gift card tags to add. */ + readonly addTags?: InputMaybe>; /** Balance of the gift card. */ - balance: PriceInput; - /** - * Slug of a channel from which the email should be sent. - * - * Added in Saleor 3.1. - */ - channel?: InputMaybe; + readonly balance: PriceInput; + /** Slug of a channel from which the email should be sent. */ + readonly channel?: InputMaybe; /** * Code to use the gift card. - * - * DEPRECATED: this field will be removed in Saleor 4.0. The code is now auto generated. + * @deprecated The code is now auto generated. */ - code?: InputMaybe; + readonly code?: InputMaybe; /** * End date of the gift card in ISO 8601 format. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `expiryDate` from `expirySettings` instead. + * @deprecated Use `expiryDate` from `expirySettings` instead. */ - endDate?: InputMaybe; + readonly endDate?: InputMaybe; + /** The gift card expiry date. */ + readonly expiryDate?: InputMaybe; + /** Determine if gift card is active. */ + readonly isActive: Scalars['Boolean']; /** - * The gift card expiry date. + * Gift Card public metadata. * - * Added in Saleor 3.1. - */ - expiryDate?: InputMaybe; - /** - * Determine if gift card is active. + * Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.1. + * Warning: never store sensitive information, including financial data such as credit card details. */ - isActive: Scalars['Boolean']; + readonly metadata?: InputMaybe>; + /** The gift card note from the staff member. */ + readonly note?: InputMaybe; /** - * The gift card note from the staff member. + * Gift Card private metadata. * - * Added in Saleor 3.1. + * Added in Saleor 3.21. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. */ - note?: InputMaybe; + readonly privateMetadata?: InputMaybe>; /** * Start date of the gift card in ISO 8601 format. - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - startDate?: InputMaybe; + readonly startDate?: InputMaybe; /** Email of the customer to whom gift card will be sent. */ - userEmail?: InputMaybe; + readonly userEmail?: InputMaybe; }; -/** - * Event sent when new gift card is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new gift card is created. */ export type GiftCardCreated = Event & { - __typename?: 'GiftCardCreated'; /** The gift card the event relates to. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -8400,275 +7403,237 @@ export type GiftCardCreated = Event & { * - GIFT_CARD_STATUS_CHANGED (async): A gift card was deactivated. */ export type GiftCardDeactivate = { - __typename?: 'GiftCardDeactivate'; - errors: Array; + readonly errors: ReadonlyArray; /** Deactivated gift card. */ - giftCard?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - giftCardErrors: Array; + readonly giftCard?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly giftCardErrors: ReadonlyArray; }; /** * Delete gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_DELETED (async): A gift card was deleted. */ export type GiftCardDelete = { - __typename?: 'GiftCardDelete'; - errors: Array; - giftCard?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - giftCardErrors: Array; + readonly errors: ReadonlyArray; + readonly giftCard?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly giftCardErrors: ReadonlyArray; }; -/** - * Event sent when gift card is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when gift card is deleted. */ export type GiftCardDeleted = Event & { - __typename?: 'GiftCardDeleted'; /** The gift card the event relates to. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type GiftCardError = { - __typename?: 'GiftCardError'; /** The error code. */ - code: GiftCardErrorCode; + readonly code: GiftCardErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of tag values that cause the error. */ - tags?: Maybe>; -}; - -/** An enumeration. */ -export type GiftCardErrorCode = - | 'ALREADY_EXISTS' - | 'DUPLICATED_INPUT_ITEM' - | 'EXPIRED_GIFT_CARD' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; + readonly tags?: Maybe>; +}; + +export enum GiftCardErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + ExpiredGiftCard = 'EXPIRED_GIFT_CARD', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} -/** - * History log of the gift card. - * - * Added in Saleor 3.1. - */ +/** History log of the gift card. */ export type GiftCardEvent = Node & { - __typename?: 'GiftCardEvent'; /** App that performed the action. Requires one of the following permissions: MANAGE_APPS, OWNER. */ - app?: Maybe; + readonly app?: Maybe; /** The gift card balance. */ - balance?: Maybe; + readonly balance?: Maybe; /** Date when event happened at in ISO 8601 format. */ - date?: Maybe; + readonly date?: Maybe; /** Email of the customer. */ - email?: Maybe; + readonly email?: Maybe; /** The gift card expiry date. */ - expiryDate?: Maybe; + readonly expiryDate?: Maybe; /** ID of the event associated with a gift card. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Content of the event. */ - message?: Maybe; + readonly message?: Maybe; /** Previous gift card expiry date. */ - oldExpiryDate?: Maybe; + readonly oldExpiryDate?: Maybe; /** The list of old gift card tags. */ - oldTags?: Maybe>; + readonly oldTags?: Maybe>; /** The order ID where gift card was used or bought. */ - orderId?: Maybe; + readonly orderId?: Maybe; /** User-friendly number of an order where gift card was used or bought. */ - orderNumber?: Maybe; + readonly orderNumber?: Maybe; /** The list of gift card tags. */ - tags?: Maybe>; + readonly tags?: Maybe>; /** Gift card event type. */ - type?: Maybe; + readonly type?: Maybe; /** User who performed the action. Requires one of the following permissions: MANAGE_USERS, MANAGE_STAFF, OWNER. */ - user?: Maybe; + readonly user?: Maybe; }; export type GiftCardEventBalance = { - __typename?: 'GiftCardEventBalance'; /** Current balance of the gift card. */ - currentBalance: Money; + readonly currentBalance: Money; /** Initial balance of the gift card. */ - initialBalance?: Maybe; + readonly initialBalance?: Maybe; /** Previous current balance of the gift card. */ - oldCurrentBalance?: Maybe; + readonly oldCurrentBalance?: Maybe; /** Previous initial balance of the gift card. */ - oldInitialBalance?: Maybe; + readonly oldInitialBalance?: Maybe; }; export type GiftCardEventFilterInput = { - orders?: InputMaybe>; - type?: InputMaybe; -}; - -/** An enumeration. */ -export type GiftCardEventsEnum = - | 'ACTIVATED' - | 'BALANCE_RESET' - | 'BOUGHT' - | 'DEACTIVATED' - | 'EXPIRY_DATE_UPDATED' - | 'ISSUED' - | 'NOTE_ADDED' - | 'RESENT' - | 'SENT_TO_CUSTOMER' - | 'TAGS_UPDATED' - | 'UPDATED' - | 'USED_IN_ORDER'; + readonly orders?: InputMaybe>; + readonly type?: InputMaybe; +}; + +export enum GiftCardEventsEnum { + Activated = 'ACTIVATED', + BalanceReset = 'BALANCE_RESET', + Bought = 'BOUGHT', + Deactivated = 'DEACTIVATED', + ExpiryDateUpdated = 'EXPIRY_DATE_UPDATED', + Issued = 'ISSUED', + NoteAdded = 'NOTE_ADDED', + Resent = 'RESENT', + SentToCustomer = 'SENT_TO_CUSTOMER', + TagsUpdated = 'TAGS_UPDATED', + Updated = 'UPDATED', + UsedInOrder = 'USED_IN_ORDER' +} -/** - * Event sent when gift card export is completed. - * - * Added in Saleor 3.16. - */ +/** Event sent when gift card export is completed. */ export type GiftCardExportCompleted = Event & { - __typename?: 'GiftCardExportCompleted'; /** The export file for gift cards. */ - export?: Maybe; + readonly export?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type GiftCardFilterInput = { - code?: InputMaybe; - createdByEmail?: InputMaybe; - currency?: InputMaybe; - currentBalance?: InputMaybe; - initialBalance?: InputMaybe; - isActive?: InputMaybe; - metadata?: InputMaybe>; - products?: InputMaybe>; - tags?: InputMaybe>; - used?: InputMaybe; - usedBy?: InputMaybe>; -}; - -/** - * Event sent when gift card metadata is updated. - * - * Added in Saleor 3.8. - */ + readonly code?: InputMaybe; + readonly createdByEmail?: InputMaybe; + readonly currency?: InputMaybe; + readonly currentBalance?: InputMaybe; + readonly initialBalance?: InputMaybe; + readonly isActive?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly products?: InputMaybe>; + readonly tags?: InputMaybe>; + readonly used?: InputMaybe; + readonly usedBy?: InputMaybe>; +}; + +/** Event sent when gift card metadata is updated. */ export type GiftCardMetadataUpdated = Event & { - __typename?: 'GiftCardMetadataUpdated'; /** The gift card the event relates to. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Resend a gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - NOTIFY_USER (async): A notification for gift card resend. */ export type GiftCardResend = { - __typename?: 'GiftCardResend'; - errors: Array; + readonly errors: ReadonlyArray; /** Gift card which has been sent. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; }; export type GiftCardResendInput = { /** Slug of a channel from which the email should be sent. */ - channel: Scalars['String']; + readonly channel: Scalars['String']; /** Email to which gift card should be send. */ - email?: InputMaybe; + readonly email?: InputMaybe; /** ID of a gift card to resend. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; }; -/** - * Event sent when gift card is e-mailed. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when gift card is e-mailed. */ export type GiftCardSent = Event & { - __typename?: 'GiftCardSent'; /** Slug of a channel for which this gift card email was sent. */ - channel?: Maybe; + readonly channel?: Maybe; /** The gift card the event relates to. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** E-mail address to which gift card was sent. */ - sentToEmail?: Maybe; + readonly sentToEmail?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Gift card related settings from site settings. */ export type GiftCardSettings = { - __typename?: 'GiftCardSettings'; /** The gift card expiry period settings. */ - expiryPeriod?: Maybe; + readonly expiryPeriod?: Maybe; /** The gift card expiry type settings. */ - expiryType: GiftCardSettingsExpiryTypeEnum; + readonly expiryType: GiftCardSettingsExpiryTypeEnum; }; export type GiftCardSettingsError = { - __typename?: 'GiftCardSettingsError'; /** The error code. */ - code: GiftCardSettingsErrorCode; + readonly code: GiftCardSettingsErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type GiftCardSettingsErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'REQUIRED'; +export enum GiftCardSettingsErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + Required = 'REQUIRED' +} -/** An enumeration. */ -export type GiftCardSettingsExpiryTypeEnum = - | 'EXPIRY_PERIOD' - | 'NEVER_EXPIRE'; +export enum GiftCardSettingsExpiryTypeEnum { + ExpiryPeriod = 'EXPIRY_PERIOD', + NeverExpire = 'NEVER_EXPIRE' +} /** * Update gift card settings. @@ -8676,91 +7641,75 @@ export type GiftCardSettingsExpiryTypeEnum = * Requires one of the following permissions: MANAGE_GIFT_CARD. */ export type GiftCardSettingsUpdate = { - __typename?: 'GiftCardSettingsUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Gift card settings. */ - giftCardSettings?: Maybe; + readonly giftCardSettings?: Maybe; }; export type GiftCardSettingsUpdateInput = { /** Defines gift card expiry period. */ - expiryPeriod?: InputMaybe; + readonly expiryPeriod?: InputMaybe; /** Defines gift card default expiry settings. */ - expiryType?: InputMaybe; + readonly expiryType?: InputMaybe; }; -export type GiftCardSortField = - /** - * Sort gift cards by created at. - * - * Added in Saleor 3.8. - */ - | 'CREATED_AT' +export enum GiftCardSortField { + /** Sort gift cards by created at. */ + CreatedAt = 'CREATED_AT', /** Sort gift cards by current balance. */ - | 'CURRENT_BALANCE' + CurrentBalance = 'CURRENT_BALANCE', /** Sort gift cards by product. */ - | 'PRODUCT' + Product = 'PRODUCT', /** Sort gift cards by used by. */ - | 'USED_BY'; + UsedBy = 'USED_BY' +} export type GiftCardSortingInput = { /** Specifies the direction in which to sort gift cards. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort gift cards by the selected field. */ - field: GiftCardSortField; + readonly field: GiftCardSortField; }; -/** - * Event sent when gift card status has changed. - * - * Added in Saleor 3.2. - */ +/** Event sent when gift card status has changed. */ export type GiftCardStatusChanged = Event & { - __typename?: 'GiftCardStatusChanged'; /** The gift card the event relates to. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * The gift card tag. - * - * Added in Saleor 3.1. - */ +/** The gift card tag. */ export type GiftCardTag = Node & { - __typename?: 'GiftCardTag'; /** ID of the tag associated with a gift card. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the tag associated with a gift card. */ - name: Scalars['String']; + readonly name: Scalars['String']; }; export type GiftCardTagCountableConnection = { - __typename?: 'GiftCardTagCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type GiftCardTagCountableEdge = { - __typename?: 'GiftCardTagCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: GiftCardTag; + readonly node: GiftCardTag; }; export type GiftCardTagFilterInput = { - search?: InputMaybe; + readonly search?: InputMaybe; }; /** @@ -8772,218 +7721,172 @@ export type GiftCardTagFilterInput = { * - GIFT_CARD_UPDATED (async): A gift card was updated. */ export type GiftCardUpdate = { - __typename?: 'GiftCardUpdate'; - errors: Array; - giftCard?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - giftCardErrors: Array; + readonly errors: ReadonlyArray; + readonly giftCard?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly giftCardErrors: ReadonlyArray; }; export type GiftCardUpdateInput = { + /** The gift card tags to add. */ + readonly addTags?: InputMaybe>; + /** The gift card balance amount. */ + readonly balanceAmount?: InputMaybe; /** - * The gift card tags to add. - * - * Added in Saleor 3.1. + * End date of the gift card in ISO 8601 format. + * @deprecated Use `expiryDate` from `expirySettings` instead. */ - addTags?: InputMaybe>; + readonly endDate?: InputMaybe; + /** The gift card expiry date. */ + readonly expiryDate?: InputMaybe; /** - * The gift card balance amount. + * Gift Card public metadata. * - * Added in Saleor 3.1. - */ - balanceAmount?: InputMaybe; - /** - * End date of the gift card in ISO 8601 format. + * Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `expiryDate` from `expirySettings` instead. + * Warning: never store sensitive information, including financial data such as credit card details. */ - endDate?: InputMaybe; + readonly metadata?: InputMaybe>; /** - * The gift card expiry date. + * Gift Card private metadata. * - * Added in Saleor 3.1. - */ - expiryDate?: InputMaybe; - /** - * The gift card tags to remove. + * Added in Saleor 3.21. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.1. + * Warning: never store sensitive information, including financial data such as credit card details. */ - removeTags?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; + /** The gift card tags to remove. */ + readonly removeTags?: InputMaybe>; /** * Start date of the gift card in ISO 8601 format. - * - * DEPRECATED: this field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - startDate?: InputMaybe; + readonly startDate?: InputMaybe; }; -/** - * Event sent when gift card is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when gift card is updated. */ export type GiftCardUpdated = Event & { - __typename?: 'GiftCardUpdated'; /** The gift card the event relates to. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Define the filtering options for foreign key fields. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Define the filtering options for foreign key fields. */ export type GlobalIdFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; }; /** Represents permission group data. */ export type Group = Node & { - __typename?: 'Group'; - /** - * List of channels the group has access to. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - accessibleChannels?: Maybe>; + /** List of channels the group has access to. */ + readonly accessibleChannels?: Maybe>; /** The ID of the group. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The name of the group. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of group permissions */ - permissions?: Maybe>; - /** - * Determine if the group have restricted access to channels. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - restrictedAccessToChannels: Scalars['Boolean']; + readonly permissions?: Maybe>; + /** Determine if the group have restricted access to channels. */ + readonly restrictedAccessToChannels: Scalars['Boolean']; /** True, if the currently authenticated user has rights to manage a group. */ - userCanManage: Scalars['Boolean']; + readonly userCanManage: Scalars['Boolean']; /** * List of group users * * Requires one of the following permissions: MANAGE_STAFF. */ - users?: Maybe>; + readonly users?: Maybe>; }; export type GroupCountableConnection = { - __typename?: 'GroupCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type GroupCountableEdge = { - __typename?: 'GroupCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Group; + readonly node: Group; }; /** Thumbnail formats for icon images. */ -export type IconThumbnailFormatEnum = - | 'ORIGINAL' - | 'WEBP'; +export enum IconThumbnailFormatEnum { + Original = 'ORIGINAL', + Webp = 'WEBP' +} /** Represents an image. */ export type Image = { - __typename?: 'Image'; /** Alt text for an image. */ - alt?: Maybe; + readonly alt?: Maybe; /** The URL of the image. */ - url: Scalars['String']; + readonly url: Scalars['String']; }; export type IntRangeInput = { /** Value greater than or equal to. */ - gte?: InputMaybe; + readonly gte?: InputMaybe; /** Value less than or equal to. */ - lte?: InputMaybe; + readonly lte?: InputMaybe; }; /** Represents an Invoice. */ export type Invoice = Job & Node & ObjectWithMetadata & { - __typename?: 'Invoice'; /** Date and time at which invoice was created. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** * URL to view an invoice. - * @deprecated This field will be removed in Saleor 4.0. Use `url` field.This field will be removed in 4.0 + * @deprecated Use `url` field. */ - externalUrl?: Maybe; + readonly externalUrl?: Maybe; /** The ID of the object. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Message associated with an invoice. */ - message?: Maybe; + readonly message?: Maybe; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Invoice number. */ - number?: Maybe; - /** - * Order related to the invoice. - * - * Added in Saleor 3.10. - */ - order?: Maybe; + readonly number?: Maybe; + /** Order related to the invoice. */ + readonly order?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Job status. */ - status: JobStatusEnum; + readonly status: JobStatusEnum; /** Date and time at which invoice was updated. */ - updatedAt: Scalars['DateTime']; - /** URL to view/download an invoice. This can be an internal URL if the Invoicing Plugin was used or an external URL if it has been provided. */ - url?: Maybe; + readonly updatedAt: Scalars['DateTime']; + /** URL to view/download an invoice. */ + readonly url?: Maybe; }; @@ -8995,7 +7898,7 @@ export type InvoiceMetafieldArgs = { /** Represents an Invoice. */ export type InvoiceMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -9007,7 +7910,7 @@ export type InvoicePrivateMetafieldArgs = { /** Represents an Invoice. */ export type InvoicePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** @@ -9016,30 +7919,29 @@ export type InvoicePrivateMetafieldsArgs = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type InvoiceCreate = { - __typename?: 'InvoiceCreate'; - errors: Array; - invoice?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - invoiceErrors: Array; + readonly errors: ReadonlyArray; + readonly invoice?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly invoiceErrors: ReadonlyArray; }; export type InvoiceCreateInput = { /** - * Fields required to update the invoice metadata. + * Fields required to update the invoice metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Invoice number. */ - number: Scalars['String']; + readonly number: Scalars['String']; /** - * Fields required to update the invoice private metadata. + * Fields required to update the invoice private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** URL of an invoice to download. */ - url: Scalars['String']; + readonly url: Scalars['String']; }; /** @@ -9048,58 +7950,47 @@ export type InvoiceCreateInput = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type InvoiceDelete = { - __typename?: 'InvoiceDelete'; - errors: Array; - invoice?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - invoiceErrors: Array; + readonly errors: ReadonlyArray; + readonly invoice?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly invoiceErrors: ReadonlyArray; }; -/** - * Event sent when invoice is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when invoice is deleted. */ export type InvoiceDeleted = Event & { - __typename?: 'InvoiceDeleted'; /** The invoice the event relates to. */ - invoice?: Maybe; + readonly invoice?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; - /** - * Order related to the invoice. - * - * Added in Saleor 3.10. - */ - order?: Maybe; + readonly issuingPrincipal?: Maybe; + /** Order related to the invoice. */ + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type InvoiceError = { - __typename?: 'InvoiceError'; /** The error code. */ - code: InvoiceErrorCode; + readonly code: InvoiceErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; -}; - -/** An enumeration. */ -export type InvoiceErrorCode = - | 'EMAIL_NOT_SET' - | 'INVALID_STATUS' - | 'NOT_FOUND' - | 'NOT_READY' - | 'NO_INVOICE_PLUGIN' - | 'NUMBER_NOT_SET' - | 'REQUIRED' - | 'URL_NOT_SET'; + readonly message?: Maybe; +}; + +export enum InvoiceErrorCode { + EmailNotSet = 'EMAIL_NOT_SET', + InvalidStatus = 'INVALID_STATUS', + NotFound = 'NOT_FOUND', + NotReady = 'NOT_READY', + NoInvoicePlugin = 'NO_INVOICE_PLUGIN', + NumberNotSet = 'NUMBER_NOT_SET', + Required = 'REQUIRED', + UrlNotSet = 'URL_NOT_SET' +} /** * Request an invoice for the order using plugin. @@ -9110,13 +8001,12 @@ export type InvoiceErrorCode = * - INVOICE_REQUESTED (async): An invoice was requested. */ export type InvoiceRequest = { - __typename?: 'InvoiceRequest'; - errors: Array; - invoice?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - invoiceErrors: Array; + readonly errors: ReadonlyArray; + readonly invoice?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly invoiceErrors: ReadonlyArray; /** Order related to an invoice. */ - order?: Maybe; + readonly order?: Maybe; }; /** @@ -9128,36 +8018,26 @@ export type InvoiceRequest = { * - INVOICE_DELETED (async): An invoice was requested to delete. */ export type InvoiceRequestDelete = { - __typename?: 'InvoiceRequestDelete'; - errors: Array; - invoice?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - invoiceErrors: Array; + readonly errors: ReadonlyArray; + readonly invoice?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly invoiceErrors: ReadonlyArray; }; -/** - * Event sent when invoice is requested. - * - * Added in Saleor 3.2. - */ +/** Event sent when invoice is requested. */ export type InvoiceRequested = Event & { - __typename?: 'InvoiceRequested'; /** The invoice the event relates to. */ - invoice?: Maybe; + readonly invoice?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; - /** - * Order related to the invoice. - * - * Added in Saleor 3.10. - */ - order: Order; + readonly issuingPrincipal?: Maybe; + /** Order related to the invoice. */ + readonly order: Order; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -9170,36 +8050,26 @@ export type InvoiceRequested = Event & { * - NOTIFY_USER (async): A notification for invoice send */ export type InvoiceSendNotification = { - __typename?: 'InvoiceSendNotification'; - errors: Array; - invoice?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - invoiceErrors: Array; + readonly errors: ReadonlyArray; + readonly invoice?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly invoiceErrors: ReadonlyArray; }; -/** - * Event sent when invoice is sent. - * - * Added in Saleor 3.2. - */ +/** Event sent when invoice is sent. */ export type InvoiceSent = Event & { - __typename?: 'InvoiceSent'; /** The invoice the event relates to. */ - invoice?: Maybe; + readonly invoice?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; - /** - * Order related to the invoice. - * - * Added in Saleor 3.10. - */ - order?: Maybe; + readonly issuingPrincipal?: Maybe; + /** Order related to the invoice. */ + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -9208,949 +8078,914 @@ export type InvoiceSent = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type InvoiceUpdate = { - __typename?: 'InvoiceUpdate'; - errors: Array; - invoice?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - invoiceErrors: Array; + readonly errors: ReadonlyArray; + readonly invoice?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly invoiceErrors: ReadonlyArray; }; export type IssuingPrincipal = App | User; export type Job = { /** Created date time of job in ISO 8601 format. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** Job message. */ - message?: Maybe; + readonly message?: Maybe; /** Job status. */ - status: JobStatusEnum; + readonly status: JobStatusEnum; /** Date time of job last update in ISO 8601 format. */ - updatedAt: Scalars['DateTime']; -}; - -/** An enumeration. */ -export type JobStatusEnum = - | 'DELETED' - | 'FAILED' - | 'PENDING' - | 'SUCCESS'; - -/** An enumeration. */ -export type LanguageCodeEnum = - | 'AF' - | 'AF_NA' - | 'AF_ZA' - | 'AGQ' - | 'AGQ_CM' - | 'AK' - | 'AK_GH' - | 'AM' - | 'AM_ET' - | 'AR' - | 'AR_AE' - | 'AR_BH' - | 'AR_DJ' - | 'AR_DZ' - | 'AR_EG' - | 'AR_EH' - | 'AR_ER' - | 'AR_IL' - | 'AR_IQ' - | 'AR_JO' - | 'AR_KM' - | 'AR_KW' - | 'AR_LB' - | 'AR_LY' - | 'AR_MA' - | 'AR_MR' - | 'AR_OM' - | 'AR_PS' - | 'AR_QA' - | 'AR_SA' - | 'AR_SD' - | 'AR_SO' - | 'AR_SS' - | 'AR_SY' - | 'AR_TD' - | 'AR_TN' - | 'AR_YE' - | 'AS' - | 'ASA' - | 'ASA_TZ' - | 'AST' - | 'AST_ES' - | 'AS_IN' - | 'AZ' - | 'AZ_CYRL' - | 'AZ_CYRL_AZ' - | 'AZ_LATN' - | 'AZ_LATN_AZ' - | 'BAS' - | 'BAS_CM' - | 'BE' - | 'BEM' - | 'BEM_ZM' - | 'BEZ' - | 'BEZ_TZ' - | 'BE_BY' - | 'BG' - | 'BG_BG' - | 'BM' - | 'BM_ML' - | 'BN' - | 'BN_BD' - | 'BN_IN' - | 'BO' - | 'BO_CN' - | 'BO_IN' - | 'BR' - | 'BRX' - | 'BRX_IN' - | 'BR_FR' - | 'BS' - | 'BS_CYRL' - | 'BS_CYRL_BA' - | 'BS_LATN' - | 'BS_LATN_BA' - | 'CA' - | 'CA_AD' - | 'CA_ES' - | 'CA_ES_VALENCIA' - | 'CA_FR' - | 'CA_IT' - | 'CCP' - | 'CCP_BD' - | 'CCP_IN' - | 'CE' - | 'CEB' - | 'CEB_PH' - | 'CE_RU' - | 'CGG' - | 'CGG_UG' - | 'CHR' - | 'CHR_US' - | 'CKB' - | 'CKB_IQ' - | 'CKB_IR' - | 'CS' - | 'CS_CZ' - | 'CU' - | 'CU_RU' - | 'CY' - | 'CY_GB' - | 'DA' - | 'DAV' - | 'DAV_KE' - | 'DA_DK' - | 'DA_GL' - | 'DE' - | 'DE_AT' - | 'DE_BE' - | 'DE_CH' - | 'DE_DE' - | 'DE_IT' - | 'DE_LI' - | 'DE_LU' - | 'DJE' - | 'DJE_NE' - | 'DSB' - | 'DSB_DE' - | 'DUA' - | 'DUA_CM' - | 'DYO' - | 'DYO_SN' - | 'DZ' - | 'DZ_BT' - | 'EBU' - | 'EBU_KE' - | 'EE' - | 'EE_GH' - | 'EE_TG' - | 'EL' - | 'EL_CY' - | 'EL_GR' - | 'EN' - | 'EN_AE' - | 'EN_AG' - | 'EN_AI' - | 'EN_AS' - | 'EN_AT' - | 'EN_AU' - | 'EN_BB' - | 'EN_BE' - | 'EN_BI' - | 'EN_BM' - | 'EN_BS' - | 'EN_BW' - | 'EN_BZ' - | 'EN_CA' - | 'EN_CC' - | 'EN_CH' - | 'EN_CK' - | 'EN_CM' - | 'EN_CX' - | 'EN_CY' - | 'EN_DE' - | 'EN_DG' - | 'EN_DK' - | 'EN_DM' - | 'EN_ER' - | 'EN_FI' - | 'EN_FJ' - | 'EN_FK' - | 'EN_FM' - | 'EN_GB' - | 'EN_GD' - | 'EN_GG' - | 'EN_GH' - | 'EN_GI' - | 'EN_GM' - | 'EN_GU' - | 'EN_GY' - | 'EN_HK' - | 'EN_IE' - | 'EN_IL' - | 'EN_IM' - | 'EN_IN' - | 'EN_IO' - | 'EN_JE' - | 'EN_JM' - | 'EN_KE' - | 'EN_KI' - | 'EN_KN' - | 'EN_KY' - | 'EN_LC' - | 'EN_LR' - | 'EN_LS' - | 'EN_MG' - | 'EN_MH' - | 'EN_MO' - | 'EN_MP' - | 'EN_MS' - | 'EN_MT' - | 'EN_MU' - | 'EN_MW' - | 'EN_MY' - | 'EN_NA' - | 'EN_NF' - | 'EN_NG' - | 'EN_NL' - | 'EN_NR' - | 'EN_NU' - | 'EN_NZ' - | 'EN_PG' - | 'EN_PH' - | 'EN_PK' - | 'EN_PN' - | 'EN_PR' - | 'EN_PW' - | 'EN_RW' - | 'EN_SB' - | 'EN_SC' - | 'EN_SD' - | 'EN_SE' - | 'EN_SG' - | 'EN_SH' - | 'EN_SI' - | 'EN_SL' - | 'EN_SS' - | 'EN_SX' - | 'EN_SZ' - | 'EN_TC' - | 'EN_TK' - | 'EN_TO' - | 'EN_TT' - | 'EN_TV' - | 'EN_TZ' - | 'EN_UG' - | 'EN_UM' - | 'EN_US' - | 'EN_VC' - | 'EN_VG' - | 'EN_VI' - | 'EN_VU' - | 'EN_WS' - | 'EN_ZA' - | 'EN_ZM' - | 'EN_ZW' - | 'EO' - | 'ES' - | 'ES_AR' - | 'ES_BO' - | 'ES_BR' - | 'ES_BZ' - | 'ES_CL' - | 'ES_CO' - | 'ES_CR' - | 'ES_CU' - | 'ES_DO' - | 'ES_EA' - | 'ES_EC' - | 'ES_ES' - | 'ES_GQ' - | 'ES_GT' - | 'ES_HN' - | 'ES_IC' - | 'ES_MX' - | 'ES_NI' - | 'ES_PA' - | 'ES_PE' - | 'ES_PH' - | 'ES_PR' - | 'ES_PY' - | 'ES_SV' - | 'ES_US' - | 'ES_UY' - | 'ES_VE' - | 'ET' - | 'ET_EE' - | 'EU' - | 'EU_ES' - | 'EWO' - | 'EWO_CM' - | 'FA' - | 'FA_AF' - | 'FA_IR' - | 'FF' - | 'FF_ADLM' - | 'FF_ADLM_BF' - | 'FF_ADLM_CM' - | 'FF_ADLM_GH' - | 'FF_ADLM_GM' - | 'FF_ADLM_GN' - | 'FF_ADLM_GW' - | 'FF_ADLM_LR' - | 'FF_ADLM_MR' - | 'FF_ADLM_NE' - | 'FF_ADLM_NG' - | 'FF_ADLM_SL' - | 'FF_ADLM_SN' - | 'FF_LATN' - | 'FF_LATN_BF' - | 'FF_LATN_CM' - | 'FF_LATN_GH' - | 'FF_LATN_GM' - | 'FF_LATN_GN' - | 'FF_LATN_GW' - | 'FF_LATN_LR' - | 'FF_LATN_MR' - | 'FF_LATN_NE' - | 'FF_LATN_NG' - | 'FF_LATN_SL' - | 'FF_LATN_SN' - | 'FI' - | 'FIL' - | 'FIL_PH' - | 'FI_FI' - | 'FO' - | 'FO_DK' - | 'FO_FO' - | 'FR' - | 'FR_BE' - | 'FR_BF' - | 'FR_BI' - | 'FR_BJ' - | 'FR_BL' - | 'FR_CA' - | 'FR_CD' - | 'FR_CF' - | 'FR_CG' - | 'FR_CH' - | 'FR_CI' - | 'FR_CM' - | 'FR_DJ' - | 'FR_DZ' - | 'FR_FR' - | 'FR_GA' - | 'FR_GF' - | 'FR_GN' - | 'FR_GP' - | 'FR_GQ' - | 'FR_HT' - | 'FR_KM' - | 'FR_LU' - | 'FR_MA' - | 'FR_MC' - | 'FR_MF' - | 'FR_MG' - | 'FR_ML' - | 'FR_MQ' - | 'FR_MR' - | 'FR_MU' - | 'FR_NC' - | 'FR_NE' - | 'FR_PF' - | 'FR_PM' - | 'FR_RE' - | 'FR_RW' - | 'FR_SC' - | 'FR_SN' - | 'FR_SY' - | 'FR_TD' - | 'FR_TG' - | 'FR_TN' - | 'FR_VU' - | 'FR_WF' - | 'FR_YT' - | 'FUR' - | 'FUR_IT' - | 'FY' - | 'FY_NL' - | 'GA' - | 'GA_GB' - | 'GA_IE' - | 'GD' - | 'GD_GB' - | 'GL' - | 'GL_ES' - | 'GSW' - | 'GSW_CH' - | 'GSW_FR' - | 'GSW_LI' - | 'GU' - | 'GUZ' - | 'GUZ_KE' - | 'GU_IN' - | 'GV' - | 'GV_IM' - | 'HA' - | 'HAW' - | 'HAW_US' - | 'HA_GH' - | 'HA_NE' - | 'HA_NG' - | 'HE' - | 'HE_IL' - | 'HI' - | 'HI_IN' - | 'HR' - | 'HR_BA' - | 'HR_HR' - | 'HSB' - | 'HSB_DE' - | 'HU' - | 'HU_HU' - | 'HY' - | 'HY_AM' - | 'IA' - | 'ID' - | 'ID_ID' - | 'IG' - | 'IG_NG' - | 'II' - | 'II_CN' - | 'IS' - | 'IS_IS' - | 'IT' - | 'IT_CH' - | 'IT_IT' - | 'IT_SM' - | 'IT_VA' - | 'JA' - | 'JA_JP' - | 'JGO' - | 'JGO_CM' - | 'JMC' - | 'JMC_TZ' - | 'JV' - | 'JV_ID' - | 'KA' - | 'KAB' - | 'KAB_DZ' - | 'KAM' - | 'KAM_KE' - | 'KA_GE' - | 'KDE' - | 'KDE_TZ' - | 'KEA' - | 'KEA_CV' - | 'KHQ' - | 'KHQ_ML' - | 'KI' - | 'KI_KE' - | 'KK' - | 'KKJ' - | 'KKJ_CM' - | 'KK_KZ' - | 'KL' - | 'KLN' - | 'KLN_KE' - | 'KL_GL' - | 'KM' - | 'KM_KH' - | 'KN' - | 'KN_IN' - | 'KO' - | 'KOK' - | 'KOK_IN' - | 'KO_KP' - | 'KO_KR' - | 'KS' - | 'KSB' - | 'KSB_TZ' - | 'KSF' - | 'KSF_CM' - | 'KSH' - | 'KSH_DE' - | 'KS_ARAB' - | 'KS_ARAB_IN' - | 'KU' - | 'KU_TR' - | 'KW' - | 'KW_GB' - | 'KY' - | 'KY_KG' - | 'LAG' - | 'LAG_TZ' - | 'LB' - | 'LB_LU' - | 'LG' - | 'LG_UG' - | 'LKT' - | 'LKT_US' - | 'LN' - | 'LN_AO' - | 'LN_CD' - | 'LN_CF' - | 'LN_CG' - | 'LO' - | 'LO_LA' - | 'LRC' - | 'LRC_IQ' - | 'LRC_IR' - | 'LT' - | 'LT_LT' - | 'LU' - | 'LUO' - | 'LUO_KE' - | 'LUY' - | 'LUY_KE' - | 'LU_CD' - | 'LV' - | 'LV_LV' - | 'MAI' - | 'MAI_IN' - | 'MAS' - | 'MAS_KE' - | 'MAS_TZ' - | 'MER' - | 'MER_KE' - | 'MFE' - | 'MFE_MU' - | 'MG' - | 'MGH' - | 'MGH_MZ' - | 'MGO' - | 'MGO_CM' - | 'MG_MG' - | 'MI' - | 'MI_NZ' - | 'MK' - | 'MK_MK' - | 'ML' - | 'ML_IN' - | 'MN' - | 'MNI' - | 'MNI_BENG' - | 'MNI_BENG_IN' - | 'MN_MN' - | 'MR' - | 'MR_IN' - | 'MS' - | 'MS_BN' - | 'MS_ID' - | 'MS_MY' - | 'MS_SG' - | 'MT' - | 'MT_MT' - | 'MUA' - | 'MUA_CM' - | 'MY' - | 'MY_MM' - | 'MZN' - | 'MZN_IR' - | 'NAQ' - | 'NAQ_NA' - | 'NB' - | 'NB_NO' - | 'NB_SJ' - | 'ND' - | 'NDS' - | 'NDS_DE' - | 'NDS_NL' - | 'ND_ZW' - | 'NE' - | 'NE_IN' - | 'NE_NP' - | 'NL' - | 'NL_AW' - | 'NL_BE' - | 'NL_BQ' - | 'NL_CW' - | 'NL_NL' - | 'NL_SR' - | 'NL_SX' - | 'NMG' - | 'NMG_CM' - | 'NN' - | 'NNH' - | 'NNH_CM' - | 'NN_NO' - | 'NUS' - | 'NUS_SS' - | 'NYN' - | 'NYN_UG' - | 'OM' - | 'OM_ET' - | 'OM_KE' - | 'OR' - | 'OR_IN' - | 'OS' - | 'OS_GE' - | 'OS_RU' - | 'PA' - | 'PA_ARAB' - | 'PA_ARAB_PK' - | 'PA_GURU' - | 'PA_GURU_IN' - | 'PCM' - | 'PCM_NG' - | 'PL' - | 'PL_PL' - | 'PRG' - | 'PS' - | 'PS_AF' - | 'PS_PK' - | 'PT' - | 'PT_AO' - | 'PT_BR' - | 'PT_CH' - | 'PT_CV' - | 'PT_GQ' - | 'PT_GW' - | 'PT_LU' - | 'PT_MO' - | 'PT_MZ' - | 'PT_PT' - | 'PT_ST' - | 'PT_TL' - | 'QU' - | 'QU_BO' - | 'QU_EC' - | 'QU_PE' - | 'RM' - | 'RM_CH' - | 'RN' - | 'RN_BI' - | 'RO' - | 'ROF' - | 'ROF_TZ' - | 'RO_MD' - | 'RO_RO' - | 'RU' - | 'RU_BY' - | 'RU_KG' - | 'RU_KZ' - | 'RU_MD' - | 'RU_RU' - | 'RU_UA' - | 'RW' - | 'RWK' - | 'RWK_TZ' - | 'RW_RW' - | 'SAH' - | 'SAH_RU' - | 'SAQ' - | 'SAQ_KE' - | 'SAT' - | 'SAT_OLCK' - | 'SAT_OLCK_IN' - | 'SBP' - | 'SBP_TZ' - | 'SD' - | 'SD_ARAB' - | 'SD_ARAB_PK' - | 'SD_DEVA' - | 'SD_DEVA_IN' - | 'SE' - | 'SEH' - | 'SEH_MZ' - | 'SES' - | 'SES_ML' - | 'SE_FI' - | 'SE_NO' - | 'SE_SE' - | 'SG' - | 'SG_CF' - | 'SHI' - | 'SHI_LATN' - | 'SHI_LATN_MA' - | 'SHI_TFNG' - | 'SHI_TFNG_MA' - | 'SI' - | 'SI_LK' - | 'SK' - | 'SK_SK' - | 'SL' - | 'SL_SI' - | 'SMN' - | 'SMN_FI' - | 'SN' - | 'SN_ZW' - | 'SO' - | 'SO_DJ' - | 'SO_ET' - | 'SO_KE' - | 'SO_SO' - | 'SQ' - | 'SQ_AL' - | 'SQ_MK' - | 'SQ_XK' - | 'SR' - | 'SR_CYRL' - | 'SR_CYRL_BA' - | 'SR_CYRL_ME' - | 'SR_CYRL_RS' - | 'SR_CYRL_XK' - | 'SR_LATN' - | 'SR_LATN_BA' - | 'SR_LATN_ME' - | 'SR_LATN_RS' - | 'SR_LATN_XK' - | 'SU' - | 'SU_LATN' - | 'SU_LATN_ID' - | 'SV' - | 'SV_AX' - | 'SV_FI' - | 'SV_SE' - | 'SW' - | 'SW_CD' - | 'SW_KE' - | 'SW_TZ' - | 'SW_UG' - | 'TA' - | 'TA_IN' - | 'TA_LK' - | 'TA_MY' - | 'TA_SG' - | 'TE' - | 'TEO' - | 'TEO_KE' - | 'TEO_UG' - | 'TE_IN' - | 'TG' - | 'TG_TJ' - | 'TH' - | 'TH_TH' - | 'TI' - | 'TI_ER' - | 'TI_ET' - | 'TK' - | 'TK_TM' - | 'TO' - | 'TO_TO' - | 'TR' - | 'TR_CY' - | 'TR_TR' - | 'TT' - | 'TT_RU' - | 'TWQ' - | 'TWQ_NE' - | 'TZM' - | 'TZM_MA' - | 'UG' - | 'UG_CN' - | 'UK' - | 'UK_UA' - | 'UR' - | 'UR_IN' - | 'UR_PK' - | 'UZ' - | 'UZ_ARAB' - | 'UZ_ARAB_AF' - | 'UZ_CYRL' - | 'UZ_CYRL_UZ' - | 'UZ_LATN' - | 'UZ_LATN_UZ' - | 'VAI' - | 'VAI_LATN' - | 'VAI_LATN_LR' - | 'VAI_VAII' - | 'VAI_VAII_LR' - | 'VI' - | 'VI_VN' - | 'VO' - | 'VUN' - | 'VUN_TZ' - | 'WAE' - | 'WAE_CH' - | 'WO' - | 'WO_SN' - | 'XH' - | 'XH_ZA' - | 'XOG' - | 'XOG_UG' - | 'YAV' - | 'YAV_CM' - | 'YI' - | 'YO' - | 'YO_BJ' - | 'YO_NG' - | 'YUE' - | 'YUE_HANS' - | 'YUE_HANS_CN' - | 'YUE_HANT' - | 'YUE_HANT_HK' - | 'ZGH' - | 'ZGH_MA' - | 'ZH' - | 'ZH_HANS' - | 'ZH_HANS_CN' - | 'ZH_HANS_HK' - | 'ZH_HANS_MO' - | 'ZH_HANS_SG' - | 'ZH_HANT' - | 'ZH_HANT_HK' - | 'ZH_HANT_MO' - | 'ZH_HANT_TW' - | 'ZU' - | 'ZU_ZA'; + readonly updatedAt: Scalars['DateTime']; +}; + +export enum JobStatusEnum { + Deleted = 'DELETED', + Failed = 'FAILED', + Pending = 'PENDING', + Success = 'SUCCESS' +} + +export enum LanguageCodeEnum { + Af = 'AF', + AfNa = 'AF_NA', + AfZa = 'AF_ZA', + Agq = 'AGQ', + AgqCm = 'AGQ_CM', + Ak = 'AK', + AkGh = 'AK_GH', + Am = 'AM', + AmEt = 'AM_ET', + Ar = 'AR', + ArAe = 'AR_AE', + ArBh = 'AR_BH', + ArDj = 'AR_DJ', + ArDz = 'AR_DZ', + ArEg = 'AR_EG', + ArEh = 'AR_EH', + ArEr = 'AR_ER', + ArIl = 'AR_IL', + ArIq = 'AR_IQ', + ArJo = 'AR_JO', + ArKm = 'AR_KM', + ArKw = 'AR_KW', + ArLb = 'AR_LB', + ArLy = 'AR_LY', + ArMa = 'AR_MA', + ArMr = 'AR_MR', + ArOm = 'AR_OM', + ArPs = 'AR_PS', + ArQa = 'AR_QA', + ArSa = 'AR_SA', + ArSd = 'AR_SD', + ArSo = 'AR_SO', + ArSs = 'AR_SS', + ArSy = 'AR_SY', + ArTd = 'AR_TD', + ArTn = 'AR_TN', + ArYe = 'AR_YE', + As = 'AS', + Asa = 'ASA', + AsaTz = 'ASA_TZ', + Ast = 'AST', + AstEs = 'AST_ES', + AsIn = 'AS_IN', + Az = 'AZ', + AzCyrl = 'AZ_CYRL', + AzCyrlAz = 'AZ_CYRL_AZ', + AzLatn = 'AZ_LATN', + AzLatnAz = 'AZ_LATN_AZ', + Bas = 'BAS', + BasCm = 'BAS_CM', + Be = 'BE', + Bem = 'BEM', + BemZm = 'BEM_ZM', + Bez = 'BEZ', + BezTz = 'BEZ_TZ', + BeBy = 'BE_BY', + Bg = 'BG', + BgBg = 'BG_BG', + Bm = 'BM', + BmMl = 'BM_ML', + Bn = 'BN', + BnBd = 'BN_BD', + BnIn = 'BN_IN', + Bo = 'BO', + BoCn = 'BO_CN', + BoIn = 'BO_IN', + Br = 'BR', + Brx = 'BRX', + BrxIn = 'BRX_IN', + BrFr = 'BR_FR', + Bs = 'BS', + BsCyrl = 'BS_CYRL', + BsCyrlBa = 'BS_CYRL_BA', + BsLatn = 'BS_LATN', + BsLatnBa = 'BS_LATN_BA', + Ca = 'CA', + CaAd = 'CA_AD', + CaEs = 'CA_ES', + CaEsValencia = 'CA_ES_VALENCIA', + CaFr = 'CA_FR', + CaIt = 'CA_IT', + Ccp = 'CCP', + CcpBd = 'CCP_BD', + CcpIn = 'CCP_IN', + Ce = 'CE', + Ceb = 'CEB', + CebPh = 'CEB_PH', + CeRu = 'CE_RU', + Cgg = 'CGG', + CggUg = 'CGG_UG', + Chr = 'CHR', + ChrUs = 'CHR_US', + Ckb = 'CKB', + CkbIq = 'CKB_IQ', + CkbIr = 'CKB_IR', + Cs = 'CS', + CsCz = 'CS_CZ', + Cu = 'CU', + CuRu = 'CU_RU', + Cy = 'CY', + CyGb = 'CY_GB', + Da = 'DA', + Dav = 'DAV', + DavKe = 'DAV_KE', + DaDk = 'DA_DK', + DaGl = 'DA_GL', + De = 'DE', + DeAt = 'DE_AT', + DeBe = 'DE_BE', + DeCh = 'DE_CH', + DeDe = 'DE_DE', + DeIt = 'DE_IT', + DeLi = 'DE_LI', + DeLu = 'DE_LU', + Dje = 'DJE', + DjeNe = 'DJE_NE', + Dsb = 'DSB', + DsbDe = 'DSB_DE', + Dua = 'DUA', + DuaCm = 'DUA_CM', + Dyo = 'DYO', + DyoSn = 'DYO_SN', + Dz = 'DZ', + DzBt = 'DZ_BT', + Ebu = 'EBU', + EbuKe = 'EBU_KE', + Ee = 'EE', + EeGh = 'EE_GH', + EeTg = 'EE_TG', + El = 'EL', + ElCy = 'EL_CY', + ElGr = 'EL_GR', + En = 'EN', + EnAe = 'EN_AE', + EnAg = 'EN_AG', + EnAi = 'EN_AI', + EnAs = 'EN_AS', + EnAt = 'EN_AT', + EnAu = 'EN_AU', + EnBb = 'EN_BB', + EnBe = 'EN_BE', + EnBi = 'EN_BI', + EnBm = 'EN_BM', + EnBs = 'EN_BS', + EnBw = 'EN_BW', + EnBz = 'EN_BZ', + EnCa = 'EN_CA', + EnCc = 'EN_CC', + EnCh = 'EN_CH', + EnCk = 'EN_CK', + EnCm = 'EN_CM', + EnCx = 'EN_CX', + EnCy = 'EN_CY', + EnDe = 'EN_DE', + EnDg = 'EN_DG', + EnDk = 'EN_DK', + EnDm = 'EN_DM', + EnEr = 'EN_ER', + EnFi = 'EN_FI', + EnFj = 'EN_FJ', + EnFk = 'EN_FK', + EnFm = 'EN_FM', + EnGb = 'EN_GB', + EnGd = 'EN_GD', + EnGg = 'EN_GG', + EnGh = 'EN_GH', + EnGi = 'EN_GI', + EnGm = 'EN_GM', + EnGu = 'EN_GU', + EnGy = 'EN_GY', + EnHk = 'EN_HK', + EnIe = 'EN_IE', + EnIl = 'EN_IL', + EnIm = 'EN_IM', + EnIn = 'EN_IN', + EnIo = 'EN_IO', + EnJe = 'EN_JE', + EnJm = 'EN_JM', + EnKe = 'EN_KE', + EnKi = 'EN_KI', + EnKn = 'EN_KN', + EnKy = 'EN_KY', + EnLc = 'EN_LC', + EnLr = 'EN_LR', + EnLs = 'EN_LS', + EnMg = 'EN_MG', + EnMh = 'EN_MH', + EnMo = 'EN_MO', + EnMp = 'EN_MP', + EnMs = 'EN_MS', + EnMt = 'EN_MT', + EnMu = 'EN_MU', + EnMw = 'EN_MW', + EnMy = 'EN_MY', + EnNa = 'EN_NA', + EnNf = 'EN_NF', + EnNg = 'EN_NG', + EnNl = 'EN_NL', + EnNr = 'EN_NR', + EnNu = 'EN_NU', + EnNz = 'EN_NZ', + EnPg = 'EN_PG', + EnPh = 'EN_PH', + EnPk = 'EN_PK', + EnPn = 'EN_PN', + EnPr = 'EN_PR', + EnPw = 'EN_PW', + EnRw = 'EN_RW', + EnSb = 'EN_SB', + EnSc = 'EN_SC', + EnSd = 'EN_SD', + EnSe = 'EN_SE', + EnSg = 'EN_SG', + EnSh = 'EN_SH', + EnSi = 'EN_SI', + EnSl = 'EN_SL', + EnSs = 'EN_SS', + EnSx = 'EN_SX', + EnSz = 'EN_SZ', + EnTc = 'EN_TC', + EnTk = 'EN_TK', + EnTo = 'EN_TO', + EnTt = 'EN_TT', + EnTv = 'EN_TV', + EnTz = 'EN_TZ', + EnUg = 'EN_UG', + EnUm = 'EN_UM', + EnUs = 'EN_US', + EnVc = 'EN_VC', + EnVg = 'EN_VG', + EnVi = 'EN_VI', + EnVu = 'EN_VU', + EnWs = 'EN_WS', + EnZa = 'EN_ZA', + EnZm = 'EN_ZM', + EnZw = 'EN_ZW', + Eo = 'EO', + Es = 'ES', + EsAr = 'ES_AR', + EsBo = 'ES_BO', + EsBr = 'ES_BR', + EsBz = 'ES_BZ', + EsCl = 'ES_CL', + EsCo = 'ES_CO', + EsCr = 'ES_CR', + EsCu = 'ES_CU', + EsDo = 'ES_DO', + EsEa = 'ES_EA', + EsEc = 'ES_EC', + EsEs = 'ES_ES', + EsGq = 'ES_GQ', + EsGt = 'ES_GT', + EsHn = 'ES_HN', + EsIc = 'ES_IC', + EsMx = 'ES_MX', + EsNi = 'ES_NI', + EsPa = 'ES_PA', + EsPe = 'ES_PE', + EsPh = 'ES_PH', + EsPr = 'ES_PR', + EsPy = 'ES_PY', + EsSv = 'ES_SV', + EsUs = 'ES_US', + EsUy = 'ES_UY', + EsVe = 'ES_VE', + Et = 'ET', + EtEe = 'ET_EE', + Eu = 'EU', + EuEs = 'EU_ES', + Ewo = 'EWO', + EwoCm = 'EWO_CM', + Fa = 'FA', + FaAf = 'FA_AF', + FaIr = 'FA_IR', + Ff = 'FF', + FfAdlm = 'FF_ADLM', + FfAdlmBf = 'FF_ADLM_BF', + FfAdlmCm = 'FF_ADLM_CM', + FfAdlmGh = 'FF_ADLM_GH', + FfAdlmGm = 'FF_ADLM_GM', + FfAdlmGn = 'FF_ADLM_GN', + FfAdlmGw = 'FF_ADLM_GW', + FfAdlmLr = 'FF_ADLM_LR', + FfAdlmMr = 'FF_ADLM_MR', + FfAdlmNe = 'FF_ADLM_NE', + FfAdlmNg = 'FF_ADLM_NG', + FfAdlmSl = 'FF_ADLM_SL', + FfAdlmSn = 'FF_ADLM_SN', + FfLatn = 'FF_LATN', + FfLatnBf = 'FF_LATN_BF', + FfLatnCm = 'FF_LATN_CM', + FfLatnGh = 'FF_LATN_GH', + FfLatnGm = 'FF_LATN_GM', + FfLatnGn = 'FF_LATN_GN', + FfLatnGw = 'FF_LATN_GW', + FfLatnLr = 'FF_LATN_LR', + FfLatnMr = 'FF_LATN_MR', + FfLatnNe = 'FF_LATN_NE', + FfLatnNg = 'FF_LATN_NG', + FfLatnSl = 'FF_LATN_SL', + FfLatnSn = 'FF_LATN_SN', + Fi = 'FI', + Fil = 'FIL', + FilPh = 'FIL_PH', + FiFi = 'FI_FI', + Fo = 'FO', + FoDk = 'FO_DK', + FoFo = 'FO_FO', + Fr = 'FR', + FrBe = 'FR_BE', + FrBf = 'FR_BF', + FrBi = 'FR_BI', + FrBj = 'FR_BJ', + FrBl = 'FR_BL', + FrCa = 'FR_CA', + FrCd = 'FR_CD', + FrCf = 'FR_CF', + FrCg = 'FR_CG', + FrCh = 'FR_CH', + FrCi = 'FR_CI', + FrCm = 'FR_CM', + FrDj = 'FR_DJ', + FrDz = 'FR_DZ', + FrFr = 'FR_FR', + FrGa = 'FR_GA', + FrGf = 'FR_GF', + FrGn = 'FR_GN', + FrGp = 'FR_GP', + FrGq = 'FR_GQ', + FrHt = 'FR_HT', + FrKm = 'FR_KM', + FrLu = 'FR_LU', + FrMa = 'FR_MA', + FrMc = 'FR_MC', + FrMf = 'FR_MF', + FrMg = 'FR_MG', + FrMl = 'FR_ML', + FrMq = 'FR_MQ', + FrMr = 'FR_MR', + FrMu = 'FR_MU', + FrNc = 'FR_NC', + FrNe = 'FR_NE', + FrPf = 'FR_PF', + FrPm = 'FR_PM', + FrRe = 'FR_RE', + FrRw = 'FR_RW', + FrSc = 'FR_SC', + FrSn = 'FR_SN', + FrSy = 'FR_SY', + FrTd = 'FR_TD', + FrTg = 'FR_TG', + FrTn = 'FR_TN', + FrVu = 'FR_VU', + FrWf = 'FR_WF', + FrYt = 'FR_YT', + Fur = 'FUR', + FurIt = 'FUR_IT', + Fy = 'FY', + FyNl = 'FY_NL', + Ga = 'GA', + GaGb = 'GA_GB', + GaIe = 'GA_IE', + Gd = 'GD', + GdGb = 'GD_GB', + Gl = 'GL', + GlEs = 'GL_ES', + Gsw = 'GSW', + GswCh = 'GSW_CH', + GswFr = 'GSW_FR', + GswLi = 'GSW_LI', + Gu = 'GU', + Guz = 'GUZ', + GuzKe = 'GUZ_KE', + GuIn = 'GU_IN', + Gv = 'GV', + GvIm = 'GV_IM', + Ha = 'HA', + Haw = 'HAW', + HawUs = 'HAW_US', + HaGh = 'HA_GH', + HaNe = 'HA_NE', + HaNg = 'HA_NG', + He = 'HE', + HeIl = 'HE_IL', + Hi = 'HI', + HiIn = 'HI_IN', + Hr = 'HR', + HrBa = 'HR_BA', + HrHr = 'HR_HR', + Hsb = 'HSB', + HsbDe = 'HSB_DE', + Hu = 'HU', + HuHu = 'HU_HU', + Hy = 'HY', + HyAm = 'HY_AM', + Ia = 'IA', + Id = 'ID', + IdId = 'ID_ID', + Ig = 'IG', + IgNg = 'IG_NG', + Ii = 'II', + IiCn = 'II_CN', + Is = 'IS', + IsIs = 'IS_IS', + It = 'IT', + ItCh = 'IT_CH', + ItIt = 'IT_IT', + ItSm = 'IT_SM', + ItVa = 'IT_VA', + Ja = 'JA', + JaJp = 'JA_JP', + Jgo = 'JGO', + JgoCm = 'JGO_CM', + Jmc = 'JMC', + JmcTz = 'JMC_TZ', + Jv = 'JV', + JvId = 'JV_ID', + Ka = 'KA', + Kab = 'KAB', + KabDz = 'KAB_DZ', + Kam = 'KAM', + KamKe = 'KAM_KE', + KaGe = 'KA_GE', + Kde = 'KDE', + KdeTz = 'KDE_TZ', + Kea = 'KEA', + KeaCv = 'KEA_CV', + Khq = 'KHQ', + KhqMl = 'KHQ_ML', + Ki = 'KI', + KiKe = 'KI_KE', + Kk = 'KK', + Kkj = 'KKJ', + KkjCm = 'KKJ_CM', + KkKz = 'KK_KZ', + Kl = 'KL', + Kln = 'KLN', + KlnKe = 'KLN_KE', + KlGl = 'KL_GL', + Km = 'KM', + KmKh = 'KM_KH', + Kn = 'KN', + KnIn = 'KN_IN', + Ko = 'KO', + Kok = 'KOK', + KokIn = 'KOK_IN', + KoKp = 'KO_KP', + KoKr = 'KO_KR', + Ks = 'KS', + Ksb = 'KSB', + KsbTz = 'KSB_TZ', + Ksf = 'KSF', + KsfCm = 'KSF_CM', + Ksh = 'KSH', + KshDe = 'KSH_DE', + KsArab = 'KS_ARAB', + KsArabIn = 'KS_ARAB_IN', + Ku = 'KU', + KuTr = 'KU_TR', + Kw = 'KW', + KwGb = 'KW_GB', + Ky = 'KY', + KyKg = 'KY_KG', + Lag = 'LAG', + LagTz = 'LAG_TZ', + Lb = 'LB', + LbLu = 'LB_LU', + Lg = 'LG', + LgUg = 'LG_UG', + Lkt = 'LKT', + LktUs = 'LKT_US', + Ln = 'LN', + LnAo = 'LN_AO', + LnCd = 'LN_CD', + LnCf = 'LN_CF', + LnCg = 'LN_CG', + Lo = 'LO', + LoLa = 'LO_LA', + Lrc = 'LRC', + LrcIq = 'LRC_IQ', + LrcIr = 'LRC_IR', + Lt = 'LT', + LtLt = 'LT_LT', + Lu = 'LU', + Luo = 'LUO', + LuoKe = 'LUO_KE', + Luy = 'LUY', + LuyKe = 'LUY_KE', + LuCd = 'LU_CD', + Lv = 'LV', + LvLv = 'LV_LV', + Mai = 'MAI', + MaiIn = 'MAI_IN', + Mas = 'MAS', + MasKe = 'MAS_KE', + MasTz = 'MAS_TZ', + Mer = 'MER', + MerKe = 'MER_KE', + Mfe = 'MFE', + MfeMu = 'MFE_MU', + Mg = 'MG', + Mgh = 'MGH', + MghMz = 'MGH_MZ', + Mgo = 'MGO', + MgoCm = 'MGO_CM', + MgMg = 'MG_MG', + Mi = 'MI', + MiNz = 'MI_NZ', + Mk = 'MK', + MkMk = 'MK_MK', + Ml = 'ML', + MlIn = 'ML_IN', + Mn = 'MN', + Mni = 'MNI', + MniBeng = 'MNI_BENG', + MniBengIn = 'MNI_BENG_IN', + MnMn = 'MN_MN', + Mr = 'MR', + MrIn = 'MR_IN', + Ms = 'MS', + MsBn = 'MS_BN', + MsId = 'MS_ID', + MsMy = 'MS_MY', + MsSg = 'MS_SG', + Mt = 'MT', + MtMt = 'MT_MT', + Mua = 'MUA', + MuaCm = 'MUA_CM', + My = 'MY', + MyMm = 'MY_MM', + Mzn = 'MZN', + MznIr = 'MZN_IR', + Naq = 'NAQ', + NaqNa = 'NAQ_NA', + Nb = 'NB', + NbNo = 'NB_NO', + NbSj = 'NB_SJ', + Nd = 'ND', + Nds = 'NDS', + NdsDe = 'NDS_DE', + NdsNl = 'NDS_NL', + NdZw = 'ND_ZW', + Ne = 'NE', + NeIn = 'NE_IN', + NeNp = 'NE_NP', + Nl = 'NL', + NlAw = 'NL_AW', + NlBe = 'NL_BE', + NlBq = 'NL_BQ', + NlCw = 'NL_CW', + NlNl = 'NL_NL', + NlSr = 'NL_SR', + NlSx = 'NL_SX', + Nmg = 'NMG', + NmgCm = 'NMG_CM', + Nn = 'NN', + Nnh = 'NNH', + NnhCm = 'NNH_CM', + NnNo = 'NN_NO', + Nus = 'NUS', + NusSs = 'NUS_SS', + Nyn = 'NYN', + NynUg = 'NYN_UG', + Om = 'OM', + OmEt = 'OM_ET', + OmKe = 'OM_KE', + Or = 'OR', + OrIn = 'OR_IN', + Os = 'OS', + OsGe = 'OS_GE', + OsRu = 'OS_RU', + Pa = 'PA', + PaArab = 'PA_ARAB', + PaArabPk = 'PA_ARAB_PK', + PaGuru = 'PA_GURU', + PaGuruIn = 'PA_GURU_IN', + Pcm = 'PCM', + PcmNg = 'PCM_NG', + Pl = 'PL', + PlPl = 'PL_PL', + Prg = 'PRG', + Ps = 'PS', + PsAf = 'PS_AF', + PsPk = 'PS_PK', + Pt = 'PT', + PtAo = 'PT_AO', + PtBr = 'PT_BR', + PtCh = 'PT_CH', + PtCv = 'PT_CV', + PtGq = 'PT_GQ', + PtGw = 'PT_GW', + PtLu = 'PT_LU', + PtMo = 'PT_MO', + PtMz = 'PT_MZ', + PtPt = 'PT_PT', + PtSt = 'PT_ST', + PtTl = 'PT_TL', + Qu = 'QU', + QuBo = 'QU_BO', + QuEc = 'QU_EC', + QuPe = 'QU_PE', + Rm = 'RM', + RmCh = 'RM_CH', + Rn = 'RN', + RnBi = 'RN_BI', + Ro = 'RO', + Rof = 'ROF', + RofTz = 'ROF_TZ', + RoMd = 'RO_MD', + RoRo = 'RO_RO', + Ru = 'RU', + RuBy = 'RU_BY', + RuKg = 'RU_KG', + RuKz = 'RU_KZ', + RuMd = 'RU_MD', + RuRu = 'RU_RU', + RuUa = 'RU_UA', + Rw = 'RW', + Rwk = 'RWK', + RwkTz = 'RWK_TZ', + RwRw = 'RW_RW', + Sah = 'SAH', + SahRu = 'SAH_RU', + Saq = 'SAQ', + SaqKe = 'SAQ_KE', + Sat = 'SAT', + SatOlck = 'SAT_OLCK', + SatOlckIn = 'SAT_OLCK_IN', + Sbp = 'SBP', + SbpTz = 'SBP_TZ', + Sd = 'SD', + SdArab = 'SD_ARAB', + SdArabPk = 'SD_ARAB_PK', + SdDeva = 'SD_DEVA', + SdDevaIn = 'SD_DEVA_IN', + Se = 'SE', + Seh = 'SEH', + SehMz = 'SEH_MZ', + Ses = 'SES', + SesMl = 'SES_ML', + SeFi = 'SE_FI', + SeNo = 'SE_NO', + SeSe = 'SE_SE', + Sg = 'SG', + SgCf = 'SG_CF', + Shi = 'SHI', + ShiLatn = 'SHI_LATN', + ShiLatnMa = 'SHI_LATN_MA', + ShiTfng = 'SHI_TFNG', + ShiTfngMa = 'SHI_TFNG_MA', + Si = 'SI', + SiLk = 'SI_LK', + Sk = 'SK', + SkSk = 'SK_SK', + Sl = 'SL', + SlSi = 'SL_SI', + Smn = 'SMN', + SmnFi = 'SMN_FI', + Sn = 'SN', + SnZw = 'SN_ZW', + So = 'SO', + SoDj = 'SO_DJ', + SoEt = 'SO_ET', + SoKe = 'SO_KE', + SoSo = 'SO_SO', + Sq = 'SQ', + SqAl = 'SQ_AL', + SqMk = 'SQ_MK', + SqXk = 'SQ_XK', + Sr = 'SR', + SrCyrl = 'SR_CYRL', + SrCyrlBa = 'SR_CYRL_BA', + SrCyrlMe = 'SR_CYRL_ME', + SrCyrlRs = 'SR_CYRL_RS', + SrCyrlXk = 'SR_CYRL_XK', + SrLatn = 'SR_LATN', + SrLatnBa = 'SR_LATN_BA', + SrLatnMe = 'SR_LATN_ME', + SrLatnRs = 'SR_LATN_RS', + SrLatnXk = 'SR_LATN_XK', + Su = 'SU', + SuLatn = 'SU_LATN', + SuLatnId = 'SU_LATN_ID', + Sv = 'SV', + SvAx = 'SV_AX', + SvFi = 'SV_FI', + SvSe = 'SV_SE', + Sw = 'SW', + SwCd = 'SW_CD', + SwKe = 'SW_KE', + SwTz = 'SW_TZ', + SwUg = 'SW_UG', + Ta = 'TA', + TaIn = 'TA_IN', + TaLk = 'TA_LK', + TaMy = 'TA_MY', + TaSg = 'TA_SG', + Te = 'TE', + Teo = 'TEO', + TeoKe = 'TEO_KE', + TeoUg = 'TEO_UG', + TeIn = 'TE_IN', + Tg = 'TG', + TgTj = 'TG_TJ', + Th = 'TH', + ThTh = 'TH_TH', + Ti = 'TI', + TiEr = 'TI_ER', + TiEt = 'TI_ET', + Tk = 'TK', + TkTm = 'TK_TM', + To = 'TO', + ToTo = 'TO_TO', + Tr = 'TR', + TrCy = 'TR_CY', + TrTr = 'TR_TR', + Tt = 'TT', + TtRu = 'TT_RU', + Twq = 'TWQ', + TwqNe = 'TWQ_NE', + Tzm = 'TZM', + TzmMa = 'TZM_MA', + Ug = 'UG', + UgCn = 'UG_CN', + Uk = 'UK', + UkUa = 'UK_UA', + Ur = 'UR', + UrIn = 'UR_IN', + UrPk = 'UR_PK', + Uz = 'UZ', + UzArab = 'UZ_ARAB', + UzArabAf = 'UZ_ARAB_AF', + UzCyrl = 'UZ_CYRL', + UzCyrlUz = 'UZ_CYRL_UZ', + UzLatn = 'UZ_LATN', + UzLatnUz = 'UZ_LATN_UZ', + Vai = 'VAI', + VaiLatn = 'VAI_LATN', + VaiLatnLr = 'VAI_LATN_LR', + VaiVaii = 'VAI_VAII', + VaiVaiiLr = 'VAI_VAII_LR', + Vi = 'VI', + ViVn = 'VI_VN', + Vo = 'VO', + Vun = 'VUN', + VunTz = 'VUN_TZ', + Wae = 'WAE', + WaeCh = 'WAE_CH', + Wo = 'WO', + WoSn = 'WO_SN', + Xh = 'XH', + XhZa = 'XH_ZA', + Xog = 'XOG', + XogUg = 'XOG_UG', + Yav = 'YAV', + YavCm = 'YAV_CM', + Yi = 'YI', + Yo = 'YO', + YoBj = 'YO_BJ', + YoNg = 'YO_NG', + Yue = 'YUE', + YueHans = 'YUE_HANS', + YueHansCn = 'YUE_HANS_CN', + YueHant = 'YUE_HANT', + YueHantHk = 'YUE_HANT_HK', + Zgh = 'ZGH', + ZghMa = 'ZGH_MA', + Zh = 'ZH', + ZhHans = 'ZH_HANS', + ZhHansCn = 'ZH_HANS_CN', + ZhHansHk = 'ZH_HANS_HK', + ZhHansMo = 'ZH_HANS_MO', + ZhHansSg = 'ZH_HANS_SG', + ZhHant = 'ZH_HANT', + ZhHantHk = 'ZH_HANT_HK', + ZhHantMo = 'ZH_HANT_MO', + ZhHantTw = 'ZH_HANT_TW', + Zu = 'ZU', + ZuZa = 'ZU_ZA' +} export type LanguageDisplay = { - __typename?: 'LanguageDisplay'; /** ISO 639 representation of the language name. */ - code: LanguageCodeEnum; + readonly code: LanguageCodeEnum; /** Full name of the language. */ - language: Scalars['String']; + readonly language: Scalars['String']; }; /** Store the current and allowed usage. */ export type LimitInfo = { - __typename?: 'LimitInfo'; /** Defines the allowed maximum resource usage, null means unlimited. */ - allowedUsage: Limits; + readonly allowedUsage: Limits; /** Defines the current resource usage. */ - currentUsage: Limits; + readonly currentUsage: Limits; }; export type Limits = { - __typename?: 'Limits'; /** Defines the number of channels. */ - channels?: Maybe; + readonly channels?: Maybe; /** Defines the number of order. */ - orders?: Maybe; + readonly orders?: Maybe; /** Defines the number of product variants. */ - productVariants?: Maybe; + readonly productVariants?: Maybe; /** Defines the number of staff users. */ - staffUsers?: Maybe; + readonly staffUsers?: Maybe; /** Defines the number of warehouses. */ - warehouses?: Maybe; + readonly warehouses?: Maybe; }; /** * List payment methods stored for the user by payment gateway. * - * Added in Saleor 3.15. - * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ export type ListStoredPaymentMethods = Event & { - __typename?: 'ListStoredPaymentMethods'; /** Channel in context which was used to fetch the list of payment methods. */ - channel: Channel; + readonly channel: Channel; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user for which the app should return a list of payment methods. */ - user: User; + readonly user: User; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** The manifest definition. */ export type Manifest = { - __typename?: 'Manifest'; /** Description of the app displayed in the dashboard. */ - about?: Maybe; + readonly about?: Maybe; /** App website rendered in the dashboard. */ - appUrl?: Maybe; - /** - * The audience that will be included in all JWT tokens for the app. - * - * Added in Saleor 3.8. - */ - audience?: Maybe; - /** - * The App's author name. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - author?: Maybe; - /** - * App's brand data. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - brand?: Maybe; + readonly appUrl?: Maybe; + /** The audience that will be included in all JWT tokens for the app. */ + readonly audience?: Maybe; + /** The App's author name. */ + readonly author?: Maybe; + /** App's brand data. */ + readonly brand?: Maybe; /** * URL to iframe with the configuration for the app. - * @deprecated This field will be removed in Saleor 4.0. Use `appUrl` instead. + * @deprecated Use `appUrl` instead. */ - configurationUrl?: Maybe; + readonly configurationUrl?: Maybe; /** * Description of the data privacy defined for this app. - * @deprecated This field will be removed in Saleor 4.0. Use `dataPrivacyUrl` instead. + * @deprecated Use `dataPrivacyUrl` instead. */ - dataPrivacy?: Maybe; + readonly dataPrivacy?: Maybe; /** URL to the full privacy policy. */ - dataPrivacyUrl?: Maybe; - /** List of extensions that will be mounted in Saleor's dashboard. For details, please [see the extension section.](https://docs.saleor.io/docs/3.x/developer/extending/apps/extending-dashboard-with-apps#key-concepts) */ - extensions: Array; + readonly dataPrivacyUrl?: Maybe; + /** List of extensions that will be mounted in Saleor's dashboard. For details, please [see the extension section.](https://docs.saleor.io/developer/extending/apps/extending-dashboard-with-apps#key-concepts) */ + readonly extensions: ReadonlyArray; /** External URL to the app homepage. */ - homepageUrl?: Maybe; + readonly homepageUrl?: Maybe; /** The identifier of the manifest for the app. */ - identifier: Scalars['String']; + readonly identifier: Scalars['String']; /** The name of the manifest for the app . */ - name: Scalars['String']; + readonly name: Scalars['String']; /** The array permissions required for the app. */ - permissions?: Maybe>; - /** - * Determines the app's required Saleor version as semver range. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - requiredSaleorVersion?: Maybe; + readonly permissions?: Maybe>; + /** Determines the app's required Saleor version as semver range. */ + readonly requiredSaleorVersion?: Maybe; /** External URL to the page where app users can find support. */ - supportUrl?: Maybe; - /** Endpoint used during process of app installation, [see installing an app.](https://docs.saleor.io/docs/3.x/developer/extending/apps/installing-apps#installing-an-app) */ - tokenTargetUrl?: Maybe; + readonly supportUrl?: Maybe; + /** Endpoint used during process of app installation, [see installing an app.](https://docs.saleor.io/developer/extending/apps/installing-apps#installing-an-app) */ + readonly tokenTargetUrl?: Maybe; /** The version of the manifest for the app. */ - version: Scalars['String']; - /** - * List of the app's webhooks. - * - * Added in Saleor 3.5. - */ - webhooks: Array; + readonly version: Scalars['String']; + /** List of the app's webhooks. */ + readonly webhooks: ReadonlyArray; }; /** Metadata for the Margin class. */ export type Margin = { - __typename?: 'Margin'; /** The starting value of the margin. */ - start?: Maybe; + readonly start?: Maybe; /** The ending value of the margin. */ - stop?: Maybe; + readonly stop?: Maybe; }; /** @@ -10162,117 +8997,106 @@ export type Margin = { * PAYMENT_FLOW - new orders marked as paid will receive a * `Payment` object, that will cover the `order.total`. */ -export type MarkAsPaidStrategyEnum = - | 'PAYMENT_FLOW' - | 'TRANSACTION_FLOW'; - -/** An enumeration. */ -export type MeasurementUnitsEnum = - | 'ACRE_FT' - | 'ACRE_IN' - | 'CM' - | 'CUBIC_CENTIMETER' - | 'CUBIC_DECIMETER' - | 'CUBIC_FOOT' - | 'CUBIC_INCH' - | 'CUBIC_METER' - | 'CUBIC_MILLIMETER' - | 'CUBIC_YARD' - | 'DM' - | 'FL_OZ' - | 'FT' - | 'G' - | 'INCH' - | 'KG' - | 'KM' - | 'LB' - | 'LITER' - | 'M' - | 'MM' - | 'OZ' - | 'PINT' - | 'QT' - | 'SQ_CM' - | 'SQ_DM' - | 'SQ_FT' - | 'SQ_INCH' - | 'SQ_KM' - | 'SQ_M' - | 'SQ_MM' - | 'SQ_YD' - | 'TONNE' - | 'YD'; +export enum MarkAsPaidStrategyEnum { + PaymentFlow = 'PAYMENT_FLOW', + TransactionFlow = 'TRANSACTION_FLOW' +} + +export enum MeasurementUnitsEnum { + AcreFt = 'ACRE_FT', + AcreIn = 'ACRE_IN', + Cm = 'CM', + CubicCentimeter = 'CUBIC_CENTIMETER', + CubicDecimeter = 'CUBIC_DECIMETER', + CubicFoot = 'CUBIC_FOOT', + CubicInch = 'CUBIC_INCH', + CubicMeter = 'CUBIC_METER', + CubicMillimeter = 'CUBIC_MILLIMETER', + CubicYard = 'CUBIC_YARD', + Dm = 'DM', + FlOz = 'FL_OZ', + Ft = 'FT', + G = 'G', + Inch = 'INCH', + Kg = 'KG', + Km = 'KM', + Lb = 'LB', + Liter = 'LITER', + M = 'M', + Mm = 'MM', + Oz = 'OZ', + Pint = 'PINT', + Qt = 'QT', + SqCm = 'SQ_CM', + SqDm = 'SQ_DM', + SqFt = 'SQ_FT', + SqInch = 'SQ_INCH', + SqKm = 'SQ_KM', + SqM = 'SQ_M', + SqMm = 'SQ_MM', + SqYd = 'SQ_YD', + Tonne = 'TONNE', + Yd = 'YD' +} export type MeasurementUnitsEnumFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; }; -export type MediaChoicesSortField = +export enum MediaChoicesSortField { /** Sort media by ID. */ - | 'ID'; + Id = 'ID' +} export type MediaInput = { /** Alt text for a product media. */ - alt?: InputMaybe; + readonly alt?: InputMaybe; /** Represents an image file in a multipart request. */ - image?: InputMaybe; + readonly image?: InputMaybe; /** Represents an URL to an external media. */ - mediaUrl?: InputMaybe; + readonly mediaUrl?: InputMaybe; }; export type MediaSortingInput = { /** Specifies the direction in which to sort media. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort media by the selected field. */ - field: MediaChoicesSortField; + readonly field: MediaChoicesSortField; }; /** Represents a single menu - an object that is used to help navigate through the store. */ export type Menu = Node & ObjectWithMetadata & { - __typename?: 'Menu'; /** The ID of the menu. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Menu items associated with this menu. */ - items?: Maybe>; + readonly items?: Maybe>; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** The name of the menu. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Slug of the menu. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; }; @@ -10284,7 +9108,7 @@ export type MenuMetafieldArgs = { /** Represents a single menu - an object that is used to help navigate through the store. */ export type MenuMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -10296,7 +9120,7 @@ export type MenuPrivateMetafieldArgs = { /** Represents a single menu - an object that is used to help navigate through the store. */ export type MenuPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** @@ -10308,29 +9132,26 @@ export type MenuPrivateMetafieldsArgs = { * - MENU_DELETED (async): A menu was deleted. */ export type MenuBulkDelete = { - __typename?: 'MenuBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; }; export type MenuCountableConnection = { - __typename?: 'MenuCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type MenuCountableEdge = { - __typename?: 'MenuCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Menu; + readonly node: Menu; }; /** @@ -10342,47 +9163,37 @@ export type MenuCountableEdge = { * - MENU_CREATED (async): A menu was created. */ export type MenuCreate = { - __typename?: 'MenuCreate'; - errors: Array; - menu?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; + readonly errors: ReadonlyArray; + readonly menu?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; }; export type MenuCreateInput = { /** List of menu items. */ - items?: InputMaybe>; + readonly items?: InputMaybe>; /** Name of the menu. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Slug of the menu. Will be generated if not provided. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; -/** - * Event sent when new menu is created. - * - * Added in Saleor 3.4. - */ +/** Event sent when new menu is created. */ export type MenuCreated = Event & { - __typename?: 'MenuCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The menu the event relates to. */ - menu?: Maybe; + readonly menu?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when new menu is created. - * - * Added in Saleor 3.4. - */ +/** Event sent when new menu is created. */ export type MenuCreatedMenuArgs = { channel?: InputMaybe; }; @@ -10396,135 +9207,111 @@ export type MenuCreatedMenuArgs = { * - MENU_DELETED (async): A menu was deleted. */ export type MenuDelete = { - __typename?: 'MenuDelete'; - errors: Array; - menu?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; + readonly errors: ReadonlyArray; + readonly menu?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; }; -/** - * Event sent when menu is deleted. - * - * Added in Saleor 3.4. - */ +/** Event sent when menu is deleted. */ export type MenuDeleted = Event & { - __typename?: 'MenuDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The menu the event relates to. */ - menu?: Maybe; + readonly menu?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when menu is deleted. - * - * Added in Saleor 3.4. - */ +/** Event sent when menu is deleted. */ export type MenuDeletedMenuArgs = { channel?: InputMaybe; }; export type MenuError = { - __typename?: 'MenuError'; /** The error code. */ - code: MenuErrorCode; + readonly code: MenuErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; -}; - -/** An enumeration. */ -export type MenuErrorCode = - | 'CANNOT_ASSIGN_NODE' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_MENU_ITEM' - | 'NOT_FOUND' - | 'NO_MENU_ITEM_PROVIDED' - | 'REQUIRED' - | 'TOO_MANY_MENU_ITEMS' - | 'UNIQUE'; + readonly message?: Maybe; +}; + +export enum MenuErrorCode { + CannotAssignNode = 'CANNOT_ASSIGN_NODE', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidMenuItem = 'INVALID_MENU_ITEM', + NotFound = 'NOT_FOUND', + NoMenuItemProvided = 'NO_MENU_ITEM_PROVIDED', + Required = 'REQUIRED', + TooManyMenuItems = 'TOO_MANY_MENU_ITEMS', + Unique = 'UNIQUE' +} export type MenuFilterInput = { - metadata?: InputMaybe>; - search?: InputMaybe; - slug?: InputMaybe>; - slugs?: InputMaybe>; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; + readonly slug?: InputMaybe>; + readonly slugs?: InputMaybe>; }; export type MenuInput = { /** Name of the menu. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Slug of the menu. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; /** Represents a single item of the related menu. Can store categories, collection or pages. */ export type MenuItem = Node & ObjectWithMetadata & { - __typename?: 'MenuItem'; /** Category associated with the menu item. */ - category?: Maybe; + readonly category?: Maybe; /** Represents the child items of the current menu item. */ - children?: Maybe>; + readonly children?: Maybe>; /** A collection associated with this menu item. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - collection?: Maybe; + readonly collection?: Maybe; /** The ID of the menu item. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Indicates the position of the menu item within the menu structure. */ - level: Scalars['Int']; + readonly level: Scalars['Int']; /** Represents the menu to which the menu item belongs. */ - menu: Menu; + readonly menu: Menu; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** The name of the menu item. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** A page associated with this menu item. Requires one of the following permissions to include unpublished items: MANAGE_PAGES. */ - page?: Maybe; + readonly page?: Maybe; /** ID of parent menu item. If empty, menu will be top level menu. */ - parent?: Maybe; + readonly parent?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Returns translated menu item fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** URL to the menu item. */ - url?: Maybe; + readonly url?: Maybe; }; @@ -10536,7 +9323,7 @@ export type MenuItemMetafieldArgs = { /** Represents a single item of the related menu. Can store categories, collection or pages. */ export type MenuItemMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -10548,7 +9335,7 @@ export type MenuItemPrivateMetafieldArgs = { /** Represents a single item of the related menu. Can store categories, collection or pages. */ export type MenuItemPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -10566,29 +9353,26 @@ export type MenuItemTranslationArgs = { * - MENU_ITEM_DELETED (async): A menu item was deleted. */ export type MenuItemBulkDelete = { - __typename?: 'MenuItemBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; }; export type MenuItemCountableConnection = { - __typename?: 'MenuItemCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type MenuItemCountableEdge = { - __typename?: 'MenuItemCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: MenuItem; + readonly node: MenuItem; }; /** @@ -10600,55 +9384,45 @@ export type MenuItemCountableEdge = { * - MENU_ITEM_CREATED (async): A menu item was created. */ export type MenuItemCreate = { - __typename?: 'MenuItemCreate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; - menuItem?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; + readonly menuItem?: Maybe; }; export type MenuItemCreateInput = { /** Category to which item points. */ - category?: InputMaybe; + readonly category?: InputMaybe; /** Collection to which item points. */ - collection?: InputMaybe; + readonly collection?: InputMaybe; /** Menu to which item belongs. */ - menu: Scalars['ID']; + readonly menu: Scalars['ID']; /** Name of the menu item. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Page to which item points. */ - page?: InputMaybe; + readonly page?: InputMaybe; /** ID of the parent menu. If empty, menu will be top level menu. */ - parent?: InputMaybe; + readonly parent?: InputMaybe; /** URL of the pointed item. */ - url?: InputMaybe; + readonly url?: InputMaybe; }; -/** - * Event sent when new menu item is created. - * - * Added in Saleor 3.4. - */ +/** Event sent when new menu item is created. */ export type MenuItemCreated = Event & { - __typename?: 'MenuItemCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The menu item the event relates to. */ - menuItem?: Maybe; + readonly menuItem?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when new menu item is created. - * - * Added in Saleor 3.4. - */ +/** Event sent when new menu item is created. */ export type MenuItemCreatedMenuItemArgs = { channel?: InputMaybe; }; @@ -10662,58 +9436,48 @@ export type MenuItemCreatedMenuItemArgs = { * - MENU_ITEM_DELETED (async): A menu item was deleted. */ export type MenuItemDelete = { - __typename?: 'MenuItemDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; - menuItem?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; + readonly menuItem?: Maybe; }; -/** - * Event sent when menu item is deleted. - * - * Added in Saleor 3.4. - */ +/** Event sent when menu item is deleted. */ export type MenuItemDeleted = Event & { - __typename?: 'MenuItemDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The menu item the event relates to. */ - menuItem?: Maybe; + readonly menuItem?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when menu item is deleted. - * - * Added in Saleor 3.4. - */ +/** Event sent when menu item is deleted. */ export type MenuItemDeletedMenuItemArgs = { channel?: InputMaybe; }; export type MenuItemFilterInput = { - metadata?: InputMaybe>; - search?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; }; export type MenuItemInput = { /** Category to which item points. */ - category?: InputMaybe; + readonly category?: InputMaybe; /** Collection to which item points. */ - collection?: InputMaybe; + readonly collection?: InputMaybe; /** Name of the menu item. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Page to which item points. */ - page?: InputMaybe; + readonly page?: InputMaybe; /** URL of the pointed item. */ - url?: InputMaybe; + readonly url?: InputMaybe; }; /** @@ -10725,50 +9489,44 @@ export type MenuItemInput = { * - MENU_ITEM_UPDATED (async): Optionally triggered when sort order or parent changed for menu item. */ export type MenuItemMove = { - __typename?: 'MenuItemMove'; - errors: Array; + readonly errors: ReadonlyArray; /** Assigned menu to move within. */ - menu?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; + readonly menu?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; }; export type MenuItemMoveInput = { /** The menu item ID to move. */ - itemId: Scalars['ID']; + readonly itemId: Scalars['ID']; /** ID of the parent menu. If empty, menu will be top level menu. */ - parentId?: InputMaybe; + readonly parentId?: InputMaybe; /** The new relative sorting position of the item (from -inf to +inf). 1 moves the item one position forward, -1 moves the item one position backward, 0 leaves the item unchanged. */ - sortOrder?: InputMaybe; + readonly sortOrder?: InputMaybe; }; export type MenuItemSortingInput = { /** Specifies the direction in which to sort menu items. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort menu items by the selected field. */ - field: MenuItemsSortField; + readonly field: MenuItemsSortField; }; /** Represents menu item's original translatable fields and related translations. */ export type MenuItemTranslatableContent = Node & { - __typename?: 'MenuItemTranslatableContent'; /** The ID of the menu item translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Represents a single item of the related menu. Can store categories, collection or pages. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. + * @deprecated Get model fields from the root level queries. */ - menuItem?: Maybe; - /** - * The ID of the menu item to translate. - * - * Added in Saleor 3.14. - */ - menuItemId: Scalars['ID']; + readonly menuItem?: Maybe; + /** The ID of the menu item to translate. */ + readonly menuItemId: Scalars['ID']; /** Name of the menu item to translate. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Returns translated menu item fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -10783,28 +9541,22 @@ export type MenuItemTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type MenuItemTranslate = { - __typename?: 'MenuItemTranslate'; - errors: Array; - menuItem?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly errors: ReadonlyArray; + readonly menuItem?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; /** Represents menu item translations. */ export type MenuItemTranslation = Node & { - __typename?: 'MenuItemTranslation'; /** The ID of the menu item translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated menu item name. */ - name: Scalars['String']; - /** - * Represents the menu item fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly name: Scalars['String']; + /** Represents the menu item fields to translate. */ + readonly translatableContent?: Maybe; }; /** @@ -10816,57 +9568,49 @@ export type MenuItemTranslation = Node & { * - MENU_ITEM_UPDATED (async): A menu item was updated. */ export type MenuItemUpdate = { - __typename?: 'MenuItemUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; - menuItem?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; + readonly menuItem?: Maybe; }; -/** - * Event sent when menu item is updated. - * - * Added in Saleor 3.4. - */ +/** Event sent when menu item is updated. */ export type MenuItemUpdated = Event & { - __typename?: 'MenuItemUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The menu item the event relates to. */ - menuItem?: Maybe; + readonly menuItem?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when menu item is updated. - * - * Added in Saleor 3.4. - */ +/** Event sent when menu item is updated. */ export type MenuItemUpdatedMenuItemArgs = { channel?: InputMaybe; }; -export type MenuItemsSortField = +export enum MenuItemsSortField { /** Sort menu items by name. */ - | 'NAME'; + Name = 'NAME' +} -export type MenuSortField = +export enum MenuSortField { /** Sort menus by items count. */ - | 'ITEMS_COUNT' + ItemsCount = 'ITEMS_COUNT', /** Sort menus by name. */ - | 'NAME'; + Name = 'NAME' +} export type MenuSortingInput = { /** Specifies the direction in which to sort menus. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort menus by the selected field. */ - field: MenuSortField; + readonly field: MenuSortField; }; /** @@ -10878,116 +9622,101 @@ export type MenuSortingInput = { * - MENU_UPDATED (async): A menu was updated. */ export type MenuUpdate = { - __typename?: 'MenuUpdate'; - errors: Array; - menu?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - menuErrors: Array; + readonly errors: ReadonlyArray; + readonly menu?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly menuErrors: ReadonlyArray; }; -/** - * Event sent when menu is updated. - * - * Added in Saleor 3.4. - */ +/** Event sent when menu is updated. */ export type MenuUpdated = Event & { - __typename?: 'MenuUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The menu the event relates to. */ - menu?: Maybe; + readonly menu?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when menu is updated. - * - * Added in Saleor 3.4. - */ +/** Event sent when menu is updated. */ export type MenuUpdatedMenuArgs = { channel?: InputMaybe; }; export type MetadataError = { - __typename?: 'MetadataError'; /** The error code. */ - code: MetadataErrorCode; + readonly code: MetadataErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type MetadataErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'NOT_UPDATED' - | 'REQUIRED'; +export enum MetadataErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + NotUpdated = 'NOT_UPDATED', + Required = 'REQUIRED' +} export type MetadataFilter = { /** Key of a metadata item. */ - key: Scalars['String']; + readonly key: Scalars['String']; /** Value of a metadata item. */ - value?: InputMaybe; + readonly value?: InputMaybe; }; export type MetadataInput = { /** Key of a metadata item. */ - key: Scalars['String']; + readonly key: Scalars['String']; /** Value of a metadata item. */ - value: Scalars['String']; + readonly value: Scalars['String']; }; export type MetadataItem = { - __typename?: 'MetadataItem'; /** Key of a metadata item. */ - key: Scalars['String']; + readonly key: Scalars['String']; /** Value of a metadata item. */ - value: Scalars['String']; + readonly value: Scalars['String']; }; /** Represents amount of money in specific currency. */ export type Money = { - __typename?: 'Money'; /** Amount of money. */ - amount: Scalars['Float']; + readonly amount: Scalars['Float']; /** Currency code. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; }; export type MoneyInput = { /** Amount of money. */ - amount: Scalars['PositiveDecimal']; + readonly amount: Scalars['PositiveDecimal']; /** Currency code. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; }; /** Represents a range of amounts of money. */ export type MoneyRange = { - __typename?: 'MoneyRange'; /** Lower bound of a price range. */ - start?: Maybe; + readonly start?: Maybe; /** Upper bound of a price range. */ - stop?: Maybe; + readonly stop?: Maybe; }; export type MoveProductInput = { /** The ID of the product to move. */ - productId: Scalars['ID']; + readonly productId: Scalars['ID']; /** The relative sorting position of the product (from -inf to +inf) starting from the first given product's actual position.1 moves the item one position forward, -1 moves the item one position backward, 0 leaves the item unchanged. */ - sortOrder?: InputMaybe; + readonly sortOrder?: InputMaybe; }; export type Mutation = { - __typename?: 'Mutation'; /** * Create a new address for the customer. * @@ -10997,21 +9726,21 @@ export type Mutation = { * - CUSTOMER_UPDATED (async): A customer account was updated. * - ADDRESS_CREATED (async): An address was created. */ - accountAddressCreate?: Maybe; + readonly accountAddressCreate?: Maybe; /** * Delete an address of the logged-in user. Requires one of the following permissions: MANAGE_USERS, IS_OWNER. * * Triggers the following webhook events: * - ADDRESS_DELETED (async): An address was deleted. */ - accountAddressDelete?: Maybe; + readonly accountAddressDelete?: Maybe; /** * Updates an address of the logged-in user. Requires one of the following permissions: MANAGE_USERS, IS_OWNER. * * Triggers the following webhook events: * - ADDRESS_UPDATED (async): An address was updated. */ - accountAddressUpdate?: Maybe; + readonly accountAddressUpdate?: Maybe; /** * Remove user account. * @@ -11020,7 +9749,7 @@ export type Mutation = { * Triggers the following webhook events: * - ACCOUNT_DELETED (async): Account was deleted. */ - accountDelete?: Maybe; + readonly accountDelete?: Maybe; /** * Register a new user. * @@ -11029,7 +9758,7 @@ export type Mutation = { * - NOTIFY_USER (async): A notification for account confirmation. * - ACCOUNT_CONFIRMATION_REQUESTED (async): An user confirmation was requested. This event is always sent regardless of settings. */ - accountRegister?: Maybe; + readonly accountRegister?: Maybe; /** * Sends an email with the account removal link for the logged-in user. * @@ -11039,7 +9768,7 @@ export type Mutation = { * - NOTIFY_USER (async): A notification for account delete request. * - ACCOUNT_DELETE_REQUESTED (async): An account delete requested. */ - accountRequestDeletion?: Maybe; + readonly accountRequestDeletion?: Maybe; /** * Sets a default address for the authenticated user. * @@ -11048,7 +9777,7 @@ export type Mutation = { * Triggers the following webhook events: * - CUSTOMER_UPDATED (async): A customer's address was updated. */ - accountSetDefaultAddress?: Maybe; + readonly accountSetDefaultAddress?: Maybe; /** * Updates the account of the logged-in user. * @@ -11058,7 +9787,7 @@ export type Mutation = { * - CUSTOMER_UPDATED (async): A customer account was updated. * - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. */ - accountUpdate?: Maybe; + readonly accountUpdate?: Maybe; /** * Creates user address. * @@ -11067,7 +9796,7 @@ export type Mutation = { * Triggers the following webhook events: * - ADDRESS_CREATED (async): A new address was created. */ - addressCreate?: Maybe; + readonly addressCreate?: Maybe; /** * Deletes an address. * @@ -11076,7 +9805,7 @@ export type Mutation = { * Triggers the following webhook events: * - ADDRESS_DELETED (async): An address was deleted. */ - addressDelete?: Maybe; + readonly addressDelete?: Maybe; /** * Sets a default address for the given user. * @@ -11085,7 +9814,7 @@ export type Mutation = { * Triggers the following webhook events: * - CUSTOMER_UPDATED (async): A customer was updated. */ - addressSetDefault?: Maybe; + readonly addressSetDefault?: Maybe; /** * Updates an address. * @@ -11094,7 +9823,7 @@ export type Mutation = { * Triggers the following webhook events: * - ADDRESS_UPDATED (async): An address was updated. */ - addressUpdate?: Maybe; + readonly addressUpdate?: Maybe; /** * Activate the app. * @@ -11103,14 +9832,14 @@ export type Mutation = { * Triggers the following webhook events: * - APP_STATUS_CHANGED (async): An app was activated. */ - appActivate?: Maybe; + readonly appActivate?: Maybe; /** * Creates a new app. Requires the following permissions: AUTHENTICATED_STAFF_USER and MANAGE_APPS. * * Triggers the following webhook events: * - APP_INSTALLED (async): An app was installed. */ - appCreate?: Maybe; + readonly appCreate?: Maybe; /** * Deactivate the app. * @@ -11119,7 +9848,7 @@ export type Mutation = { * Triggers the following webhook events: * - APP_STATUS_CHANGED (async): An app was deactivated. */ - appDeactivate?: Maybe; + readonly appDeactivate?: Maybe; /** * Deletes an app. * @@ -11128,21 +9857,29 @@ export type Mutation = { * Triggers the following webhook events: * - APP_DELETED (async): An app was deleted. */ - appDelete?: Maybe; + readonly appDelete?: Maybe; /** * Delete failed installation. * * Requires one of the following permissions: MANAGE_APPS. */ - appDeleteFailedInstallation?: Maybe; + readonly appDeleteFailedInstallation?: Maybe; /** * Fetch and validate manifest. * * Requires one of the following permissions: MANAGE_APPS. */ - appFetchManifest?: Maybe; + readonly appFetchManifest?: Maybe; /** Install new app by using app manifest. Requires the following permissions: AUTHENTICATED_STAFF_USER and MANAGE_APPS. */ - appInstall?: Maybe; + readonly appInstall?: Maybe; + /** + * Re-enable sync webhooks for provided app. Can be used to manually re-enable sync webhooks for the app before the cooldown period ends. + * + * Added in Saleor 3.21. + * + * Requires one of the following permissions: MANAGE_APPS. + */ + readonly appReenableSyncWebhooks?: Maybe; /** * Retry failed installation of new app. * @@ -11151,21 +9888,21 @@ export type Mutation = { * Triggers the following webhook events: * - APP_INSTALLED (async): An app was installed. */ - appRetryInstall?: Maybe; + readonly appRetryInstall?: Maybe; /** * Creates a new token. * * Requires one of the following permissions: MANAGE_APPS. */ - appTokenCreate?: Maybe; + readonly appTokenCreate?: Maybe; /** * Deletes an authentication token assigned to app. * * Requires one of the following permissions: MANAGE_APPS. */ - appTokenDelete?: Maybe; + readonly appTokenDelete?: Maybe; /** Verify provided app token. */ - appTokenVerify?: Maybe; + readonly appTokenVerify?: Maybe; /** * Updates an existing app. * @@ -11174,30 +9911,26 @@ export type Mutation = { * Triggers the following webhook events: * - APP_UPDATED (async): An app was updated. */ - appUpdate?: Maybe; + readonly appUpdate?: Maybe; /** * Assigns storefront's navigation menus. * * Requires one of the following permissions: MANAGE_MENUS, MANAGE_SETTINGS. */ - assignNavigation?: Maybe; + readonly assignNavigation?: Maybe; /** * Add shipping zone to given warehouse. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - assignWarehouseShippingZone?: Maybe; + readonly assignWarehouseShippingZone?: Maybe; /** * Creates attributes. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Triggers the following webhook events: * - ATTRIBUTE_CREATED (async): An attribute was created. */ - attributeBulkCreate?: Maybe; + readonly attributeBulkCreate?: Maybe; /** * Deletes attributes. * @@ -11206,37 +9939,29 @@ export type Mutation = { * Triggers the following webhook events: * - ATTRIBUTE_DELETED (async): An attribute was deleted. */ - attributeBulkDelete?: Maybe; + readonly attributeBulkDelete?: Maybe; /** * Creates/updates translations for attributes. * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - attributeBulkTranslate?: Maybe; + readonly attributeBulkTranslate?: Maybe; /** * Updates attributes. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Triggers the following webhook events: * - ATTRIBUTE_UPDATED (async): An attribute was updated. Optionally called when new attribute value was created or deleted. * - ATTRIBUTE_VALUE_CREATED (async): Called optionally when an attribute value was created. * - ATTRIBUTE_VALUE_DELETED (async): Called optionally when an attribute value was deleted. */ - attributeBulkUpdate?: Maybe; + readonly attributeBulkUpdate?: Maybe; /** * Creates an attribute. * * Triggers the following webhook events: * - ATTRIBUTE_CREATED (async): An attribute was created. */ - attributeCreate?: Maybe; + readonly attributeCreate?: Maybe; /** * Deletes an attribute. * @@ -11245,7 +9970,7 @@ export type Mutation = { * Triggers the following webhook events: * - ATTRIBUTE_DELETED (async): An attribute was deleted. */ - attributeDelete?: Maybe; + readonly attributeDelete?: Maybe; /** * Reorder the values of an attribute. * @@ -11255,13 +9980,13 @@ export type Mutation = { * - ATTRIBUTE_VALUE_UPDATED (async): An attribute value was updated. * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ - attributeReorderValues?: Maybe; + readonly attributeReorderValues?: Maybe; /** * Creates/updates translations for an attribute. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - attributeTranslate?: Maybe; + readonly attributeTranslate?: Maybe; /** * Updates attribute. * @@ -11270,7 +9995,7 @@ export type Mutation = { * Triggers the following webhook events: * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ - attributeUpdate?: Maybe; + readonly attributeUpdate?: Maybe; /** * Deletes values of attributes. * @@ -11280,17 +10005,13 @@ export type Mutation = { * - ATTRIBUTE_VALUE_DELETED (async): An attribute value was deleted. * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ - attributeValueBulkDelete?: Maybe; + readonly attributeValueBulkDelete?: Maybe; /** * Creates/updates translations for attributes values. * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - attributeValueBulkTranslate?: Maybe; + readonly attributeValueBulkTranslate?: Maybe; /** * Creates a value for an attribute. * @@ -11300,7 +10021,7 @@ export type Mutation = { * - ATTRIBUTE_VALUE_CREATED (async): An attribute value was created. * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ - attributeValueCreate?: Maybe; + readonly attributeValueCreate?: Maybe; /** * Deletes a value of an attribute. * @@ -11310,13 +10031,13 @@ export type Mutation = { * - ATTRIBUTE_VALUE_DELETED (async): An attribute value was deleted. * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ - attributeValueDelete?: Maybe; + readonly attributeValueDelete?: Maybe; /** * Creates/updates translations for an attribute value. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - attributeValueTranslate?: Maybe; + readonly attributeValueTranslate?: Maybe; /** * Updates value of an attribute. * @@ -11326,37 +10047,37 @@ export type Mutation = { * - ATTRIBUTE_VALUE_UPDATED (async): An attribute value was updated. * - ATTRIBUTE_UPDATED (async): An attribute was updated. */ - attributeValueUpdate?: Maybe; + readonly attributeValueUpdate?: Maybe; /** * Deletes categories. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - categoryBulkDelete?: Maybe; + readonly categoryBulkDelete?: Maybe; /** * Creates a new category. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - categoryCreate?: Maybe; + readonly categoryCreate?: Maybe; /** * Deletes a category. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - categoryDelete?: Maybe; + readonly categoryDelete?: Maybe; /** * Creates/updates translations for a category. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - categoryTranslate?: Maybe; + readonly categoryTranslate?: Maybe; /** * Updates a category. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - categoryUpdate?: Maybe; + readonly categoryUpdate?: Maybe; /** * Activate a channel. * @@ -11365,7 +10086,7 @@ export type Mutation = { * Triggers the following webhook events: * - CHANNEL_STATUS_CHANGED (async): A channel was activated. */ - channelActivate?: Maybe; + readonly channelActivate?: Maybe; /** * Creates new channel. * @@ -11374,7 +10095,7 @@ export type Mutation = { * Triggers the following webhook events: * - CHANNEL_CREATED (async): A channel was created. */ - channelCreate?: Maybe; + readonly channelCreate?: Maybe; /** * Deactivate a channel. * @@ -11383,7 +10104,7 @@ export type Mutation = { * Triggers the following webhook events: * - CHANNEL_STATUS_CHANGED (async): A channel was deactivated. */ - channelDeactivate?: Maybe; + readonly channelDeactivate?: Maybe; /** * Delete a channel. Orders associated with the deleted channel will be moved to the target channel. Checkouts, product availability, and pricing will be removed. * @@ -11392,15 +10113,13 @@ export type Mutation = { * Triggers the following webhook events: * - CHANNEL_DELETED (async): A channel was deleted. */ - channelDelete?: Maybe; + readonly channelDelete?: Maybe; /** * Reorder the warehouses of a channel. * - * Added in Saleor 3.7. - * * Requires one of the following permissions: MANAGE_CHANNELS. */ - channelReorderWarehouses?: Maybe; + readonly channelReorderWarehouses?: Maybe; /** * Update a channel. * @@ -11413,21 +10132,21 @@ export type Mutation = { * - CHANNEL_UPDATED (async): A channel was updated. * - CHANNEL_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. */ - channelUpdate?: Maybe; + readonly channelUpdate?: Maybe; /** * Adds a gift card or a voucher to a checkout. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutAddPromoCode?: Maybe; + readonly checkoutAddPromoCode?: Maybe; /** * Update billing address in the existing checkout. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutBillingAddressUpdate?: Maybe; + readonly checkoutBillingAddressUpdate?: Maybe; /** * Completes the checkout. As a result a new order is created. The mutation allows to create the unpaid order when setting `orderSettings.allowUnpaidOrders` for given `Channel` is set to `true`. When `orderSettings.allowUnpaidOrders` is set to `false`, checkout can be completed only when attached `Payment`/`TransactionItem`s fully cover the checkout's total. When processing the checkout with `Payment`, in case of required additional confirmation step like 3D secure, the `confirmationNeeded` flag will be set to True and no order will be created until payment is confirmed with second call of this mutation. * @@ -11443,7 +10162,7 @@ export type Mutation = { * - ORDER_FULLY_PAID (async): Triggered when newly created order is fully paid. * - ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. */ - checkoutComplete?: Maybe; + readonly checkoutComplete?: Maybe; /** * Create a new checkout. * @@ -11452,172 +10171,173 @@ export type Mutation = { * Triggers the following webhook events: * - CHECKOUT_CREATED (async): A checkout was created. */ - checkoutCreate?: Maybe; + readonly checkoutCreate?: Maybe; + /** Create new checkout from existing order. */ + readonly checkoutCreateFromOrder?: Maybe; /** - * Create new checkout from existing order. + * Sets the customer as the owner of the checkout. * - * Added in Saleor 3.14. + * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_USER. * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. + * Triggers the following webhook events: + * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutCreateFromOrder?: Maybe; + readonly checkoutCustomerAttach?: Maybe; /** - * Sets the customer as the owner of the checkout. + * Removes the user assigned as the owner of the checkout. * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_USER. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutCustomerAttach?: Maybe; + readonly checkoutCustomerDetach?: Maybe; /** - * Removes the user assigned as the owner of the checkout. + * Updates customer note in the existing checkout object. * - * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_USER. + * Added in Saleor 3.21. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutCustomerDetach?: Maybe; + readonly checkoutCustomerNoteUpdate?: Maybe; /** * Updates the delivery method (shipping method or pick up point) of the checkout. Updates the checkout shipping_address for click and collect delivery for a warehouse address. * - * Added in Saleor 3.1. - * * Triggers the following webhook events: * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout delivery method with the external one. * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutDeliveryMethodUpdate?: Maybe; + readonly checkoutDeliveryMethodUpdate?: Maybe; /** * Updates email address in the existing checkout object. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutEmailUpdate?: Maybe; + readonly checkoutEmailUpdate?: Maybe; /** * Update language code in the existing checkout. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutLanguageCodeUpdate?: Maybe; + readonly checkoutLanguageCodeUpdate?: Maybe; /** * Deletes a CheckoutLine. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. - * @deprecated This field will be removed in Saleor 4.0. Use `checkoutLinesDelete` instead. + * @deprecated Use `checkoutLinesDelete` instead. */ - checkoutLineDelete?: Maybe; + readonly checkoutLineDelete?: Maybe; /** * Adds a checkout line to the existing checkout.If line was already in checkout, its quantity will be increased. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutLinesAdd?: Maybe; + readonly checkoutLinesAdd?: Maybe; /** * Deletes checkout lines. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutLinesDelete?: Maybe; + readonly checkoutLinesDelete?: Maybe; /** * Updates checkout line in the existing checkout. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutLinesUpdate?: Maybe; + readonly checkoutLinesUpdate?: Maybe; /** Create a new payment for given checkout. */ - checkoutPaymentCreate?: Maybe; + readonly checkoutPaymentCreate?: Maybe; /** * Remove a gift card or a voucher from a checkout. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutRemovePromoCode?: Maybe; + readonly checkoutRemovePromoCode?: Maybe; /** * Update shipping address in the existing checkout. * * Triggers the following webhook events: * - CHECKOUT_UPDATED (async): A checkout was updated. */ - checkoutShippingAddressUpdate?: Maybe; + readonly checkoutShippingAddressUpdate?: Maybe; /** * Updates the shipping method of the checkout. * * Triggers the following webhook events: * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout shipping method with the external one. * - CHECKOUT_UPDATED (async): A checkout was updated. - * @deprecated This field will be removed in Saleor 4.0. Use `checkoutDeliveryMethodUpdate` instead. + * @deprecated Use `checkoutDeliveryMethodUpdate` instead. */ - checkoutShippingMethodUpdate?: Maybe; + readonly checkoutShippingMethodUpdate?: Maybe; /** * Adds products to a collection. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - collectionAddProducts?: Maybe; + readonly collectionAddProducts?: Maybe; /** * Deletes collections. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - collectionBulkDelete?: Maybe; + readonly collectionBulkDelete?: Maybe; /** * Manage collection's availability in channels. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - collectionChannelListingUpdate?: Maybe; + readonly collectionChannelListingUpdate?: Maybe; /** * Creates a new collection. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - collectionCreate?: Maybe; + readonly collectionCreate?: Maybe; /** * Deletes a collection. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - collectionDelete?: Maybe; + readonly collectionDelete?: Maybe; /** * Remove products from a collection. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - collectionRemoveProducts?: Maybe; + readonly collectionRemoveProducts?: Maybe; /** * Reorder the products of a collection. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - collectionReorderProducts?: Maybe; + readonly collectionReorderProducts?: Maybe; /** * Creates/updates translations for a collection. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - collectionTranslate?: Maybe; + readonly collectionTranslate?: Maybe; /** * Updates a collection. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - collectionUpdate?: Maybe; + readonly collectionUpdate?: Maybe; /** * Confirm user account with token sent by email during registration. * * Triggers the following webhook events: * - ACCOUNT_CONFIRMED (async): Account was confirmed. */ - confirmAccount?: Maybe; + readonly confirmAccount?: Maybe; /** * Confirm the email change of the logged-in user. * @@ -11628,13 +10348,13 @@ export type Mutation = { * - NOTIFY_USER (async): A notification that account email change was confirmed. * - ACCOUNT_EMAIL_CHANGED (async): An account email was changed. */ - confirmEmailChange?: Maybe; + readonly confirmEmailChange?: Maybe; /** * Creates new warehouse. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - createWarehouse?: Maybe; + readonly createWarehouse?: Maybe; /** * Deletes customers. * @@ -11643,21 +10363,17 @@ export type Mutation = { * Triggers the following webhook events: * - CUSTOMER_DELETED (async): A customer account was deleted. */ - customerBulkDelete?: Maybe; + readonly customerBulkDelete?: Maybe; /** * Updates customers. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_USERS. * * Triggers the following webhook events: * - CUSTOMER_UPDATED (async): A customer account was updated. * - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. */ - customerBulkUpdate?: Maybe; + readonly customerBulkUpdate?: Maybe; /** * Creates a new customer. * @@ -11669,7 +10385,7 @@ export type Mutation = { * - NOTIFY_USER (async): A notification for setting the password. * - ACCOUNT_SET_PASSWORD_REQUESTED (async): Setting a new password for the account is requested. */ - customerCreate?: Maybe; + readonly customerCreate?: Maybe; /** * Deletes a customer. * @@ -11678,7 +10394,7 @@ export type Mutation = { * Triggers the following webhook events: * - CUSTOMER_DELETED (async): A customer account was deleted. */ - customerDelete?: Maybe; + readonly customerDelete?: Maybe; /** * Updates an existing customer. * @@ -11688,96 +10404,94 @@ export type Mutation = { * - CUSTOMER_UPDATED (async): A new customer account was updated. * - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. */ - customerUpdate?: Maybe; + readonly customerUpdate?: Maybe; /** Delete metadata of an object. To use it, you need to have access to the modified object. */ - deleteMetadata?: Maybe; + readonly deleteMetadata?: Maybe; /** Delete object's private metadata. To use it, you need to be an authenticated staff user or an app and have access to the modified object. */ - deletePrivateMetadata?: Maybe; + readonly deletePrivateMetadata?: Maybe; /** * Deletes selected warehouse. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - deleteWarehouse?: Maybe; + readonly deleteWarehouse?: Maybe; /** * Create new digital content. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - digitalContentCreate?: Maybe; + readonly digitalContentCreate?: Maybe; /** * Remove digital content assigned to given variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - digitalContentDelete?: Maybe; + readonly digitalContentDelete?: Maybe; /** * Update digital content. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - digitalContentUpdate?: Maybe; + readonly digitalContentUpdate?: Maybe; /** * Generate new URL to digital content. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - digitalContentUrlCreate?: Maybe; + readonly digitalContentUrlCreate?: Maybe; /** * Deletes draft orders. * * Requires one of the following permissions: MANAGE_ORDERS. */ - draftOrderBulkDelete?: Maybe; + readonly draftOrderBulkDelete?: Maybe; /** * Completes creating an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - draftOrderComplete?: Maybe; + readonly draftOrderComplete?: Maybe; /** * Creates a new draft order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - draftOrderCreate?: Maybe; + readonly draftOrderCreate?: Maybe; /** * Deletes a draft order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - draftOrderDelete?: Maybe; + readonly draftOrderDelete?: Maybe; /** * Deletes order lines. * * Requires one of the following permissions: MANAGE_ORDERS. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - draftOrderLinesBulkDelete?: Maybe; + readonly draftOrderLinesBulkDelete?: Maybe; /** * Updates a draft order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - draftOrderUpdate?: Maybe; + readonly draftOrderUpdate?: Maybe; /** * Retries event delivery. * * Requires one of the following permissions: MANAGE_APPS. */ - eventDeliveryRetry?: Maybe; + readonly eventDeliveryRetry?: Maybe; /** * Export gift cards to csv file. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - NOTIFY_USER (async): A notification for the exported file. * - GIFT_CARD_EXPORT_COMPLETED (async): A notification for the exported file. */ - exportGiftCards?: Maybe; + readonly exportGiftCards?: Maybe; /** * Export products to csv file. * @@ -11787,7 +10501,7 @@ export type Mutation = { * - NOTIFY_USER (async): A notification for the exported file. * - PRODUCT_EXPORT_COMPLETED (async): A notification for the exported file. */ - exportProducts?: Maybe; + readonly exportProducts?: Maybe; /** * Export voucher codes to csv/xlsx file. * @@ -11800,30 +10514,28 @@ export type Mutation = { * Triggers the following webhook events: * - VOUCHER_CODE_EXPORT_COMPLETED (async): A notification for the exported file. */ - exportVoucherCodes?: Maybe; + readonly exportVoucherCodes?: Maybe; /** Prepare external authentication URL for user by custom plugin. */ - externalAuthenticationUrl?: Maybe; + readonly externalAuthenticationUrl?: Maybe; /** Logout user by custom plugin. */ - externalLogout?: Maybe; + readonly externalLogout?: Maybe; /** * Trigger sending a notification with the notify plugin method. Serializes nodes provided as ids parameter and includes this data in the notification payload. - * - * Added in Saleor 3.1. - * @deprecated \n\nDEPRECATED: this mutation will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - externalNotificationTrigger?: Maybe; + readonly externalNotificationTrigger?: Maybe; /** Obtain external access tokens for user by custom plugin. */ - externalObtainAccessTokens?: Maybe; + readonly externalObtainAccessTokens?: Maybe; /** Refresh user's access by custom plugin. */ - externalRefresh?: Maybe; + readonly externalRefresh?: Maybe; /** Verify external authentication data by plugin. */ - externalVerify?: Maybe; + readonly externalVerify?: Maybe; /** * Upload a file. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - fileUpload?: Maybe; + readonly fileUpload?: Maybe; /** * Activate a gift card. * @@ -11832,63 +10544,53 @@ export type Mutation = { * Triggers the following webhook events: * - GIFT_CARD_STATUS_CHANGED (async): A gift card was activated. */ - giftCardActivate?: Maybe; + readonly giftCardActivate?: Maybe; /** * Adds note to the gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_UPDATED (async): A gift card was updated. */ - giftCardAddNote?: Maybe; + readonly giftCardAddNote?: Maybe; /** * Activate gift cards. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_STATUS_CHANGED (async): A gift card was activated. */ - giftCardBulkActivate?: Maybe; + readonly giftCardBulkActivate?: Maybe; /** * Create gift cards. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_CREATED (async): A gift card was created. * - NOTIFY_USER (async): A notification for created gift card. */ - giftCardBulkCreate?: Maybe; + readonly giftCardBulkCreate?: Maybe; /** * Deactivate gift cards. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_STATUS_CHANGED (async): A gift card was deactivated. */ - giftCardBulkDeactivate?: Maybe; + readonly giftCardBulkDeactivate?: Maybe; /** * Delete gift cards. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_DELETED (async): A gift card was deleted. */ - giftCardBulkDelete?: Maybe; + readonly giftCardBulkDelete?: Maybe; /** * Creates a new gift card. * @@ -11898,7 +10600,7 @@ export type Mutation = { * - GIFT_CARD_CREATED (async): A gift card was created. * - NOTIFY_USER (async): A notification for created gift card. */ - giftCardCreate?: Maybe; + readonly giftCardCreate?: Maybe; /** * Deactivate a gift card. * @@ -11907,35 +10609,31 @@ export type Mutation = { * Triggers the following webhook events: * - GIFT_CARD_STATUS_CHANGED (async): A gift card was deactivated. */ - giftCardDeactivate?: Maybe; + readonly giftCardDeactivate?: Maybe; /** * Delete gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - GIFT_CARD_DELETED (async): A gift card was deleted. */ - giftCardDelete?: Maybe; + readonly giftCardDelete?: Maybe; /** * Resend a gift card. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. * * Triggers the following webhook events: * - NOTIFY_USER (async): A notification for gift card resend. */ - giftCardResend?: Maybe; + readonly giftCardResend?: Maybe; /** * Update gift card settings. * * Requires one of the following permissions: MANAGE_GIFT_CARD. */ - giftCardSettingsUpdate?: Maybe; + readonly giftCardSettingsUpdate?: Maybe; /** * Update a gift card. * @@ -11944,19 +10642,19 @@ export type Mutation = { * Triggers the following webhook events: * - GIFT_CARD_UPDATED (async): A gift card was updated. */ - giftCardUpdate?: Maybe; + readonly giftCardUpdate?: Maybe; /** * Creates a ready to send invoice. * * Requires one of the following permissions: MANAGE_ORDERS. */ - invoiceCreate?: Maybe; + readonly invoiceCreate?: Maybe; /** * Deletes an invoice. * * Requires one of the following permissions: MANAGE_ORDERS. */ - invoiceDelete?: Maybe; + readonly invoiceDelete?: Maybe; /** * Request an invoice for the order using plugin. * @@ -11965,7 +10663,7 @@ export type Mutation = { * Triggers the following webhook events: * - INVOICE_REQUESTED (async): An invoice was requested. */ - invoiceRequest?: Maybe; + readonly invoiceRequest?: Maybe; /** * Requests deletion of an invoice. * @@ -11974,7 +10672,7 @@ export type Mutation = { * Triggers the following webhook events: * - INVOICE_DELETED (async): An invoice was requested to delete. */ - invoiceRequestDelete?: Maybe; + readonly invoiceRequestDelete?: Maybe; /** * Send an invoice notification to the customer. * @@ -11984,13 +10682,13 @@ export type Mutation = { * - INVOICE_SENT (async): A notification for invoice send * - NOTIFY_USER (async): A notification for invoice send */ - invoiceSendNotification?: Maybe; + readonly invoiceSendNotification?: Maybe; /** * Updates an invoice. * * Requires one of the following permissions: MANAGE_ORDERS. */ - invoiceUpdate?: Maybe; + readonly invoiceUpdate?: Maybe; /** * Deletes menus. * @@ -11999,7 +10697,7 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_DELETED (async): A menu was deleted. */ - menuBulkDelete?: Maybe; + readonly menuBulkDelete?: Maybe; /** * Creates a new Menu. * @@ -12008,7 +10706,7 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_CREATED (async): A menu was created. */ - menuCreate?: Maybe; + readonly menuCreate?: Maybe; /** * Deletes a menu. * @@ -12017,7 +10715,7 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_DELETED (async): A menu was deleted. */ - menuDelete?: Maybe; + readonly menuDelete?: Maybe; /** * Deletes menu items. * @@ -12026,7 +10724,7 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_ITEM_DELETED (async): A menu item was deleted. */ - menuItemBulkDelete?: Maybe; + readonly menuItemBulkDelete?: Maybe; /** * Creates a new menu item. * @@ -12035,7 +10733,7 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_ITEM_CREATED (async): A menu item was created. */ - menuItemCreate?: Maybe; + readonly menuItemCreate?: Maybe; /** * Deletes a menu item. * @@ -12044,7 +10742,7 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_ITEM_DELETED (async): A menu item was deleted. */ - menuItemDelete?: Maybe; + readonly menuItemDelete?: Maybe; /** * Moves items of menus. * @@ -12053,13 +10751,13 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_ITEM_UPDATED (async): Optionally triggered when sort order or parent changed for menu item. */ - menuItemMove?: Maybe; + readonly menuItemMove?: Maybe; /** * Creates/updates translations for a menu item. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - menuItemTranslate?: Maybe; + readonly menuItemTranslate?: Maybe; /** * Updates a menu item. * @@ -12068,7 +10766,7 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_ITEM_UPDATED (async): A menu item was updated. */ - menuItemUpdate?: Maybe; + readonly menuItemUpdate?: Maybe; /** * Updates a menu. * @@ -12077,55 +10775,47 @@ export type Mutation = { * Triggers the following webhook events: * - MENU_UPDATED (async): A menu was updated. */ - menuUpdate?: Maybe; + readonly menuUpdate?: Maybe; /** * Adds note to the order. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. - * * Requires one of the following permissions: MANAGE_ORDERS. - * @deprecated This field will be removed in Saleor 4.0. Use `orderNoteAdd` instead. + * @deprecated Use `orderNoteAdd` instead. */ - orderAddNote?: Maybe; + readonly orderAddNote?: Maybe; /** * Cancels orders. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderBulkCancel?: Maybe; + readonly orderBulkCancel?: Maybe; /** * Creates multiple orders. * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS_IMPORT. */ - orderBulkCreate?: Maybe; + readonly orderBulkCreate?: Maybe; /** * Cancel an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderCancel?: Maybe; + readonly orderCancel?: Maybe; /** * Capture an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderCapture?: Maybe; + readonly orderCapture?: Maybe; /** * Confirms an unconfirmed order by changing status to unfulfilled. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderConfirm?: Maybe; + readonly orderConfirm?: Maybe; /** * Create new order from existing checkout. Requires the following permissions: AUTHENTICATED_APP and HANDLE_CHECKOUTS. * - * Added in Saleor 3.2. - * * Triggers the following webhook events: * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. * - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. @@ -12138,25 +10828,25 @@ export type Mutation = { * - ORDER_FULLY_PAID (async): Triggered when newly created order is fully paid. * - ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. */ - orderCreateFromCheckout?: Maybe; + readonly orderCreateFromCheckout?: Maybe; /** * Adds discount to the order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderDiscountAdd?: Maybe; + readonly orderDiscountAdd?: Maybe; /** * Remove discount from the order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderDiscountDelete?: Maybe; + readonly orderDiscountDelete?: Maybe; /** * Update discount for the order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderDiscountUpdate?: Maybe; + readonly orderDiscountUpdate?: Maybe; /** * Creates new fulfillments for an order. * @@ -12168,36 +10858,34 @@ export type Mutation = { * - FULFILLMENT_TRACKING_NUMBER_UPDATED (async): Sent when fulfillment tracking number is updated. * - FULFILLMENT_APPROVED (async): A fulfillment is approved. */ - orderFulfill?: Maybe; + readonly orderFulfill?: Maybe; /** * Approve existing fulfillment. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_ORDERS. * * Triggers the following webhook events: * - FULFILLMENT_APPROVED (async): Fulfillment is approved. */ - orderFulfillmentApprove?: Maybe; + readonly orderFulfillmentApprove?: Maybe; /** * Cancels existing fulfillment and optionally restocks items. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderFulfillmentCancel?: Maybe; + readonly orderFulfillmentCancel?: Maybe; /** * Refund products. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderFulfillmentRefundProducts?: Maybe; + readonly orderFulfillmentRefundProducts?: Maybe; /** * Return products. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderFulfillmentReturnProducts?: Maybe; + readonly orderFulfillmentReturnProducts?: Maybe; /** * Updates a fulfillment for an order. * @@ -12206,273 +10894,239 @@ export type Mutation = { * Triggers the following webhook events: * - FULFILLMENT_TRACKING_NUMBER_UPDATED (async): Fulfillment tracking number is updated. */ - orderFulfillmentUpdateTracking?: Maybe; + readonly orderFulfillmentUpdateTracking?: Maybe; /** * Adds granted refund to the order. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderGrantRefundCreate?: Maybe; + readonly orderGrantRefundCreate?: Maybe; /** * Updates granted refund. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderGrantRefundUpdate?: Maybe; + readonly orderGrantRefundUpdate?: Maybe; /** * Deletes an order line from an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderLineDelete?: Maybe; + readonly orderLineDelete?: Maybe; /** * Remove discount applied to the order line. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderLineDiscountRemove?: Maybe; + readonly orderLineDiscountRemove?: Maybe; /** * Update discount for the order line. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderLineDiscountUpdate?: Maybe; + readonly orderLineDiscountUpdate?: Maybe; /** * Updates an order line of an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderLineUpdate?: Maybe; + readonly orderLineUpdate?: Maybe; /** * Create order lines for an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderLinesCreate?: Maybe; + readonly orderLinesCreate?: Maybe; /** * Mark order as manually paid. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderMarkAsPaid?: Maybe; + readonly orderMarkAsPaid?: Maybe; /** * Adds note to the order. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderNoteAdd?: Maybe; + readonly orderNoteAdd?: Maybe; /** * Updates note of an order. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderNoteUpdate?: Maybe; + readonly orderNoteUpdate?: Maybe; /** * Refund an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderRefund?: Maybe; + readonly orderRefund?: Maybe; /** * Update shop order settings across all channels. Returns `orderSettings` for the first `channel` in alphabetical order. * * Requires one of the following permissions: MANAGE_ORDERS. - * @deprecated \n\nDEPRECATED: this mutation will be removed in Saleor 4.0. Use `channelUpdate` mutation instead. + * @deprecated Use `channelUpdate` mutation instead. */ - orderSettingsUpdate?: Maybe; + readonly orderSettingsUpdate?: Maybe; /** * Updates an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderUpdate?: Maybe; + readonly orderUpdate?: Maybe; /** * Updates a shipping method of the order. Requires shipping method ID to update, when null is passed then currently assigned shipping method is removed. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderUpdateShipping?: Maybe; + readonly orderUpdateShipping?: Maybe; /** * Void an order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orderVoid?: Maybe; + readonly orderVoid?: Maybe; /** * Assign attributes to a given page type. * * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - pageAttributeAssign?: Maybe; + readonly pageAttributeAssign?: Maybe; /** * Unassign attributes from a given page type. * * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - pageAttributeUnassign?: Maybe; + readonly pageAttributeUnassign?: Maybe; /** * Deletes pages. * * Requires one of the following permissions: MANAGE_PAGES. */ - pageBulkDelete?: Maybe; + readonly pageBulkDelete?: Maybe; /** * Publish pages. * * Requires one of the following permissions: MANAGE_PAGES. */ - pageBulkPublish?: Maybe; + readonly pageBulkPublish?: Maybe; /** * Creates a new page. * * Requires one of the following permissions: MANAGE_PAGES. */ - pageCreate?: Maybe; + readonly pageCreate?: Maybe; /** * Deletes a page. * * Requires one of the following permissions: MANAGE_PAGES. */ - pageDelete?: Maybe; + readonly pageDelete?: Maybe; /** * Reorder page attribute values. * * Requires one of the following permissions: MANAGE_PAGES. */ - pageReorderAttributeValues?: Maybe; + readonly pageReorderAttributeValues?: Maybe; /** * Creates/updates translations for a page. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - pageTranslate?: Maybe; + readonly pageTranslate?: Maybe; /** * Delete page types. * * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - pageTypeBulkDelete?: Maybe; + readonly pageTypeBulkDelete?: Maybe; /** * Create a new page type. * * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - pageTypeCreate?: Maybe; + readonly pageTypeCreate?: Maybe; /** * Delete a page type. * * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - pageTypeDelete?: Maybe; + readonly pageTypeDelete?: Maybe; /** * Reorder the attributes of a page type. * * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - pageTypeReorderAttributes?: Maybe; + readonly pageTypeReorderAttributes?: Maybe; /** * Update page type. * * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - pageTypeUpdate?: Maybe; + readonly pageTypeUpdate?: Maybe; /** * Updates an existing page. * * Requires one of the following permissions: MANAGE_PAGES. */ - pageUpdate?: Maybe; + readonly pageUpdate?: Maybe; /** * Change the password of the logged in user. * * Requires one of the following permissions: AUTHENTICATED_USER. */ - passwordChange?: Maybe; + readonly passwordChange?: Maybe; /** * Captures the authorized payment amount. * * Requires one of the following permissions: MANAGE_ORDERS. */ - paymentCapture?: Maybe; + readonly paymentCapture?: Maybe; /** Check payment balance. */ - paymentCheckBalance?: Maybe; - /** - * Initializes a payment gateway session. It triggers the webhook `PAYMENT_GATEWAY_INITIALIZE_SESSION`, to the requested `paymentGateways`. If `paymentGateways` is not provided, the webhook will be send to all subscribed payment gateways. There is a limit of 100 transaction items per checkout / order. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - paymentGatewayInitialize?: Maybe; + readonly paymentCheckBalance?: Maybe; + /** Initializes a payment gateway session. It triggers the webhook `PAYMENT_GATEWAY_INITIALIZE_SESSION`, to the requested `paymentGateways`. If `paymentGateways` is not provided, the webhook will be send to all subscribed payment gateways. There is a limit of 100 transaction items per checkout / order. */ + readonly paymentGatewayInitialize?: Maybe; /** * Initializes payment gateway for tokenizing payment method session. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION (sync): The customer requested to initialize payment gateway for tokenization. */ - paymentGatewayInitializeTokenization?: Maybe; + readonly paymentGatewayInitializeTokenization?: Maybe; /** Initializes payment process when it is required by gateway. */ - paymentInitialize?: Maybe; + readonly paymentInitialize?: Maybe; /** * Tokenize payment method. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION (sync): The customer requested to tokenize payment method. */ - paymentMethodInitializeTokenization?: Maybe; + readonly paymentMethodInitializeTokenization?: Maybe; /** * Tokenize payment method. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION (sync): The customer continues payment method tokenization. */ - paymentMethodProcessTokenization?: Maybe; + readonly paymentMethodProcessTokenization?: Maybe; /** * Refunds the captured payment amount. * * Requires one of the following permissions: MANAGE_ORDERS. */ - paymentRefund?: Maybe; + readonly paymentRefund?: Maybe; /** * Voids the authorized payment. * * Requires one of the following permissions: MANAGE_ORDERS. */ - paymentVoid?: Maybe; + readonly paymentVoid?: Maybe; /** * Create new permission group. Apps are not allowed to perform this mutation. * @@ -12481,7 +11135,7 @@ export type Mutation = { * Triggers the following webhook events: * - PERMISSION_GROUP_CREATED (async) */ - permissionGroupCreate?: Maybe; + readonly permissionGroupCreate?: Maybe; /** * Delete permission group. Apps are not allowed to perform this mutation. * @@ -12490,7 +11144,7 @@ export type Mutation = { * Triggers the following webhook events: * - PERMISSION_GROUP_DELETED (async) */ - permissionGroupDelete?: Maybe; + readonly permissionGroupDelete?: Maybe; /** * Update permission group. Apps are not allowed to perform this mutation. * @@ -12499,371 +11153,319 @@ export type Mutation = { * Triggers the following webhook events: * - PERMISSION_GROUP_UPDATED (async) */ - permissionGroupUpdate?: Maybe; + readonly permissionGroupUpdate?: Maybe; /** * Update plugin configuration. * * Requires one of the following permissions: MANAGE_PLUGINS. */ - pluginUpdate?: Maybe; + readonly pluginUpdate?: Maybe; /** * Assign attributes to a given product type. * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - productAttributeAssign?: Maybe; + readonly productAttributeAssign?: Maybe; /** * Update attributes assigned to product variant for given product type. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - productAttributeAssignmentUpdate?: Maybe; + readonly productAttributeAssignmentUpdate?: Maybe; /** * Un-assign attributes from a given product type. * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - productAttributeUnassign?: Maybe; + readonly productAttributeUnassign?: Maybe; /** * Creates products. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productBulkCreate?: Maybe; + readonly productBulkCreate?: Maybe; /** * Deletes products. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productBulkDelete?: Maybe; + readonly productBulkDelete?: Maybe; /** * Creates/updates translations for products. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. * * Triggers the following webhook events: * - TRANSLATION_CREATED (async): Called when a translation was created. * - TRANSLATION_UPDATED (async): Called when a translation was updated. */ - productBulkTranslate?: Maybe; + readonly productBulkTranslate?: Maybe; /** * Manage product's availability in channels. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productChannelListingUpdate?: Maybe; + readonly productChannelListingUpdate?: Maybe; /** * Creates a new product. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productCreate?: Maybe; + readonly productCreate?: Maybe; /** * Deletes a product. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productDelete?: Maybe; + readonly productDelete?: Maybe; /** * Deletes product media. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productMediaBulkDelete?: Maybe; + readonly productMediaBulkDelete?: Maybe; /** * Create a media object (image or video URL) associated with product. For image, this mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productMediaCreate?: Maybe; + readonly productMediaCreate?: Maybe; /** * Deletes a product media. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productMediaDelete?: Maybe; + readonly productMediaDelete?: Maybe; /** * Changes ordering of the product media. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productMediaReorder?: Maybe; + readonly productMediaReorder?: Maybe; /** * Updates a product media. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productMediaUpdate?: Maybe; + readonly productMediaUpdate?: Maybe; /** * Reorder product attribute values. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productReorderAttributeValues?: Maybe; + readonly productReorderAttributeValues?: Maybe; /** * Creates/updates translations for a product. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - productTranslate?: Maybe; + readonly productTranslate?: Maybe; /** * Deletes product types. * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - productTypeBulkDelete?: Maybe; + readonly productTypeBulkDelete?: Maybe; /** * Creates a new product type. * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - productTypeCreate?: Maybe; + readonly productTypeCreate?: Maybe; /** * Deletes a product type. * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - productTypeDelete?: Maybe; + readonly productTypeDelete?: Maybe; /** * Reorder the attributes of a product type. * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - productTypeReorderAttributes?: Maybe; + readonly productTypeReorderAttributes?: Maybe; /** * Updates an existing product type. * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ - productTypeUpdate?: Maybe; + readonly productTypeUpdate?: Maybe; /** * Updates an existing product. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productUpdate?: Maybe; + readonly productUpdate?: Maybe; /** * Creates product variants for a given product. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantBulkCreate?: Maybe; + readonly productVariantBulkCreate?: Maybe; /** * Deletes product variants. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantBulkDelete?: Maybe; + readonly productVariantBulkDelete?: Maybe; /** * Creates/updates translations for products variants. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. * * Triggers the following webhook events: * - TRANSLATION_CREATED (async): A translation was created. * - TRANSLATION_UPDATED (async): A translation was updated. */ - productVariantBulkTranslate?: Maybe; + readonly productVariantBulkTranslate?: Maybe; /** * Update multiple product variants. * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantBulkUpdate?: Maybe; + readonly productVariantBulkUpdate?: Maybe; /** * Manage product variant prices in channels. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantChannelListingUpdate?: Maybe; + readonly productVariantChannelListingUpdate?: Maybe; /** * Creates a new variant for a product. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantCreate?: Maybe; + readonly productVariantCreate?: Maybe; /** * Deletes a product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantDelete?: Maybe; + readonly productVariantDelete?: Maybe; /** * Deactivates product variant preorder. It changes all preorder allocation into regular allocation. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantPreorderDeactivate?: Maybe; + readonly productVariantPreorderDeactivate?: Maybe; /** * Reorder the variants of a product. Mutation updates updated_at on product and triggers PRODUCT_UPDATED webhook. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantReorder?: Maybe; + readonly productVariantReorder?: Maybe; /** * Reorder product variant attribute values. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantReorderAttributeValues?: Maybe; + readonly productVariantReorderAttributeValues?: Maybe; /** * Set default variant for a product. Mutation triggers PRODUCT_UPDATED webhook. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantSetDefault?: Maybe; + readonly productVariantSetDefault?: Maybe; /** * Creates stocks for product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantStocksCreate?: Maybe; + readonly productVariantStocksCreate?: Maybe; /** * Delete stocks from product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantStocksDelete?: Maybe; + readonly productVariantStocksDelete?: Maybe; /** * Update stocks for product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantStocksUpdate?: Maybe; + readonly productVariantStocksUpdate?: Maybe; /** * Creates/updates translations for a product variant. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - productVariantTranslate?: Maybe; + readonly productVariantTranslate?: Maybe; /** * Updates an existing variant for product. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - productVariantUpdate?: Maybe; + readonly productVariantUpdate?: Maybe; /** * Deletes promotions. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_DELETED (async): A promotion was deleted. */ - promotionBulkDelete?: Maybe; + readonly promotionBulkDelete?: Maybe; /** * Creates a new promotion. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_CREATED (async): A promotion was created. * - PROMOTION_STARTED (async): Optionally called if promotion was started. */ - promotionCreate?: Maybe; + readonly promotionCreate?: Maybe; /** * Deletes a promotion. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_DELETED (async): A promotion was deleted. */ - promotionDelete?: Maybe; + readonly promotionDelete?: Maybe; /** * Creates a new promotion rule. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_RULE_CREATED (async): A promotion rule was created. */ - promotionRuleCreate?: Maybe; + readonly promotionRuleCreate?: Maybe; /** * Deletes a promotion rule. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_RULE_DELETED (async): A promotion rule was deleted. */ - promotionRuleDelete?: Maybe; + readonly promotionRuleDelete?: Maybe; /** * Creates/updates translations for a promotion rule. * - * Added in Saleor 3.17. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - promotionRuleTranslate?: Maybe; + readonly promotionRuleTranslate?: Maybe; /** * Updates an existing promotion rule. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_RULE_UPDATED (async): A promotion rule was updated. */ - promotionRuleUpdate?: Maybe; + readonly promotionRuleUpdate?: Maybe; /** * Creates/updates translations for a promotion. * - * Added in Saleor 3.17. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - promotionTranslate?: Maybe; + readonly promotionTranslate?: Maybe; /** * Updates an existing promotion. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: @@ -12871,7 +11473,7 @@ export type Mutation = { * - PROMOTION_STARTED (async): Optionally called if promotion was started. * - PROMOTION_ENDED (async): Optionally called if promotion was ended. */ - promotionUpdate?: Maybe; + readonly promotionUpdate?: Maybe; /** * Request email change of the logged in user. * @@ -12881,7 +11483,7 @@ export type Mutation = { * - NOTIFY_USER (async): A notification for account email change. * - ACCOUNT_CHANGE_EMAIL_REQUESTED (async): An account email change was requested. */ - requestEmailChange?: Maybe; + readonly requestEmailChange?: Maybe; /** * Sends an email with the account password modification link. * @@ -12890,7 +11492,7 @@ export type Mutation = { * - ACCOUNT_SET_PASSWORD_REQUESTED (async): Setting a new password for the account is requested. * - STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. */ - requestPasswordReset?: Maybe; + readonly requestPasswordReset?: Maybe; /** * Deletes sales. * @@ -12899,195 +11501,182 @@ export type Mutation = { * Triggers the following webhook events: * - SALE_DELETED (async): A sale was deleted. */ - saleBulkDelete?: Maybe; + readonly saleBulkDelete?: Maybe; /** * Adds products, categories, collections to a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` mutation instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_UPDATED (async): A sale was updated. + * @deprecated Use `promotionRuleCreate` and `promotionRuleUpdate` mutations instead. */ - saleCataloguesAdd?: Maybe; + readonly saleCataloguesAdd?: Maybe; /** * Removes products, categories, collections from a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleUpdate` or `promotionRuleDelete` mutations instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_UPDATED (async): A sale was updated. + * @deprecated Use `promotionRuleUpdate` and `promotionRuleDelete` mutations instead. */ - saleCataloguesRemove?: Maybe; + readonly saleCataloguesRemove?: Maybe; /** * Manage sale's availability in channels. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` or `promotionRuleUpdate` mutations instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. + * @deprecated Use `promotionRuleUpdate` mutation instead. */ - saleChannelListingUpdate?: Maybe; + readonly saleChannelListingUpdate?: Maybe; /** * Creates a new sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionCreate` mutation instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_CREATED (async): A sale was created. + * @deprecated Use `promotionCreate` mutation instead. */ - saleCreate?: Maybe; + readonly saleCreate?: Maybe; /** * Deletes a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionDelete` mutation instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_DELETED (async): A sale was deleted. + * @deprecated Use `promotionDelete` mutation instead. */ - saleDelete?: Maybe; + readonly saleDelete?: Maybe; /** * Creates/updates translations for a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PromotionTranslate` mutation instead. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. + * @deprecated Use `promotionTranslate` mutation instead. */ - saleTranslate?: Maybe; + readonly saleTranslate?: Maybe; /** * Updates a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionUpdate` mutation instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_UPDATED (async): A sale was updated. * - SALE_TOGGLE (async): Optionally triggered when a sale is started or stopped. + * @deprecated Use `promotionUpdate` mutation instead. */ - saleUpdate?: Maybe; + readonly saleUpdate?: Maybe; /** * Sends a notification confirmation. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - NOTIFY_USER (async): A notification for account confirmation. * - ACCOUNT_CONFIRMATION_REQUESTED (async): An account confirmation was requested. This event is always sent regardless of settings. */ - sendConfirmationEmail?: Maybe; + readonly sendConfirmationEmail?: Maybe; /** Sets the user's password from the token sent by email using the RequestPasswordReset mutation. */ - setPassword?: Maybe; + readonly setPassword?: Maybe; /** * Manage shipping method's availability in channels. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingMethodChannelListingUpdate?: Maybe; + readonly shippingMethodChannelListingUpdate?: Maybe; /** * Deletes shipping prices. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingPriceBulkDelete?: Maybe; + readonly shippingPriceBulkDelete?: Maybe; /** * Creates a new shipping price. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingPriceCreate?: Maybe; + readonly shippingPriceCreate?: Maybe; /** * Deletes a shipping price. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingPriceDelete?: Maybe; + readonly shippingPriceDelete?: Maybe; /** * Exclude products from shipping price. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingPriceExcludeProducts?: Maybe; + readonly shippingPriceExcludeProducts?: Maybe; /** * Remove product from excluded list for shipping price. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingPriceRemoveProductFromExclude?: Maybe; + readonly shippingPriceRemoveProductFromExclude?: Maybe; /** * Creates/updates translations for a shipping method. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - shippingPriceTranslate?: Maybe; + readonly shippingPriceTranslate?: Maybe; /** * Updates a new shipping price. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingPriceUpdate?: Maybe; + readonly shippingPriceUpdate?: Maybe; /** * Deletes shipping zones. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingZoneBulkDelete?: Maybe; + readonly shippingZoneBulkDelete?: Maybe; /** * Creates a new shipping zone. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingZoneCreate?: Maybe; + readonly shippingZoneCreate?: Maybe; /** * Deletes a shipping zone. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingZoneDelete?: Maybe; + readonly shippingZoneDelete?: Maybe; /** * Updates a new shipping zone. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingZoneUpdate?: Maybe; + readonly shippingZoneUpdate?: Maybe; /** * Update the shop's address. If the `null` value is passed, the currently selected address will be deleted. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - shopAddressUpdate?: Maybe; + readonly shopAddressUpdate?: Maybe; /** * Updates site domain of the shop. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead. - * * Requires one of the following permissions: MANAGE_SETTINGS. - * @deprecated \n\nDEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead. + * @deprecated Use `PUBLIC_URL` environment variable instead. */ - shopDomainUpdate?: Maybe; + readonly shopDomainUpdate?: Maybe; /** * Fetch tax rates. * * Requires one of the following permissions: MANAGE_SETTINGS. - * @deprecated \n\nDEPRECATED: this mutation will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - shopFetchTaxRates?: Maybe; + readonly shopFetchTaxRates?: Maybe; /** * Creates/updates translations for shop settings. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - shopSettingsTranslate?: Maybe; + readonly shopSettingsTranslate?: Maybe; /** * Updates shop settings. * @@ -13096,7 +11685,7 @@ export type Mutation = { * Triggers the following webhook events: * - SHOP_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. */ - shopSettingsUpdate?: Maybe; + readonly shopSettingsUpdate?: Maybe; /** * Deletes staff users. Apps are not allowed to perform this mutation. * @@ -13105,7 +11694,7 @@ export type Mutation = { * Triggers the following webhook events: * - STAFF_DELETED (async): A staff account was deleted. */ - staffBulkDelete?: Maybe; + readonly staffBulkDelete?: Maybe; /** * Creates a new staff user. Apps are not allowed to perform this mutation. * @@ -13116,7 +11705,7 @@ export type Mutation = { * - NOTIFY_USER (async): A notification for setting the password. * - STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. */ - staffCreate?: Maybe; + readonly staffCreate?: Maybe; /** * Deletes a staff user. Apps are not allowed to perform this mutation. * @@ -13125,25 +11714,25 @@ export type Mutation = { * Triggers the following webhook events: * - STAFF_DELETED (async): A staff account was deleted. */ - staffDelete?: Maybe; + readonly staffDelete?: Maybe; /** * Creates a new staff notification recipient. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - staffNotificationRecipientCreate?: Maybe; + readonly staffNotificationRecipientCreate?: Maybe; /** * Delete staff notification recipient. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - staffNotificationRecipientDelete?: Maybe; + readonly staffNotificationRecipientDelete?: Maybe; /** * Updates a staff notification recipient. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - staffNotificationRecipientUpdate?: Maybe; + readonly staffNotificationRecipientUpdate?: Maybe; /** * Updates an existing staff user. Apps are not allowed to perform this mutation. * @@ -13152,213 +11741,172 @@ export type Mutation = { * Triggers the following webhook events: * - STAFF_UPDATED (async): A staff account was updated. */ - staffUpdate?: Maybe; + readonly staffUpdate?: Maybe; /** * Updates stocks for a given variant and warehouse. Variant and warehouse selectors have to be the same for all stock inputs. Is not allowed to use 'variantId' in one input and 'variantExternalReference' in another. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_PRODUCTS. * * Triggers the following webhook events: * - PRODUCT_VARIANT_STOCK_UPDATED (async): A product variant stock details were updated. */ - stockBulkUpdate?: Maybe; + readonly stockBulkUpdate?: Maybe; /** * Request to delete a stored payment method on payment provider side. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - STORED_PAYMENT_METHOD_DELETE_REQUESTED (sync): The customer requested to delete a payment method. */ - storedPaymentMethodRequestDelete?: Maybe; + readonly storedPaymentMethodRequestDelete?: Maybe; /** * Create a tax class. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ - taxClassCreate?: Maybe; + readonly taxClassCreate?: Maybe; /** * Delete a tax class. After deleting the tax class any products, product types or shipping methods using it are updated to use the default tax class. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ - taxClassDelete?: Maybe; + readonly taxClassDelete?: Maybe; /** * Update a tax class. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ - taxClassUpdate?: Maybe; + readonly taxClassUpdate?: Maybe; /** * Update tax configuration for a channel. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ - taxConfigurationUpdate?: Maybe; + readonly taxConfigurationUpdate?: Maybe; /** * Remove all tax class rates for a specific country. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ - taxCountryConfigurationDelete?: Maybe; + readonly taxCountryConfigurationDelete?: Maybe; /** * Update tax class rates for a specific country. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ - taxCountryConfigurationUpdate?: Maybe; + readonly taxCountryConfigurationUpdate?: Maybe; /** * Exempt checkout or order from charging the taxes. When tax exemption is enabled, taxes won't be charged for the checkout or order. Taxes may still be calculated in cases when product prices are entered with the tax included and the net price needs to be known. * - * Added in Saleor 3.8. - * * Requires one of the following permissions: MANAGE_TAXES. */ - taxExemptionManage?: Maybe; + readonly taxExemptionManage?: Maybe; /** Create JWT token. */ - tokenCreate?: Maybe; + readonly tokenCreate?: Maybe; /** Refresh JWT token. Mutation tries to take refreshToken from the input. If it fails it will try to take `refreshToken` from the http-only cookie `refreshToken`. `csrfToken` is required when `refreshToken` is provided as a cookie. */ - tokenRefresh?: Maybe; + readonly tokenRefresh?: Maybe; /** Verify JWT token. */ - tokenVerify?: Maybe; + readonly tokenVerify?: Maybe; /** * Deactivate all JWT tokens of the currently authenticated user. * * Requires one of the following permissions: AUTHENTICATED_USER. */ - tokensDeactivateAll?: Maybe; + readonly tokensDeactivateAll?: Maybe; /** * Create transaction for checkout or order. * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: HANDLE_PAYMENTS. */ - transactionCreate?: Maybe; + readonly transactionCreate?: Maybe; /** * Report the event for the transaction. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. - */ - transactionEventReport?: Maybe; - /** - * Initializes a transaction session. It triggers the webhook `TRANSACTION_INITIALIZE_SESSION`, to the requested `paymentGateways`. There is a limit of 100 transaction items per checkout / order. - * - * Added in Saleor 3.13. * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - transactionInitialize?: Maybe; - /** - * Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. + * Triggers the following webhook events: + * - TRANSACTION_ITEM_METADATA_UPDATED (async): Optionally called when transaction's metadata was updated. + * - CHECKOUT_FULLY_PAID (async): Optionally called when the checkout charge status changed to `FULL` or `OVERCHARGED`. + * - ORDER_UPDATED (async): Optionally called when the transaction is related to the order and the order was updated. */ - transactionProcess?: Maybe; + readonly transactionEventReport?: Maybe; + /** Initializes a transaction session. It triggers the webhook `TRANSACTION_INITIALIZE_SESSION`, to the requested `paymentGateways`. There is a limit of 100 transaction items per checkout / order. */ + readonly transactionInitialize?: Maybe; + /** Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. */ + readonly transactionProcess?: Maybe; /** * Request an action for payment transaction. * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: HANDLE_PAYMENTS. */ - transactionRequestAction?: Maybe; + readonly transactionRequestAction?: Maybe; /** * Request a refund for payment transaction based on granted refund. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: HANDLE_PAYMENTS. */ - transactionRequestRefundForGrantedRefund?: Maybe; + readonly transactionRequestRefundForGrantedRefund?: Maybe; /** * Update transaction. * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. */ - transactionUpdate?: Maybe; + readonly transactionUpdate?: Maybe; /** * Remove shipping zone from given warehouse. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - unassignWarehouseShippingZone?: Maybe; - /** Updates metadata of an object. To use it, you need to have access to the modified object. */ - updateMetadata?: Maybe; - /** Updates private metadata of an object. To use it, you need to be an authenticated staff user or an app and have access to the modified object. */ - updatePrivateMetadata?: Maybe; + readonly unassignWarehouseShippingZone?: Maybe; + /** + * Updates metadata of an object.Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly updateMetadata?: Maybe; + /** + * Updates private metadata of an object. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly updatePrivateMetadata?: Maybe; /** * Updates given warehouse. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - updateWarehouse?: Maybe; + readonly updateWarehouse?: Maybe; /** * Deletes a user avatar. Only for staff members. * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. */ - userAvatarDelete?: Maybe; + readonly userAvatarDelete?: Maybe; /** * Create a user avatar. Only for staff members. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. */ - userAvatarUpdate?: Maybe; + readonly userAvatarUpdate?: Maybe; /** * Activate or deactivate users. * * Requires one of the following permissions: MANAGE_USERS. */ - userBulkSetActive?: Maybe; + readonly userBulkSetActive?: Maybe; /** * Assign an media to a product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - variantMediaAssign?: Maybe; + readonly variantMediaAssign?: Maybe; /** * Unassign an media from a product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - variantMediaUnassign?: Maybe; + readonly variantMediaUnassign?: Maybe; /** * Deletes vouchers. * @@ -13367,7 +11915,7 @@ export type Mutation = { * Triggers the following webhook events: * - VOUCHER_DELETED (async): A voucher was deleted. */ - voucherBulkDelete?: Maybe; + readonly voucherBulkDelete?: Maybe; /** * Adds products, categories, collections to a voucher. * @@ -13376,7 +11924,7 @@ export type Mutation = { * Triggers the following webhook events: * - VOUCHER_UPDATED (async): A voucher was updated. */ - voucherCataloguesAdd?: Maybe; + readonly voucherCataloguesAdd?: Maybe; /** * Removes products, categories, collections from a voucher. * @@ -13385,7 +11933,7 @@ export type Mutation = { * Triggers the following webhook events: * - VOUCHER_UPDATED (async): A voucher was updated. */ - voucherCataloguesRemove?: Maybe; + readonly voucherCataloguesRemove?: Maybe; /** * Manage voucher's availability in channels. * @@ -13394,7 +11942,7 @@ export type Mutation = { * Triggers the following webhook events: * - VOUCHER_UPDATED (async): A voucher was updated. */ - voucherChannelListingUpdate?: Maybe; + readonly voucherChannelListingUpdate?: Maybe; /** * Deletes voucher codes. * @@ -13405,7 +11953,7 @@ export type Mutation = { * Triggers the following webhook events: * - VOUCHER_CODES_DELETED (async): A voucher codes were deleted. */ - voucherCodeBulkDelete?: Maybe; + readonly voucherCodeBulkDelete?: Maybe; /** * Creates a new voucher. * @@ -13415,7 +11963,7 @@ export type Mutation = { * - VOUCHER_CREATED (async): A voucher was created. * - VOUCHER_CODES_CREATED (async): A voucher codes were created. */ - voucherCreate?: Maybe; + readonly voucherCreate?: Maybe; /** * Deletes a voucher. * @@ -13424,13 +11972,13 @@ export type Mutation = { * Triggers the following webhook events: * - VOUCHER_DELETED (async): A voucher was deleted. */ - voucherDelete?: Maybe; + readonly voucherDelete?: Maybe; /** * Creates/updates translations for a voucher. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - voucherTranslate?: Maybe; + readonly voucherTranslate?: Maybe; /** * Updates a voucher. * @@ -13440,45 +11988,37 @@ export type Mutation = { * - VOUCHER_UPDATED (async): A voucher was updated. * - VOUCHER_CODES_CREATED (async): A voucher code was created. */ - voucherUpdate?: Maybe; + readonly voucherUpdate?: Maybe; /** * Creates a new webhook subscription. * * Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. */ - webhookCreate?: Maybe; + readonly webhookCreate?: Maybe; /** * Delete a webhook. Before the deletion, the webhook is deactivated to pause any deliveries that are already scheduled. The deletion might fail if delivery is in progress. In such a case, the webhook is not deleted but remains deactivated. * * Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. */ - webhookDelete?: Maybe; + readonly webhookDelete?: Maybe; /** * Performs a dry run of a webhook event. Supports a single event (the first, if multiple provided in the `query`). Requires permission relevant to processed event. * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. */ - webhookDryRun?: Maybe; + readonly webhookDryRun?: Maybe; /** * Trigger a webhook event. Supports a single event (the first, if multiple provided in the `webhook.subscription_query`). Requires permission relevant to processed event. Successfully delivered webhook returns `delivery` with status='PENDING' and empty payload. * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. */ - webhookTrigger?: Maybe; + readonly webhookTrigger?: Maybe; /** * Updates a webhook subscription. * * Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. */ - webhookUpdate?: Maybe; + readonly webhookUpdate?: Maybe; }; @@ -13587,6 +12127,11 @@ export type MutationAppInstallArgs = { }; +export type MutationAppReenableSyncWebhooksArgs = { + appId: Scalars['ID']; +}; + + export type MutationAppRetryInstallArgs = { activateAfterInstallation?: InputMaybe; id: Scalars['ID']; @@ -13622,29 +12167,29 @@ export type MutationAssignNavigationArgs = { export type MutationAssignWarehouseShippingZoneArgs = { id: Scalars['ID']; - shippingZoneIds: Array; + shippingZoneIds: ReadonlyArray; }; export type MutationAttributeBulkCreateArgs = { - attributes: Array; + attributes: ReadonlyArray; errorPolicy?: InputMaybe; }; export type MutationAttributeBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; export type MutationAttributeBulkTranslateArgs = { errorPolicy?: InputMaybe; - translations: Array; + translations: ReadonlyArray; }; export type MutationAttributeBulkUpdateArgs = { - attributes: Array; + attributes: ReadonlyArray; errorPolicy?: InputMaybe; }; @@ -13662,7 +12207,7 @@ export type MutationAttributeDeleteArgs = { export type MutationAttributeReorderValuesArgs = { attributeId: Scalars['ID']; - moves: Array; + moves: ReadonlyArray; }; @@ -13681,13 +12226,13 @@ export type MutationAttributeUpdateArgs = { export type MutationAttributeValueBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; export type MutationAttributeValueBulkTranslateArgs = { errorPolicy?: InputMaybe; - translations: Array; + translations: ReadonlyArray; }; @@ -13718,7 +12263,7 @@ export type MutationAttributeValueUpdateArgs = { export type MutationCategoryBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -13769,7 +12314,7 @@ export type MutationChannelDeleteArgs = { export type MutationChannelReorderWarehousesArgs = { channelId: Scalars['ID']; - moves: Array; + moves: ReadonlyArray; }; @@ -13791,6 +12336,7 @@ export type MutationCheckoutBillingAddressUpdateArgs = { billingAddress: AddressInput; checkoutId?: InputMaybe; id?: InputMaybe; + saveAddress?: InputMaybe; token?: InputMaybe; validationRules?: InputMaybe; }; @@ -13799,7 +12345,7 @@ export type MutationCheckoutBillingAddressUpdateArgs = { export type MutationCheckoutCompleteArgs = { checkoutId?: InputMaybe; id?: InputMaybe; - metadata?: InputMaybe>; + metadata?: InputMaybe>; paymentData?: InputMaybe; redirectUrl?: InputMaybe; storeSource?: InputMaybe; @@ -13832,6 +12378,12 @@ export type MutationCheckoutCustomerDetachArgs = { }; +export type MutationCheckoutCustomerNoteUpdateArgs = { + customerNote: Scalars['String']; + id: Scalars['ID']; +}; + + export type MutationCheckoutDeliveryMethodUpdateArgs = { deliveryMethodId?: InputMaybe; id?: InputMaybe; @@ -13866,14 +12418,14 @@ export type MutationCheckoutLineDeleteArgs = { export type MutationCheckoutLinesAddArgs = { checkoutId?: InputMaybe; id?: InputMaybe; - lines: Array; + lines: ReadonlyArray; token?: InputMaybe; }; export type MutationCheckoutLinesDeleteArgs = { id?: InputMaybe; - linesIds: Array; + linesIds: ReadonlyArray; token?: InputMaybe; }; @@ -13881,7 +12433,7 @@ export type MutationCheckoutLinesDeleteArgs = { export type MutationCheckoutLinesUpdateArgs = { checkoutId?: InputMaybe; id?: InputMaybe; - lines: Array; + lines: ReadonlyArray; token?: InputMaybe; }; @@ -13906,6 +12458,7 @@ export type MutationCheckoutRemovePromoCodeArgs = { export type MutationCheckoutShippingAddressUpdateArgs = { checkoutId?: InputMaybe; id?: InputMaybe; + saveAddress?: InputMaybe; shippingAddress: AddressInput; token?: InputMaybe; validationRules?: InputMaybe; @@ -13922,12 +12475,12 @@ export type MutationCheckoutShippingMethodUpdateArgs = { export type MutationCollectionAddProductsArgs = { collectionId: Scalars['ID']; - products: Array; + products: ReadonlyArray; }; export type MutationCollectionBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -13949,13 +12502,13 @@ export type MutationCollectionDeleteArgs = { export type MutationCollectionRemoveProductsArgs = { collectionId: Scalars['ID']; - products: Array; + products: ReadonlyArray; }; export type MutationCollectionReorderProductsArgs = { collectionId: Scalars['ID']; - moves: Array; + moves: ReadonlyArray; }; @@ -13990,12 +12543,12 @@ export type MutationCreateWarehouseArgs = { export type MutationCustomerBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; export type MutationCustomerBulkUpdateArgs = { - customers: Array; + customers: ReadonlyArray; errorPolicy?: InputMaybe; }; @@ -14020,13 +12573,13 @@ export type MutationCustomerUpdateArgs = { export type MutationDeleteMetadataArgs = { id: Scalars['ID']; - keys: Array; + keys: ReadonlyArray; }; export type MutationDeletePrivateMetadataArgs = { id: Scalars['ID']; - keys: Array; + keys: ReadonlyArray; }; @@ -14058,7 +12611,7 @@ export type MutationDigitalContentUrlCreateArgs = { export type MutationDraftOrderBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14079,7 +12632,7 @@ export type MutationDraftOrderDeleteArgs = { export type MutationDraftOrderLinesBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14164,7 +12717,7 @@ export type MutationGiftCardAddNoteArgs = { export type MutationGiftCardBulkActivateArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14174,12 +12727,12 @@ export type MutationGiftCardBulkCreateArgs = { export type MutationGiftCardBulkDeactivateArgs = { - ids: Array; + ids: ReadonlyArray; }; export type MutationGiftCardBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14248,7 +12801,7 @@ export type MutationInvoiceUpdateArgs = { export type MutationMenuBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14263,7 +12816,7 @@ export type MutationMenuDeleteArgs = { export type MutationMenuItemBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14279,7 +12832,7 @@ export type MutationMenuItemDeleteArgs = { export type MutationMenuItemMoveArgs = { menu: Scalars['ID']; - moves: Array; + moves: ReadonlyArray; }; @@ -14309,13 +12862,13 @@ export type MutationOrderAddNoteArgs = { export type MutationOrderBulkCancelArgs = { - ids: Array; + ids: ReadonlyArray; }; export type MutationOrderBulkCreateArgs = { errorPolicy?: InputMaybe; - orders: Array; + orders: ReadonlyArray; stockUpdatePolicy?: InputMaybe; }; @@ -14338,8 +12891,8 @@ export type MutationOrderConfirmArgs = { export type MutationOrderCreateFromCheckoutArgs = { id: Scalars['ID']; - metadata?: InputMaybe>; - privateMetadata?: InputMaybe>; + metadata?: InputMaybe>; + privateMetadata?: InputMaybe>; removeCheckout?: InputMaybe; }; @@ -14434,7 +12987,7 @@ export type MutationOrderLineUpdateArgs = { export type MutationOrderLinesCreateArgs = { id: Scalars['ID']; - input: Array; + input: ReadonlyArray; }; @@ -14486,24 +13039,24 @@ export type MutationOrderVoidArgs = { export type MutationPageAttributeAssignArgs = { - attributeIds: Array; + attributeIds: ReadonlyArray; pageTypeId: Scalars['ID']; }; export type MutationPageAttributeUnassignArgs = { - attributeIds: Array; + attributeIds: ReadonlyArray; pageTypeId: Scalars['ID']; }; export type MutationPageBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; export type MutationPageBulkPublishArgs = { - ids: Array; + ids: ReadonlyArray; isPublished: Scalars['Boolean']; }; @@ -14520,7 +13073,7 @@ export type MutationPageDeleteArgs = { export type MutationPageReorderAttributeValuesArgs = { attributeId: Scalars['ID']; - moves: Array; + moves: ReadonlyArray; pageId: Scalars['ID']; }; @@ -14533,7 +13086,7 @@ export type MutationPageTranslateArgs = { export type MutationPageTypeBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14548,7 +13101,7 @@ export type MutationPageTypeDeleteArgs = { export type MutationPageTypeReorderAttributesArgs = { - moves: Array; + moves: ReadonlyArray; pageTypeId: Scalars['ID']; }; @@ -14585,7 +13138,7 @@ export type MutationPaymentCheckBalanceArgs = { export type MutationPaymentGatewayInitializeArgs = { amount?: InputMaybe; id: Scalars['ID']; - paymentGateways?: InputMaybe>; + paymentGateways?: InputMaybe>; }; @@ -14653,37 +13206,37 @@ export type MutationPluginUpdateArgs = { export type MutationProductAttributeAssignArgs = { - operations: Array; + operations: ReadonlyArray; productTypeId: Scalars['ID']; }; export type MutationProductAttributeAssignmentUpdateArgs = { - operations: Array; + operations: ReadonlyArray; productTypeId: Scalars['ID']; }; export type MutationProductAttributeUnassignArgs = { - attributeIds: Array; + attributeIds: ReadonlyArray; productTypeId: Scalars['ID']; }; export type MutationProductBulkCreateArgs = { errorPolicy?: InputMaybe; - products: Array; + products: ReadonlyArray; }; export type MutationProductBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; export type MutationProductBulkTranslateArgs = { errorPolicy?: InputMaybe; - translations: Array; + translations: ReadonlyArray; }; @@ -14705,7 +13258,7 @@ export type MutationProductDeleteArgs = { export type MutationProductMediaBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14720,7 +13273,7 @@ export type MutationProductMediaDeleteArgs = { export type MutationProductMediaReorderArgs = { - mediaIds: Array; + mediaIds: ReadonlyArray; productId: Scalars['ID']; }; @@ -14733,7 +13286,7 @@ export type MutationProductMediaUpdateArgs = { export type MutationProductReorderAttributeValuesArgs = { attributeId: Scalars['ID']; - moves: Array; + moves: ReadonlyArray; productId: Scalars['ID']; }; @@ -14746,7 +13299,7 @@ export type MutationProductTranslateArgs = { export type MutationProductTypeBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14761,7 +13314,7 @@ export type MutationProductTypeDeleteArgs = { export type MutationProductTypeReorderAttributesArgs = { - moves: Array; + moves: ReadonlyArray; productTypeId: Scalars['ID']; type: ProductAttributeType; }; @@ -14783,32 +13336,32 @@ export type MutationProductUpdateArgs = { export type MutationProductVariantBulkCreateArgs = { errorPolicy?: InputMaybe; product: Scalars['ID']; - variants: Array; + variants: ReadonlyArray; }; export type MutationProductVariantBulkDeleteArgs = { - ids?: InputMaybe>; - skus?: InputMaybe>; + ids?: InputMaybe>; + skus?: InputMaybe>; }; export type MutationProductVariantBulkTranslateArgs = { errorPolicy?: InputMaybe; - translations: Array; + translations: ReadonlyArray; }; export type MutationProductVariantBulkUpdateArgs = { errorPolicy?: InputMaybe; product: Scalars['ID']; - variants: Array; + variants: ReadonlyArray; }; export type MutationProductVariantChannelListingUpdateArgs = { id?: InputMaybe; - input: Array; + input: ReadonlyArray; sku?: InputMaybe; }; @@ -14831,14 +13384,14 @@ export type MutationProductVariantPreorderDeactivateArgs = { export type MutationProductVariantReorderArgs = { - moves: Array; + moves: ReadonlyArray; productId: Scalars['ID']; }; export type MutationProductVariantReorderAttributeValuesArgs = { attributeId: Scalars['ID']; - moves: Array; + moves: ReadonlyArray; variantId: Scalars['ID']; }; @@ -14850,7 +13403,7 @@ export type MutationProductVariantSetDefaultArgs = { export type MutationProductVariantStocksCreateArgs = { - stocks: Array; + stocks: ReadonlyArray; variantId: Scalars['ID']; }; @@ -14858,13 +13411,13 @@ export type MutationProductVariantStocksCreateArgs = { export type MutationProductVariantStocksDeleteArgs = { sku?: InputMaybe; variantId?: InputMaybe; - warehouseIds?: InputMaybe>; + warehouseIds?: InputMaybe>; }; export type MutationProductVariantStocksUpdateArgs = { sku?: InputMaybe; - stocks: Array; + stocks: ReadonlyArray; variantId?: InputMaybe; }; @@ -14885,7 +13438,7 @@ export type MutationProductVariantUpdateArgs = { export type MutationPromotionBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -14951,7 +13504,7 @@ export type MutationRequestPasswordResetArgs = { export type MutationSaleBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -15016,7 +13569,7 @@ export type MutationShippingMethodChannelListingUpdateArgs = { export type MutationShippingPriceBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -15038,7 +13591,7 @@ export type MutationShippingPriceExcludeProductsArgs = { export type MutationShippingPriceRemoveProductFromExcludeArgs = { id: Scalars['ID']; - products: Array; + products: ReadonlyArray; }; @@ -15056,7 +13609,7 @@ export type MutationShippingPriceUpdateArgs = { export type MutationShippingZoneBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -15098,7 +13651,7 @@ export type MutationShopSettingsUpdateArgs = { export type MutationStaffBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -15136,7 +13689,7 @@ export type MutationStaffUpdateArgs = { export type MutationStockBulkUpdateArgs = { errorPolicy?: InputMaybe; - stocks: Array; + stocks: ReadonlyArray; }; @@ -15175,7 +13728,7 @@ export type MutationTaxCountryConfigurationDeleteArgs = { export type MutationTaxCountryConfigurationUpdateArgs = { countryCode: CountryCode; - updateTaxClassRates: Array; + updateTaxClassRates: ReadonlyArray; }; @@ -15212,13 +13765,15 @@ export type MutationTransactionCreateArgs = { export type MutationTransactionEventReportArgs = { amount?: InputMaybe; - availableActions?: InputMaybe>; + availableActions?: InputMaybe>; externalUrl?: InputMaybe; id?: InputMaybe; message?: InputMaybe; pspReference: Scalars['String']; time?: InputMaybe; token?: InputMaybe; + transactionMetadata?: InputMaybe>; + transactionPrivateMetadata?: InputMaybe>; type: TransactionEventTypeEnum; }; @@ -15266,19 +13821,19 @@ export type MutationTransactionUpdateArgs = { export type MutationUnassignWarehouseShippingZoneArgs = { id: Scalars['ID']; - shippingZoneIds: Array; + shippingZoneIds: ReadonlyArray; }; export type MutationUpdateMetadataArgs = { id: Scalars['ID']; - input: Array; + input: ReadonlyArray; }; export type MutationUpdatePrivateMetadataArgs = { id: Scalars['ID']; - input: Array; + input: ReadonlyArray; }; @@ -15295,7 +13850,7 @@ export type MutationUserAvatarUpdateArgs = { export type MutationUserBulkSetActiveArgs = { - ids: Array; + ids: ReadonlyArray; isActive: Scalars['Boolean']; }; @@ -15313,7 +13868,7 @@ export type MutationVariantMediaUnassignArgs = { export type MutationVoucherBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -15336,7 +13891,7 @@ export type MutationVoucherChannelListingUpdateArgs = { export type MutationVoucherCodeBulkDeleteArgs = { - ids: Array; + ids: ReadonlyArray; }; @@ -15391,42 +13946,43 @@ export type MutationWebhookUpdateArgs = { }; export type NameTranslationInput = { - name?: InputMaybe; + readonly name?: InputMaybe; }; -export type NavigationType = +export enum NavigationType { /** Main storefront navigation. */ - | 'MAIN' + Main = 'MAIN', /** Secondary storefront navigation. */ - | 'SECONDARY'; + Secondary = 'SECONDARY' +} /** An object with an ID */ export type Node = { /** The ID of the object. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; }; export type ObjectWithMetadata = { /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. */ - metafield?: Maybe; + readonly metafield?: Maybe; /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ - metafields?: Maybe; + readonly metafields?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. */ - privateMetafield?: Maybe; + readonly privateMetafield?: Maybe; /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ - privateMetafields?: Maybe; + readonly privateMetafields?: Maybe; }; @@ -15436,7 +13992,7 @@ export type ObjectWithMetadataMetafieldArgs = { export type ObjectWithMetadataMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -15446,350 +14002,245 @@ export type ObjectWithMetadataPrivateMetafieldArgs = { export type ObjectWithMetadataPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** Represents an order in the shop. */ export type Order = Node & ObjectWithMetadata & { - __typename?: 'Order'; /** List of actions that can be performed in the current state of an order. */ - actions: Array; - /** - * The authorize status of the order. - * - * Added in Saleor 3.4. - */ - authorizeStatus: OrderAuthorizeStatusEnum; - /** - * Collection points that can be used for this order. - * - * Added in Saleor 3.1. - */ - availableCollectionPoints: Array; + readonly actions: ReadonlyArray; + /** The authorize status of the order. */ + readonly authorizeStatus: OrderAuthorizeStatusEnum; + /** Collection points that can be used for this order. */ + readonly availableCollectionPoints: ReadonlyArray; /** * Shipping methods that can be used with this order. * @deprecated Use `shippingMethods`, this field will be removed in 4.0 */ - availableShippingMethods?: Maybe>; + readonly availableShippingMethods?: Maybe>; /** Billing address. The full data can be access for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_ORDERS, OWNER. */ - billingAddress?: Maybe
; + readonly billingAddress?: Maybe
; /** Informs whether a draft order can be finalized(turned into a regular order). */ - canFinalize: Scalars['Boolean']; + readonly canFinalize: Scalars['Boolean']; /** Channel through which the order was placed. */ - channel: Channel; - /** - * The charge status of the order. - * - * Added in Saleor 3.4. - */ - chargeStatus: OrderChargeStatusEnum; - /** - * ID of the checkout that the order was created from. - * - * Added in Saleor 3.11. - */ - checkoutId?: Maybe; + readonly channel: Channel; + /** The charge status of the order. */ + readonly chargeStatus: OrderChargeStatusEnum; + /** ID of the checkout that the order was created from. */ + readonly checkoutId?: Maybe; /** Name of the collection point where the order should be picked up by the customer. */ - collectionPointName?: Maybe; + readonly collectionPointName?: Maybe; /** Date and time when the order was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** Additional information provided by the customer about the order. */ - customerNote: Scalars['String']; - /** - * The delivery method selected for this order. - * - * Added in Saleor 3.1. - */ - deliveryMethod?: Maybe; + readonly customerNote: Scalars['String']; + /** The delivery method selected for this order. */ + readonly deliveryMethod?: Maybe; /** * Returns applied discount. - * @deprecated This field will be removed in Saleor 4.0. Use the `discounts` field instead. + * @deprecated Use the `discounts` field instead. */ - discount?: Maybe; + readonly discount?: Maybe; /** * Discount name. - * @deprecated This field will be removed in Saleor 4.0. Use the `discounts` field instead. + * @deprecated Use the `discounts` field instead. */ - discountName?: Maybe; + readonly discountName?: Maybe; /** List of all discounts assigned to the order. */ - discounts: Array; - /** - * Determines whether displayed prices should include taxes. - * - * Added in Saleor 3.9. - */ - displayGrossPrices: Scalars['Boolean']; + readonly discounts: ReadonlyArray; + /** Determines whether displayed prices should include taxes. */ + readonly displayGrossPrices: Scalars['Boolean']; /** List of errors that occurred during order validation. */ - errors: Array; + readonly errors: ReadonlyArray; /** * List of events associated with the order. * * Requires one of the following permissions: MANAGE_ORDERS. */ - events: Array; - /** - * External ID of this order. - * - * Added in Saleor 3.10. - */ - externalReference?: Maybe; + readonly events: ReadonlyArray; + /** External ID of this order. */ + readonly externalReference?: Maybe; /** List of shipments for the order. */ - fulfillments: Array; + readonly fulfillments: ReadonlyArray; /** List of user gift cards. */ - giftCards: Array; + readonly giftCards: ReadonlyArray; /** * List of granted refunds. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - grantedRefunds: Array; + readonly grantedRefunds: ReadonlyArray; /** ID of the order. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of order invoices. Can be fetched for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_ORDERS, OWNER. */ - invoices: Array; + readonly invoices: ReadonlyArray; /** Informs if an order is fully paid. */ - isPaid: Scalars['Boolean']; + readonly isPaid: Scalars['Boolean']; /** Returns True, if order requires shipping. */ - isShippingRequired: Scalars['Boolean']; - /** @deprecated This field will be removed in Saleor 4.0. Use the `languageCodeEnum` field to fetch the language code. */ - languageCode: Scalars['String']; + readonly isShippingRequired: Scalars['Boolean']; + /** @deprecated Use the `languageCodeEnum` field to fetch the language code. */ + readonly languageCode: Scalars['String']; /** Order language code. */ - languageCodeEnum: LanguageCodeEnum; + readonly languageCodeEnum: LanguageCodeEnum; /** List of order lines. */ - lines: Array; + readonly lines: ReadonlyArray; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** User-friendly number of an order. */ - number: Scalars['String']; + readonly number: Scalars['String']; /** The order origin. */ - origin: OrderOriginEnum; + readonly origin: OrderOriginEnum; /** The ID of the order that was the base for this order. */ - original?: Maybe; + readonly original?: Maybe; /** Internal payment status. */ - paymentStatus: PaymentChargeStatusEnum; + readonly paymentStatus: PaymentChargeStatusEnum; /** User-friendly payment status. */ - paymentStatusDisplay: Scalars['String']; + readonly paymentStatusDisplay: Scalars['String']; /** List of payments for the order. */ - payments: Array; + readonly payments: ReadonlyArray; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** URL to which user should be redirected after order is placed. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shipping address. The full data can be access for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_ORDERS, OWNER. */ - shippingAddress?: Maybe
; + readonly shippingAddress?: Maybe
; /** * Shipping method for this order. - * @deprecated This field will be removed in Saleor 4.0. Use `deliveryMethod` instead. + * @deprecated Use `deliveryMethod` instead. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; /** Method used for shipping. */ - shippingMethodName?: Maybe; + readonly shippingMethodName?: Maybe; /** Shipping methods related to this order. */ - shippingMethods: Array; + readonly shippingMethods: ReadonlyArray; /** Total price of shipping. */ - shippingPrice: TaxedMoney; + readonly shippingPrice: TaxedMoney; /** * Denormalized tax class assigned to the shipping method. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - shippingTaxClass?: Maybe; - /** - * Denormalized public metadata of the shipping method's tax class. - * - * Added in Saleor 3.9. - */ - shippingTaxClassMetadata: Array; - /** - * Denormalized name of the tax class assigned to the shipping method. - * - * Added in Saleor 3.9. - */ - shippingTaxClassName?: Maybe; - /** - * Denormalized private metadata of the shipping method's tax class. Requires staff permissions to access. - * - * Added in Saleor 3.9. - */ - shippingTaxClassPrivateMetadata: Array; + readonly shippingTaxClass?: Maybe; + /** Denormalized public metadata of the shipping method's tax class. */ + readonly shippingTaxClassMetadata: ReadonlyArray; + /** Denormalized name of the tax class assigned to the shipping method. */ + readonly shippingTaxClassName?: Maybe; + /** Denormalized private metadata of the shipping method's tax class. Requires staff permissions to access. */ + readonly shippingTaxClassPrivateMetadata: ReadonlyArray; /** The shipping tax rate value. */ - shippingTaxRate: Scalars['Float']; + readonly shippingTaxRate: Scalars['Float']; /** Status of the order. */ - status: OrderStatus; + readonly status: OrderStatus; /** User-friendly order status. */ - statusDisplay: Scalars['String']; + readonly statusDisplay: Scalars['String']; /** The sum of line prices not including shipping. */ - subtotal: TaxedMoney; - /** - * Returns True if order has to be exempt from taxes. - * - * Added in Saleor 3.8. - */ - taxExemption: Scalars['Boolean']; - /** @deprecated This field will be removed in Saleor 4.0. Use `id` instead. */ - token: Scalars['String']; + readonly subtotal: TaxedMoney; + /** Returns True if order has to be exempt from taxes. */ + readonly taxExemption: Scalars['Boolean']; + /** @deprecated Use `id` instead. */ + readonly token: Scalars['String']; /** Total amount of the order. */ - total: TaxedMoney; + readonly total: TaxedMoney; /** * Total amount of ongoing authorize requests for the order's transactions. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - totalAuthorizePending: Money; + readonly totalAuthorizePending: Money; /** Amount authorized for the order. */ - totalAuthorized: Money; + readonly totalAuthorized: Money; /** The difference between the paid and the order total amount. */ - totalBalance: Money; + readonly totalBalance: Money; /** * Total amount of ongoing cancel requests for the order's transactions. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - totalCancelPending: Money; - /** - * Amount canceled for the order. - * - * Added in Saleor 3.13. - */ - totalCanceled: Money; + readonly totalCancelPending: Money; + /** Amount canceled for the order. */ + readonly totalCanceled: Money; /** * Amount captured for the order. - * @deprecated This field will be removed in Saleor 4.0. Use `totalCharged` instead. + * @deprecated Use `totalCharged` instead. */ - totalCaptured: Money; + readonly totalCaptured: Money; /** * Total amount of ongoing charge requests for the order's transactions. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - totalChargePending: Money; - /** - * Amount charged for the order. - * - * Added in Saleor 3.13. - */ - totalCharged: Money; + readonly totalChargePending: Money; + /** Amount charged for the order. */ + readonly totalCharged: Money; /** * Total amount of granted refund. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - totalGrantedRefund: Money; + readonly totalGrantedRefund: Money; /** * Total amount of ongoing refund requests for the order's transactions. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - totalRefundPending: Money; - /** - * Total refund amount for the order. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - totalRefunded: Money; + readonly totalRefundPending: Money; + /** Total refund amount for the order. */ + readonly totalRefunded: Money; /** * The difference amount between granted refund and the amounts that are pending and refunded. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ - totalRemainingGrant: Money; - /** Google Analytics tracking client ID. This field will be removed in Saleor 4.0. */ - trackingClientId: Scalars['String']; - /** - * List of transactions for the order. Requires one of the following permissions: MANAGE_ORDERS, HANDLE_PAYMENTS. - * - * Added in Saleor 3.4. - */ - transactions: Array; + readonly totalRemainingGrant: Money; + /** Google Analytics tracking client ID. */ + readonly trackingClientId: Scalars['String']; + /** List of transactions for the order. Requires one of the following permissions: MANAGE_ORDERS, HANDLE_PAYMENTS. */ + readonly transactions: ReadonlyArray; /** * Translated discount name. - * @deprecated This field will be removed in Saleor 4.0. Use the `discounts` field instead. + * @deprecated Use the `discounts` field instead. */ - translatedDiscountName?: Maybe; + readonly translatedDiscountName?: Maybe; /** * Undiscounted total price of shipping. * * Added in Saleor 3.19. */ - undiscountedShippingPrice?: Maybe; + readonly undiscountedShippingPrice: Money; /** Undiscounted total amount of the order. */ - undiscountedTotal: TaxedMoney; + readonly undiscountedTotal: TaxedMoney; /** Date and time when the order was created. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; /** User who placed the order. This field is set only for orders placed by authenticated users. Can be fetched for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_USERS, MANAGE_ORDERS, HANDLE_PAYMENTS, OWNER. */ - user?: Maybe; + readonly user?: Maybe; /** Email address of the customer. The full data can be access for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_ORDERS, OWNER. */ - userEmail?: Maybe; + readonly userEmail?: Maybe; /** Voucher linked to the order. */ - voucher?: Maybe; + readonly voucher?: Maybe; /** * Voucher code that was used for Order. * * Added in Saleor 3.18. */ - voucherCode?: Maybe; + readonly voucherCode?: Maybe; /** Weight of the order. */ - weight: Weight; + readonly weight: Weight; }; @@ -15801,7 +14252,7 @@ export type OrderMetafieldArgs = { /** Represents an order in the shop. */ export type OrderMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -15813,44 +14264,38 @@ export type OrderPrivateMetafieldArgs = { /** Represents an order in the shop. */ export type OrderPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; -export type OrderAction = +export enum OrderAction { /** Represents the capture action. */ - | 'CAPTURE' + Capture = 'CAPTURE', /** Represents a mark-as-paid action. */ - | 'MARK_AS_PAID' + MarkAsPaid = 'MARK_AS_PAID', /** Represents a refund action. */ - | 'REFUND' + Refund = 'REFUND', /** Represents a void action. */ - | 'VOID'; + Void = 'VOID' +} /** * Adds note to the order. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. - * * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderAddNote = { - __typename?: 'OrderAddNote'; - errors: Array; + readonly errors: ReadonlyArray; /** Order note created. */ - event?: Maybe; + readonly event?: Maybe; /** Order with the note added. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type OrderAddNoteInput = { - /** - * Note message. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - */ - message: Scalars['String']; + /** Note message. */ + readonly message: Scalars['String']; }; /** @@ -15869,10 +14314,11 @@ export type OrderAddNoteInput = { * FULL - the funds that are authorized and charged fully cover the * `order.total`-`order.totalGrantedRefund` */ -export type OrderAuthorizeStatusEnum = - | 'FULL' - | 'NONE' - | 'PARTIAL'; +export enum OrderAuthorizeStatusEnum { + Full = 'FULL', + None = 'NONE', + Partial = 'PARTIAL' +} /** * Cancels orders. @@ -15880,272 +14326,321 @@ export type OrderAuthorizeStatusEnum = * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderBulkCancel = { - __typename?: 'OrderBulkCancel'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; /** * Creates multiple orders. * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS_IMPORT. */ export type OrderBulkCreate = { - __typename?: 'OrderBulkCreate'; /** Returns how many objects were created. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the created orders. */ - results: Array; + readonly results: ReadonlyArray; }; export type OrderBulkCreateDeliveryMethodInput = { /** The ID of the shipping method. */ - shippingMethodId?: InputMaybe; + readonly shippingMethodId?: InputMaybe; /** The name of the shipping method. */ - shippingMethodName?: InputMaybe; + readonly shippingMethodName?: InputMaybe; /** The price of the shipping. */ - shippingPrice?: InputMaybe; + readonly shippingPrice?: InputMaybe; /** The ID of the tax class. */ - shippingTaxClassId?: InputMaybe; - /** Metadata of the tax class. */ - shippingTaxClassMetadata?: InputMaybe>; + readonly shippingTaxClassId?: InputMaybe; + /** + * Metadata of the tax class. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly shippingTaxClassMetadata?: InputMaybe>; /** The name of the tax class. */ - shippingTaxClassName?: InputMaybe; - /** Private metadata of the tax class. */ - shippingTaxClassPrivateMetadata?: InputMaybe>; + readonly shippingTaxClassName?: InputMaybe; + /** + * Private metadata of the tax class. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly shippingTaxClassPrivateMetadata?: InputMaybe>; /** Tax rate of the shipping. */ - shippingTaxRate?: InputMaybe; + readonly shippingTaxRate?: InputMaybe; /** The ID of the warehouse. */ - warehouseId?: InputMaybe; + readonly warehouseId?: InputMaybe; /** The name of the warehouse. */ - warehouseName?: InputMaybe; + readonly warehouseName?: InputMaybe; }; export type OrderBulkCreateError = { - __typename?: 'OrderBulkCreateError'; /** The error code. */ - code?: Maybe; + readonly code?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; -}; - -/** An enumeration. */ -export type OrderBulkCreateErrorCode = - | 'BULK_LIMIT' - | 'FUTURE_DATE' - | 'GRAPHQL_ERROR' - | 'INCORRECT_CURRENCY' - | 'INSUFFICIENT_STOCK' - | 'INVALID' - | 'INVALID_QUANTITY' - | 'METADATA_KEY_REQUIRED' - | 'NEGATIVE_INDEX' - | 'NON_EXISTING_STOCK' - | 'NOTE_LENGTH' - | 'NOT_FOUND' - | 'NO_RELATED_ORDER_LINE' - | 'ORDER_LINE_FULFILLMENT_LINE_MISMATCH' - | 'PRICE_ERROR' - | 'REQUIRED' - | 'TOO_MANY_IDENTIFIERS' - | 'UNIQUE'; + readonly path?: Maybe; +}; + +export enum OrderBulkCreateErrorCode { + BulkLimit = 'BULK_LIMIT', + FutureDate = 'FUTURE_DATE', + GraphqlError = 'GRAPHQL_ERROR', + IncorrectCurrency = 'INCORRECT_CURRENCY', + InsufficientStock = 'INSUFFICIENT_STOCK', + Invalid = 'INVALID', + InvalidQuantity = 'INVALID_QUANTITY', + MetadataKeyRequired = 'METADATA_KEY_REQUIRED', + NegativeIndex = 'NEGATIVE_INDEX', + NonExistingStock = 'NON_EXISTING_STOCK', + NoteLength = 'NOTE_LENGTH', + NotFound = 'NOT_FOUND', + NoRelatedOrderLine = 'NO_RELATED_ORDER_LINE', + OrderLineFulfillmentLineMismatch = 'ORDER_LINE_FULFILLMENT_LINE_MISMATCH', + PriceError = 'PRICE_ERROR', + Required = 'REQUIRED', + TooManyIdentifiers = 'TOO_MANY_IDENTIFIERS', + Unique = 'UNIQUE' +} export type OrderBulkCreateFulfillmentInput = { /** List of items informing how to fulfill the order. */ - lines?: InputMaybe>; + readonly lines?: InputMaybe>; /** Fulfillment's tracking code. */ - trackingCode?: InputMaybe; + readonly trackingCode?: InputMaybe; }; export type OrderBulkCreateFulfillmentLineInput = { /** 0-based index of order line, which the fulfillment line refers to. */ - orderLineIndex: Scalars['Int']; + readonly orderLineIndex: Scalars['Int']; /** The number of line items to be fulfilled from given warehouse. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** The external ID of the product variant. */ - variantExternalReference?: InputMaybe; + readonly variantExternalReference?: InputMaybe; /** The ID of the product variant. */ - variantId?: InputMaybe; + readonly variantId?: InputMaybe; /** The SKU of the product variant. */ - variantSku?: InputMaybe; + readonly variantSku?: InputMaybe; /** ID of the warehouse from which the item will be fulfilled. */ - warehouse: Scalars['ID']; + readonly warehouse: Scalars['ID']; }; export type OrderBulkCreateInput = { /** Billing address of the customer. */ - billingAddress: AddressInput; + readonly billingAddress: AddressInput; /** Slug of the channel associated with the order. */ - channel: Scalars['String']; + readonly channel: Scalars['String']; /** The date, when the order was inserted to Saleor database. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** Currency code. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; /** Note about customer. */ - customerNote?: InputMaybe; + readonly customerNote?: InputMaybe; /** The delivery method selected for this order. */ - deliveryMethod?: InputMaybe; + readonly deliveryMethod?: InputMaybe; /** List of discounts. */ - discounts?: InputMaybe>; + readonly discounts?: InputMaybe>; /** Determines whether displayed prices should include taxes. */ - displayGrossPrices?: InputMaybe; + readonly displayGrossPrices?: InputMaybe; /** External ID of the order. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** Fulfillments of the order. */ - fulfillments?: InputMaybe>; + readonly fulfillments?: InputMaybe>; /** List of gift card codes associated with the order. */ - giftCards?: InputMaybe>; + readonly giftCards?: InputMaybe>; /** Invoices related to the order. */ - invoices?: InputMaybe>; + readonly invoices?: InputMaybe>; /** Order language code. */ - languageCode: LanguageCodeEnum; + readonly languageCode: LanguageCodeEnum; /** List of order lines. */ - lines: Array; - /** Metadata of the order. */ - metadata?: InputMaybe>; + readonly lines: ReadonlyArray; + /** + * Metadata of the order. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly metadata?: InputMaybe>; /** Notes related to the order. */ - notes?: InputMaybe>; - /** Private metadata of the order. */ - privateMetadata?: InputMaybe>; + readonly notes?: InputMaybe>; + /** + * Private metadata of the order. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly privateMetadata?: InputMaybe>; /** URL of a view, where users should be redirected to see the order details. */ - redirectUrl?: InputMaybe; + readonly redirectUrl?: InputMaybe; /** Shipping address of the customer. */ - shippingAddress?: InputMaybe; + readonly shippingAddress?: InputMaybe; /** Status of the order. */ - status?: InputMaybe; + readonly status?: InputMaybe; /** Transactions related to the order. */ - transactions?: InputMaybe>; + readonly transactions?: InputMaybe>; /** Customer associated with the order. */ - user: OrderBulkCreateUserInput; + readonly user: OrderBulkCreateUserInput; /** * Code of a voucher associated with the order. * * Added in Saleor 3.18. */ - voucherCode?: InputMaybe; + readonly voucherCode?: InputMaybe; /** Weight of the order in kg. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; export type OrderBulkCreateInvoiceInput = { /** The date, when the invoice was created. */ - createdAt: Scalars['DateTime']; - /** Metadata of the invoice. */ - metadata?: InputMaybe>; + readonly createdAt: Scalars['DateTime']; + /** + * Metadata of the invoice. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly metadata?: InputMaybe>; /** Invoice number. */ - number?: InputMaybe; - /** Private metadata of the invoice. */ - privateMetadata?: InputMaybe>; + readonly number?: InputMaybe; + /** + * Private metadata of the invoice. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly privateMetadata?: InputMaybe>; /** URL of the invoice to download. */ - url?: InputMaybe; + readonly url?: InputMaybe; }; export type OrderBulkCreateNoteInput = { /** The app ID associated with the message. */ - appId?: InputMaybe; + readonly appId?: InputMaybe; /** The date associated with the message. */ - date?: InputMaybe; + readonly date?: InputMaybe; /** Note message. Max characters: 255. */ - message: Scalars['String']; + readonly message: Scalars['String']; /** The user email associated with the message. */ - userEmail?: InputMaybe; + readonly userEmail?: InputMaybe; /** The user external ID associated with the message. */ - userExternalReference?: InputMaybe; + readonly userExternalReference?: InputMaybe; /** The user ID associated with the message. */ - userId?: InputMaybe; + readonly userId?: InputMaybe; }; export type OrderBulkCreateOrderLineInput = { /** The date, when the order line was created. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** Gift card flag. */ - isGiftCard: Scalars['Boolean']; + readonly isGiftCard: Scalars['Boolean']; /** Determines whether shipping of the order line items is required. */ - isShippingRequired: Scalars['Boolean']; - /** Metadata of the order line. */ - metadata?: InputMaybe>; - /** Private metadata of the order line. */ - privateMetadata?: InputMaybe>; + readonly isShippingRequired: Scalars['Boolean']; + /** + * Metadata of the order line. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly metadata?: InputMaybe>; + /** + * Private metadata of the order line. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly privateMetadata?: InputMaybe>; /** The name of the product. */ - productName?: InputMaybe; + readonly productName?: InputMaybe; + /** + * The SKU of the product. + * + * Added in Saleor 3.18. + */ + readonly productSku?: InputMaybe; /** Number of items in the order line */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** The ID of the tax class. */ - taxClassId?: InputMaybe; - /** Metadata of the tax class. */ - taxClassMetadata?: InputMaybe>; + readonly taxClassId?: InputMaybe; + /** + * Metadata of the tax class. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly taxClassMetadata?: InputMaybe>; /** The name of the tax class. */ - taxClassName?: InputMaybe; - /** Private metadata of the tax class. */ - taxClassPrivateMetadata?: InputMaybe>; + readonly taxClassName?: InputMaybe; + /** + * Private metadata of the tax class. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly taxClassPrivateMetadata?: InputMaybe>; /** Tax rate of the order line. */ - taxRate?: InputMaybe; + readonly taxRate?: InputMaybe; /** Price of the order line. */ - totalPrice: TaxedMoneyInput; + readonly totalPrice: TaxedMoneyInput; /** Translation of the product name. */ - translatedProductName?: InputMaybe; + readonly translatedProductName?: InputMaybe; /** Translation of the product variant name. */ - translatedVariantName?: InputMaybe; + readonly translatedVariantName?: InputMaybe; /** Price of the order line excluding applied discount. */ - undiscountedTotalPrice: TaxedMoneyInput; + readonly undiscountedTotalPrice: TaxedMoneyInput; + /** + * Reason of the discount on order line. + * + * Added in Saleor 3.19. + */ + readonly unitDiscountReason?: InputMaybe; + /** + * Type of the discount: fixed or percent + * + * Added in Saleor 3.19. + */ + readonly unitDiscountType?: InputMaybe; + /** + * Value of the discount. Can store fixed value or percent value + * + * Added in Saleor 3.19. + */ + readonly unitDiscountValue?: InputMaybe; /** The external ID of the product variant. */ - variantExternalReference?: InputMaybe; + readonly variantExternalReference?: InputMaybe; /** The ID of the product variant. */ - variantId?: InputMaybe; + readonly variantId?: InputMaybe; /** The name of the product variant. */ - variantName?: InputMaybe; + readonly variantName?: InputMaybe; /** The SKU of the product variant. */ - variantSku?: InputMaybe; + readonly variantSku?: InputMaybe; /** The ID of the warehouse, where the line will be allocated. */ - warehouse: Scalars['ID']; + readonly warehouse: Scalars['ID']; }; export type OrderBulkCreateResult = { - __typename?: 'OrderBulkCreateResult'; /** List of errors occurred on create attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; /** Order data. */ - order?: Maybe; + readonly order?: Maybe; }; export type OrderBulkCreateUserInput = { /** Customer email associated with the order. */ - email?: InputMaybe; + readonly email?: InputMaybe; /** Customer external ID associated with the order. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** Customer ID associated with the order. */ - id?: InputMaybe; + readonly id?: InputMaybe; }; -/** - * Event sent when orders are imported. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when orders are imported. */ export type OrderBulkCreated = Event & { - __typename?: 'OrderBulkCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The orders the event relates to. */ - orders?: Maybe>; + readonly orders?: Maybe>; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -16154,31 +14649,25 @@ export type OrderBulkCreated = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderCancel = { - __typename?: 'OrderCancel'; - errors: Array; + readonly errors: ReadonlyArray; /** Canceled order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; -/** - * Event sent when order is canceled. - * - * Added in Saleor 3.2. - */ +/** Event sent when order is canceled. */ export type OrderCancelled = Event & { - __typename?: 'OrderCancelled'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -16187,12 +14676,11 @@ export type OrderCancelled = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderCapture = { - __typename?: 'OrderCapture'; - errors: Array; + readonly errors: ReadonlyArray; /** Captured order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; /** @@ -16215,11 +14703,12 @@ export type OrderCapture = { * OVERCHARGED - the charged funds are bigger than the * `order.total`-`order.totalGrantedRefund` */ -export type OrderChargeStatusEnum = - | 'FULL' - | 'NONE' - | 'OVERCHARGED' - | 'PARTIAL'; +export enum OrderChargeStatusEnum { + Full = 'FULL', + None = 'NONE', + Overcharged = 'OVERCHARGED', + Partial = 'PARTIAL' +} /** * Confirms an unconfirmed order by changing status to unfulfilled. @@ -16227,54 +14716,44 @@ export type OrderChargeStatusEnum = * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderConfirm = { - __typename?: 'OrderConfirm'; - errors: Array; - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly errors: ReadonlyArray; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; -/** - * Event sent when order is confirmed. - * - * Added in Saleor 3.2. - */ +/** Event sent when order is confirmed. */ export type OrderConfirmed = Event & { - __typename?: 'OrderConfirmed'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type OrderCountableConnection = { - __typename?: 'OrderCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type OrderCountableEdge = { - __typename?: 'OrderCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Order; + readonly node: Order; }; /** * Create new order from existing checkout. Requires the following permissions: AUTHENTICATED_APP and HANDLE_CHECKOUTS. * - * Added in Saleor 3.2. - * * Triggers the following webhook events: * - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. * - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. @@ -16288,91 +14767,93 @@ export type OrderCountableEdge = { * - ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. */ export type OrderCreateFromCheckout = { - __typename?: 'OrderCreateFromCheckout'; - errors: Array; + readonly errors: ReadonlyArray; /** Placed order. */ - order?: Maybe; + readonly order?: Maybe; }; export type OrderCreateFromCheckoutError = { - __typename?: 'OrderCreateFromCheckoutError'; /** The error code. */ - code: OrderCreateFromCheckoutErrorCode; + readonly code: OrderCreateFromCheckoutErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** List of line Ids which cause the error. */ - lines?: Maybe>; + readonly lines?: Maybe>; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of variant IDs which causes the error. */ - variants?: Maybe>; -}; - -/** An enumeration. */ -export type OrderCreateFromCheckoutErrorCode = - | 'BILLING_ADDRESS_NOT_SET' - | 'CHANNEL_INACTIVE' - | 'CHECKOUT_NOT_FOUND' - | 'EMAIL_NOT_SET' - | 'GIFT_CARD_NOT_APPLICABLE' - | 'GRAPHQL_ERROR' - | 'INSUFFICIENT_STOCK' - | 'INVALID_SHIPPING_METHOD' - | 'NO_LINES' - | 'SHIPPING_ADDRESS_NOT_SET' - | 'SHIPPING_METHOD_NOT_SET' - | 'TAX_ERROR' - | 'UNAVAILABLE_VARIANT_IN_CHANNEL' - | 'VOUCHER_NOT_APPLICABLE'; + readonly variants?: Maybe>; +}; + +export enum OrderCreateFromCheckoutErrorCode { + BillingAddressNotSet = 'BILLING_ADDRESS_NOT_SET', + ChannelInactive = 'CHANNEL_INACTIVE', + CheckoutNotFound = 'CHECKOUT_NOT_FOUND', + EmailNotSet = 'EMAIL_NOT_SET', + GiftCardNotApplicable = 'GIFT_CARD_NOT_APPLICABLE', + GraphqlError = 'GRAPHQL_ERROR', + InsufficientStock = 'INSUFFICIENT_STOCK', + InvalidShippingMethod = 'INVALID_SHIPPING_METHOD', + NoLines = 'NO_LINES', + ShippingAddressNotSet = 'SHIPPING_ADDRESS_NOT_SET', + ShippingMethodNotSet = 'SHIPPING_METHOD_NOT_SET', + TaxError = 'TAX_ERROR', + UnavailableVariantInChannel = 'UNAVAILABLE_VARIANT_IN_CHANNEL', + VoucherNotApplicable = 'VOUCHER_NOT_APPLICABLE' +} -/** - * Event sent when new order is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new order is created. */ export type OrderCreated = Event & { - __typename?: 'OrderCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -export type OrderDirection = +export enum OrderDirection { /** Specifies an ascending sort order. */ - | 'ASC' + Asc = 'ASC', /** Specifies a descending sort order. */ - | 'DESC'; + Desc = 'DESC' +} /** Contains all details related to the applied discount to the order. */ export type OrderDiscount = Node & { - __typename?: 'OrderDiscount'; - /** Returns amount of discount. */ - amount: Money; + /** + * Returns amount of discount. + * @deprecated Use `total` instead. + */ + readonly amount: Money; /** The ID of discount applied. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The name of applied discount. */ - name?: Maybe; + readonly name?: Maybe; /** * Explanation for the applied discount. * * Requires one of the following permissions: MANAGE_ORDERS. */ - reason?: Maybe; + readonly reason?: Maybe; + /** + * The amount of discount applied to the order. + * + * Added in Saleor 3.21. + */ + readonly total: Money; /** Translated name of the applied discount. */ - translatedName?: Maybe; + readonly translatedName?: Maybe; /** The type of applied discount: Sale, Voucher or Manual. */ - type: OrderDiscountType; + readonly type: OrderDiscountType; /** Value of the discount. Can store fixed value or percent value */ - value: Scalars['PositiveDecimal']; + readonly value: Scalars['PositiveDecimal']; /** Type of the discount: fixed or percent */ - valueType: DiscountValueTypeEnum; + readonly valueType: DiscountValueTypeEnum; }; /** @@ -16381,21 +14862,20 @@ export type OrderDiscount = Node & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderDiscountAdd = { - __typename?: 'OrderDiscountAdd'; - errors: Array; + readonly errors: ReadonlyArray; /** Order which has been discounted. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type OrderDiscountCommonInput = { /** Explanation for the applied discount. */ - reason?: InputMaybe; + readonly reason?: InputMaybe; /** Value of the discount. Can store fixed value or percent value */ - value: Scalars['PositiveDecimal']; + readonly value: Scalars['PositiveDecimal']; /** Type of the discount: fixed or percent */ - valueType: DiscountValueTypeEnum; + readonly valueType: DiscountValueTypeEnum; }; /** @@ -16404,21 +14884,20 @@ export type OrderDiscountCommonInput = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderDiscountDelete = { - __typename?: 'OrderDiscountDelete'; - errors: Array; + readonly errors: ReadonlyArray; /** Order which has removed discount. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; -/** An enumeration. */ -export type OrderDiscountType = - | 'MANUAL' - | 'ORDER_PROMOTION' - | 'PROMOTION' - | 'SALE' - | 'VOUCHER'; +export enum OrderDiscountType { + Manual = 'MANUAL', + OrderPromotion = 'ORDER_PROMOTION', + Promotion = 'PROMOTION', + Sale = 'SALE', + Voucher = 'VOUCHER' +} /** * Update discount for the order. @@ -16426,316 +14905,290 @@ export type OrderDiscountType = * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderDiscountUpdate = { - __typename?: 'OrderDiscountUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Order which has been discounted. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type OrderDraftFilterInput = { - channels?: InputMaybe>; - created?: InputMaybe; - customer?: InputMaybe; - metadata?: InputMaybe>; - search?: InputMaybe; + readonly channels?: InputMaybe>; + readonly created?: InputMaybe; + readonly customer?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; }; export type OrderError = { - __typename?: 'OrderError'; /** A type of address that causes the error. */ - addressType?: Maybe; + readonly addressType?: Maybe; /** The error code. */ - code: OrderErrorCode; + readonly code: OrderErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of order line IDs that cause the error. */ - orderLines?: Maybe>; + readonly orderLines?: Maybe>; /** List of product variants that are associated with the error */ - variants?: Maybe>; + readonly variants?: Maybe>; /** Warehouse ID which causes the error. */ - warehouse?: Maybe; -}; - -/** An enumeration. */ -export type OrderErrorCode = - | 'BILLING_ADDRESS_NOT_SET' - | 'CANNOT_CANCEL_FULFILLMENT' - | 'CANNOT_CANCEL_ORDER' - | 'CANNOT_DELETE' - | 'CANNOT_DISCOUNT' - | 'CANNOT_FULFILL_UNPAID_ORDER' - | 'CANNOT_REFUND' - | 'CAPTURE_INACTIVE_PAYMENT' - | 'CHANNEL_INACTIVE' - | 'DUPLICATED_INPUT_ITEM' - | 'FULFILL_ORDER_LINE' - | 'GIFT_CARD_LINE' - | 'GRAPHQL_ERROR' - | 'INSUFFICIENT_STOCK' - | 'INVALID' - | 'INVALID_QUANTITY' - | 'INVALID_VOUCHER' - | 'INVALID_VOUCHER_CODE' - | 'NON_EDITABLE_GIFT_LINE' - | 'NON_REMOVABLE_GIFT_LINE' - | 'NOT_AVAILABLE_IN_CHANNEL' - | 'NOT_EDITABLE' - | 'NOT_FOUND' - | 'ORDER_NO_SHIPPING_ADDRESS' - | 'PAYMENT_ERROR' - | 'PAYMENT_MISSING' - | 'PRODUCT_NOT_PUBLISHED' - | 'PRODUCT_UNAVAILABLE_FOR_PURCHASE' - | 'REQUIRED' - | 'SHIPPING_METHOD_NOT_APPLICABLE' - | 'SHIPPING_METHOD_REQUIRED' - | 'TAX_ERROR' - | 'TRANSACTION_ERROR' - | 'UNIQUE' - | 'VOID_INACTIVE_PAYMENT' - | 'ZERO_QUANTITY'; + readonly warehouse?: Maybe; +}; + +export enum OrderErrorCode { + BillingAddressNotSet = 'BILLING_ADDRESS_NOT_SET', + CannotCancelFulfillment = 'CANNOT_CANCEL_FULFILLMENT', + CannotCancelOrder = 'CANNOT_CANCEL_ORDER', + CannotDelete = 'CANNOT_DELETE', + CannotDiscount = 'CANNOT_DISCOUNT', + CannotFulfillUnpaidOrder = 'CANNOT_FULFILL_UNPAID_ORDER', + CannotRefund = 'CANNOT_REFUND', + CaptureInactivePayment = 'CAPTURE_INACTIVE_PAYMENT', + ChannelInactive = 'CHANNEL_INACTIVE', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + FulfillOrderLine = 'FULFILL_ORDER_LINE', + GiftCardLine = 'GIFT_CARD_LINE', + GraphqlError = 'GRAPHQL_ERROR', + InsufficientStock = 'INSUFFICIENT_STOCK', + Invalid = 'INVALID', + InvalidQuantity = 'INVALID_QUANTITY', + InvalidVoucher = 'INVALID_VOUCHER', + InvalidVoucherCode = 'INVALID_VOUCHER_CODE', + MissingAddressData = 'MISSING_ADDRESS_DATA', + NonEditableGiftLine = 'NON_EDITABLE_GIFT_LINE', + NonRemovableGiftLine = 'NON_REMOVABLE_GIFT_LINE', + NotAvailableInChannel = 'NOT_AVAILABLE_IN_CHANNEL', + NotEditable = 'NOT_EDITABLE', + NotFound = 'NOT_FOUND', + OrderNoShippingAddress = 'ORDER_NO_SHIPPING_ADDRESS', + PaymentError = 'PAYMENT_ERROR', + PaymentMissing = 'PAYMENT_MISSING', + ProductNotPublished = 'PRODUCT_NOT_PUBLISHED', + ProductUnavailableForPurchase = 'PRODUCT_UNAVAILABLE_FOR_PURCHASE', + Required = 'REQUIRED', + ShippingMethodNotApplicable = 'SHIPPING_METHOD_NOT_APPLICABLE', + ShippingMethodRequired = 'SHIPPING_METHOD_REQUIRED', + TaxError = 'TAX_ERROR', + TransactionError = 'TRANSACTION_ERROR', + Unique = 'UNIQUE', + VoidInactivePayment = 'VOID_INACTIVE_PAYMENT', + ZeroQuantity = 'ZERO_QUANTITY' +} /** History log of the order. */ export type OrderEvent = Node & { - __typename?: 'OrderEvent'; /** Amount of money. */ - amount?: Maybe; + readonly amount?: Maybe; /** App that performed the action. Requires of of the following permissions: MANAGE_APPS, MANAGE_ORDERS, OWNER. */ - app?: Maybe; + readonly app?: Maybe; /** Composed ID of the Fulfillment. */ - composedId?: Maybe; + readonly composedId?: Maybe; /** Date when event happened at in ISO 8601 format. */ - date?: Maybe; + readonly date?: Maybe; /** The discount applied to the order. */ - discount?: Maybe; + readonly discount?: Maybe; /** Email of the customer. */ - email?: Maybe; + readonly email?: Maybe; /** Type of an email sent to the customer. */ - emailType?: Maybe; + readonly emailType?: Maybe; /** The lines fulfilled. */ - fulfilledItems?: Maybe>; + readonly fulfilledItems?: Maybe>; /** ID of the event associated with an order. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Number of an invoice related to the order. */ - invoiceNumber?: Maybe; + readonly invoiceNumber?: Maybe; /** The concerned lines. */ - lines?: Maybe>; + readonly lines?: Maybe>; /** Content of the event. */ - message?: Maybe; + readonly message?: Maybe; /** User-friendly number of an order. */ - orderNumber?: Maybe; + readonly orderNumber?: Maybe; /** List of oversold lines names. */ - oversoldItems?: Maybe>; + readonly oversoldItems?: Maybe>; /** The payment gateway of the payment. */ - paymentGateway?: Maybe; + readonly paymentGateway?: Maybe; /** The payment reference from the payment provider. */ - paymentId?: Maybe; + readonly paymentId?: Maybe; /** Number of items. */ - quantity?: Maybe; + readonly quantity?: Maybe; /** The reference of payment's transaction. */ - reference?: Maybe; - /** - * The order event which is related to this event. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - related?: Maybe; + readonly reference?: Maybe; + /** The order event which is related to this event. */ + readonly related?: Maybe; /** The order which is related to this order. */ - relatedOrder?: Maybe; + readonly relatedOrder?: Maybe; /** Define if shipping costs were included to the refund. */ - shippingCostsIncluded?: Maybe; + readonly shippingCostsIncluded?: Maybe; /** The transaction reference of captured payment. */ - transactionReference?: Maybe; + readonly transactionReference?: Maybe; /** Order event type. */ - type?: Maybe; + readonly type?: Maybe; /** User who performed the action. */ - user?: Maybe; + readonly user?: Maybe; /** The warehouse were items were restocked. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; export type OrderEventCountableConnection = { - __typename?: 'OrderEventCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type OrderEventCountableEdge = { - __typename?: 'OrderEventCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: OrderEvent; + readonly node: OrderEvent; }; export type OrderEventDiscountObject = { - __typename?: 'OrderEventDiscountObject'; /** Returns amount of discount. */ - amount?: Maybe; + readonly amount?: Maybe; /** Returns amount of discount. */ - oldAmount?: Maybe; + readonly oldAmount?: Maybe; /** Value of the discount. Can store fixed value or percent value. */ - oldValue?: Maybe; + readonly oldValue?: Maybe; /** Type of the discount: fixed or percent. */ - oldValueType?: Maybe; + readonly oldValueType?: Maybe; /** Explanation for the applied discount. */ - reason?: Maybe; + readonly reason?: Maybe; /** Value of the discount. Can store fixed value or percent value. */ - value: Scalars['PositiveDecimal']; + readonly value: Scalars['PositiveDecimal']; /** Type of the discount: fixed or percent. */ - valueType: DiscountValueTypeEnum; + readonly valueType: DiscountValueTypeEnum; }; export type OrderEventOrderLineObject = { - __typename?: 'OrderEventOrderLineObject'; /** The discount applied to the order line. */ - discount?: Maybe; + readonly discount?: Maybe; /** The variant name. */ - itemName?: Maybe; + readonly itemName?: Maybe; /** The order line. */ - orderLine?: Maybe; + readonly orderLine?: Maybe; /** The variant quantity. */ - quantity?: Maybe; -}; - -/** An enumeration. */ -export type OrderEventsEmailsEnum = - | 'CONFIRMED' - | 'DIGITAL_LINKS' - | 'FULFILLMENT_CONFIRMATION' - | 'ORDER_CANCEL' - | 'ORDER_CONFIRMATION' - | 'ORDER_REFUND' - | 'PAYMENT_CONFIRMATION' - | 'SHIPPING_CONFIRMATION' - | 'TRACKING_UPDATED'; + readonly quantity?: Maybe; +}; + +export enum OrderEventsEmailsEnum { + Confirmed = 'CONFIRMED', + DigitalLinks = 'DIGITAL_LINKS', + FulfillmentConfirmation = 'FULFILLMENT_CONFIRMATION', + OrderCancel = 'ORDER_CANCEL', + OrderConfirmation = 'ORDER_CONFIRMATION', + OrderRefund = 'ORDER_REFUND', + PaymentConfirmation = 'PAYMENT_CONFIRMATION', + ShippingConfirmation = 'SHIPPING_CONFIRMATION', + TrackingUpdated = 'TRACKING_UPDATED' +} /** The different order event types. */ -export type OrderEventsEnum = - | 'ADDED_PRODUCTS' - | 'CANCELED' - | 'CONFIRMED' - | 'DRAFT_CREATED' - | 'DRAFT_CREATED_FROM_REPLACE' - | 'EMAIL_SENT' - | 'EXPIRED' - | 'EXTERNAL_SERVICE_NOTIFICATION' - | 'FULFILLMENT_AWAITS_APPROVAL' - | 'FULFILLMENT_CANCELED' - | 'FULFILLMENT_FULFILLED_ITEMS' - | 'FULFILLMENT_REFUNDED' - | 'FULFILLMENT_REPLACED' - | 'FULFILLMENT_RESTOCKED_ITEMS' - | 'FULFILLMENT_RETURNED' - | 'INVOICE_GENERATED' - | 'INVOICE_REQUESTED' - | 'INVOICE_SENT' - | 'INVOICE_UPDATED' - | 'NOTE_ADDED' - | 'NOTE_UPDATED' - | 'ORDER_DISCOUNT_ADDED' - | 'ORDER_DISCOUNT_AUTOMATICALLY_UPDATED' - | 'ORDER_DISCOUNT_DELETED' - | 'ORDER_DISCOUNT_UPDATED' - | 'ORDER_FULLY_PAID' - | 'ORDER_LINE_DISCOUNT_REMOVED' - | 'ORDER_LINE_DISCOUNT_UPDATED' - | 'ORDER_LINE_PRODUCT_DELETED' - | 'ORDER_LINE_VARIANT_DELETED' - | 'ORDER_MARKED_AS_PAID' - | 'ORDER_REPLACEMENT_CREATED' - | 'OTHER' - | 'OVERSOLD_ITEMS' - | 'PAYMENT_AUTHORIZED' - | 'PAYMENT_CAPTURED' - | 'PAYMENT_FAILED' - | 'PAYMENT_REFUNDED' - | 'PAYMENT_VOIDED' - | 'PLACED' - | 'PLACED_FROM_DRAFT' - | 'REMOVED_PRODUCTS' - | 'TRACKING_UPDATED' - | 'TRANSACTION_CANCEL_REQUESTED' - | 'TRANSACTION_CHARGE_REQUESTED' - | 'TRANSACTION_EVENT' - | 'TRANSACTION_MARK_AS_PAID_FAILED' - | 'TRANSACTION_REFUND_REQUESTED' - | 'UPDATED_ADDRESS'; +export enum OrderEventsEnum { + AddedProducts = 'ADDED_PRODUCTS', + Canceled = 'CANCELED', + Confirmed = 'CONFIRMED', + DraftCreated = 'DRAFT_CREATED', + DraftCreatedFromReplace = 'DRAFT_CREATED_FROM_REPLACE', + EmailSent = 'EMAIL_SENT', + Expired = 'EXPIRED', + ExternalServiceNotification = 'EXTERNAL_SERVICE_NOTIFICATION', + FulfillmentAwaitsApproval = 'FULFILLMENT_AWAITS_APPROVAL', + FulfillmentCanceled = 'FULFILLMENT_CANCELED', + FulfillmentFulfilledItems = 'FULFILLMENT_FULFILLED_ITEMS', + FulfillmentRefunded = 'FULFILLMENT_REFUNDED', + FulfillmentReplaced = 'FULFILLMENT_REPLACED', + FulfillmentRestockedItems = 'FULFILLMENT_RESTOCKED_ITEMS', + FulfillmentReturned = 'FULFILLMENT_RETURNED', + InvoiceGenerated = 'INVOICE_GENERATED', + InvoiceRequested = 'INVOICE_REQUESTED', + InvoiceSent = 'INVOICE_SENT', + InvoiceUpdated = 'INVOICE_UPDATED', + NoteAdded = 'NOTE_ADDED', + NoteUpdated = 'NOTE_UPDATED', + OrderDiscountAdded = 'ORDER_DISCOUNT_ADDED', + OrderDiscountAutomaticallyUpdated = 'ORDER_DISCOUNT_AUTOMATICALLY_UPDATED', + OrderDiscountDeleted = 'ORDER_DISCOUNT_DELETED', + OrderDiscountUpdated = 'ORDER_DISCOUNT_UPDATED', + OrderFullyPaid = 'ORDER_FULLY_PAID', + OrderLineDiscountRemoved = 'ORDER_LINE_DISCOUNT_REMOVED', + OrderLineDiscountUpdated = 'ORDER_LINE_DISCOUNT_UPDATED', + OrderLineProductDeleted = 'ORDER_LINE_PRODUCT_DELETED', + OrderLineVariantDeleted = 'ORDER_LINE_VARIANT_DELETED', + OrderMarkedAsPaid = 'ORDER_MARKED_AS_PAID', + OrderReplacementCreated = 'ORDER_REPLACEMENT_CREATED', + Other = 'OTHER', + OversoldItems = 'OVERSOLD_ITEMS', + PaymentAuthorized = 'PAYMENT_AUTHORIZED', + PaymentCaptured = 'PAYMENT_CAPTURED', + PaymentFailed = 'PAYMENT_FAILED', + PaymentRefunded = 'PAYMENT_REFUNDED', + PaymentVoided = 'PAYMENT_VOIDED', + Placed = 'PLACED', + PlacedAutomaticallyFromPaidCheckout = 'PLACED_AUTOMATICALLY_FROM_PAID_CHECKOUT', + PlacedFromDraft = 'PLACED_FROM_DRAFT', + RemovedProducts = 'REMOVED_PRODUCTS', + TrackingUpdated = 'TRACKING_UPDATED', + TransactionCancelRequested = 'TRANSACTION_CANCEL_REQUESTED', + TransactionChargeRequested = 'TRANSACTION_CHARGE_REQUESTED', + TransactionEvent = 'TRANSACTION_EVENT', + TransactionMarkAsPaidFailed = 'TRANSACTION_MARK_AS_PAID_FAILED', + TransactionRefundRequested = 'TRANSACTION_REFUND_REQUESTED', + UpdatedAddress = 'UPDATED_ADDRESS' +} -/** - * Event sent when order becomes expired. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when order becomes expired. */ export type OrderExpired = Event & { - __typename?: 'OrderExpired'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type OrderFilterInput = { - authorizeStatus?: InputMaybe>; - channels?: InputMaybe>; - chargeStatus?: InputMaybe>; - checkoutIds?: InputMaybe>; - checkoutTokens?: InputMaybe>; - created?: InputMaybe; - customer?: InputMaybe; - giftCardBought?: InputMaybe; - giftCardUsed?: InputMaybe; - ids?: InputMaybe>; - isClickAndCollect?: InputMaybe; - isPreorder?: InputMaybe; - metadata?: InputMaybe>; - numbers?: InputMaybe>; - paymentStatus?: InputMaybe>; - search?: InputMaybe; - status?: InputMaybe>; - updatedAt?: InputMaybe; -}; - -/** - * Filter shipping methods for order. - * - * Added in Saleor 3.6. - */ + readonly authorizeStatus?: InputMaybe>; + readonly channels?: InputMaybe>; + readonly chargeStatus?: InputMaybe>; + readonly checkoutIds?: InputMaybe>; + readonly checkoutTokens?: InputMaybe>; + readonly created?: InputMaybe; + readonly customer?: InputMaybe; + readonly giftCardBought?: InputMaybe; + readonly giftCardUsed?: InputMaybe; + readonly ids?: InputMaybe>; + readonly isClickAndCollect?: InputMaybe; + readonly isPreorder?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly numbers?: InputMaybe>; + readonly paymentStatus?: InputMaybe>; + readonly search?: InputMaybe; + readonly status?: InputMaybe>; + readonly updatedAt?: InputMaybe; +}; + +/** Filter shipping methods for order. */ export type OrderFilterShippingMethods = Event & { - __typename?: 'OrderFilterShippingMethods'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; - /** - * Shipping methods that can be used with this checkout. - * - * Added in Saleor 3.6. - */ - shippingMethods?: Maybe>; + readonly recipient?: Maybe; + /** Shipping methods that can be used with this checkout. */ + readonly shippingMethods?: Maybe>; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -16750,289 +15203,206 @@ export type OrderFilterShippingMethods = Event & { * - FULFILLMENT_APPROVED (async): A fulfillment is approved. */ export type OrderFulfill = { - __typename?: 'OrderFulfill'; - errors: Array; + readonly errors: ReadonlyArray; /** List of created fulfillments. */ - fulfillments?: Maybe>; + readonly fulfillments?: Maybe>; /** Fulfilled order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type OrderFulfillInput = { /** If true, then allow proceed fulfillment when stock is exceeded. */ - allowStockToBeExceeded?: InputMaybe; + readonly allowStockToBeExceeded?: InputMaybe; /** List of items informing how to fulfill the order. */ - lines: Array; + readonly lines: ReadonlyArray; /** If true, send an email notification to the customer. */ - notifyCustomer?: InputMaybe; - /** - * Fulfillment tracking number. - * - * Added in Saleor 3.6. - */ - trackingNumber?: InputMaybe; + readonly notifyCustomer?: InputMaybe; + /** Fulfillment tracking number. */ + readonly trackingNumber?: InputMaybe; }; export type OrderFulfillLineInput = { /** The ID of the order line. */ - orderLineId?: InputMaybe; + readonly orderLineId?: InputMaybe; /** List of stock items to create. */ - stocks: Array; + readonly stocks: ReadonlyArray; }; export type OrderFulfillStockInput = { /** The number of line items to be fulfilled from given warehouse. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** ID of the warehouse from which the item will be fulfilled. */ - warehouse: Scalars['ID']; + readonly warehouse: Scalars['ID']; }; -/** - * Event sent when order is fulfilled. - * - * Added in Saleor 3.2. - */ +/** Event sent when order is fulfilled. */ export type OrderFulfilled = Event & { - __typename?: 'OrderFulfilled'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when order is fully paid. - * - * Added in Saleor 3.2. - */ +/** Event sent when order is fully paid. */ export type OrderFullyPaid = Event & { - __typename?: 'OrderFullyPaid'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * The order is fully refunded. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** The order is fully refunded. */ export type OrderFullyRefunded = Event & { - __typename?: 'OrderFullyRefunded'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Adds granted refund to the order. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderGrantRefundCreate = { - __typename?: 'OrderGrantRefundCreate'; - errors: Array; + readonly errors: ReadonlyArray; /** Created granted refund. */ - grantedRefund?: Maybe; + readonly grantedRefund?: Maybe; /** Order which has assigned new grant refund. */ - order?: Maybe; + readonly order?: Maybe; }; export type OrderGrantRefundCreateError = { - __typename?: 'OrderGrantRefundCreateError'; /** The error code. */ - code: OrderGrantRefundCreateErrorCode; + readonly code: OrderGrantRefundCreateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; - /** - * List of lines which cause the error. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - lines?: Maybe>; + readonly field?: Maybe; + /** List of lines which cause the error. */ + readonly lines?: Maybe>; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type OrderGrantRefundCreateErrorCode = - | 'AMOUNT_GREATER_THAN_AVAILABLE' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'SHIPPING_COSTS_ALREADY_GRANTED'; +export enum OrderGrantRefundCreateErrorCode { + AmountGreaterThanAvailable = 'AMOUNT_GREATER_THAN_AVAILABLE', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + ShippingCostsAlreadyGranted = 'SHIPPING_COSTS_ALREADY_GRANTED' +} export type OrderGrantRefundCreateInput = { /** Amount of the granted refund. If not provided, the amount will be calculated automatically based on provided `lines` and `grantRefundForShipping`. */ - amount?: InputMaybe; - /** - * Determine if granted refund should include shipping costs. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - grantRefundForShipping?: InputMaybe; - /** - * Lines to assign to granted refund. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - lines?: InputMaybe>; + readonly amount?: InputMaybe; + /** Determine if granted refund should include shipping costs. */ + readonly grantRefundForShipping?: InputMaybe; + /** Lines to assign to granted refund. */ + readonly lines?: InputMaybe>; /** Reason of the granted refund. */ - reason?: InputMaybe; + readonly reason?: InputMaybe; /** - * The ID of the transaction item related to the granted refund. If `amount` provided in the input, the transaction.chargedAmount needs to be equal or greater than provided `amount`.If `amount` is not provided in the input and calculated automatically by Saleor, the `min(calculatedAmount, transaction.chargedAmount)` will be used.Field will be required starting from Saleor 3.21. + * The ID of the transaction item related to the granted refund. If `amount` provided in the input, the transaction.chargedAmount needs to be equal or greater than provided `amount`.If `amount` is not provided in the input and calculated automatically by Saleor, the `min(calculatedAmount, transaction.chargedAmount)` will be used. Field required starting from Saleor 3.21. * * Added in Saleor 3.20. * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - transactionId?: InputMaybe; + readonly transactionId: Scalars['ID']; }; export type OrderGrantRefundCreateLineError = { - __typename?: 'OrderGrantRefundCreateLineError'; /** The error code. */ - code: OrderGrantRefundCreateLineErrorCode; + readonly code: OrderGrantRefundCreateLineErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The ID of the line related to the error. */ - lineId: Scalars['ID']; + readonly lineId: Scalars['ID']; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type OrderGrantRefundCreateLineErrorCode = - | 'GRAPHQL_ERROR' - | 'NOT_FOUND' - | 'QUANTITY_GREATER_THAN_AVAILABLE'; +export enum OrderGrantRefundCreateLineErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + NotFound = 'NOT_FOUND', + QuantityGreaterThanAvailable = 'QUANTITY_GREATER_THAN_AVAILABLE' +} export type OrderGrantRefundCreateLineInput = { /** The ID of the order line. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The quantity of line items to be marked to refund. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Reason of the granted refund for the line. */ - reason?: InputMaybe; + readonly reason?: InputMaybe; }; /** * Updates granted refund. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderGrantRefundUpdate = { - __typename?: 'OrderGrantRefundUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Created granted refund. */ - grantedRefund?: Maybe; + readonly grantedRefund?: Maybe; /** Order which has assigned updated grant refund. */ - order?: Maybe; + readonly order?: Maybe; }; export type OrderGrantRefundUpdateError = { - __typename?: 'OrderGrantRefundUpdateError'; - /** - * List of lines to add which cause the error. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - addLines?: Maybe>; + /** List of lines to add which cause the error. */ + readonly addLines?: Maybe>; /** The error code. */ - code: OrderGrantRefundUpdateErrorCode; + readonly code: OrderGrantRefundUpdateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; - /** - * List of lines to remove which cause the error. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - removeLines?: Maybe>; -}; - -/** An enumeration. */ -export type OrderGrantRefundUpdateErrorCode = - | 'AMOUNT_GREATER_THAN_AVAILABLE' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'SHIPPING_COSTS_ALREADY_GRANTED'; + readonly message?: Maybe; + /** List of lines to remove which cause the error. */ + readonly removeLines?: Maybe>; +}; + +export enum OrderGrantRefundUpdateErrorCode { + AmountGreaterThanAvailable = 'AMOUNT_GREATER_THAN_AVAILABLE', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + ShippingCostsAlreadyGranted = 'SHIPPING_COSTS_ALREADY_GRANTED' +} export type OrderGrantRefundUpdateInput = { - /** - * Lines to assign to granted refund. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - addLines?: InputMaybe>; + /** Lines to assign to granted refund. */ + readonly addLines?: InputMaybe>; /** Amount of the granted refund. if not provided and `addLines` or `removeLines` or `grantRefundForShipping` is provided, amount will be calculated automatically. */ - amount?: InputMaybe; - /** - * Determine if granted refund should include shipping costs. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - grantRefundForShipping?: InputMaybe; + readonly amount?: InputMaybe; + /** Determine if granted refund should include shipping costs. */ + readonly grantRefundForShipping?: InputMaybe; /** Reason of the granted refund. */ - reason?: InputMaybe; - /** - * Lines to remove from granted refund. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - removeLines?: InputMaybe>; + readonly reason?: InputMaybe; + /** Lines to remove from granted refund. */ + readonly removeLines?: InputMaybe>; /** * The ID of the transaction item related to the granted refund. If `amount` provided in the input, the transaction.chargedAmount needs to be equal or greater than provided `amount`.If `amount` is not provided in the input and calculated automatically by Saleor, the `min(calculatedAmount, transaction.chargedAmount)` will be used.Field will be required starting from Saleor 3.21. * @@ -17040,110 +15410,83 @@ export type OrderGrantRefundUpdateInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - transactionId?: InputMaybe; + readonly transactionId?: InputMaybe; }; export type OrderGrantRefundUpdateLineAddInput = { /** The ID of the order line. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The quantity of line items to be marked to refund. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Reason of the granted refund for the line. */ - reason?: InputMaybe; + readonly reason?: InputMaybe; }; export type OrderGrantRefundUpdateLineError = { - __typename?: 'OrderGrantRefundUpdateLineError'; /** The error code. */ - code: OrderGrantRefundUpdateLineErrorCode; + readonly code: OrderGrantRefundUpdateLineErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The ID of the line related to the error. */ - lineId: Scalars['ID']; + readonly lineId: Scalars['ID']; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type OrderGrantRefundUpdateLineErrorCode = - | 'GRAPHQL_ERROR' - | 'NOT_FOUND' - | 'QUANTITY_GREATER_THAN_AVAILABLE'; +export enum OrderGrantRefundUpdateLineErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + NotFound = 'NOT_FOUND', + QuantityGreaterThanAvailable = 'QUANTITY_GREATER_THAN_AVAILABLE' +} -/** - * The details of granted refund. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** The details of granted refund. */ export type OrderGrantedRefund = { - __typename?: 'OrderGrantedRefund'; /** Refund amount. */ - amount: Money; + readonly amount: Money; /** App that performed the action. */ - app?: Maybe; + readonly app?: Maybe; /** Time of creation. */ - createdAt: Scalars['DateTime']; - id: Scalars['ID']; - /** - * Lines assigned to the granted refund. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - lines?: Maybe>; + readonly createdAt: Scalars['DateTime']; + readonly id: Scalars['ID']; + /** Lines assigned to the granted refund. */ + readonly lines?: Maybe>; /** Reason of the refund. */ - reason?: Maybe; - /** - * If true, the refunded amount includes the shipping price.If false, the refunded amount does not include the shipping price. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - shippingCostsIncluded: Scalars['Boolean']; + readonly reason?: Maybe; + /** If true, the refunded amount includes the shipping price.If false, the refunded amount does not include the shipping price. */ + readonly shippingCostsIncluded: Scalars['Boolean']; /** * Status of the granted refund calculated based on transactionItem assigned to granted refund. * * Added in Saleor 3.20. */ - status: OrderGrantedRefundStatusEnum; + readonly status: OrderGrantedRefundStatusEnum; /** * The transaction assigned to the granted refund. * * Added in Saleor 3.20. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** * List of refund events associated with the granted refund. * * Added in Saleor 3.20. */ - transactionEvents?: Maybe>; + readonly transactionEvents?: Maybe>; /** Time of last update. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; /** User who performed the action. Requires of of the following permissions: MANAGE_USERS, MANAGE_STAFF, OWNER. */ - user?: Maybe; + readonly user?: Maybe; }; -/** - * Represents granted refund line. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents granted refund line. */ export type OrderGrantedRefundLine = { - __typename?: 'OrderGrantedRefundLine'; - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Line of the order associated with this granted refund. */ - orderLine: OrderLine; + readonly orderLine: OrderLine; /** Number of items to refund. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Reason for refunding the line. */ - reason?: Maybe; + readonly reason?: Maybe; }; /** @@ -17154,24 +15497,30 @@ export type OrderGrantedRefundLine = { * FULL - the refund on related transactionItem is fully processed * FAIL - the refund on related transactionItem failed */ -export type OrderGrantedRefundStatusEnum = - | 'FAILURE' - | 'NONE' - | 'PENDING' - | 'SUCCESS'; +export enum OrderGrantedRefundStatusEnum { + Failure = 'FAILURE', + None = 'NONE', + Pending = 'PENDING', + Success = 'SUCCESS' +} /** Represents order line of particular order. */ export type OrderLine = Node & ObjectWithMetadata & { - __typename?: 'OrderLine'; /** * List of allocations across warehouses. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. */ - allocations?: Maybe>; - digitalContentUrl?: Maybe; + readonly allocations?: Maybe>; + readonly digitalContentUrl?: Maybe; + /** + * List of applied discounts + * + * Added in Saleor 3.21. + */ + readonly discounts?: Maybe>; /** ID of the order line. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Determine if the line is a gift. * @@ -17179,136 +15528,86 @@ export type OrderLine = Node & ObjectWithMetadata & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - isGift?: Maybe; - /** - * Returns True, if the line unit price was overridden. - * - * Added in Saleor 3.14. - */ - isPriceOverridden?: Maybe; + readonly isGift?: Maybe; + /** Returns True, if the line unit price was overridden. */ + readonly isPriceOverridden?: Maybe; /** Whether the product variant requires shipping. */ - isShippingRequired: Scalars['Boolean']; - /** - * List of public metadata items. Can be accessed without permissions. - * - * Added in Saleor 3.5. - */ - metadata: Array; + readonly isShippingRequired: Scalars['Boolean']; + /** List of public metadata items. Can be accessed without permissions. */ + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.5. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.5. - */ - metafields?: Maybe; - /** - * List of private metadata items. Requires staff permissions to access. - * - * Added in Saleor 3.5. - */ - privateMetadata: Array; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; + /** List of private metadata items. Requires staff permissions to access. */ + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.5. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.5. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Name of the product in order line. */ - productName: Scalars['String']; + readonly productName: Scalars['String']; /** SKU of the product variant. */ - productSku?: Maybe; + readonly productSku?: Maybe; /** The ID of the product variant. */ - productVariantId?: Maybe; + readonly productVariantId?: Maybe; /** Number of variant items ordered. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Number of variant items fulfilled. */ - quantityFulfilled: Scalars['Int']; - /** - * A quantity of items remaining to be fulfilled. - * - * Added in Saleor 3.1. - */ - quantityToFulfill: Scalars['Int']; - /** - * Denormalized sale ID, set when order line is created for a product variant that is on sale. - * - * Added in Saleor 3.14. - */ - saleId?: Maybe; + readonly quantityFulfilled: Scalars['Int']; + /** A quantity of items remaining to be fulfilled. */ + readonly quantityToFulfill: Scalars['Int']; + /** Denormalized sale ID, set when order line is created for a product variant that is on sale. */ + readonly saleId?: Maybe; /** * Denormalized tax class of the product in this order line. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxClass?: Maybe; - /** - * Denormalized public metadata of the tax class. - * - * Added in Saleor 3.9. - */ - taxClassMetadata: Array; - /** - * Denormalized name of the tax class. - * - * Added in Saleor 3.9. - */ - taxClassName?: Maybe; - /** - * Denormalized private metadata of the tax class. Requires staff permissions to access. - * - * Added in Saleor 3.9. - */ - taxClassPrivateMetadata: Array; + readonly taxClass?: Maybe; + /** Denormalized public metadata of the tax class. */ + readonly taxClassMetadata: ReadonlyArray; + /** Denormalized name of the tax class. */ + readonly taxClassName?: Maybe; + /** Denormalized private metadata of the tax class. Requires staff permissions to access. */ + readonly taxClassPrivateMetadata: ReadonlyArray; /** Rate of tax applied on product variant. */ - taxRate: Scalars['Float']; - thumbnail?: Maybe; + readonly taxRate: Scalars['Float']; + readonly thumbnail?: Maybe; /** Price of the order line. */ - totalPrice: TaxedMoney; + readonly totalPrice: TaxedMoney; /** Product name in the customer's language */ - translatedProductName: Scalars['String']; + readonly translatedProductName: Scalars['String']; /** Variant name in the customer's language */ - translatedVariantName: Scalars['String']; + readonly translatedVariantName: Scalars['String']; /** Price of the order line without discounts. */ - undiscountedTotalPrice: TaxedMoney; - /** Price of the single item in the order line without applied an order line discount. */ - undiscountedUnitPrice: TaxedMoney; - /** The discount applied to the single order line. */ - unitDiscount: Money; - /** Reason for any discounts applied on a product in the order. */ - unitDiscountReason?: Maybe; - /** Type of the discount: fixed or percent */ - unitDiscountType?: Maybe; - /** Value of the discount. Can store fixed value or percent value */ - unitDiscountValue: Scalars['PositiveDecimal']; - /** Price of the single item in the order line. */ - unitPrice: TaxedMoney; + readonly undiscountedTotalPrice: TaxedMoney; + /** Price of the single item in the order line without any discount applied. */ + readonly undiscountedUnitPrice: TaxedMoney; + /** Sum of the line-level discounts applied to the order line. Order-level discounts which affect the line are not visible in this field. For order-level discount portion (if any), please query `order.discounts` field. */ + readonly unitDiscount: Money; + /** Reason for line-level discounts applied on the order line. Order-level discounts which affect the line are not visible in this field. For order-level discount reason (if any), please query `order.discounts` field. */ + readonly unitDiscountReason?: Maybe; + /** Type of the discount: `fixed` or `percent`. This field shouldn't be used when multiple discounts affect the line. There is a limitation, that after running `checkoutComplete` mutation the field is always set to `fixed`. */ + readonly unitDiscountType?: Maybe; + /** Value of the discount. Can store fixed value or percent value. This field shouldn't be used when multiple discounts affect the line. There is a limitation, that after running `checkoutComplete` mutation the field always stores fixed value. */ + readonly unitDiscountValue: Scalars['PositiveDecimal']; + /** Price of the single item in the order line with all the line-level discounts and order-level discount portions applied. */ + readonly unitPrice: TaxedMoney; /** A purchased product variant. Note: this field may be null if the variant has been removed from stock at all. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - variant?: Maybe; + readonly variant?: Maybe; /** Name of the variant of product in order line. */ - variantName: Scalars['String']; - /** - * Voucher code that was used for this order line. - * - * Added in Saleor 3.14. - */ - voucherCode?: Maybe; + readonly variantName: Scalars['String']; + /** Voucher code that was used for this order line. */ + readonly voucherCode?: Maybe; }; @@ -17320,7 +15619,7 @@ export type OrderLineMetafieldArgs = { /** Represents order line of particular order. */ export type OrderLineMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -17332,7 +15631,7 @@ export type OrderLinePrivateMetafieldArgs = { /** Represents order line of particular order. */ export type OrderLinePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -17343,24 +15642,14 @@ export type OrderLineThumbnailArgs = { }; export type OrderLineCreateInput = { - /** - * Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. - * - * Added in Saleor 3.6. - */ - forceNewLine?: InputMaybe; - /** - * Custom price of the item.When the line with the same variant will be provided multiple times, the last price will be used. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - price?: InputMaybe; + /** Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. */ + readonly forceNewLine?: InputMaybe; + /** Custom price of the item.When the line with the same variant will be provided multiple times, the last price will be used. */ + readonly price?: InputMaybe; /** Number of variant items ordered. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Product variant ID. */ - variantId: Scalars['ID']; + readonly variantId: Scalars['ID']; }; /** @@ -17369,14 +15658,39 @@ export type OrderLineCreateInput = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderLineDelete = { - __typename?: 'OrderLineDelete'; - errors: Array; + readonly errors: ReadonlyArray; /** A related order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; /** An order line that was deleted. */ - orderLine?: Maybe; + readonly orderLine?: Maybe; +}; + +/** Represent the discount applied to order line. */ +export type OrderLineDiscount = { + /** The ID of discount applied. */ + readonly id: Scalars['ID']; + /** The name of applied discount. */ + readonly name?: Maybe; + /** + * Explanation for the applied discount. + * + * Requires one of the following permissions: MANAGE_ORDERS. + */ + readonly reason?: Maybe; + /** The discount amount applied to the line item. */ + readonly total: Money; + /** Translated name of the applied discount. */ + readonly translatedName?: Maybe; + /** The type of applied discount: Sale, Voucher or Manual. */ + readonly type: OrderDiscountType; + /** The discount amount applied to the single line unit. */ + readonly unit: Money; + /** Value of the discount. Can store fixed value or percent value */ + readonly value: Scalars['PositiveDecimal']; + /** Type of the discount: fixed or percent */ + readonly valueType: DiscountValueTypeEnum; }; /** @@ -17385,14 +15699,13 @@ export type OrderLineDelete = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderLineDiscountRemove = { - __typename?: 'OrderLineDiscountRemove'; - errors: Array; + readonly errors: ReadonlyArray; /** Order which is related to line which has removed discount. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; /** Order line which has removed discount. */ - orderLine?: Maybe; + readonly orderLine?: Maybe; }; /** @@ -17401,19 +15714,18 @@ export type OrderLineDiscountRemove = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderLineDiscountUpdate = { - __typename?: 'OrderLineDiscountUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Order which is related to the discounted line. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; /** Order line which has been discounted. */ - orderLine?: Maybe; + readonly orderLine?: Maybe; }; export type OrderLineInput = { /** Number of variant items ordered. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; }; /** @@ -17422,13 +15734,12 @@ export type OrderLineInput = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderLineUpdate = { - __typename?: 'OrderLineUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Related order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; - orderLine?: Maybe; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; + readonly orderLine?: Maybe; }; /** @@ -17437,14 +15748,13 @@ export type OrderLineUpdate = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderLinesCreate = { - __typename?: 'OrderLinesCreate'; - errors: Array; + readonly errors: ReadonlyArray; /** Related order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; /** List of added order lines. */ - orderLines?: Maybe>; + readonly orderLines?: Maybe>; }; /** @@ -17453,142 +15763,117 @@ export type OrderLinesCreate = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderMarkAsPaid = { - __typename?: 'OrderMarkAsPaid'; - errors: Array; + readonly errors: ReadonlyArray; /** Order marked as paid. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; -/** - * Event sent when order metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when order metadata is updated. */ export type OrderMetadataUpdated = Event & { - __typename?: 'OrderMetadataUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Adds note to the order. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderNoteAdd = { - __typename?: 'OrderNoteAdd'; - errors: Array; + readonly errors: ReadonlyArray; /** Order note created. */ - event?: Maybe; + readonly event?: Maybe; /** Order with the note added. */ - order?: Maybe; + readonly order?: Maybe; }; export type OrderNoteAddError = { - __typename?: 'OrderNoteAddError'; /** The error code. */ - code?: Maybe; + readonly code?: Maybe; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type OrderNoteAddErrorCode = - | 'GRAPHQL_ERROR' - | 'REQUIRED'; +export enum OrderNoteAddErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Required = 'REQUIRED' +} export type OrderNoteInput = { /** Note message. */ - message: Scalars['String']; + readonly message: Scalars['String']; }; /** * Updates note of an order. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderNoteUpdate = { - __typename?: 'OrderNoteUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Order note updated. */ - event?: Maybe; + readonly event?: Maybe; /** Order with the note updated. */ - order?: Maybe; + readonly order?: Maybe; }; export type OrderNoteUpdateError = { - __typename?: 'OrderNoteUpdateError'; /** The error code. */ - code?: Maybe; + readonly code?: Maybe; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type OrderNoteUpdateErrorCode = - | 'GRAPHQL_ERROR' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum OrderNoteUpdateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} export type OrderOrCheckout = Checkout | Order; -/** An enumeration. */ -export type OrderOriginEnum = - | 'BULK_CREATE' - | 'CHECKOUT' - | 'DRAFT' - | 'REISSUE'; +export enum OrderOriginEnum { + BulkCreate = 'BULK_CREATE', + Checkout = 'CHECKOUT', + Draft = 'DRAFT', + Reissue = 'REISSUE' +} -/** - * Payment has been made. The order may be partially or fully paid. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Payment has been made. The order may be partially or fully paid. */ export type OrderPaid = Event & { - __typename?: 'OrderPaid'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type OrderPredicateInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; + readonly OR?: InputMaybe>; /** Defines the conditions related to checkout and order objects. */ - discountedObjectPredicate?: InputMaybe; + readonly discountedObjectPredicate?: InputMaybe; }; /** @@ -17597,122 +15882,103 @@ export type OrderPredicateInput = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderRefund = { - __typename?: 'OrderRefund'; - errors: Array; + readonly errors: ReadonlyArray; /** A refunded order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type OrderRefundFulfillmentLineInput = { /** The ID of the fulfillment line to refund. */ - fulfillmentLineId: Scalars['ID']; + readonly fulfillmentLineId: Scalars['ID']; /** The number of items to be refunded. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; }; export type OrderRefundLineInput = { /** The ID of the order line to refund. */ - orderLineId: Scalars['ID']; + readonly orderLineId: Scalars['ID']; /** The number of items to be refunded. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; }; export type OrderRefundProductsInput = { /** The total amount of refund when the value is provided manually. */ - amountToRefund?: InputMaybe; + readonly amountToRefund?: InputMaybe; /** List of fulfilled lines to refund. */ - fulfillmentLines?: InputMaybe>; + readonly fulfillmentLines?: InputMaybe>; /** If true, Saleor will refund shipping costs. If amountToRefund is providedincludeShippingCosts will be ignored. */ - includeShippingCosts?: InputMaybe; + readonly includeShippingCosts?: InputMaybe; /** List of unfulfilled lines to refund. */ - orderLines?: InputMaybe>; + readonly orderLines?: InputMaybe>; }; -/** - * The order received a refund. The order may be partially or fully refunded. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** The order received a refund. The order may be partially or fully refunded. */ export type OrderRefunded = Event & { - __typename?: 'OrderRefunded'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type OrderReturnFulfillmentLineInput = { /** The ID of the fulfillment line to return. */ - fulfillmentLineId: Scalars['ID']; + readonly fulfillmentLineId: Scalars['ID']; /** The number of items to be returned. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Determines, if the line should be added to replace order. */ - replace?: InputMaybe; + readonly replace?: InputMaybe; }; export type OrderReturnLineInput = { /** The ID of the order line to return. */ - orderLineId: Scalars['ID']; + readonly orderLineId: Scalars['ID']; /** The number of items to be returned. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Determines, if the line should be added to replace order. */ - replace?: InputMaybe; + readonly replace?: InputMaybe; }; export type OrderReturnProductsInput = { /** The total amount of refund when the value is provided manually. */ - amountToRefund?: InputMaybe; + readonly amountToRefund?: InputMaybe; /** List of fulfilled lines to return. */ - fulfillmentLines?: InputMaybe>; + readonly fulfillmentLines?: InputMaybe>; /** If true, Saleor will refund shipping costs. If amountToRefund is providedincludeShippingCosts will be ignored. */ - includeShippingCosts?: InputMaybe; + readonly includeShippingCosts?: InputMaybe; /** List of unfulfilled lines to return. */ - orderLines?: InputMaybe>; + readonly orderLines?: InputMaybe>; /** If true, Saleor will call refund action for all lines. */ - refund?: InputMaybe; + readonly refund?: InputMaybe; }; /** Represents the channel-specific order settings. */ export type OrderSettings = { - __typename?: 'OrderSettings'; - /** - * Determine if it is possible to place unpaid order by calling `checkoutComplete` mutation. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - allowUnpaidOrders: Scalars['Boolean']; + /** Determine if it is possible to place unpaid order by calling `checkoutComplete` mutation. */ + readonly allowUnpaidOrders: Scalars['Boolean']; /** When disabled, all new orders from checkout will be marked as unconfirmed. When enabled orders from checkout will become unfulfilled immediately. */ - automaticallyConfirmAllNewOrders: Scalars['Boolean']; + readonly automaticallyConfirmAllNewOrders: Scalars['Boolean']; /** When enabled, all non-shippable gift card orders will be fulfilled automatically. */ - automaticallyFulfillNonShippableGiftCard: Scalars['Boolean']; + readonly automaticallyFulfillNonShippableGiftCard: Scalars['Boolean']; + /** The time in days after expired orders will be deleted. */ + readonly deleteExpiredOrdersAfter: Scalars['Day']; /** - * The time in days after expired orders will be deleted. + * Time in hours after which the draft order line price will be refreshed. * - * Added in Saleor 3.14. + * Added in Saleor 3.21. * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - deleteExpiredOrdersAfter: Scalars['Day']; - /** - * Expiration time in minutes. Default null - means do not expire any orders. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - expireOrdersAfter?: Maybe; + readonly draftOrderLinePriceFreezePeriod?: Maybe; + /** Expiration time in minutes. Default null - means do not expire any orders. */ + readonly expireOrdersAfter?: Maybe; /** * Determine if voucher applied on draft order should be count toward voucher usage. * @@ -17720,62 +15986,56 @@ export type OrderSettings = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - includeDraftOrderInVoucherUsage: Scalars['Boolean']; + readonly includeDraftOrderInVoucherUsage: Scalars['Boolean']; /** * Determine what strategy will be used to mark the order as paid. Based on the chosen option, the proper object will be created and attached to the order when it's manually marked as paid. * `PAYMENT_FLOW` - [default option] creates the `Payment` object. * `TRANSACTION_FLOW` - creates the `TransactionItem` object. + */ + readonly markAsPaidStrategy: MarkAsPaidStrategyEnum; + /** + * This flag only affects orders created from checkout and applies specifically to vouchers of the types: `SPECIFIC_PRODUCT` and `ENTIRE_ORDER` with `applyOncePerOrder` enabled. + * - When legacy propagation is enabled, discounts from these vouchers are represented as `OrderDiscount` objects, attached to the order and returned in the `Order.discounts` field. Additionally, percentage-based vouchers are converted to fixed-value discounts. + * - When legacy propagation is disabled, discounts are represented as `OrderLineDiscount` objects, attached to individual lines and returned in the `OrderLine.discounts` field. In this case, percentage-based vouchers retain their original type. + * In future releases, `OrderLineDiscount` will become the default behavior, and this flag will be deprecated and removed. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. + * Added in Saleor 3.21. */ - markAsPaidStrategy: MarkAsPaidStrategyEnum; + readonly useLegacyLineDiscountPropagation: Scalars['Boolean']; }; export type OrderSettingsError = { - __typename?: 'OrderSettingsError'; /** The error code. */ - code: OrderSettingsErrorCode; + readonly code: OrderSettingsErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type OrderSettingsErrorCode = - | 'INVALID'; +export enum OrderSettingsErrorCode { + Invalid = 'INVALID' +} export type OrderSettingsInput = { - /** - * Determine if it is possible to place unpaid order by calling `checkoutComplete` mutation. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - allowUnpaidOrders?: InputMaybe; + /** Determine if it is possible to place unpaid order by calling `checkoutComplete` mutation. */ + readonly allowUnpaidOrders?: InputMaybe; /** When disabled, all new orders from checkout will be marked as unconfirmed. When enabled orders from checkout will become unfulfilled immediately. By default set to True */ - automaticallyConfirmAllNewOrders?: InputMaybe; + readonly automaticallyConfirmAllNewOrders?: InputMaybe; /** When enabled, all non-shippable gift card orders will be fulfilled automatically. By default set to True. */ - automaticallyFulfillNonShippableGiftCard?: InputMaybe; - /** - * The time in days after expired orders will be deleted.Allowed range is from 1 to 120. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - deleteExpiredOrdersAfter?: InputMaybe; + readonly automaticallyFulfillNonShippableGiftCard?: InputMaybe; + /** The time in days after expired orders will be deleted.Allowed range is from 1 to 120. */ + readonly deleteExpiredOrdersAfter?: InputMaybe; /** - * Expiration time in minutes. Default null - means do not expire any orders. Enter 0 or null to disable. + * Time in hours after which the draft order line price will be refreshed. Default value is 24 hours. Enter 0 or null to disable. * - * Added in Saleor 3.13. + * Added in Saleor 3.21. * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - expireOrdersAfter?: InputMaybe; + readonly draftOrderLinePriceFreezePeriod?: InputMaybe; + /** Expiration time in minutes. Default null - means do not expire any orders. Enter 0 or null to disable. */ + readonly expireOrdersAfter?: InputMaybe; /** * Specify whether a coupon applied to draft orders will count toward voucher usage. * @@ -17785,17 +16045,22 @@ export type OrderSettingsInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - includeDraftOrderInVoucherUsage?: InputMaybe; + readonly includeDraftOrderInVoucherUsage?: InputMaybe; /** * Determine what strategy will be used to mark the order as paid. Based on the chosen option, the proper object will be created and attached to the order when it's manually marked as paid. * `PAYMENT_FLOW` - [default option] creates the `Payment` object. * `TRANSACTION_FLOW` - creates the `TransactionItem` object. + */ + readonly markAsPaidStrategy?: InputMaybe; + /** + * This flag only affects orders created from checkout and applies specifically to vouchers of the types: `SPECIFIC_PRODUCT` and `ENTIRE_ORDER` with `applyOncePerOrder` enabled. + * - When legacy propagation is enabled, discounts from these vouchers are represented as `OrderDiscount` objects, attached to the order and returned in the `Order.discounts` field. Additionally, percentage-based vouchers are converted to fixed-value discounts. + * - When legacy propagation is disabled, discounts are represented as `OrderLineDiscount` objects, attached to individual lines and returned in the `OrderLine.discounts` field. In this case, percentage-based vouchers retain their original type. + * In future releases, `OrderLineDiscount` will become the default behavior, and this flag will be deprecated and removed. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. + * Added in Saleor 3.21. */ - markAsPaidStrategy?: InputMaybe; + readonly useLegacyLineDiscountPropagation?: InputMaybe; }; /** @@ -17804,74 +16069,67 @@ export type OrderSettingsInput = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderSettingsUpdate = { - __typename?: 'OrderSettingsUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Order settings. */ - orderSettings?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderSettingsErrors: Array; + readonly orderSettings?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderSettingsErrors: ReadonlyArray; }; export type OrderSettingsUpdateInput = { /** When disabled, all new orders from checkout will be marked as unconfirmed. When enabled orders from checkout will become unfulfilled immediately. By default set to True */ - automaticallyConfirmAllNewOrders?: InputMaybe; + readonly automaticallyConfirmAllNewOrders?: InputMaybe; /** When enabled, all non-shippable gift card orders will be fulfilled automatically. By default set to True. */ - automaticallyFulfillNonShippableGiftCard?: InputMaybe; + readonly automaticallyFulfillNonShippableGiftCard?: InputMaybe; }; -export type OrderSortField = - /** - * Sort orders by creation date. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - */ - | 'CREATED_AT' - /** - * Sort orders by creation date. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - */ - | 'CREATION_DATE' +export enum OrderSortField { + /** Sort orders by creation date. */ + CreatedAt = 'CREATED_AT', + /** Sort orders by creation date. */ + CreationDate = 'CREATION_DATE', /** Sort orders by customer. */ - | 'CUSTOMER' + Customer = 'CUSTOMER', /** Sort orders by fulfillment status. */ - | 'FULFILLMENT_STATUS' + FulfillmentStatus = 'FULFILLMENT_STATUS', /** Sort orders by last modified at. */ - | 'LAST_MODIFIED_AT' + LastModifiedAt = 'LAST_MODIFIED_AT', /** Sort orders by number. */ - | 'NUMBER' + Number = 'NUMBER', /** Sort orders by payment. */ - | 'PAYMENT' + Payment = 'PAYMENT', /** Sort orders by rank. Note: This option is available only with the `search` filter. */ - | 'RANK'; + Rank = 'RANK' +} export type OrderSortingInput = { /** Specifies the direction in which to sort orders. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort orders by the selected field. */ - field: OrderSortField; -}; - -/** An enumeration. */ -export type OrderStatus = - | 'CANCELED' - | 'DRAFT' - | 'EXPIRED' - | 'FULFILLED' - | 'PARTIALLY_FULFILLED' - | 'PARTIALLY_RETURNED' - | 'RETURNED' - | 'UNCONFIRMED' - | 'UNFULFILLED'; - -export type OrderStatusFilter = - | 'CANCELED' - | 'FULFILLED' - | 'PARTIALLY_FULFILLED' - | 'READY_TO_CAPTURE' - | 'READY_TO_FULFILL' - | 'UNCONFIRMED' - | 'UNFULFILLED'; + readonly field: OrderSortField; +}; + +export enum OrderStatus { + Canceled = 'CANCELED', + Draft = 'DRAFT', + Expired = 'EXPIRED', + Fulfilled = 'FULFILLED', + PartiallyFulfilled = 'PARTIALLY_FULFILLED', + PartiallyReturned = 'PARTIALLY_RETURNED', + Returned = 'RETURNED', + Unconfirmed = 'UNCONFIRMED', + Unfulfilled = 'UNFULFILLED' +} + +export enum OrderStatusFilter { + Canceled = 'CANCELED', + Fulfilled = 'FULFILLED', + PartiallyFulfilled = 'PARTIALLY_FULFILLED', + ReadyToCapture = 'READY_TO_CAPTURE', + ReadyToFulfill = 'READY_TO_FULFILL', + Unconfirmed = 'UNCONFIRMED', + Unfulfilled = 'UNFULFILLED' +} /** * Updates an order. @@ -17879,26 +16137,43 @@ export type OrderStatusFilter = * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderUpdate = { - __typename?: 'OrderUpdate'; - errors: Array; - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly errors: ReadonlyArray; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type OrderUpdateInput = { /** Billing address of the customer. */ - billingAddress?: InputMaybe; + readonly billingAddress?: InputMaybe; + /** External ID of this order. */ + readonly externalReference?: InputMaybe; /** - * External ID of this order. + * Order language code. * - * Added in Saleor 3.10. + * Added in Saleor 3.21. */ - externalReference?: InputMaybe; + readonly languageCode?: InputMaybe; + /** + * Order public metadata. + * + * Added in Saleor 3.21.Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly metadata?: InputMaybe>; + /** + * Order private metadata. + * + * Added in Saleor 3.21.Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly privateMetadata?: InputMaybe>; /** Shipping address of the customer. */ - shippingAddress?: InputMaybe; + readonly shippingAddress?: InputMaybe; /** Email address of the customer. */ - userEmail?: InputMaybe; + readonly userEmail?: InputMaybe; }; /** @@ -17907,36 +16182,30 @@ export type OrderUpdateInput = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderUpdateShipping = { - __typename?: 'OrderUpdateShipping'; - errors: Array; + readonly errors: ReadonlyArray; /** Order with updated shipping method. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; export type OrderUpdateShippingInput = { /** ID of the selected shipping method, pass null to remove currently assigned shipping method. */ - shippingMethod?: InputMaybe; + readonly shippingMethod?: InputMaybe; }; -/** - * Event sent when order is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when order is updated. */ export type OrderUpdated = Event & { - __typename?: 'OrderUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The order the event relates to. */ - order?: Maybe; + readonly order?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -17945,90 +16214,72 @@ export type OrderUpdated = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type OrderVoid = { - __typename?: 'OrderVoid'; - errors: Array; + readonly errors: ReadonlyArray; /** A voided order. */ - order?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - orderErrors: Array; + readonly order?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly orderErrors: ReadonlyArray; }; /** A static page that can be manually added by a shop operator through the dashboard. */ export type Page = Node & ObjectWithMetadata & { - __typename?: 'Page'; /** List of attributes assigned to this product. */ - attributes: Array; + readonly attributes: ReadonlyArray; /** * Content of the page. * * Rich text format. For reference see https://editorjs.io/ */ - content?: Maybe; + readonly content?: Maybe; /** * Content of the page. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `content` field instead. + * @deprecated Use the `content` field instead. */ - contentJson: Scalars['JSONString']; + readonly contentJson: Scalars['JSONString']; /** Date and time at which page was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** ID of the page. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Determines if the page is published. */ - isPublished: Scalars['Boolean']; + readonly isPublished: Scalars['Boolean']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Determines the type of page */ - pageType: PageType; + readonly pageType: PageType; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date. */ - publicationDate?: Maybe; - /** - * The page publication date. - * - * Added in Saleor 3.3. */ - publishedAt?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** @deprecated Use the `publishedAt` field to fetch the publication date. */ + readonly publicationDate?: Maybe; + /** The page publication date. */ + readonly publishedAt?: Maybe; /** Description of the page for SEO. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** Title of the page for SEO. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; /** Slug of the page. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; /** Title of the page. */ - title: Scalars['String']; + readonly title: Scalars['String']; /** Returns translated page fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -18040,7 +16291,7 @@ export type PageMetafieldArgs = { /** A static page that can be manually added by a shop operator through the dashboard. */ export type PageMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -18052,7 +16303,7 @@ export type PagePrivateMetafieldArgs = { /** A static page that can be manually added by a shop operator through the dashboard. */ export type PagePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -18067,12 +16318,11 @@ export type PageTranslationArgs = { * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ export type PageAttributeAssign = { - __typename?: 'PageAttributeAssign'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; /** The updated page type. */ - pageType?: Maybe; + readonly pageType?: Maybe; }; /** @@ -18081,12 +16331,11 @@ export type PageAttributeAssign = { * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ export type PageAttributeUnassign = { - __typename?: 'PageAttributeUnassign'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; /** The updated page type. */ - pageType?: Maybe; + readonly pageType?: Maybe; }; /** @@ -18095,12 +16344,11 @@ export type PageAttributeUnassign = { * Requires one of the following permissions: MANAGE_PAGES. */ export type PageBulkDelete = { - __typename?: 'PageBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; }; /** @@ -18109,29 +16357,26 @@ export type PageBulkDelete = { * Requires one of the following permissions: MANAGE_PAGES. */ export type PageBulkPublish = { - __typename?: 'PageBulkPublish'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; }; export type PageCountableConnection = { - __typename?: 'PageCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type PageCountableEdge = { - __typename?: 'PageCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Page; + readonly node: Page; }; /** @@ -18140,63 +16385,52 @@ export type PageCountableEdge = { * Requires one of the following permissions: MANAGE_PAGES. */ export type PageCreate = { - __typename?: 'PageCreate'; - errors: Array; - page?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly errors: ReadonlyArray; + readonly page?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; }; export type PageCreateInput = { /** List of attributes. */ - attributes?: InputMaybe>; + readonly attributes?: InputMaybe>; /** * Page content. * * Rich text format. For reference see https://editorjs.io/ */ - content?: InputMaybe; + readonly content?: InputMaybe; /** Determines if page is visible in the storefront. */ - isPublished?: InputMaybe; + readonly isPublished?: InputMaybe; /** ID of the page type that page belongs to. */ - pageType: Scalars['ID']; + readonly pageType: Scalars['ID']; /** * Publication date. ISO 8601 standard. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. + * @deprecated Use `publishedAt` field instead. */ - publicationDate?: InputMaybe; - /** - * Publication date time. ISO 8601 standard. - * - * Added in Saleor 3.3. - */ - publishedAt?: InputMaybe; + readonly publicationDate?: InputMaybe; + /** Publication date time. ISO 8601 standard. */ + readonly publishedAt?: InputMaybe; /** Search engine optimization fields. */ - seo?: InputMaybe; + readonly seo?: InputMaybe; /** Page internal name. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** Page title. */ - title?: InputMaybe; + readonly title?: InputMaybe; }; -/** - * Event sent when new page is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new page is created. */ export type PageCreated = Event & { - __typename?: 'PageCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The page the event relates to. */ - page?: Maybe; + readonly page?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -18205,106 +16439,93 @@ export type PageCreated = Event & { * Requires one of the following permissions: MANAGE_PAGES. */ export type PageDelete = { - __typename?: 'PageDelete'; - errors: Array; - page?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly errors: ReadonlyArray; + readonly page?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; }; -/** - * Event sent when page is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when page is deleted. */ export type PageDeleted = Event & { - __typename?: 'PageDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The page the event relates to. */ - page?: Maybe; + readonly page?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type PageError = { - __typename?: 'PageError'; /** List of attributes IDs which causes the error. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** The error code. */ - code: PageErrorCode; + readonly code: PageErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of attribute values IDs which causes the error. */ - values?: Maybe>; + readonly values?: Maybe>; }; -/** An enumeration. */ -export type PageErrorCode = - | 'ATTRIBUTE_ALREADY_ASSIGNED' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; +export enum PageErrorCode { + AttributeAlreadyAssigned = 'ATTRIBUTE_ALREADY_ASSIGNED', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type PageFilterInput = { - ids?: InputMaybe>; - metadata?: InputMaybe>; - pageTypes?: InputMaybe>; - search?: InputMaybe; - slugs?: InputMaybe>; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; + readonly pageTypes?: InputMaybe>; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; }; /** The Relay compliant `PageInfo` type, containing data necessary to paginate this connection. */ export type PageInfo = { - __typename?: 'PageInfo'; /** When paginating forwards, the cursor to continue. */ - endCursor?: Maybe; + readonly endCursor?: Maybe; /** When paginating forwards, are there more items? */ - hasNextPage: Scalars['Boolean']; + readonly hasNextPage: Scalars['Boolean']; /** When paginating backwards, are there more items? */ - hasPreviousPage: Scalars['Boolean']; + readonly hasPreviousPage: Scalars['Boolean']; /** When paginating backwards, the cursor to continue. */ - startCursor?: Maybe; + readonly startCursor?: Maybe; }; export type PageInput = { /** List of attributes. */ - attributes?: InputMaybe>; + readonly attributes?: InputMaybe>; /** * Page content. * * Rich text format. For reference see https://editorjs.io/ */ - content?: InputMaybe; + readonly content?: InputMaybe; /** Determines if page is visible in the storefront. */ - isPublished?: InputMaybe; + readonly isPublished?: InputMaybe; /** * Publication date. ISO 8601 standard. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. + * @deprecated Use `publishedAt` field instead. */ - publicationDate?: InputMaybe; - /** - * Publication date time. ISO 8601 standard. - * - * Added in Saleor 3.3. - */ - publishedAt?: InputMaybe; + readonly publicationDate?: InputMaybe; + /** Publication date time. ISO 8601 standard. */ + readonly publishedAt?: InputMaybe; /** Search engine optimization fields. */ - seo?: InputMaybe; + readonly seo?: InputMaybe; /** Page internal name. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** Page title. */ - title?: InputMaybe; + readonly title?: InputMaybe; }; /** @@ -18313,92 +16534,77 @@ export type PageInput = { * Requires one of the following permissions: MANAGE_PAGES. */ export type PageReorderAttributeValues = { - __typename?: 'PageReorderAttributeValues'; - errors: Array; + readonly errors: ReadonlyArray; /** Page from which attribute values are reordered. */ - page?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; -}; - -export type PageSortField = - /** - * Sort pages by creation date. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - */ - | 'CREATED_AT' - /** - * Sort pages by creation date. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - */ - | 'CREATION_DATE' - /** - * Sort pages by publication date. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - */ - | 'PUBLICATION_DATE' - /** - * Sort pages by publication date. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - */ - | 'PUBLISHED_AT' + readonly page?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; +}; + +export enum PageSortField { + /** Sort pages by creation date. */ + CreatedAt = 'CREATED_AT', + /** Sort pages by creation date. */ + CreationDate = 'CREATION_DATE', + /** Sort pages by publication date. */ + PublicationDate = 'PUBLICATION_DATE', + /** Sort pages by publication date. */ + PublishedAt = 'PUBLISHED_AT', /** Sort pages by slug. */ - | 'SLUG' + Slug = 'SLUG', /** Sort pages by title. */ - | 'TITLE' + Title = 'TITLE', /** Sort pages by visibility. */ - | 'VISIBILITY'; + Visibility = 'VISIBILITY' +} export type PageSortingInput = { /** Specifies the direction in which to sort pages. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort pages by the selected field. */ - field: PageSortField; + readonly field: PageSortField; }; /** Represents page's original translatable fields and related translations. */ export type PageTranslatableContent = Node & { - __typename?: 'PageTranslatableContent'; /** List of page content attribute values that can be translated. */ - attributeValues: Array; + readonly attributeValues: ReadonlyArray; /** * Content of the page to translate. * * Rich text format. For reference see https://editorjs.io/ */ - content?: Maybe; + readonly content?: Maybe; /** * Content of the page. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `content` field instead. + * @deprecated Use the `content` field instead. */ - contentJson?: Maybe; + readonly contentJson?: Maybe; /** The ID of the page translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * A static page that can be manually added by a shop operator through the dashboard. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. + * @deprecated Get model fields from the root level queries. */ - page?: Maybe; + readonly page?: Maybe; + /** The ID of the page to translate. */ + readonly pageId: Scalars['ID']; + /** SEO description to translate. */ + readonly seoDescription?: Maybe; + /** SEO title to translate. */ + readonly seoTitle?: Maybe; /** - * The ID of the page to translate. + * Slug to translate. * - * Added in Saleor 3.14. + * Added in Saleor 3.21. */ - pageId: Scalars['ID']; - /** SEO description to translate. */ - seoDescription?: Maybe; - /** SEO title to translate. */ - seoTitle?: Maybe; + readonly slug?: Maybe; /** Page title to translate. */ - title: Scalars['String']; + readonly title: Scalars['String']; /** Returns translated page fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -18413,45 +16619,45 @@ export type PageTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type PageTranslate = { - __typename?: 'PageTranslate'; - errors: Array; - page?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly errors: ReadonlyArray; + readonly page?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; /** Represents page translations. */ export type PageTranslation = Node & { - __typename?: 'PageTranslation'; /** * Translated content of the page. * * Rich text format. For reference see https://editorjs.io/ */ - content?: Maybe; + readonly content?: Maybe; /** * Translated description of the page. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `content` field instead. + * @deprecated Use the `content` field instead. */ - contentJson?: Maybe; + readonly contentJson?: Maybe; /** The ID of the page translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated SEO description. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** Translated SEO title. */ - seoTitle?: Maybe; - /** Translated page title. */ - title?: Maybe; + readonly seoTitle?: Maybe; /** - * Represents the page fields to translate. + * Translated page slug. * - * Added in Saleor 3.14. + * Added in Saleor 3.21. */ - translatableContent?: Maybe; + readonly slug?: Maybe; + /** Translated page title. */ + readonly title?: Maybe; + /** Represents the page fields to translate. */ + readonly translatableContent?: Maybe; }; export type PageTranslationInput = { @@ -18460,67 +16666,55 @@ export type PageTranslationInput = { * * Rich text format. For reference see https://editorjs.io/ */ - content?: InputMaybe; - seoDescription?: InputMaybe; - seoTitle?: InputMaybe; - title?: InputMaybe; + readonly content?: InputMaybe; + readonly seoDescription?: InputMaybe; + readonly seoTitle?: InputMaybe; + readonly slug?: InputMaybe; + readonly title?: InputMaybe; }; /** Represents a type of page. It defines what attributes are available to pages of this type. */ export type PageType = Node & ObjectWithMetadata & { - __typename?: 'PageType'; /** Page attributes of that page type. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** * Attributes that can be assigned to the page type. * * Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - availableAttributes?: Maybe; + readonly availableAttributes?: Maybe; /** * Whether page type has pages assigned. * * Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ - hasPages?: Maybe; + readonly hasPages?: Maybe; /** ID of the page type. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Name of the page type. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Slug of the page type. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; }; @@ -18543,7 +16737,7 @@ export type PageTypeMetafieldArgs = { /** Represents a type of page. It defines what attributes are available to pages of this type. */ export type PageTypeMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -18555,7 +16749,7 @@ export type PageTypePrivateMetafieldArgs = { /** Represents a type of page. It defines what attributes are available to pages of this type. */ export type PageTypePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** @@ -18564,29 +16758,26 @@ export type PageTypePrivateMetafieldsArgs = { * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ export type PageTypeBulkDelete = { - __typename?: 'PageTypeBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; }; export type PageTypeCountableConnection = { - __typename?: 'PageTypeCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type PageTypeCountableEdge = { - __typename?: 'PageTypeCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: PageType; + readonly node: PageType; }; /** @@ -18595,39 +16786,33 @@ export type PageTypeCountableEdge = { * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ export type PageTypeCreate = { - __typename?: 'PageTypeCreate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; - pageType?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; + readonly pageType?: Maybe; }; export type PageTypeCreateInput = { /** List of attribute IDs to be assigned to the page type. */ - addAttributes?: InputMaybe>; + readonly addAttributes?: InputMaybe>; /** Name of the page type. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Page type slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; -/** - * Event sent when new page type is created. - * - * Added in Saleor 3.5. - */ +/** Event sent when new page type is created. */ export type PageTypeCreated = Event & { - __typename?: 'PageTypeCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The page type the event relates to. */ - pageType?: Maybe; + readonly pageType?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -18636,35 +16821,29 @@ export type PageTypeCreated = Event & { * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ export type PageTypeDelete = { - __typename?: 'PageTypeDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; - pageType?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; + readonly pageType?: Maybe; }; -/** - * Event sent when page type is deleted. - * - * Added in Saleor 3.5. - */ +/** Event sent when page type is deleted. */ export type PageTypeDeleted = Event & { - __typename?: 'PageTypeDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The page type the event relates to. */ - pageType?: Maybe; + readonly pageType?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type PageTypeFilterInput = { - search?: InputMaybe; - slugs?: InputMaybe>; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; }; /** @@ -18673,25 +16852,25 @@ export type PageTypeFilterInput = { * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ export type PageTypeReorderAttributes = { - __typename?: 'PageTypeReorderAttributes'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; /** Page type from which attributes are reordered. */ - pageType?: Maybe; + readonly pageType?: Maybe; }; -export type PageTypeSortField = +export enum PageTypeSortField { /** Sort page types by name. */ - | 'NAME' + Name = 'NAME', /** Sort page types by slug. */ - | 'SLUG'; + Slug = 'SLUG' +} export type PageTypeSortingInput = { /** Specifies the direction in which to sort page types. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort page types by the selected field. */ - field: PageTypeSortField; + readonly field: PageTypeSortField; }; /** @@ -18700,41 +16879,35 @@ export type PageTypeSortingInput = { * Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. */ export type PageTypeUpdate = { - __typename?: 'PageTypeUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; - pageType?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; + readonly pageType?: Maybe; }; export type PageTypeUpdateInput = { /** List of attribute IDs to be assigned to the page type. */ - addAttributes?: InputMaybe>; + readonly addAttributes?: InputMaybe>; /** Name of the page type. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** List of attribute IDs to be assigned to the page type. */ - removeAttributes?: InputMaybe>; + readonly removeAttributes?: InputMaybe>; /** Page type slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; -/** - * Event sent when page type is updated. - * - * Added in Saleor 3.5. - */ +/** Event sent when page type is updated. */ export type PageTypeUpdated = Event & { - __typename?: 'PageTypeUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The page type the event relates to. */ - pageType?: Maybe; + readonly pageType?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -18743,30 +16916,24 @@ export type PageTypeUpdated = Event & { * Requires one of the following permissions: MANAGE_PAGES. */ export type PageUpdate = { - __typename?: 'PageUpdate'; - errors: Array; - page?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pageErrors: Array; + readonly errors: ReadonlyArray; + readonly page?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly pageErrors: ReadonlyArray; }; -/** - * Event sent when page is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when page is updated. */ export type PageUpdated = Event & { - __typename?: 'PageUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The page the event relates to. */ - page?: Maybe; + readonly page?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -18775,117 +16942,95 @@ export type PageUpdated = Event & { * Requires one of the following permissions: AUTHENTICATED_USER. */ export type PasswordChange = { - __typename?: 'PasswordChange'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** A user instance with a new password. */ - user?: Maybe; + readonly user?: Maybe; }; /** Represents a payment of a given type. */ export type Payment = Node & ObjectWithMetadata & { - __typename?: 'Payment'; /** * List of actions that can be performed in the current state of a payment. * * Requires one of the following permissions: MANAGE_ORDERS. */ - actions: Array; + readonly actions: ReadonlyArray; /** * Maximum amount of money that can be captured. * * Requires one of the following permissions: MANAGE_ORDERS. */ - availableCaptureAmount?: Maybe; + readonly availableCaptureAmount?: Maybe; /** * Maximum amount of money that can be refunded. * * Requires one of the following permissions: MANAGE_ORDERS. */ - availableRefundAmount?: Maybe; + readonly availableRefundAmount?: Maybe; /** Total amount captured for this payment. */ - capturedAmount?: Maybe; + readonly capturedAmount?: Maybe; /** Internal payment status. */ - chargeStatus: PaymentChargeStatusEnum; + readonly chargeStatus: PaymentChargeStatusEnum; /** Checkout associated with a payment. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Date and time at which payment was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** The details of the card used for this payment. */ - creditCard?: Maybe; + readonly creditCard?: Maybe; /** * IP address of the user who created the payment. * * Requires one of the following permissions: MANAGE_ORDERS. */ - customerIpAddress?: Maybe; + readonly customerIpAddress?: Maybe; /** Payment gateway used for payment. */ - gateway: Scalars['String']; + readonly gateway: Scalars['String']; /** ID of the payment. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Determines if the payment is active or not. */ - isActive: Scalars['Boolean']; + readonly isActive: Scalars['Boolean']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Date and time at which payment was modified. */ - modified: Scalars['DateTime']; + readonly modified: Scalars['DateTime']; /** Order associated with a payment. */ - order?: Maybe; - /** - * Informs whether this is a partial payment. - * - * Added in Saleor 3.14. - */ - partial: Scalars['Boolean']; + readonly order?: Maybe; + /** Informs whether this is a partial payment. */ + readonly partial: Scalars['Boolean']; /** Type of method used for payment. */ - paymentMethodType: Scalars['String']; + readonly paymentMethodType: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; - /** - * PSP reference of the payment. - * - * Added in Saleor 3.14. */ - pspReference?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** PSP reference of the payment. */ + readonly pspReference?: Maybe; /** Unique token associated with a payment. */ - token: Scalars['String']; + readonly token: Scalars['String']; /** Total amount of the payment. */ - total?: Maybe; + readonly total?: Maybe; /** * List of all transactions within this payment. * * Requires one of the following permissions: MANAGE_ORDERS. */ - transactions?: Maybe>; + readonly transactions?: Maybe>; }; @@ -18897,7 +17042,7 @@ export type PaymentMetafieldArgs = { /** Represents a payment of a given type. */ export type PaymentMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -18909,26 +17054,21 @@ export type PaymentPrivateMetafieldArgs = { /** Represents a payment of a given type. */ export type PaymentPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; -/** - * Authorize payment. - * - * Added in Saleor 3.6. - */ +/** Authorize payment. */ export type PaymentAuthorize = Event & { - __typename?: 'PaymentAuthorize'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** Look up a payment. */ - payment?: Maybe; + readonly payment?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -18937,275 +17077,232 @@ export type PaymentAuthorize = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type PaymentCapture = { - __typename?: 'PaymentCapture'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated payment. */ - payment?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - paymentErrors: Array; + readonly payment?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly paymentErrors: ReadonlyArray; }; -/** - * Capture payment. - * - * Added in Saleor 3.6. - */ +/** Capture payment. */ export type PaymentCaptureEvent = Event & { - __typename?: 'PaymentCaptureEvent'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** Look up a payment. */ - payment?: Maybe; + readonly payment?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; -}; - -/** An enumeration. */ -export type PaymentChargeStatusEnum = - | 'CANCELLED' - | 'FULLY_CHARGED' - | 'FULLY_REFUNDED' - | 'NOT_CHARGED' - | 'PARTIALLY_CHARGED' - | 'PARTIALLY_REFUNDED' - | 'PENDING' - | 'REFUSED'; + readonly version?: Maybe; +}; + +export enum PaymentChargeStatusEnum { + Cancelled = 'CANCELLED', + FullyCharged = 'FULLY_CHARGED', + FullyRefunded = 'FULLY_REFUNDED', + NotCharged = 'NOT_CHARGED', + PartiallyCharged = 'PARTIALLY_CHARGED', + PartiallyRefunded = 'PARTIALLY_REFUNDED', + Pending = 'PENDING', + Refused = 'REFUSED' +} /** Check payment balance. */ export type PaymentCheckBalance = { - __typename?: 'PaymentCheckBalance'; /** Response from the gateway. */ - data?: Maybe; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - paymentErrors: Array; + readonly data?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly paymentErrors: ReadonlyArray; }; export type PaymentCheckBalanceInput = { /** Information about card. */ - card: CardInput; + readonly card: CardInput; /** Slug of a channel for which the data should be returned. */ - channel: Scalars['String']; + readonly channel: Scalars['String']; /** An ID of a payment gateway to check. */ - gatewayId: Scalars['String']; + readonly gatewayId: Scalars['String']; /** Payment method name. */ - method: Scalars['String']; + readonly method: Scalars['String']; }; -/** - * Confirm payment. - * - * Added in Saleor 3.6. - */ +/** Confirm payment. */ export type PaymentConfirmEvent = Event & { - __typename?: 'PaymentConfirmEvent'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** Look up a payment. */ - payment?: Maybe; + readonly payment?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type PaymentCountableConnection = { - __typename?: 'PaymentCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type PaymentCountableEdge = { - __typename?: 'PaymentCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Payment; + readonly node: Payment; }; export type PaymentError = { - __typename?: 'PaymentError'; /** The error code. */ - code: PaymentErrorCode; + readonly code: PaymentErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of variant IDs which causes the error. */ - variants?: Maybe>; -}; - -/** An enumeration. */ -export type PaymentErrorCode = - | 'BALANCE_CHECK_ERROR' - | 'BILLING_ADDRESS_NOT_SET' - | 'CHANNEL_INACTIVE' - | 'CHECKOUT_COMPLETION_IN_PROGRESS' - | 'CHECKOUT_EMAIL_NOT_SET' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_SHIPPING_METHOD' - | 'NOT_FOUND' - | 'NOT_SUPPORTED_GATEWAY' - | 'NO_CHECKOUT_LINES' - | 'PARTIAL_PAYMENT_NOT_ALLOWED' - | 'PAYMENT_ERROR' - | 'REQUIRED' - | 'SHIPPING_ADDRESS_NOT_SET' - | 'SHIPPING_METHOD_NOT_SET' - | 'UNAVAILABLE_VARIANT_IN_CHANNEL' - | 'UNIQUE'; + readonly variants?: Maybe>; +}; + +export enum PaymentErrorCode { + BalanceCheckError = 'BALANCE_CHECK_ERROR', + BillingAddressNotSet = 'BILLING_ADDRESS_NOT_SET', + ChannelInactive = 'CHANNEL_INACTIVE', + CheckoutCompletionInProgress = 'CHECKOUT_COMPLETION_IN_PROGRESS', + CheckoutEmailNotSet = 'CHECKOUT_EMAIL_NOT_SET', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidShippingMethod = 'INVALID_SHIPPING_METHOD', + NotFound = 'NOT_FOUND', + NotSupportedGateway = 'NOT_SUPPORTED_GATEWAY', + NoCheckoutLines = 'NO_CHECKOUT_LINES', + PartialPaymentNotAllowed = 'PARTIAL_PAYMENT_NOT_ALLOWED', + PaymentError = 'PAYMENT_ERROR', + Required = 'REQUIRED', + ShippingAddressNotSet = 'SHIPPING_ADDRESS_NOT_SET', + ShippingMethodNotSet = 'SHIPPING_METHOD_NOT_SET', + UnavailableVariantInChannel = 'UNAVAILABLE_VARIANT_IN_CHANNEL', + Unique = 'UNIQUE' +} export type PaymentFilterInput = { - checkouts?: InputMaybe>; - /** - * Filter by ids. - * - * Added in Saleor 3.8. - */ - ids?: InputMaybe>; + readonly checkouts?: InputMaybe>; + /** Filter by ids. */ + readonly ids?: InputMaybe>; }; /** Available payment gateway backend with configuration necessary to setup client. */ export type PaymentGateway = { - __typename?: 'PaymentGateway'; /** Payment gateway client configuration. */ - config: Array; + readonly config: ReadonlyArray; /** Payment gateway supported currencies. */ - currencies: Array; + readonly currencies: ReadonlyArray; /** Payment gateway ID. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Payment gateway name. */ - name: Scalars['String']; + readonly name: Scalars['String']; }; export type PaymentGatewayConfig = { - __typename?: 'PaymentGatewayConfig'; /** The JSON data required to initialize the payment gateway. */ - data?: Maybe; - errors?: Maybe>; + readonly data?: Maybe; + readonly errors?: Maybe>; /** The app identifier. */ - id: Scalars['String']; + readonly id: Scalars['String']; }; export type PaymentGatewayConfigError = { - __typename?: 'PaymentGatewayConfigError'; /** The error code. */ - code: PaymentGatewayConfigErrorCode; + readonly code: PaymentGatewayConfigErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PaymentGatewayConfigErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum PaymentGatewayConfigErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} -/** - * Initializes a payment gateway session. It triggers the webhook `PAYMENT_GATEWAY_INITIALIZE_SESSION`, to the requested `paymentGateways`. If `paymentGateways` is not provided, the webhook will be send to all subscribed payment gateways. There is a limit of 100 transaction items per checkout / order. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Initializes a payment gateway session. It triggers the webhook `PAYMENT_GATEWAY_INITIALIZE_SESSION`, to the requested `paymentGateways`. If `paymentGateways` is not provided, the webhook will be send to all subscribed payment gateways. There is a limit of 100 transaction items per checkout / order. */ export type PaymentGatewayInitialize = { - __typename?: 'PaymentGatewayInitialize'; - errors: Array; + readonly errors: ReadonlyArray; /** List of payment gateway configurations. */ - gatewayConfigs?: Maybe>; + readonly gatewayConfigs?: Maybe>; }; export type PaymentGatewayInitializeError = { - __typename?: 'PaymentGatewayInitializeError'; /** The error code. */ - code: PaymentGatewayInitializeErrorCode; + readonly code: PaymentGatewayInitializeErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PaymentGatewayInitializeErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum PaymentGatewayInitializeErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} -/** - * Event sent when user wants to initialize the payment gateway. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when user wants to initialize the payment gateway. */ export type PaymentGatewayInitializeSession = Event & { - __typename?: 'PaymentGatewayInitializeSession'; /** Amount requested for initializing the payment gateway. */ - amount?: Maybe; + readonly amount?: Maybe; /** Payment gateway data in JSON format, received from storefront. */ - data?: Maybe; + readonly data?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Checkout or order */ - sourceObject: OrderOrCheckout; + readonly sourceObject: OrderOrCheckout; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Initializes payment gateway for tokenizing payment method session. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION (sync): The customer requested to initialize payment gateway for tokenization. */ export type PaymentGatewayInitializeTokenization = { - __typename?: 'PaymentGatewayInitializeTokenization'; /** A data returned by payment app. */ - data?: Maybe; - errors: Array; + readonly data?: Maybe; + readonly errors: ReadonlyArray; /** A status of the payment gateway initialization. */ - result: PaymentGatewayInitializeTokenizationResult; + readonly result: PaymentGatewayInitializeTokenizationResult; }; export type PaymentGatewayInitializeTokenizationError = { - __typename?: 'PaymentGatewayInitializeTokenizationError'; /** The error code. */ - code: PaymentGatewayInitializeTokenizationErrorCode; + readonly code: PaymentGatewayInitializeTokenizationErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PaymentGatewayInitializeTokenizationErrorCode = - | 'CHANNEL_INACTIVE' - | 'GATEWAY_ERROR' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum PaymentGatewayInitializeTokenizationErrorCode { + ChannelInactive = 'CHANNEL_INACTIVE', + GatewayError = 'GATEWAY_ERROR', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} /** * Result of initialize payment gateway for tokenization of payment method. @@ -19215,250 +17312,206 @@ export type PaymentGatewayInitializeTokenizationErrorCode = * FAILED_TO_INITIALIZE - The payment gateway was not initialized. * FAILED_TO_DELIVER - The request to initialize payment gateway was not delivered. */ -export type PaymentGatewayInitializeTokenizationResult = - | 'FAILED_TO_DELIVER' - | 'FAILED_TO_INITIALIZE' - | 'SUCCESSFULLY_INITIALIZED'; +export enum PaymentGatewayInitializeTokenizationResult { + FailedToDeliver = 'FAILED_TO_DELIVER', + FailedToInitialize = 'FAILED_TO_INITIALIZE', + SuccessfullyInitialized = 'SUCCESSFULLY_INITIALIZED' +} -/** - * Event sent to initialize a new session in payment gateway to store the payment method. - * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent to initialize a new session in payment gateway to store the payment method. */ export type PaymentGatewayInitializeTokenizationSession = Event & { - __typename?: 'PaymentGatewayInitializeTokenizationSession'; /** Channel related to the requested action. */ - channel: Channel; + readonly channel: Channel; /** Payment gateway data in JSON format, received from storefront. */ - data?: Maybe; + readonly data?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user related to the requested action. */ - user: User; + readonly user: User; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type PaymentGatewayToInitialize = { /** The data that will be passed to the payment gateway. */ - data?: InputMaybe; + readonly data?: InputMaybe; /** The identifier of the payment gateway app to initialize. */ - id: Scalars['String']; + readonly id: Scalars['String']; }; /** Initializes payment process when it is required by gateway. */ export type PaymentInitialize = { - __typename?: 'PaymentInitialize'; - errors: Array; + readonly errors: ReadonlyArray; /** Payment that was initialized. */ - initializedPayment?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - paymentErrors: Array; + readonly initializedPayment?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly paymentErrors: ReadonlyArray; }; /** Server-side data generated by a payment gateway. Optional step when the payment provider requires an additional action to initialize payment session. */ export type PaymentInitialized = { - __typename?: 'PaymentInitialized'; /** Initialized data by gateway. */ - data?: Maybe; + readonly data?: Maybe; /** ID of a payment gateway. */ - gateway: Scalars['String']; + readonly gateway: Scalars['String']; /** Payment gateway name. */ - name: Scalars['String']; + readonly name: Scalars['String']; }; export type PaymentInput = { /** Total amount of the transaction, including all taxes and discounts. If no amount is provided, the checkout total will be used. */ - amount?: InputMaybe; + readonly amount?: InputMaybe; /** A gateway to use with that payment. */ - gateway: Scalars['String']; + readonly gateway: Scalars['String']; /** - * User public metadata. + * User public metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.1. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** URL of a storefront view where user should be redirected after requiring additional actions. Payment with additional actions will not be finished if this field is not provided. */ - returnUrl?: InputMaybe; - /** - * Payment store type. - * - * Added in Saleor 3.1. - */ - storePaymentMethod?: InputMaybe; + readonly returnUrl?: InputMaybe; + /** Payment store type. */ + readonly storePaymentMethod?: InputMaybe; /** Client-side generated payment token, representing customer's billing data in a secure manner. */ - token?: InputMaybe; + readonly token?: InputMaybe; }; -/** - * List payment gateways. - * - * Added in Saleor 3.6. - */ +/** List payment gateways. */ export type PaymentListGateways = Event & { - __typename?: 'PaymentListGateways'; /** The checkout the event relates to. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Tokenize payment method. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION (sync): The customer requested to tokenize payment method. */ export type PaymentMethodInitializeTokenization = { - __typename?: 'PaymentMethodInitializeTokenization'; /** A data returned by the payment app. */ - data?: Maybe; - errors: Array; + readonly data?: Maybe; + readonly errors: ReadonlyArray; /** The identifier of the payment method. */ - id?: Maybe; + readonly id?: Maybe; /** A status of the payment method tokenization. */ - result: PaymentMethodTokenizationResult; + readonly result: PaymentMethodTokenizationResult; }; export type PaymentMethodInitializeTokenizationError = { - __typename?: 'PaymentMethodInitializeTokenizationError'; /** The error code. */ - code: PaymentMethodInitializeTokenizationErrorCode; + readonly code: PaymentMethodInitializeTokenizationErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PaymentMethodInitializeTokenizationErrorCode = - | 'CHANNEL_INACTIVE' - | 'GATEWAY_ERROR' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum PaymentMethodInitializeTokenizationErrorCode { + ChannelInactive = 'CHANNEL_INACTIVE', + GatewayError = 'GATEWAY_ERROR', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} -/** - * Event sent when user requests a tokenization of payment method. - * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when user requests a tokenization of payment method. */ export type PaymentMethodInitializeTokenizationSession = Event & { - __typename?: 'PaymentMethodInitializeTokenizationSession'; /** Channel related to the requested action. */ - channel: Channel; + readonly channel: Channel; /** Payment gateway data in JSON format, received from storefront. */ - data?: Maybe; + readonly data?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The payment flow that the tokenized payment method should support. */ - paymentFlowToSupport: TokenizedPaymentFlowEnum; + readonly paymentFlowToSupport: TokenizedPaymentFlowEnum; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user related to the requested action. */ - user: User; + readonly user: User; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Tokenize payment method. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION (sync): The customer continues payment method tokenization. */ export type PaymentMethodProcessTokenization = { - __typename?: 'PaymentMethodProcessTokenization'; /** A data returned by the payment app. */ - data?: Maybe; - errors: Array; + readonly data?: Maybe; + readonly errors: ReadonlyArray; /** The identifier of the payment method. */ - id?: Maybe; + readonly id?: Maybe; /** A status of the payment method tokenization. */ - result: PaymentMethodTokenizationResult; + readonly result: PaymentMethodTokenizationResult; }; export type PaymentMethodProcessTokenizationError = { - __typename?: 'PaymentMethodProcessTokenizationError'; /** The error code. */ - code: PaymentMethodProcessTokenizationErrorCode; + readonly code: PaymentMethodProcessTokenizationErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PaymentMethodProcessTokenizationErrorCode = - | 'CHANNEL_INACTIVE' - | 'GATEWAY_ERROR' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum PaymentMethodProcessTokenizationErrorCode { + ChannelInactive = 'CHANNEL_INACTIVE', + GatewayError = 'GATEWAY_ERROR', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} -/** - * Event sent when user continues a tokenization of payment method. - * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when user continues a tokenization of payment method. */ export type PaymentMethodProcessTokenizationSession = Event & { - __typename?: 'PaymentMethodProcessTokenizationSession'; /** Channel related to the requested action. */ - channel: Channel; + readonly channel: Channel; /** Payment gateway data in JSON format, received from storefront. */ - data?: Maybe; + readonly data?: Maybe; /** The ID returned by app from `PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION` webhook. */ - id: Scalars['String']; + readonly id: Scalars['String']; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user related to the requested action. */ - user: User; + readonly user: User; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type PaymentMethodRequestDeleteError = { - __typename?: 'PaymentMethodRequestDeleteError'; /** The error code. */ - code: StoredPaymentMethodRequestDeleteErrorCode; + readonly code: StoredPaymentMethodRequestDeleteErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; /** @@ -19471,30 +17524,26 @@ export type PaymentMethodRequestDeleteError = { * FAILED_TO_TOKENIZE - The payment method was not tokenized. * FAILED_TO_DELIVER - The request to tokenize payment method was not delivered. */ -export type PaymentMethodTokenizationResult = - | 'ADDITIONAL_ACTION_REQUIRED' - | 'FAILED_TO_DELIVER' - | 'FAILED_TO_TOKENIZE' - | 'PENDING' - | 'SUCCESSFULLY_TOKENIZED'; +export enum PaymentMethodTokenizationResult { + AdditionalActionRequired = 'ADDITIONAL_ACTION_REQUIRED', + FailedToDeliver = 'FAILED_TO_DELIVER', + FailedToTokenize = 'FAILED_TO_TOKENIZE', + Pending = 'PENDING', + SuccessfullyTokenized = 'SUCCESSFULLY_TOKENIZED' +} -/** - * Process payment. - * - * Added in Saleor 3.6. - */ +/** Process payment. */ export type PaymentProcessEvent = Event & { - __typename?: 'PaymentProcessEvent'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** Look up a payment. */ - payment?: Maybe; + readonly payment?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -19503,74 +17552,52 @@ export type PaymentProcessEvent = Event & { * Requires one of the following permissions: MANAGE_ORDERS. */ export type PaymentRefund = { - __typename?: 'PaymentRefund'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated payment. */ - payment?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - paymentErrors: Array; + readonly payment?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly paymentErrors: ReadonlyArray; }; -/** - * Refund payment. - * - * Added in Saleor 3.6. - */ +/** Refund payment. */ export type PaymentRefundEvent = Event & { - __typename?: 'PaymentRefundEvent'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** Look up a payment. */ - payment?: Maybe; + readonly payment?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Represents the channel-specific payment settings. */ export type PaymentSettings = { - __typename?: 'PaymentSettings'; - /** - * Determine the transaction flow strategy to be used. Include the selected option in the payload sent to the payment app, as a requested action for the transaction. - * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - defaultTransactionFlowStrategy: TransactionFlowStrategyEnum; + /** Determine the transaction flow strategy to be used. Include the selected option in the payload sent to the payment app, as a requested action for the transaction. */ + readonly defaultTransactionFlowStrategy: TransactionFlowStrategyEnum; }; export type PaymentSettingsInput = { - /** - * Determine the transaction flow strategy to be used. Include the selected option in the payload sent to the payment app, as a requested action for the transaction. - * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - defaultTransactionFlowStrategy?: InputMaybe; + /** Determine the transaction flow strategy to be used. Include the selected option in the payload sent to the payment app, as a requested action for the transaction. */ + readonly defaultTransactionFlowStrategy?: InputMaybe; }; /** Represents a payment source stored for user in payment gateway, such as credit card. */ export type PaymentSource = { - __typename?: 'PaymentSource'; /** Stored credit card details if available. */ - creditCardInfo?: Maybe; + readonly creditCardInfo?: Maybe; /** Payment gateway name. */ - gateway: Scalars['String']; + readonly gateway: Scalars['String']; /** * List of public metadata items. * - * Added in Saleor 3.1. - * * Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** ID of stored payment method. */ - paymentMethodId?: Maybe; + readonly paymentMethodId?: Maybe; }; /** @@ -19579,68 +17606,61 @@ export type PaymentSource = { * Requires one of the following permissions: MANAGE_ORDERS. */ export type PaymentVoid = { - __typename?: 'PaymentVoid'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated payment. */ - payment?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - paymentErrors: Array; + readonly payment?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly paymentErrors: ReadonlyArray; }; -/** - * Void payment. - * - * Added in Saleor 3.6. - */ +/** Void payment. */ export type PaymentVoidEvent = Event & { - __typename?: 'PaymentVoidEvent'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** Look up a payment. */ - payment?: Maybe; + readonly payment?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Represents a permission object in a friendly form. */ export type Permission = { - __typename?: 'Permission'; /** Internal code for permission. */ - code: PermissionEnum; + readonly code: PermissionEnum; /** Describe action(s) allowed to do by permission. */ - name: Scalars['String']; -}; - -/** An enumeration. */ -export type PermissionEnum = - | 'HANDLE_CHECKOUTS' - | 'HANDLE_PAYMENTS' - | 'HANDLE_TAXES' - | 'IMPERSONATE_USER' - | 'MANAGE_APPS' - | 'MANAGE_CHANNELS' - | 'MANAGE_CHECKOUTS' - | 'MANAGE_DISCOUNTS' - | 'MANAGE_GIFT_CARD' - | 'MANAGE_MENUS' - | 'MANAGE_OBSERVABILITY' - | 'MANAGE_ORDERS' - | 'MANAGE_ORDERS_IMPORT' - | 'MANAGE_PAGES' - | 'MANAGE_PAGE_TYPES_AND_ATTRIBUTES' - | 'MANAGE_PLUGINS' - | 'MANAGE_PRODUCTS' - | 'MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES' - | 'MANAGE_SETTINGS' - | 'MANAGE_SHIPPING' - | 'MANAGE_STAFF' - | 'MANAGE_TAXES' - | 'MANAGE_TRANSLATIONS' - | 'MANAGE_USERS'; + readonly name: Scalars['String']; +}; + +export enum PermissionEnum { + HandleCheckouts = 'HANDLE_CHECKOUTS', + HandlePayments = 'HANDLE_PAYMENTS', + HandleTaxes = 'HANDLE_TAXES', + ImpersonateUser = 'IMPERSONATE_USER', + ManageApps = 'MANAGE_APPS', + ManageChannels = 'MANAGE_CHANNELS', + ManageCheckouts = 'MANAGE_CHECKOUTS', + ManageDiscounts = 'MANAGE_DISCOUNTS', + ManageGiftCard = 'MANAGE_GIFT_CARD', + ManageMenus = 'MANAGE_MENUS', + ManageObservability = 'MANAGE_OBSERVABILITY', + ManageOrders = 'MANAGE_ORDERS', + ManageOrdersImport = 'MANAGE_ORDERS_IMPORT', + ManagePages = 'MANAGE_PAGES', + ManagePageTypesAndAttributes = 'MANAGE_PAGE_TYPES_AND_ATTRIBUTES', + ManagePlugins = 'MANAGE_PLUGINS', + ManageProducts = 'MANAGE_PRODUCTS', + ManageProductTypesAndAttributes = 'MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES', + ManageSettings = 'MANAGE_SETTINGS', + ManageShipping = 'MANAGE_SHIPPING', + ManageStaff = 'MANAGE_STAFF', + ManageTaxes = 'MANAGE_TAXES', + ManageTranslations = 'MANAGE_TRANSLATIONS', + ManageUsers = 'MANAGE_USERS' +} /** * Create new permission group. Apps are not allowed to perform this mutation. @@ -19651,55 +17671,37 @@ export type PermissionEnum = * - PERMISSION_GROUP_CREATED (async) */ export type PermissionGroupCreate = { - __typename?: 'PermissionGroupCreate'; - errors: Array; - group?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - permissionGroupErrors: Array; + readonly errors: ReadonlyArray; + readonly group?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly permissionGroupErrors: ReadonlyArray; }; export type PermissionGroupCreateInput = { - /** - * List of channels to assign to this group. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - addChannels?: InputMaybe>; + /** List of channels to assign to this group. */ + readonly addChannels?: InputMaybe>; /** List of permission code names to assign to this group. */ - addPermissions?: InputMaybe>; + readonly addPermissions?: InputMaybe>; /** List of users to assign to this group. */ - addUsers?: InputMaybe>; + readonly addUsers?: InputMaybe>; /** Group name. */ - name: Scalars['String']; - /** - * Determine if the group has restricted access to channels. DEFAULT: False - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - restrictedAccessToChannels?: InputMaybe; + readonly name: Scalars['String']; + /** Determine if the group has restricted access to channels. DEFAULT: False */ + readonly restrictedAccessToChannels?: InputMaybe; }; -/** - * Event sent when new permission group is created. - * - * Added in Saleor 3.6. - */ +/** Event sent when new permission group is created. */ export type PermissionGroupCreated = Event & { - __typename?: 'PermissionGroupCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The permission group the event relates to. */ - permissionGroup?: Maybe; + readonly permissionGroup?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -19711,75 +17713,69 @@ export type PermissionGroupCreated = Event & { * - PERMISSION_GROUP_DELETED (async) */ export type PermissionGroupDelete = { - __typename?: 'PermissionGroupDelete'; - errors: Array; - group?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - permissionGroupErrors: Array; + readonly errors: ReadonlyArray; + readonly group?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly permissionGroupErrors: ReadonlyArray; }; -/** - * Event sent when permission group is deleted. - * - * Added in Saleor 3.6. - */ +/** Event sent when permission group is deleted. */ export type PermissionGroupDeleted = Event & { - __typename?: 'PermissionGroupDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The permission group the event relates to. */ - permissionGroup?: Maybe; + readonly permissionGroup?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type PermissionGroupError = { - __typename?: 'PermissionGroupError'; /** List of channels IDs which causes the error. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** The error code. */ - code: PermissionGroupErrorCode; + readonly code: PermissionGroupErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of permissions which causes the error. */ - permissions?: Maybe>; + readonly permissions?: Maybe>; /** List of user IDs which causes the error. */ - users?: Maybe>; -}; - -/** An enumeration. */ -export type PermissionGroupErrorCode = - | 'ASSIGN_NON_STAFF_MEMBER' - | 'CANNOT_REMOVE_FROM_LAST_GROUP' - | 'DUPLICATED_INPUT_ITEM' - | 'LEFT_NOT_MANAGEABLE_PERMISSION' - | 'OUT_OF_SCOPE_CHANNEL' - | 'OUT_OF_SCOPE_PERMISSION' - | 'OUT_OF_SCOPE_USER' - | 'REQUIRED' - | 'UNIQUE'; + readonly users?: Maybe>; +}; + +export enum PermissionGroupErrorCode { + AssignNonStaffMember = 'ASSIGN_NON_STAFF_MEMBER', + CannotRemoveFromLastGroup = 'CANNOT_REMOVE_FROM_LAST_GROUP', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + LeftNotManageablePermission = 'LEFT_NOT_MANAGEABLE_PERMISSION', + OutOfScopeChannel = 'OUT_OF_SCOPE_CHANNEL', + OutOfScopePermission = 'OUT_OF_SCOPE_PERMISSION', + OutOfScopeUser = 'OUT_OF_SCOPE_USER', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type PermissionGroupFilterInput = { - ids?: InputMaybe>; - search?: InputMaybe; + readonly ids?: InputMaybe>; + readonly search?: InputMaybe; }; /** Sorting options for permission groups. */ -export type PermissionGroupSortField = +export enum PermissionGroupSortField { /** Sort permission group accounts by name. */ - | 'NAME'; + Name = 'NAME' +} export type PermissionGroupSortingInput = { /** Specifies the direction in which to sort permission group. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort permission group by the selected field. */ - field: PermissionGroupSortField; + readonly field: PermissionGroupSortField; }; /** @@ -19791,155 +17787,128 @@ export type PermissionGroupSortingInput = { * - PERMISSION_GROUP_UPDATED (async) */ export type PermissionGroupUpdate = { - __typename?: 'PermissionGroupUpdate'; - errors: Array; - group?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - permissionGroupErrors: Array; + readonly errors: ReadonlyArray; + readonly group?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly permissionGroupErrors: ReadonlyArray; }; export type PermissionGroupUpdateInput = { - /** - * List of channels to assign to this group. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - addChannels?: InputMaybe>; + /** List of channels to assign to this group. */ + readonly addChannels?: InputMaybe>; /** List of permission code names to assign to this group. */ - addPermissions?: InputMaybe>; + readonly addPermissions?: InputMaybe>; /** List of users to assign to this group. */ - addUsers?: InputMaybe>; + readonly addUsers?: InputMaybe>; /** Group name. */ - name?: InputMaybe; - /** - * List of channels to unassign from this group. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - removeChannels?: InputMaybe>; + readonly name?: InputMaybe; + /** List of channels to unassign from this group. */ + readonly removeChannels?: InputMaybe>; /** List of permission code names to unassign from this group. */ - removePermissions?: InputMaybe>; + readonly removePermissions?: InputMaybe>; /** List of users to unassign from this group. */ - removeUsers?: InputMaybe>; - /** - * Determine if the group has restricted access to channels. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - restrictedAccessToChannels?: InputMaybe; + readonly removeUsers?: InputMaybe>; + /** Determine if the group has restricted access to channels. */ + readonly restrictedAccessToChannels?: InputMaybe; }; -/** - * Event sent when permission group is updated. - * - * Added in Saleor 3.6. - */ +/** Event sent when permission group is updated. */ export type PermissionGroupUpdated = Event & { - __typename?: 'PermissionGroupUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The permission group the event relates to. */ - permissionGroup?: Maybe; + readonly permissionGroup?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Plugin. */ export type Plugin = { - __typename?: 'Plugin'; /** Channel-specific plugin configuration. */ - channelConfigurations: Array; + readonly channelConfigurations: ReadonlyArray; /** Description of the plugin. */ - description: Scalars['String']; + readonly description: Scalars['String']; /** Global configuration of the plugin (not channel-specific). */ - globalConfiguration?: Maybe; + readonly globalConfiguration?: Maybe; /** Identifier of the plugin. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the plugin. */ - name: Scalars['String']; + readonly name: Scalars['String']; }; /** Stores information about a configuration of plugin. */ export type PluginConfiguration = { - __typename?: 'PluginConfiguration'; /** Determines if plugin is active or not. */ - active: Scalars['Boolean']; + readonly active: Scalars['Boolean']; /** The channel to which the plugin configuration is assigned to. */ - channel?: Maybe; + readonly channel?: Maybe; /** Configuration of the plugin. */ - configuration?: Maybe>; + readonly configuration?: Maybe>; }; -export type PluginConfigurationType = - | 'GLOBAL' - | 'PER_CHANNEL'; +export enum PluginConfigurationType { + Global = 'GLOBAL', + PerChannel = 'PER_CHANNEL' +} export type PluginCountableConnection = { - __typename?: 'PluginCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type PluginCountableEdge = { - __typename?: 'PluginCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Plugin; + readonly node: Plugin; }; export type PluginError = { - __typename?: 'PluginError'; /** The error code. */ - code: PluginErrorCode; + readonly code: PluginErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PluginErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'PLUGIN_MISCONFIGURED' - | 'REQUIRED' - | 'UNIQUE'; +export enum PluginErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + PluginMisconfigured = 'PLUGIN_MISCONFIGURED', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type PluginFilterInput = { - search?: InputMaybe; - statusInChannels?: InputMaybe; - type?: InputMaybe; + readonly search?: InputMaybe; + readonly statusInChannels?: InputMaybe; + readonly type?: InputMaybe; }; -export type PluginSortField = - | 'IS_ACTIVE' - | 'NAME'; +export enum PluginSortField { + IsActive = 'IS_ACTIVE', + Name = 'NAME' +} export type PluginSortingInput = { /** Specifies the direction in which to sort plugins. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort plugins by the selected field. */ - field: PluginSortField; + readonly field: PluginSortField; }; export type PluginStatusInChannelsInput = { - active: Scalars['Boolean']; - channels: Array; + readonly active: Scalars['Boolean']; + readonly channels: ReadonlyArray; }; /** @@ -19948,222 +17917,205 @@ export type PluginStatusInChannelsInput = { * Requires one of the following permissions: MANAGE_PLUGINS. */ export type PluginUpdate = { - __typename?: 'PluginUpdate'; - errors: Array; - plugin?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - pluginsErrors: Array; + readonly errors: ReadonlyArray; + readonly plugin?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly pluginsErrors: ReadonlyArray; }; export type PluginUpdateInput = { /** Indicates whether the plugin should be enabled. */ - active?: InputMaybe; + readonly active?: InputMaybe; /** Configuration of the plugin. */ - configuration?: InputMaybe>; + readonly configuration?: InputMaybe>; }; -/** An enumeration. */ -export type PostalCodeRuleInclusionTypeEnum = - | 'EXCLUDE' - | 'INCLUDE'; +export enum PostalCodeRuleInclusionTypeEnum { + Exclude = 'EXCLUDE', + Include = 'INCLUDE' +} /** Represents preorder settings for product variant. */ export type PreorderData = { - __typename?: 'PreorderData'; /** Preorder end date. */ - endDate?: Maybe; + readonly endDate?: Maybe; /** * Total number of sold product variant during preorder. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - globalSoldUnits: Scalars['Int']; + readonly globalSoldUnits: Scalars['Int']; /** * The global preorder threshold for product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - globalThreshold?: Maybe; + readonly globalThreshold?: Maybe; }; export type PreorderSettingsInput = { /** The end date for preorder. */ - endDate?: InputMaybe; + readonly endDate?: InputMaybe; /** The global threshold for preorder variant. */ - globalThreshold?: InputMaybe; + readonly globalThreshold?: InputMaybe; }; /** Represents preorder variant data for channel. */ export type PreorderThreshold = { - __typename?: 'PreorderThreshold'; /** Preorder threshold for product variant in this channel. */ - quantity?: Maybe; + readonly quantity?: Maybe; /** Number of sold product variant in this channel. */ - soldUnits: Scalars['Int']; + readonly soldUnits: Scalars['Int']; }; export type PriceInput = { /** Amount of money. */ - amount: Scalars['PositiveDecimal']; + readonly amount: Scalars['PositiveDecimal']; /** Currency code. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; }; export type PriceRangeInput = { /** Price greater than or equal to. */ - gte?: InputMaybe; + readonly gte?: InputMaybe; /** Price less than or equal to. */ - lte?: InputMaybe; + readonly lte?: InputMaybe; }; /** Represents an individual item for sale in the storefront. */ export type Product = Node & ObjectWithMetadata & { - __typename?: 'Product'; - /** - * Get a single attribute attached to product by attribute slug. - * - * Added in Saleor 3.9. - */ - attribute?: Maybe; + /** Get a single attribute attached to product by attribute slug. */ + readonly attribute?: Maybe; /** List of attributes assigned to this product. */ - attributes: Array; + readonly attributes: ReadonlyArray; /** * Date when product is available for purchase. - * @deprecated This field will be removed in Saleor 4.0. Use the `availableForPurchaseAt` field to fetch the available for purchase date. + * @deprecated Use the `availableForPurchaseAt` field to fetch the available for purchase date. */ - availableForPurchase?: Maybe; + readonly availableForPurchase?: Maybe; /** Date when product is available for purchase. */ - availableForPurchaseAt?: Maybe; - category?: Maybe; + readonly availableForPurchaseAt?: Maybe; + readonly category?: Maybe; /** Channel given to retrieve this product. Also used by federation gateway to resolve this object in a federated query. */ - channel?: Maybe; + readonly channel?: Maybe; /** * List of availability in channels for the product. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - channelListings?: Maybe>; - /** @deprecated This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` field to determine whether tax collection is enabled. */ - chargeTaxes: Scalars['Boolean']; + readonly channelListings?: Maybe>; + /** @deprecated Use `Channel.taxConfiguration` field to determine whether tax collection is enabled. */ + readonly chargeTaxes: Scalars['Boolean']; /** List of collections for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - collections?: Maybe>; + readonly collections?: Maybe>; /** The date and time when the product was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** Default variant of the product. */ - defaultVariant?: Maybe; + readonly defaultVariant?: Maybe; /** * Description of the product. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Description of the product. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. - */ - descriptionJson?: Maybe; - /** - * External ID of this product. - * - * Added in Saleor 3.10. + * @deprecated Use the `description` field instead. */ - externalReference?: Maybe; + readonly descriptionJson?: Maybe; + /** External ID of this product. */ + readonly externalReference?: Maybe; /** The ID of the product. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Get a single product image by ID. - * @deprecated This field will be removed in Saleor 4.0. Use the `mediaById` field instead. + * @deprecated Use the `mediaById` field instead. */ - imageById?: Maybe; + readonly imageById?: Maybe; /** * List of images for the product. - * @deprecated This field will be removed in Saleor 4.0. Use the `media` field instead. + * @deprecated Use the `media` field instead. */ - images?: Maybe>; + readonly images?: Maybe>; /** Whether the product is in stock, set as available for purchase in the given channel, and published. */ - isAvailable?: Maybe; + readonly isAvailable?: Maybe; /** Refers to a state that can be set by admins to control whether a product is available for purchase in storefronts. This does not guarantee the availability of stock. When set to `False`, this product is still visible to customers, but it cannot be purchased. */ - isAvailableForPurchase?: Maybe; + readonly isAvailableForPurchase?: Maybe; /** List of media for the product. */ - media?: Maybe>; + readonly media?: Maybe>; /** Get a single product media by ID. */ - mediaById?: Maybe; + readonly mediaById?: Maybe; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** SEO description of the product. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Lists the storefront product's pricing, the current price and discounts, only meant for displaying. */ - pricing?: Maybe; + readonly pricing?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** Type of the product. */ + readonly productType: ProductType; /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. + * List of variants for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. * - * Added in Saleor 3.3. + * Added in Saleor 3.21. */ - privateMetafields?: Maybe; - /** Type of the product. */ - productType: ProductType; + readonly productVariants?: Maybe; /** Rating of the product. */ - rating?: Maybe; + readonly rating?: Maybe; /** SEO description of the product. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** SEO title of the product. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; /** Slug of the product. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; /** * Tax class assigned to this product type. All products of this product type use this tax class, unless it's overridden in the `Product` type. * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxClass?: Maybe; + readonly taxClass?: Maybe; /** * A type of tax. Assigned by enabled tax gateway - * @deprecated This field will be removed in Saleor 4.0. Use `taxClass` field instead. + * @deprecated Use `taxClass` field instead. */ - taxType?: Maybe; + readonly taxType?: Maybe; /** Thumbnail of the product. */ - thumbnail?: Maybe; + readonly thumbnail?: Maybe; /** Returns translated product fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** The date and time when the product was last updated. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; /** * Get a single variant by SKU or ID. - * - * Added in Saleor 3.9. - * @deprecated This field will be removed in Saleor 4.0. Use top-level `variant` query. + * @deprecated Use top-level `variant` query. + */ + readonly variant?: Maybe; + /** + * List of variants for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. + * @deprecated Use `productVariants` field instead. */ - variant?: Maybe; - /** List of variants for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - variants?: Maybe>; + readonly variants?: Maybe>; /** Weight of the product. */ - weight?: Maybe; + readonly weight?: Maybe; }; @@ -20205,7 +18157,7 @@ export type ProductMetafieldArgs = { /** Represents an individual item for sale in the storefront. */ export type ProductMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -20223,7 +18175,19 @@ export type ProductPrivateMetafieldArgs = { /** Represents an individual item for sale in the storefront. */ export type ProductPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; +}; + + +/** Represents an individual item for sale in the storefront. */ +export type ProductProductVariantsArgs = { + after?: InputMaybe; + before?: InputMaybe; + filter?: InputMaybe; + first?: InputMaybe; + last?: InputMaybe; + sortBy?: InputMaybe; + where?: InputMaybe; }; @@ -20252,57 +18216,46 @@ export type ProductVariantArgs = { * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ export type ProductAttributeAssign = { - __typename?: 'ProductAttributeAssign'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; /** The updated product type. */ - productType?: Maybe; + readonly productType?: Maybe; }; export type ProductAttributeAssignInput = { /** The ID of the attribute to assign. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The attribute type to be assigned as. */ - type: ProductAttributeType; - /** - * Whether attribute is allowed in variant selection. Allowed types are: ['dropdown', 'boolean', 'swatch', 'numeric']. - * - * Added in Saleor 3.1. - */ - variantSelection?: InputMaybe; + readonly type: ProductAttributeType; + /** Whether attribute is allowed in variant selection. Allowed types are: ['dropdown', 'boolean', 'swatch', 'numeric']. */ + readonly variantSelection?: InputMaybe; }; /** * Update attributes assigned to product variant for given product type. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ export type ProductAttributeAssignmentUpdate = { - __typename?: 'ProductAttributeAssignmentUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; /** The updated product type. */ - productType?: Maybe; + readonly productType?: Maybe; }; export type ProductAttributeAssignmentUpdateInput = { /** The ID of the attribute to assign. */ - id: Scalars['ID']; - /** - * Whether attribute is allowed in variant selection. Allowed types are: ['dropdown', 'boolean', 'swatch', 'numeric']. - * - * Added in Saleor 3.1. - */ - variantSelection: Scalars['Boolean']; + readonly id: Scalars['ID']; + /** Whether attribute is allowed in variant selection. Allowed types are: ['dropdown', 'boolean', 'swatch', 'numeric']. */ + readonly variantSelection: Scalars['Boolean']; }; -export type ProductAttributeType = - | 'PRODUCT' - | 'VARIANT'; +export enum ProductAttributeType { + Product = 'PRODUCT', + Variant = 'VARIANT' +} /** * Un-assign attributes from a given product type. @@ -20310,119 +18263,118 @@ export type ProductAttributeType = * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ export type ProductAttributeUnassign = { - __typename?: 'ProductAttributeUnassign'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; /** The updated product type. */ - productType?: Maybe; + readonly productType?: Maybe; }; /** * Creates products. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductBulkCreate = { - __typename?: 'ProductBulkCreate'; /** Returns how many objects were created. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the created products. */ - results: Array; + readonly results: ReadonlyArray; }; export type ProductBulkCreateError = { - __typename?: 'ProductBulkCreateError'; /** List of attributes IDs which causes the error. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** List of channel IDs which causes the error. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** The error code. */ - code: ProductBulkCreateErrorCode; + readonly code: ProductBulkCreateErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; + readonly path?: Maybe; /** List of attribute values IDs which causes the error. */ - values?: Maybe>; + readonly values?: Maybe>; /** List of warehouse IDs which causes the error. */ - warehouses?: Maybe>; -}; - -/** An enumeration. */ -export type ProductBulkCreateErrorCode = - | 'ATTRIBUTE_ALREADY_ASSIGNED' - | 'ATTRIBUTE_CANNOT_BE_ASSIGNED' - | 'ATTRIBUTE_VARIANTS_DISABLED' - | 'BLANK' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_PRICE' - | 'MAX_LENGTH' - | 'NOT_FOUND' - | 'PRODUCT_NOT_ASSIGNED_TO_CHANNEL' - | 'PRODUCT_WITHOUT_CATEGORY' - | 'REQUIRED' - | 'UNIQUE' - | 'UNSUPPORTED_MEDIA_PROVIDER'; + readonly warehouses?: Maybe>; +}; + +export enum ProductBulkCreateErrorCode { + AttributeAlreadyAssigned = 'ATTRIBUTE_ALREADY_ASSIGNED', + AttributeCannotBeAssigned = 'ATTRIBUTE_CANNOT_BE_ASSIGNED', + AttributeVariantsDisabled = 'ATTRIBUTE_VARIANTS_DISABLED', + Blank = 'BLANK', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidPrice = 'INVALID_PRICE', + MaxLength = 'MAX_LENGTH', + NotFound = 'NOT_FOUND', + ProductNotAssignedToChannel = 'PRODUCT_NOT_ASSIGNED_TO_CHANNEL', + ProductWithoutCategory = 'PRODUCT_WITHOUT_CATEGORY', + Required = 'REQUIRED', + Unique = 'UNIQUE', + UnsupportedMediaProvider = 'UNSUPPORTED_MEDIA_PROVIDER' +} export type ProductBulkCreateInput = { /** List of attributes. */ - attributes?: InputMaybe>; + readonly attributes?: InputMaybe>; /** ID of the product's category. */ - category?: InputMaybe; + readonly category?: InputMaybe; /** List of channels in which the product is available. */ - channelListings?: InputMaybe>; + readonly channelListings?: InputMaybe>; /** * Determine if taxes are being charged for the product. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. + * @deprecated Use `Channel.taxConfiguration` to configure whether tax collection is enabled. */ - chargeTaxes?: InputMaybe; + readonly chargeTaxes?: InputMaybe; /** List of IDs of collections that the product belongs to. */ - collections?: InputMaybe>; + readonly collections?: InputMaybe>; /** * Product description. * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; + readonly description?: InputMaybe; /** External ID of this product. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** List of media inputs associated with the product. */ - media?: InputMaybe>; - /** Fields required to update the product metadata. */ - metadata?: InputMaybe>; + readonly media?: InputMaybe>; + /** + * Fields required to update the product metadata. Can be read by any API client authorized to read the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly metadata?: InputMaybe>; /** Product name. */ - name?: InputMaybe; - /** Fields required to update the product private metadata. */ - privateMetadata?: InputMaybe>; + readonly name?: InputMaybe; + /** + * Fields required to update the product private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ + readonly privateMetadata?: InputMaybe>; /** ID of the type that product belongs to. */ - productType: Scalars['ID']; + readonly productType: Scalars['ID']; /** Defines the product rating value. */ - rating?: InputMaybe; + readonly rating?: InputMaybe; /** Search engine optimization fields. */ - seo?: InputMaybe; + readonly seo?: InputMaybe; /** Product slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** ID of a tax class to assign to this product. If not provided, product will use the tax class which is assigned to the product type. */ - taxClass?: InputMaybe; + readonly taxClass?: InputMaybe; /** * Tax rate for enabled tax gateway. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. + * @deprecated Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. */ - taxCode?: InputMaybe; + readonly taxCode?: InputMaybe; /** Input list of product variants to create. */ - variants?: InputMaybe>; + readonly variants?: InputMaybe>; /** Weight of the Product. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; /** @@ -20431,29 +18383,23 @@ export type ProductBulkCreateInput = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductBulkDelete = { - __typename?: 'ProductBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; export type ProductBulkResult = { - __typename?: 'ProductBulkResult'; /** List of errors occurred on create attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; /** Product data. */ - product?: Maybe; + readonly product?: Maybe; }; /** * Creates/updates translations for products. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. * * Triggers the following webhook events: @@ -20461,88 +18407,76 @@ export type ProductBulkResult = { * - TRANSLATION_UPDATED (async): Called when a translation was updated. */ export type ProductBulkTranslate = { - __typename?: 'ProductBulkTranslate'; /** Returns how many translations were created/updated. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the translations. */ - results: Array; + readonly results: ReadonlyArray; }; export type ProductBulkTranslateError = { - __typename?: 'ProductBulkTranslateError'; /** The error code. */ - code: ProductTranslateErrorCode; + readonly code: ProductTranslateErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; + readonly path?: Maybe; }; export type ProductBulkTranslateInput = { /** External reference of an product. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** Product ID. */ - id?: InputMaybe; + readonly id?: InputMaybe; /** Translation language code. */ - languageCode: LanguageCodeEnum; + readonly languageCode: LanguageCodeEnum; /** Translation fields. */ - translationFields: TranslationInput; + readonly translationFields: TranslationInput; }; export type ProductBulkTranslateResult = { - __typename?: 'ProductBulkTranslateResult'; /** List of errors occurred on translation attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; /** Product translation data. */ - translation?: Maybe; + readonly translation?: Maybe; }; /** Represents product channel listing. */ export type ProductChannelListing = Node & { - __typename?: 'ProductChannelListing'; - /** @deprecated This field will be removed in Saleor 4.0. Use the `availableForPurchaseAt` field to fetch the available for purchase date. */ - availableForPurchase?: Maybe; - /** - * The product available for purchase date time. - * - * Added in Saleor 3.3. - */ - availableForPurchaseAt?: Maybe; + /** @deprecated Use the `availableForPurchaseAt` field to fetch the available for purchase date. */ + readonly availableForPurchase?: Maybe; + /** The product available for purchase date time. */ + readonly availableForPurchaseAt?: Maybe; /** The channel in which the product is listed. */ - channel: Channel; + readonly channel: Channel; /** The price of the cheapest variant (including discounts). */ - discountedPrice?: Maybe; + readonly discountedPrice?: Maybe; /** The ID of the product channel listing. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Refers to a state that can be set by admins to control whether a product is available for purchase in storefronts in this channel. This does not guarantee the availability of stock. When set to `False`, this product is still visible to customers, but it cannot be purchased. */ - isAvailableForPurchase?: Maybe; + readonly isAvailableForPurchase?: Maybe; /** Indicates if the product is published in the channel. */ - isPublished: Scalars['Boolean']; + readonly isPublished: Scalars['Boolean']; /** * Range of margin percentage value. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - margin?: Maybe; + readonly margin?: Maybe; /** Lists the storefront product's pricing, the current price and discounts, only meant for displaying. */ - pricing?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date. */ - publicationDate?: Maybe; - /** - * The product publication date time. - * - * Added in Saleor 3.3. - */ - publishedAt?: Maybe; + readonly pricing?: Maybe; + /** @deprecated Use the `publishedAt` field to fetch the publication date. */ + readonly publicationDate?: Maybe; + /** The product publication date time. */ + readonly publishedAt?: Maybe; /** * Purchase cost of product. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - purchaseCost?: Maybe; + readonly purchaseCost?: Maybe; /** Indicates product visibility in the channel listings. */ - visibleInListings: Scalars['Boolean']; + readonly visibleInListings: Scalars['Boolean']; }; @@ -20553,74 +18487,63 @@ export type ProductChannelListingPricingArgs = { export type ProductChannelListingAddInput = { /** List of variants to which the channel should be assigned. */ - addVariants?: InputMaybe>; - /** - * A start date time from which a product will be available for purchase. When not set and `isAvailable` is set to True, the current day is assumed. - * - * Added in Saleor 3.3. - */ - availableForPurchaseAt?: InputMaybe; + readonly addVariants?: InputMaybe>; + /** A start date time from which a product will be available for purchase. When not set and `isAvailable` is set to True, the current day is assumed. */ + readonly availableForPurchaseAt?: InputMaybe; /** * A start date from which a product will be available for purchase. When not set and isAvailable is set to True, the current day is assumed. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `availableForPurchaseAt` field instead. + * @deprecated Use `availableForPurchaseAt` field instead. */ - availableForPurchaseDate?: InputMaybe; + readonly availableForPurchaseDate?: InputMaybe; /** ID of a channel. */ - channelId: Scalars['ID']; + readonly channelId: Scalars['ID']; /** Determines if product should be available for purchase in this channel. This does not guarantee the availability of stock. When set to `False`, this product is still visible to customers, but it cannot be purchased. */ - isAvailableForPurchase?: InputMaybe; + readonly isAvailableForPurchase?: InputMaybe; /** Determines if object is visible to customers. */ - isPublished?: InputMaybe; + readonly isPublished?: InputMaybe; /** * Publication date. ISO 8601 standard. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - */ - publicationDate?: InputMaybe; - /** - * Publication date time. ISO 8601 standard. - * - * Added in Saleor 3.3. + * @deprecated Use `publishedAt` field instead. */ - publishedAt?: InputMaybe; + readonly publicationDate?: InputMaybe; + /** Publication date time. ISO 8601 standard. */ + readonly publishedAt?: InputMaybe; /** List of variants from which the channel should be unassigned. */ - removeVariants?: InputMaybe>; + readonly removeVariants?: InputMaybe>; /** Determines if product is visible in product listings (doesn't apply to product collections). */ - visibleInListings?: InputMaybe; + readonly visibleInListings?: InputMaybe; }; export type ProductChannelListingCreateInput = { /** A start date time from which a product will be available for purchase. When not set and `isAvailable` is set to True, the current day is assumed. */ - availableForPurchaseAt?: InputMaybe; + readonly availableForPurchaseAt?: InputMaybe; /** ID of a channel. */ - channelId: Scalars['ID']; + readonly channelId: Scalars['ID']; /** Determines if product should be available for purchase in this channel. This does not guarantee the availability of stock. When set to `False`, this product is still visible to customers, but it cannot be purchased. */ - isAvailableForPurchase?: InputMaybe; + readonly isAvailableForPurchase?: InputMaybe; /** Determines if object is visible to customers. */ - isPublished?: InputMaybe; + readonly isPublished?: InputMaybe; /** Publication date time. ISO 8601 standard. */ - publishedAt?: InputMaybe; + readonly publishedAt?: InputMaybe; /** Determines if product is visible in product listings (doesn't apply to product collections). */ - visibleInListings?: InputMaybe; + readonly visibleInListings?: InputMaybe; }; export type ProductChannelListingError = { - __typename?: 'ProductChannelListingError'; /** List of attributes IDs which causes the error. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** List of channels IDs which causes the error. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** The error code. */ - code: ProductErrorCode; + readonly code: ProductErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of attribute values IDs which causes the error. */ - values?: Maybe>; + readonly values?: Maybe>; /** List of variants IDs which causes the error. */ - variants?: Maybe>; + readonly variants?: Maybe>; }; /** @@ -20629,36 +18552,33 @@ export type ProductChannelListingError = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductChannelListingUpdate = { - __typename?: 'ProductChannelListingUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** An updated product instance. */ - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productChannelListingErrors: Array; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productChannelListingErrors: ReadonlyArray; }; export type ProductChannelListingUpdateInput = { /** List of channels from which the product should be unassigned. */ - removeChannels?: InputMaybe>; + readonly removeChannels?: InputMaybe>; /** List of channels to which the product should be assigned or updated. */ - updateChannels?: InputMaybe>; + readonly updateChannels?: InputMaybe>; }; export type ProductCountableConnection = { - __typename?: 'ProductCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type ProductCountableEdge = { - __typename?: 'ProductCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Product; + readonly node: Product; }; /** @@ -20667,99 +18587,83 @@ export type ProductCountableEdge = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductCreate = { - __typename?: 'ProductCreate'; - errors: Array; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; export type ProductCreateInput = { /** List of attributes. */ - attributes?: InputMaybe>; + readonly attributes?: InputMaybe>; /** ID of the product's category. */ - category?: InputMaybe; + readonly category?: InputMaybe; /** * Determine if taxes are being charged for the product. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. + * @deprecated Use `Channel.taxConfiguration` to configure whether tax collection is enabled. */ - chargeTaxes?: InputMaybe; + readonly chargeTaxes?: InputMaybe; /** List of IDs of collections that the product belongs to. */ - collections?: InputMaybe>; + readonly collections?: InputMaybe>; /** * Product description. * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; - /** - * External ID of this product. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly description?: InputMaybe; + /** External ID of this product. */ + readonly externalReference?: InputMaybe; /** - * Fields required to update the product metadata. + * Fields required to update the product metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Product name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** - * Fields required to update the product private metadata. + * Fields required to update the product private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** ID of the type that product belongs to. */ - productType: Scalars['ID']; + readonly productType: Scalars['ID']; /** Defines the product rating value. */ - rating?: InputMaybe; + readonly rating?: InputMaybe; /** Search engine optimization fields. */ - seo?: InputMaybe; + readonly seo?: InputMaybe; /** Product slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** ID of a tax class to assign to this product. If not provided, product will use the tax class which is assigned to the product type. */ - taxClass?: InputMaybe; + readonly taxClass?: InputMaybe; /** * Tax rate for enabled tax gateway. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. + * @deprecated Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. */ - taxCode?: InputMaybe; + readonly taxCode?: InputMaybe; /** Weight of the Product. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; -/** - * Event sent when new product is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new product is created. */ export type ProductCreated = Event & { - __typename?: 'ProductCreated'; /** The category of the product. */ - category?: Maybe; + readonly category?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product the event relates to. */ - product?: Maybe; + readonly product?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when new product is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new product is created. */ export type ProductCreatedProductArgs = { channel?: InputMaybe; }; @@ -20770,179 +18674,146 @@ export type ProductCreatedProductArgs = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductDelete = { - __typename?: 'ProductDelete'; - errors: Array; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -/** - * Event sent when product is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when product is deleted. */ export type ProductDeleted = Event & { - __typename?: 'ProductDeleted'; /** The category of the product. */ - category?: Maybe; + readonly category?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product the event relates to. */ - product?: Maybe; + readonly product?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when product is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when product is deleted. */ export type ProductDeletedProductArgs = { channel?: InputMaybe; }; export type ProductError = { - __typename?: 'ProductError'; /** List of attributes IDs which causes the error. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** The error code. */ - code: ProductErrorCode; + readonly code: ProductErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of attribute values IDs which causes the error. */ - values?: Maybe>; -}; - -/** An enumeration. */ -export type ProductErrorCode = - | 'ALREADY_EXISTS' - | 'ATTRIBUTE_ALREADY_ASSIGNED' - | 'ATTRIBUTE_CANNOT_BE_ASSIGNED' - | 'ATTRIBUTE_VARIANTS_DISABLED' - | 'CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_PRICE' - | 'MEDIA_ALREADY_ASSIGNED' - | 'NOT_FOUND' - | 'NOT_PRODUCTS_IMAGE' - | 'NOT_PRODUCTS_VARIANT' - | 'PREORDER_VARIANT_CANNOT_BE_DEACTIVATED' - | 'PRODUCT_NOT_ASSIGNED_TO_CHANNEL' - | 'PRODUCT_WITHOUT_CATEGORY' - | 'REQUIRED' - | 'UNIQUE' - | 'UNSUPPORTED_MEDIA_PROVIDER' - | 'VARIANT_NO_DIGITAL_CONTENT'; + readonly values?: Maybe>; +}; + +export enum ProductErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + AttributeAlreadyAssigned = 'ATTRIBUTE_ALREADY_ASSIGNED', + AttributeCannotBeAssigned = 'ATTRIBUTE_CANNOT_BE_ASSIGNED', + AttributeVariantsDisabled = 'ATTRIBUTE_VARIANTS_DISABLED', + CannotManageProductWithoutVariant = 'CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidPrice = 'INVALID_PRICE', + MediaAlreadyAssigned = 'MEDIA_ALREADY_ASSIGNED', + NotFound = 'NOT_FOUND', + NotProductsImage = 'NOT_PRODUCTS_IMAGE', + NotProductsVariant = 'NOT_PRODUCTS_VARIANT', + PreorderVariantCannotBeDeactivated = 'PREORDER_VARIANT_CANNOT_BE_DEACTIVATED', + ProductNotAssignedToChannel = 'PRODUCT_NOT_ASSIGNED_TO_CHANNEL', + ProductWithoutCategory = 'PRODUCT_WITHOUT_CATEGORY', + Required = 'REQUIRED', + Unique = 'UNIQUE', + UnsupportedMediaProvider = 'UNSUPPORTED_MEDIA_PROVIDER', + VariantNoDigitalContent = 'VARIANT_NO_DIGITAL_CONTENT' +} -/** - * Event sent when product export is completed. - * - * Added in Saleor 3.16. - */ +/** Event sent when product export is completed. */ export type ProductExportCompleted = Event & { - __typename?: 'ProductExportCompleted'; /** The export file for products. */ - export?: Maybe; + readonly export?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; -}; - -export type ProductFieldEnum = - | 'CATEGORY' - | 'CHARGE_TAXES' - | 'COLLECTIONS' - | 'DESCRIPTION' - | 'NAME' - | 'PRODUCT_MEDIA' - | 'PRODUCT_TYPE' - | 'PRODUCT_WEIGHT' - | 'VARIANT_ID' - | 'VARIANT_MEDIA' - | 'VARIANT_SKU' - | 'VARIANT_WEIGHT'; + readonly version?: Maybe; +}; + +export enum ProductFieldEnum { + Category = 'CATEGORY', + ChargeTaxes = 'CHARGE_TAXES', + Collections = 'COLLECTIONS', + Description = 'DESCRIPTION', + Name = 'NAME', + ProductMedia = 'PRODUCT_MEDIA', + ProductType = 'PRODUCT_TYPE', + ProductWeight = 'PRODUCT_WEIGHT', + VariantId = 'VARIANT_ID', + VariantMedia = 'VARIANT_MEDIA', + VariantSku = 'VARIANT_SKU', + VariantWeight = 'VARIANT_WEIGHT' +} export type ProductFilterInput = { - attributes?: InputMaybe>; - /** - * Filter by the date of availability for purchase. - * - * Added in Saleor 3.8. - */ - availableFrom?: InputMaybe; - categories?: InputMaybe>; + readonly attributes?: InputMaybe>; + /** Filter by the date of availability for purchase. */ + readonly availableFrom?: InputMaybe; + readonly categories?: InputMaybe>; /** * Specifies the channel by which the data should be filtered. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. + * @deprecated Use root-level channel argument instead. */ - channel?: InputMaybe; - collections?: InputMaybe>; + readonly channel?: InputMaybe; + readonly collections?: InputMaybe>; /** Filter on whether product is a gift card or not. */ - giftCard?: InputMaybe; - hasCategory?: InputMaybe; - hasPreorderedVariants?: InputMaybe; - ids?: InputMaybe>; - /** - * Filter by availability for purchase. - * - * Added in Saleor 3.8. - */ - isAvailable?: InputMaybe; - isPublished?: InputMaybe; - /** - * Filter by visibility in product listings. - * - * Added in Saleor 3.8. - */ - isVisibleInListing?: InputMaybe; - metadata?: InputMaybe>; + readonly giftCard?: InputMaybe; + readonly hasCategory?: InputMaybe; + readonly hasPreorderedVariants?: InputMaybe; + readonly ids?: InputMaybe>; + /** Filter by availability for purchase. */ + readonly isAvailable?: InputMaybe; + readonly isPublished?: InputMaybe; + /** Filter by visibility in product listings. */ + readonly isVisibleInListing?: InputMaybe; + readonly metadata?: InputMaybe>; /** Filter by the lowest variant price after discounts. */ - minimalPrice?: InputMaybe; - price?: InputMaybe; - productTypes?: InputMaybe>; - /** - * Filter by the publication date. - * - * Added in Saleor 3.8. - */ - publishedFrom?: InputMaybe; - search?: InputMaybe; - slugs?: InputMaybe>; + readonly minimalPrice?: InputMaybe; + readonly price?: InputMaybe; + readonly productTypes?: InputMaybe>; + /** Filter by the publication date. */ + readonly publishedFrom?: InputMaybe; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; /** Filter by variants having specific stock status. */ - stockAvailability?: InputMaybe; - stocks?: InputMaybe; + readonly stockAvailability?: InputMaybe; + readonly stocks?: InputMaybe; /** Filter by when was the most recent update. */ - updatedAt?: InputMaybe; + readonly updatedAt?: InputMaybe; }; /** Represents a product image. */ export type ProductImage = { - __typename?: 'ProductImage'; /** The alt text of the image. */ - alt?: Maybe; + readonly alt?: Maybe; /** The ID of the image. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The new relative sorting position of the item (from -inf to +inf). 1 moves the item one position forward, -1 moves the item one position backward, 0 leaves the item unchanged. */ - sortOrder?: Maybe; + readonly sortOrder?: Maybe; /** The URL of the image. */ - url: Scalars['String']; + readonly url: Scalars['String']; }; @@ -20954,122 +18825,91 @@ export type ProductImageUrlArgs = { export type ProductInput = { /** List of attributes. */ - attributes?: InputMaybe>; + readonly attributes?: InputMaybe>; /** ID of the product's category. */ - category?: InputMaybe; + readonly category?: InputMaybe; /** * Determine if taxes are being charged for the product. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. + * @deprecated Use `Channel.taxConfiguration` to configure whether tax collection is enabled. */ - chargeTaxes?: InputMaybe; + readonly chargeTaxes?: InputMaybe; /** List of IDs of collections that the product belongs to. */ - collections?: InputMaybe>; + readonly collections?: InputMaybe>; /** * Product description. * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; - /** - * External ID of this product. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly description?: InputMaybe; + /** External ID of this product. */ + readonly externalReference?: InputMaybe; /** - * Fields required to update the product metadata. + * Fields required to update the product metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Product name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** - * Fields required to update the product private metadata. + * Fields required to update the product private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** Defines the product rating value. */ - rating?: InputMaybe; + readonly rating?: InputMaybe; /** Search engine optimization fields. */ - seo?: InputMaybe; + readonly seo?: InputMaybe; /** Product slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** ID of a tax class to assign to this product. If not provided, product will use the tax class which is assigned to the product type. */ - taxClass?: InputMaybe; + readonly taxClass?: InputMaybe; /** * Tax rate for enabled tax gateway. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. + * @deprecated Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. */ - taxCode?: InputMaybe; + readonly taxCode?: InputMaybe; /** Weight of the Product. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; /** Represents a product media. */ export type ProductMedia = Node & ObjectWithMetadata & { - __typename?: 'ProductMedia'; /** The alt text of the media. */ - alt: Scalars['String']; + readonly alt: Scalars['String']; /** The unique ID of the product media. */ - id: Scalars['ID']; - /** - * List of public metadata items. Can be accessed without permissions. - * - * Added in Saleor 3.12. - */ - metadata: Array; + readonly id: Scalars['ID']; + /** List of public metadata items. Can be accessed without permissions. */ + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.12. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.12. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** The oEmbed data of the media. */ - oembedData: Scalars['JSONString']; - /** - * List of private metadata items. Requires staff permissions to access. - * - * Added in Saleor 3.12. - */ - privateMetadata: Array; + readonly oembedData: Scalars['JSONString']; + /** List of private metadata items. Requires staff permissions to access. */ + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.12. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.12. */ - privateMetafields?: Maybe; - /** - * Product id the media refers to. - * - * Added in Saleor 3.12. - */ - productId?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** Product id the media refers to. */ + readonly productId?: Maybe; /** The sort order of the media. */ - sortOrder?: Maybe; + readonly sortOrder?: Maybe; /** The type of the media. */ - type: ProductMediaType; + readonly type: ProductMediaType; /** The URL of the media. */ - url: Scalars['String']; + readonly url: Scalars['String']; }; @@ -21081,7 +18921,7 @@ export type ProductMediaMetafieldArgs = { /** Represents a product media. */ export type ProductMediaMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -21093,7 +18933,7 @@ export type ProductMediaPrivateMetafieldArgs = { /** Represents a product media. */ export type ProductMediaPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -21109,12 +18949,11 @@ export type ProductMediaUrlArgs = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductMediaBulkDelete = { - __typename?: 'ProductMediaBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; /** @@ -21123,42 +18962,36 @@ export type ProductMediaBulkDelete = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductMediaCreate = { - __typename?: 'ProductMediaCreate'; - errors: Array; - media?: Maybe; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly media?: Maybe; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; export type ProductMediaCreateInput = { /** Alt text for a product media. */ - alt?: InputMaybe; + readonly alt?: InputMaybe; /** Represents an image file in a multipart request. */ - image?: InputMaybe; + readonly image?: InputMaybe; /** Represents an URL to an external media. */ - mediaUrl?: InputMaybe; + readonly mediaUrl?: InputMaybe; /** ID of an product. */ - product: Scalars['ID']; + readonly product: Scalars['ID']; }; -/** - * Event sent when new product media is created. - * - * Added in Saleor 3.12. - */ +/** Event sent when new product media is created. */ export type ProductMediaCreated = Event & { - __typename?: 'ProductMediaCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product media the event relates to. */ - productMedia?: Maybe; + readonly productMedia?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -21167,31 +19000,25 @@ export type ProductMediaCreated = Event & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductMediaDelete = { - __typename?: 'ProductMediaDelete'; - errors: Array; - media?: Maybe; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly media?: Maybe; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -/** - * Event sent when product media is deleted. - * - * Added in Saleor 3.12. - */ +/** Event sent when product media is deleted. */ export type ProductMediaDeleted = Event & { - __typename?: 'ProductMediaDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product media the event relates to. */ - productMedia?: Maybe; + readonly productMedia?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -21200,18 +19027,17 @@ export type ProductMediaDeleted = Event & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductMediaReorder = { - __typename?: 'ProductMediaReorder'; - errors: Array; - media?: Maybe>; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly media?: Maybe>; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -/** An enumeration. */ -export type ProductMediaType = - | 'IMAGE' - | 'VIDEO'; +export enum ProductMediaType { + Image = 'IMAGE', + Video = 'VIDEO' +} /** * Updates a product media. @@ -21219,65 +19045,50 @@ export type ProductMediaType = * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductMediaUpdate = { - __typename?: 'ProductMediaUpdate'; - errors: Array; - media?: Maybe; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly media?: Maybe; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; export type ProductMediaUpdateInput = { /** Alt text for a product media. */ - alt?: InputMaybe; + readonly alt?: InputMaybe; }; -/** - * Event sent when product media is updated. - * - * Added in Saleor 3.12. - */ +/** Event sent when product media is updated. */ export type ProductMediaUpdated = Event & { - __typename?: 'ProductMediaUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product media the event relates to. */ - productMedia?: Maybe; + readonly productMedia?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when product metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when product metadata is updated. */ export type ProductMetadataUpdated = Event & { - __typename?: 'ProductMetadataUpdated'; /** The category of the product. */ - category?: Maybe; + readonly category?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product the event relates to. */ - product?: Maybe; + readonly product?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when product metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when product metadata is updated. */ export type ProductMetadataUpdatedProductArgs = { channel?: InputMaybe; }; @@ -21287,104 +19098,107 @@ export type ProductOrder = { * Sort product by the selected attribute's values. * Note: this doesn't take translations into account yet. */ - attributeId?: InputMaybe; + readonly attributeId?: InputMaybe; /** * Specifies the channel in which to sort the data. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. + * @deprecated Use root-level channel argument instead. */ - channel?: InputMaybe; + readonly channel?: InputMaybe; /** Specifies the direction in which to sort products. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort products by the selected field. */ - field?: InputMaybe; + readonly field?: InputMaybe; }; -export type ProductOrderField = +export enum ProductOrderField { /** * Sort products by collection. Note: This option is available only for the `Collection.products` query. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'COLLECTION' - /** - * Sort products by creation date. - * - * Added in Saleor 3.8. - */ - | 'CREATED_AT' + Collection = 'COLLECTION', + /** Sort products by creation date. */ + CreatedAt = 'CREATED_AT', /** Sort products by update date. */ - | 'DATE' + Date = 'DATE', /** Sort products by update date. */ - | 'LAST_MODIFIED' + LastModified = 'LAST_MODIFIED', /** Sort products by update date. */ - | 'LAST_MODIFIED_AT' + LastModifiedAt = 'LAST_MODIFIED_AT', /** * Sort products by a minimal price of a product's variant. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'MINIMAL_PRICE' + MinimalPrice = 'MINIMAL_PRICE', /** Sort products by name. */ - | 'NAME' + Name = 'NAME', /** * Sort products by price. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'PRICE' + Price = 'PRICE', /** * Sort products by publication date. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'PUBLICATION_DATE' + PublicationDate = 'PUBLICATION_DATE', /** * Sort products by publication status. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'PUBLISHED' + Published = 'PUBLISHED', /** * Sort products by publication date. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'PUBLISHED_AT' + PublishedAt = 'PUBLISHED_AT', /** Sort products by rank. Note: This option is available only with the `search` filter. */ - | 'RANK' + Rank = 'RANK', /** Sort products by rating. */ - | 'RATING' + Rating = 'RATING', /** Sort products by type. */ - | 'TYPE'; + Type = 'TYPE' +} /** Represents availability of a product in the storefront. */ export type ProductPricingInfo = { - __typename?: 'ProductPricingInfo'; /** The discount amount if in sale (null otherwise). */ - discount?: Maybe; + readonly discount?: Maybe; /** * The discount amount in the local currency. - * @deprecated This field will be removed in Saleor 4.0. Always returns `null`. + * @deprecated Always returns `null`. */ - discountLocalCurrency?: Maybe; + readonly discountLocalCurrency?: Maybe; /** - * Determines whether displayed prices should include taxes. + * The discount amount compared to prior price. Null if product is not on sale or prior price was not provided in VariantChannelListing * - * Added in Saleor 3.9. + * Added in Saleor 3.21. */ - displayGrossPrices: Scalars['Boolean']; + readonly discountPrior?: Maybe; + /** Determines whether displayed prices should include taxes. */ + readonly displayGrossPrices: Scalars['Boolean']; /** Whether it is in sale or not. */ - onSale?: Maybe; + readonly onSale?: Maybe; /** The discounted price range of the product variants. */ - priceRange?: Maybe; + readonly priceRange?: Maybe; /** * The discounted price range of the product variants in the local currency. - * @deprecated This field will be removed in Saleor 4.0. Always returns `null`. + * @deprecated Always returns `null`. */ - priceRangeLocalCurrency?: Maybe; + readonly priceRangeLocalCurrency?: Maybe; + /** + * The prior price range of the product variants. + * + * Added in Saleor 3.21. + */ + readonly priceRangePrior?: Maybe; /** The undiscounted price range of the product variants. */ - priceRangeUndiscounted?: Maybe; + readonly priceRangeUndiscounted?: Maybe; }; /** @@ -21393,58 +19207,58 @@ export type ProductPricingInfo = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductReorderAttributeValues = { - __typename?: 'ProductReorderAttributeValues'; - errors: Array; + readonly errors: ReadonlyArray; /** Product from which attribute values are reordered. */ - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; export type ProductStockFilterInput = { - quantity?: InputMaybe; - warehouseIds?: InputMaybe>; + readonly quantity?: InputMaybe; + readonly warehouseIds?: InputMaybe>; }; /** Represents product's original translatable fields and related translations. */ export type ProductTranslatableContent = Node & { - __typename?: 'ProductTranslatableContent'; /** List of product attribute values that can be translated. */ - attributeValues: Array; + readonly attributeValues: ReadonlyArray; /** * Product's description to translate. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Description of the product. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. + * @deprecated Use the `description` field instead. */ - descriptionJson?: Maybe; + readonly descriptionJson?: Maybe; /** The ID of the product translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Product's name to translate. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** * Represents an individual item for sale in the storefront. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. + * @deprecated Get model fields from the root level queries. */ - product?: Maybe; + readonly product?: Maybe; + /** The ID of the product to translate. */ + readonly productId: Scalars['ID']; + /** SEO description to translate. */ + readonly seoDescription?: Maybe; + /** SEO title to translate. */ + readonly seoTitle?: Maybe; /** - * The ID of the product to translate. + * Slug to translate. * - * Added in Saleor 3.14. + * Added in Saleor 3.21. */ - productId: Scalars['ID']; - /** SEO description to translate. */ - seoDescription?: Maybe; - /** SEO title to translate. */ - seoTitle?: Maybe; + readonly slug?: Maybe; /** Returns translated product fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -21459,140 +19273,123 @@ export type ProductTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type ProductTranslate = { - __typename?: 'ProductTranslate'; - errors: Array; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly errors: ReadonlyArray; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; -/** An enumeration. */ -export type ProductTranslateErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum ProductTranslateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} /** Represents product translations. */ export type ProductTranslation = Node & { - __typename?: 'ProductTranslation'; /** * Translated description of the product. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * Translated description of the product. * * Rich text format. For reference see https://editorjs.io/ - * @deprecated This field will be removed in Saleor 4.0. Use the `description` field instead. + * @deprecated Use the `description` field instead. */ - descriptionJson?: Maybe; + readonly descriptionJson?: Maybe; /** The ID of the product translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated product name. */ - name?: Maybe; + readonly name?: Maybe; /** Translated SEO description. */ - seoDescription?: Maybe; + readonly seoDescription?: Maybe; /** Translated SEO title. */ - seoTitle?: Maybe; + readonly seoTitle?: Maybe; /** - * Represents the product fields to translate. + * Translated product slug. * - * Added in Saleor 3.14. + * Added in Saleor 3.21. */ - translatableContent?: Maybe; + readonly slug?: Maybe; + /** Represents the product fields to translate. */ + readonly translatableContent?: Maybe; }; /** Represents a type of product. It defines what attributes are available to products of this type. */ export type ProductType = Node & ObjectWithMetadata & { - __typename?: 'ProductType'; - /** - * Variant attributes of that product type with attached variant selection. - * - * Added in Saleor 3.1. - */ - assignedVariantAttributes?: Maybe>; + /** Variant attributes of that product type with attached variant selection. */ + readonly assignedVariantAttributes?: Maybe>; /** * List of attributes which can be assigned to this product type. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - availableAttributes?: Maybe; + readonly availableAttributes?: Maybe; /** Whether the product type has variants. */ - hasVariants: Scalars['Boolean']; + readonly hasVariants: Scalars['Boolean']; /** The ID of the product type. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Whether the product type is digital. */ - isDigital: Scalars['Boolean']; + readonly isDigital: Scalars['Boolean']; /** Whether shipping is required for this product type. */ - isShippingRequired: Scalars['Boolean']; + readonly isShippingRequired: Scalars['Boolean']; /** The product type kind. */ - kind: ProductTypeKindEnum; + readonly kind: ProductTypeKindEnum; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Name of the product type. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Product attributes of that product type. */ - productAttributes?: Maybe>; + readonly productAttributes?: Maybe>; /** * List of products of this type. - * @deprecated This field will be removed in Saleor 4.0. Use the top-level `products` query with the `productTypes` filter. + * @deprecated Use the top-level `products` query with the `productTypes` filter. */ - products?: Maybe; + readonly products?: Maybe; /** Slug of the product type. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; /** * Tax class assigned to this product type. All products of this product type use this tax class, unless it's overridden in the `Product` type. * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxClass?: Maybe; + readonly taxClass?: Maybe; /** * A type of tax. Assigned by enabled tax gateway - * @deprecated This field will be removed in Saleor 4.0. Use `taxClass` field instead. + * @deprecated Use `taxClass` field instead. */ - taxType?: Maybe; + readonly taxType?: Maybe; /** * Variant attributes of that product type. - * @deprecated This field will be removed in Saleor 4.0. Use `assignedVariantAttributes` instead. + * @deprecated Use `assignedVariantAttributes` instead. */ - variantAttributes?: Maybe>; + readonly variantAttributes?: Maybe>; /** Weight of the product type. */ - weight?: Maybe; + readonly weight?: Maybe; }; @@ -21621,7 +19418,7 @@ export type ProductTypeMetafieldArgs = { /** Represents a type of product. It defines what attributes are available to products of this type. */ export type ProductTypeMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -21633,7 +19430,7 @@ export type ProductTypePrivateMetafieldArgs = { /** Represents a type of product. It defines what attributes are available to products of this type. */ export type ProductTypePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -21658,33 +19455,31 @@ export type ProductTypeVariantAttributesArgs = { * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ export type ProductTypeBulkDelete = { - __typename?: 'ProductTypeBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -export type ProductTypeConfigurable = - | 'CONFIGURABLE' - | 'SIMPLE'; +export enum ProductTypeConfigurable { + Configurable = 'CONFIGURABLE', + Simple = 'SIMPLE' +} export type ProductTypeCountableConnection = { - __typename?: 'ProductTypeCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type ProductTypeCountableEdge = { - __typename?: 'ProductTypeCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: ProductType; + readonly node: ProductType; }; /** @@ -21693,11 +19488,10 @@ export type ProductTypeCountableEdge = { * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ export type ProductTypeCreate = { - __typename?: 'ProductTypeCreate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - productType?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly productType?: Maybe; }; /** @@ -21706,60 +19500,59 @@ export type ProductTypeCreate = { * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ export type ProductTypeDelete = { - __typename?: 'ProductTypeDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - productType?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly productType?: Maybe; }; -export type ProductTypeEnum = - | 'DIGITAL' - | 'SHIPPABLE'; +export enum ProductTypeEnum { + Digital = 'DIGITAL', + Shippable = 'SHIPPABLE' +} export type ProductTypeFilterInput = { - configurable?: InputMaybe; - ids?: InputMaybe>; - kind?: InputMaybe; - metadata?: InputMaybe>; - productType?: InputMaybe; - search?: InputMaybe; - slugs?: InputMaybe>; + readonly configurable?: InputMaybe; + readonly ids?: InputMaybe>; + readonly kind?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly productType?: InputMaybe; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; }; export type ProductTypeInput = { /** Determines if product of this type has multiple variants. This option mainly simplifies product management in the dashboard. There is always at least one variant created under the hood. */ - hasVariants?: InputMaybe; + readonly hasVariants?: InputMaybe; /** Determines if products are digital. */ - isDigital?: InputMaybe; + readonly isDigital?: InputMaybe; /** Determines if shipping is required for products of this variant. */ - isShippingRequired?: InputMaybe; + readonly isShippingRequired?: InputMaybe; /** The product type kind. */ - kind?: InputMaybe; + readonly kind?: InputMaybe; /** Name of the product type. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** List of attributes shared among all product variants. */ - productAttributes?: InputMaybe>; + readonly productAttributes?: InputMaybe>; /** Product type slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** ID of a tax class to assign to this product type. All products of this product type would use this tax class, unless it's overridden in the `Product` type. */ - taxClass?: InputMaybe; + readonly taxClass?: InputMaybe; /** * Tax rate for enabled tax gateway. - * - * DEPRECATED: this field will be removed in Saleor 4.0.. Use tax classes to control the tax calculation for a product type. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. + * @deprecated Use tax classes to control the tax calculation for a product type. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. */ - taxCode?: InputMaybe; + readonly taxCode?: InputMaybe; /** List of attributes used to distinguish between different variants of a product. */ - variantAttributes?: InputMaybe>; + readonly variantAttributes?: InputMaybe>; /** Weight of the ProductType items. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; -/** An enumeration. */ -export type ProductTypeKindEnum = - | 'GIFT_CARD' - | 'NORMAL'; +export enum ProductTypeKindEnum { + GiftCard = 'GIFT_CARD', + Normal = 'NORMAL' +} /** * Reorder the attributes of a product type. @@ -21767,27 +19560,27 @@ export type ProductTypeKindEnum = * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ export type ProductTypeReorderAttributes = { - __typename?: 'ProductTypeReorderAttributes'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; /** Product type from which attributes are reordered. */ - productType?: Maybe; + readonly productType?: Maybe; }; -export type ProductTypeSortField = +export enum ProductTypeSortField { /** Sort products by type. */ - | 'DIGITAL' + Digital = 'DIGITAL', /** Sort products by name. */ - | 'NAME' + Name = 'NAME', /** Sort products by shipping. */ - | 'SHIPPING_REQUIRED'; + ShippingRequired = 'SHIPPING_REQUIRED' +} export type ProductTypeSortingInput = { /** Specifies the direction in which to sort product types. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort product types by the selected field. */ - field: ProductTypeSortField; + readonly field: ProductTypeSortField; }; /** @@ -21796,11 +19589,10 @@ export type ProductTypeSortingInput = { * Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. */ export type ProductTypeUpdate = { - __typename?: 'ProductTypeUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - productType?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly productType?: Maybe; }; /** @@ -21809,158 +19601,127 @@ export type ProductTypeUpdate = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductUpdate = { - __typename?: 'ProductUpdate'; - errors: Array; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -/** - * Event sent when product is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when product is updated. */ export type ProductUpdated = Event & { - __typename?: 'ProductUpdated'; /** The category of the product. */ - category?: Maybe; + readonly category?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product the event relates to. */ - product?: Maybe; + readonly product?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when product is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when product is updated. */ export type ProductUpdatedProductArgs = { channel?: InputMaybe; }; /** Represents a version of a product such as different size or color. */ export type ProductVariant = Node & ObjectWithMetadata & { - __typename?: 'ProductVariant'; /** List of attributes assigned to this variant. */ - attributes: Array; + readonly attributes: ReadonlyArray; /** Channel given to retrieve this product variant. Also used by federation gateway to resolve this object in a federated query. */ - channel?: Maybe; + readonly channel?: Maybe; /** * List of price information in channels for the product. * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - channelListings?: Maybe>; + readonly channelListings?: Maybe>; /** The date and time when the product variant was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** * Digital content for the product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - digitalContent?: Maybe; - /** - * External ID of this product. - * - * Added in Saleor 3.10. - */ - externalReference?: Maybe; + readonly digitalContent?: Maybe; + /** External ID of this product. */ + readonly externalReference?: Maybe; /** The ID of the product variant. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * List of images for the product variant. - * @deprecated This field will be removed in Saleor 4.0. Use the `media` field instead. + * @deprecated Use the `media` field instead. */ - images?: Maybe>; + readonly images?: Maybe>; /** Gross margin percentage value. */ - margin?: Maybe; + readonly margin?: Maybe; /** List of media for the product variant. */ - media?: Maybe>; + readonly media?: Maybe>; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** The name of the product variant. */ - name: Scalars['String']; - /** - * Preorder data for product variant. - * - * Added in Saleor 3.1. - */ - preorder?: Maybe; + readonly name: Scalars['String']; + /** Preorder data for product variant. */ + readonly preorder?: Maybe; /** Lists the storefront variant's pricing, the current price and discounts, only meant for displaying. */ - pricing?: Maybe; + readonly pricing?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** The product to which the variant belongs. */ - product: Product; + readonly product: Product; /** Quantity of a product available for sale in one checkout. Field value will be `null` when no `limitQuantityPerCheckout` in global settings has been set, and `productVariant` stocks are not tracked. */ - quantityAvailable?: Maybe; + readonly quantityAvailable?: Maybe; /** The maximum quantity of this variant that a customer can purchase. */ - quantityLimitPerCustomer?: Maybe; + readonly quantityLimitPerCustomer?: Maybe; /** * Total quantity ordered. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - quantityOrdered?: Maybe; + readonly quantityOrdered?: Maybe; /** * Total revenue generated by a variant in given period of time. Note: this field should be queried using `reportProductSales` query as it uses optimizations suitable for such calculations. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - revenue?: Maybe; + readonly revenue?: Maybe; /** The SKU (stock keeping unit) of the product variant. */ - sku?: Maybe; + readonly sku?: Maybe; /** * Stocks for the product variant. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. */ - stocks?: Maybe>; + readonly stocks?: Maybe>; /** Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. */ - trackInventory: Scalars['Boolean']; + readonly trackInventory: Scalars['Boolean']; /** Returns translated product variant fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** The date and time when the product variant was last updated. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; /** The weight of the product variant. */ - weight?: Maybe; + readonly weight?: Maybe; }; @@ -21978,7 +19739,7 @@ export type ProductVariantMetafieldArgs = { /** Represents a version of a product such as different size or color. */ export type ProductVariantMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -21996,7 +19757,7 @@ export type ProductVariantPrivateMetafieldArgs = { /** Represents a version of a product such as different size or color. */ export type ProductVariantPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -22025,33 +19786,24 @@ export type ProductVariantTranslationArgs = { languageCode: LanguageCodeEnum; }; -/** - * Event sent when product variant is back in stock. - * - * Added in Saleor 3.2. - */ +/** Event sent when product variant is back in stock. */ export type ProductVariantBackInStock = Event & { - __typename?: 'ProductVariantBackInStock'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product variant the event relates to. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** Look up a warehouse. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; -/** - * Event sent when product variant is back in stock. - * - * Added in Saleor 3.2. - */ +/** Event sent when product variant is back in stock. */ export type ProductVariantBackInStockProductVariantArgs = { channel?: InputMaybe; }; @@ -22062,67 +19814,50 @@ export type ProductVariantBackInStockProductVariantArgs = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantBulkCreate = { - __typename?: 'ProductVariantBulkCreate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - bulkProductErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly bulkProductErrors: ReadonlyArray; /** Returns how many objects were created. */ - count: Scalars['Int']; - errors: Array; - /** List of the created variants.This field will be removed in Saleor 4.0. */ - productVariants: Array; - /** - * List of the created variants. - * - * Added in Saleor 3.11. - */ - results: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** List of the created variants. */ + readonly productVariants: ReadonlyArray; + /** List of the created variants. */ + readonly results: ReadonlyArray; }; export type ProductVariantBulkCreateInput = { /** List of attributes specific to this variant. */ - attributes: Array; + readonly attributes: ReadonlyArray; /** List of prices assigned to channels. */ - channelListings?: InputMaybe>; + readonly channelListings?: InputMaybe>; + /** External ID of this product variant. */ + readonly externalReference?: InputMaybe; /** - * External ID of this product variant. + * Fields required to update the product variant metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.10. + * Warning: never store sensitive information, including financial data such as credit card details. */ - externalReference?: InputMaybe; - /** - * Fields required to update the product variant metadata. - * - * Added in Saleor 3.8. - */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Variant name. */ - name?: InputMaybe; - /** - * Determines if variant is in preorder. - * - * Added in Saleor 3.1. - */ - preorder?: InputMaybe; - /** - * Fields required to update the product variant private metadata. - * - * Added in Saleor 3.8. - */ - privateMetadata?: InputMaybe>; + readonly name?: InputMaybe; + /** Determines if variant is in preorder. */ + readonly preorder?: InputMaybe; /** - * Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. + * Fields required to update the product variant private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.1. + * Warning: never store sensitive information, including financial data such as credit card details. */ - quantityLimitPerCustomer?: InputMaybe; + readonly privateMetadata?: InputMaybe>; + /** Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. */ + readonly quantityLimitPerCustomer?: InputMaybe; /** Stock keeping unit. */ - sku?: InputMaybe; + readonly sku?: InputMaybe; /** Stocks of a product available for sale. */ - stocks?: InputMaybe>; + readonly stocks?: InputMaybe>; /** Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. */ - trackInventory?: InputMaybe; + readonly trackInventory?: InputMaybe; /** Weight of the Product Variant. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; /** @@ -22131,81 +19866,62 @@ export type ProductVariantBulkCreateInput = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantBulkDelete = { - __typename?: 'ProductVariantBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; export type ProductVariantBulkError = { - __typename?: 'ProductVariantBulkError'; /** List of attributes IDs which causes the error. */ - attributes?: Maybe>; + readonly attributes?: Maybe>; /** List of channel listings IDs which causes the error. */ - channelListings?: Maybe>; - /** - * List of channel IDs which causes the error. - * - * Added in Saleor 3.12. - */ - channels?: Maybe>; + readonly channelListings?: Maybe>; + /** List of channel IDs which causes the error. */ + readonly channels?: Maybe>; /** The error code. */ - code: ProductVariantBulkErrorCode; + readonly code: ProductVariantBulkErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; - /** - * Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - * - * Added in Saleor 3.14. - */ - path?: Maybe; - /** - * List of stocks IDs which causes the error. - * - * Added in Saleor 3.12. - */ - stocks?: Maybe>; + readonly message?: Maybe; + /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ + readonly path?: Maybe; + /** List of stocks IDs which causes the error. */ + readonly stocks?: Maybe>; /** List of attribute values IDs which causes the error. */ - values?: Maybe>; + readonly values?: Maybe>; /** List of warehouse IDs which causes the error. */ - warehouses?: Maybe>; -}; - -/** An enumeration. */ -export type ProductVariantBulkErrorCode = - | 'ATTRIBUTE_ALREADY_ASSIGNED' - | 'ATTRIBUTE_CANNOT_BE_ASSIGNED' - | 'ATTRIBUTE_VARIANTS_DISABLED' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_PRICE' - | 'NOT_FOUND' - | 'NOT_PRODUCTS_VARIANT' - | 'PRODUCT_NOT_ASSIGNED_TO_CHANNEL' - | 'REQUIRED' - | 'STOCK_ALREADY_EXISTS' - | 'UNIQUE'; + readonly warehouses?: Maybe>; +}; + +export enum ProductVariantBulkErrorCode { + AttributeAlreadyAssigned = 'ATTRIBUTE_ALREADY_ASSIGNED', + AttributeCannotBeAssigned = 'ATTRIBUTE_CANNOT_BE_ASSIGNED', + AttributeVariantsDisabled = 'ATTRIBUTE_VARIANTS_DISABLED', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidPrice = 'INVALID_PRICE', + NotFound = 'NOT_FOUND', + NotProductsVariant = 'NOT_PRODUCTS_VARIANT', + ProductNotAssignedToChannel = 'PRODUCT_NOT_ASSIGNED_TO_CHANNEL', + Required = 'REQUIRED', + StockAlreadyExists = 'STOCK_ALREADY_EXISTS', + Unique = 'UNIQUE' +} export type ProductVariantBulkResult = { - __typename?: 'ProductVariantBulkResult'; /** List of errors occurred on create attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; /** Product variant data. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; }; /** * Creates/updates translations for products variants. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. * * Triggers the following webhook events: @@ -22213,165 +19929,132 @@ export type ProductVariantBulkResult = { * - TRANSLATION_UPDATED (async): A translation was updated. */ export type ProductVariantBulkTranslate = { - __typename?: 'ProductVariantBulkTranslate'; /** Returns how many translations were created/updated. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the translations. */ - results: Array; + readonly results: ReadonlyArray; }; export type ProductVariantBulkTranslateError = { - __typename?: 'ProductVariantBulkTranslateError'; /** The error code. */ - code: ProductVariantTranslateErrorCode; + readonly code: ProductVariantTranslateErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; + readonly path?: Maybe; }; export type ProductVariantBulkTranslateInput = { /** External reference of a product variant. */ - externalReference?: InputMaybe; + readonly externalReference?: InputMaybe; /** Product variant ID. */ - id?: InputMaybe; + readonly id?: InputMaybe; /** Translation language code. */ - languageCode: LanguageCodeEnum; + readonly languageCode: LanguageCodeEnum; /** Translation fields. */ - translationFields: NameTranslationInput; + readonly translationFields: NameTranslationInput; }; export type ProductVariantBulkTranslateResult = { - __typename?: 'ProductVariantBulkTranslateResult'; /** List of errors occurred on translation attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; /** Product variant translation data. */ - translation?: Maybe; + readonly translation?: Maybe; }; /** * Update multiple product variants. * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantBulkUpdate = { - __typename?: 'ProductVariantBulkUpdate'; /** Returns how many objects were updated. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the updated variants. */ - results: Array; + readonly results: ReadonlyArray; }; -/** - * Input fields to update product variants. - * - * Added in Saleor 3.11. - */ +/** Input fields to update product variants. */ export type ProductVariantBulkUpdateInput = { /** List of attributes specific to this variant. */ - attributes?: InputMaybe>; - /** - * Channel listings input. - * - * Added in Saleor 3.12. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - channelListings?: InputMaybe; - /** - * External ID of this product variant. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly attributes?: InputMaybe>; + /** Channel listings input. */ + readonly channelListings?: InputMaybe; + /** External ID of this product variant. */ + readonly externalReference?: InputMaybe; /** ID of the product variant to update. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** - * Fields required to update the product variant metadata. + * Fields required to update the product variant metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Variant name. */ - name?: InputMaybe; + readonly name?: InputMaybe; + /** Determines if variant is in preorder. */ + readonly preorder?: InputMaybe; /** - * Determines if variant is in preorder. + * Fields required to update the product variant private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.1. + * Warning: never store sensitive information, including financial data such as credit card details. */ - preorder?: InputMaybe; - /** - * Fields required to update the product variant private metadata. - * - * Added in Saleor 3.8. - */ - privateMetadata?: InputMaybe>; - /** - * Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - * - * Added in Saleor 3.1. - */ - quantityLimitPerCustomer?: InputMaybe; + readonly privateMetadata?: InputMaybe>; + /** Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. */ + readonly quantityLimitPerCustomer?: InputMaybe; /** Stock keeping unit. */ - sku?: InputMaybe; - /** - * Stocks input. - * - * Added in Saleor 3.12. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - stocks?: InputMaybe; + readonly sku?: InputMaybe; + /** Stocks input. */ + readonly stocks?: InputMaybe; /** Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. */ - trackInventory?: InputMaybe; + readonly trackInventory?: InputMaybe; /** Weight of the Product Variant. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; /** Represents product variant channel listing. */ export type ProductVariantChannelListing = Node & { - __typename?: 'ProductVariantChannelListing'; /** The channel to which the variant listing belongs. */ - channel: Channel; + readonly channel: Channel; /** Cost price of the variant. */ - costPrice?: Maybe; + readonly costPrice?: Maybe; /** The ID of the variant channel listing. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Gross margin percentage value. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - margin?: Maybe; + readonly margin?: Maybe; + /** Preorder variant data. */ + readonly preorderThreshold?: Maybe; + /** The price of the variant. */ + readonly price?: Maybe; /** - * Preorder variant data. + * Prior price of the variant used for discount calculations. * - * Added in Saleor 3.1. + * Added in Saleor 3.21. */ - preorderThreshold?: Maybe; - /** The price of the variant. */ - price?: Maybe; + readonly priorPrice?: Maybe; }; export type ProductVariantChannelListingAddInput = { /** ID of a channel. */ - channelId: Scalars['ID']; + readonly channelId: Scalars['ID']; /** Cost price of the variant in channel. */ - costPrice?: InputMaybe; + readonly costPrice?: InputMaybe; + /** The threshold for preorder variant in channel. */ + readonly preorderThreshold?: InputMaybe; + /** Price of the particular variant in channel. */ + readonly price: Scalars['PositiveDecimal']; /** - * The threshold for preorder variant in channel. + * Previous price of the variant in channel. Useful for providing promotion information required by customer protection laws such as EU Omnibus directive. * - * Added in Saleor 3.1. + * Added in Saleor 3.21. */ - preorderThreshold?: InputMaybe; - /** Price of the particular variant in channel. */ - price: Scalars['PositiveDecimal']; + readonly priorPrice?: InputMaybe; }; /** @@ -22380,38 +20063,35 @@ export type ProductVariantChannelListingAddInput = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantChannelListingUpdate = { - __typename?: 'ProductVariantChannelListingUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productChannelListingErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productChannelListingErrors: ReadonlyArray; /** An updated product variant instance. */ - variant?: Maybe; + readonly variant?: Maybe; }; export type ProductVariantChannelListingUpdateInput = { /** List of channels to create variant channel listings. */ - create?: InputMaybe>; + readonly create?: InputMaybe>; /** List of channel listings to remove. */ - remove?: InputMaybe>; + readonly remove?: InputMaybe>; /** List of channel listings to update. */ - update?: InputMaybe>; + readonly update?: InputMaybe>; }; export type ProductVariantCountableConnection = { - __typename?: 'ProductVariantCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type ProductVariantCountableEdge = { - __typename?: 'ProductVariantCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: ProductVariant; + readonly node: ProductVariant; }; /** @@ -22420,85 +20100,63 @@ export type ProductVariantCountableEdge = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantCreate = { - __typename?: 'ProductVariantCreate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - productVariant?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly productVariant?: Maybe; }; export type ProductVariantCreateInput = { /** List of attributes specific to this variant. */ - attributes: Array; + readonly attributes: ReadonlyArray; + /** External ID of this product variant. */ + readonly externalReference?: InputMaybe; /** - * External ID of this product variant. + * Fields required to update the product variant metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.10. + * Warning: never store sensitive information, including financial data such as credit card details. */ - externalReference?: InputMaybe; - /** - * Fields required to update the product variant metadata. - * - * Added in Saleor 3.8. - */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Variant name. */ - name?: InputMaybe; + readonly name?: InputMaybe; + /** Determines if variant is in preorder. */ + readonly preorder?: InputMaybe; /** - * Determines if variant is in preorder. + * Fields required to update the product variant private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.1. + * Warning: never store sensitive information, including financial data such as credit card details. */ - preorder?: InputMaybe; - /** - * Fields required to update the product variant private metadata. - * - * Added in Saleor 3.8. - */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** Product ID of which type is the variant. */ - product: Scalars['ID']; - /** - * Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - * - * Added in Saleor 3.1. - */ - quantityLimitPerCustomer?: InputMaybe; + readonly product: Scalars['ID']; + /** Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. */ + readonly quantityLimitPerCustomer?: InputMaybe; /** Stock keeping unit. */ - sku?: InputMaybe; + readonly sku?: InputMaybe; /** Stocks of a product available for sale. */ - stocks?: InputMaybe>; + readonly stocks?: InputMaybe>; /** Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. */ - trackInventory?: InputMaybe; + readonly trackInventory?: InputMaybe; /** Weight of the Product Variant. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; -/** - * Event sent when new product variant is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new product variant is created. */ export type ProductVariantCreated = Event & { - __typename?: 'ProductVariantCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product variant the event relates to. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when new product variant is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new product variant is created. */ export type ProductVariantCreatedProductVariantArgs = { channel?: InputMaybe; }; @@ -22509,149 +20167,109 @@ export type ProductVariantCreatedProductVariantArgs = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantDelete = { - __typename?: 'ProductVariantDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - productVariant?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly productVariant?: Maybe; }; -/** - * Event sent when product variant is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when product variant is deleted. */ export type ProductVariantDeleted = Event & { - __typename?: 'ProductVariantDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product variant the event relates to. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when product variant is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when product variant is deleted. */ export type ProductVariantDeletedProductVariantArgs = { channel?: InputMaybe; }; export type ProductVariantFilterInput = { - isPreorder?: InputMaybe; - metadata?: InputMaybe>; - search?: InputMaybe; - sku?: InputMaybe>; - updatedAt?: InputMaybe; + readonly isPreorder?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; + readonly sku?: InputMaybe>; + readonly updatedAt?: InputMaybe; }; export type ProductVariantInput = { /** List of attributes specific to this variant. */ - attributes?: InputMaybe>; - /** - * External ID of this product variant. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly attributes?: InputMaybe>; + /** External ID of this product variant. */ + readonly externalReference?: InputMaybe; /** - * Fields required to update the product variant metadata. + * Fields required to update the product variant metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.8. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Variant name. */ - name?: InputMaybe; - /** - * Determines if variant is in preorder. - * - * Added in Saleor 3.1. - */ - preorder?: InputMaybe; - /** - * Fields required to update the product variant private metadata. - * - * Added in Saleor 3.8. - */ - privateMetadata?: InputMaybe>; + readonly name?: InputMaybe; + /** Determines if variant is in preorder. */ + readonly preorder?: InputMaybe; /** - * Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. + * Fields required to update the product variant private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.1. + * Warning: never store sensitive information, including financial data such as credit card details. */ - quantityLimitPerCustomer?: InputMaybe; + readonly privateMetadata?: InputMaybe>; + /** Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. */ + readonly quantityLimitPerCustomer?: InputMaybe; /** Stock keeping unit. */ - sku?: InputMaybe; + readonly sku?: InputMaybe; /** Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. */ - trackInventory?: InputMaybe; + readonly trackInventory?: InputMaybe; /** Weight of the Product Variant. */ - weight?: InputMaybe; + readonly weight?: InputMaybe; }; -/** - * Event sent when product variant metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when product variant metadata is updated. */ export type ProductVariantMetadataUpdated = Event & { - __typename?: 'ProductVariantMetadataUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product variant the event relates to. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when product variant metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when product variant metadata is updated. */ export type ProductVariantMetadataUpdatedProductVariantArgs = { channel?: InputMaybe; }; -/** - * Event sent when product variant is out of stock. - * - * Added in Saleor 3.2. - */ +/** Event sent when product variant is out of stock. */ export type ProductVariantOutOfStock = Event & { - __typename?: 'ProductVariantOutOfStock'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product variant the event relates to. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** Look up a warehouse. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; -/** - * Event sent when product variant is out of stock. - * - * Added in Saleor 3.2. - */ +/** Event sent when product variant is out of stock. */ export type ProductVariantOutOfStockProductVariantArgs = { channel?: InputMaybe; }; @@ -22659,15 +20277,12 @@ export type ProductVariantOutOfStockProductVariantArgs = { /** * Deactivates product variant preorder. It changes all preorder allocation into regular allocation. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantPreorderDeactivate = { - __typename?: 'ProductVariantPreorderDeactivate'; - errors: Array; + readonly errors: ReadonlyArray; /** Product variant with ended preorder. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; }; /** @@ -22676,11 +20291,10 @@ export type ProductVariantPreorderDeactivate = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantReorder = { - __typename?: 'ProductVariantReorder'; - errors: Array; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; /** @@ -22689,12 +20303,11 @@ export type ProductVariantReorder = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantReorderAttributeValues = { - __typename?: 'ProductVariantReorderAttributeValues'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; /** Product variant from which attribute values are reordered. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; }; /** @@ -22703,55 +20316,42 @@ export type ProductVariantReorderAttributeValues = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantSetDefault = { - __typename?: 'ProductVariantSetDefault'; - errors: Array; - product?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; + readonly errors: ReadonlyArray; + readonly product?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; }; -export type ProductVariantSortField = +export enum ProductVariantSortField { /** Sort products variants by last modified at. */ - | 'LAST_MODIFIED_AT'; + LastModifiedAt = 'LAST_MODIFIED_AT' +} export type ProductVariantSortingInput = { /** Specifies the direction in which to sort productVariants. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort productVariants by the selected field. */ - field: ProductVariantSortField; + readonly field: ProductVariantSortField; }; -/** - * Event sent when product variant stock is updated. - * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when product variant stock is updated. */ export type ProductVariantStockUpdated = Event & { - __typename?: 'ProductVariantStockUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product variant the event relates to. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** Look up a warehouse. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; -/** - * Event sent when product variant stock is updated. - * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when product variant stock is updated. */ export type ProductVariantStockUpdatedProductVariantArgs = { channel?: InputMaybe; }; @@ -22762,12 +20362,11 @@ export type ProductVariantStockUpdatedProductVariantArgs = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantStocksCreate = { - __typename?: 'ProductVariantStocksCreate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - bulkStockErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly bulkStockErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Updated product variant. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; }; /** @@ -22776,12 +20375,11 @@ export type ProductVariantStocksCreate = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantStocksDelete = { - __typename?: 'ProductVariantStocksDelete'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated product variant. */ - productVariant?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - stockErrors: Array; + readonly productVariant?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly stockErrors: ReadonlyArray; }; /** @@ -22790,45 +20388,39 @@ export type ProductVariantStocksDelete = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantStocksUpdate = { - __typename?: 'ProductVariantStocksUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - bulkStockErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly bulkStockErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Updated product variant. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; }; export type ProductVariantStocksUpdateInput = { /** List of warehouses to create stocks. */ - create?: InputMaybe>; + readonly create?: InputMaybe>; /** List of stocks to remove. */ - remove?: InputMaybe>; + readonly remove?: InputMaybe>; /** List of stocks to update. */ - update?: InputMaybe>; + readonly update?: InputMaybe>; }; /** Represents product variant's original translatable fields and related translations. */ export type ProductVariantTranslatableContent = Node & { - __typename?: 'ProductVariantTranslatableContent'; /** List of product variant attribute values that can be translated. */ - attributeValues: Array; + readonly attributeValues: ReadonlyArray; /** The ID of the product variant translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the product variant to translate. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** * Represents a version of a product such as different size or color. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. - */ - productVariant?: Maybe; - /** - * The ID of the product variant to translate. - * - * Added in Saleor 3.14. + * @deprecated Get model fields from the root level queries. */ - productVariantId: Scalars['ID']; + readonly productVariant?: Maybe; + /** The ID of the product variant to translate. */ + readonly productVariantId: Scalars['ID']; /** Returns translated product variant fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -22843,35 +20435,29 @@ export type ProductVariantTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type ProductVariantTranslate = { - __typename?: 'ProductVariantTranslate'; - errors: Array; - productVariant?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly errors: ReadonlyArray; + readonly productVariant?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; -/** An enumeration. */ -export type ProductVariantTranslateErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum ProductVariantTranslateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} /** Represents product variant translations. */ export type ProductVariantTranslation = Node & { - __typename?: 'ProductVariantTranslation'; /** The ID of the product variant translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated product variant name. */ - name: Scalars['String']; - /** - * Represents the product variant fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly name: Scalars['String']; + /** Represents the product variant fields to translate. */ + readonly translatableContent?: Maybe; }; /** @@ -22880,156 +20466,127 @@ export type ProductVariantTranslation = Node & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type ProductVariantUpdate = { - __typename?: 'ProductVariantUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - productVariant?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly productVariant?: Maybe; }; -/** - * Event sent when product variant is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when product variant is updated. */ export type ProductVariantUpdated = Event & { - __typename?: 'ProductVariantUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The product variant the event relates to. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when product variant is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when product variant is updated. */ export type ProductVariantUpdatedProductVariantArgs = { channel?: InputMaybe; }; export type ProductVariantWhereInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; - ids?: InputMaybe>; - metadata?: InputMaybe>; + readonly OR?: InputMaybe>; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; }; export type ProductWhereInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; + readonly OR?: InputMaybe>; /** Filter by attributes associated with the product. */ - attributes?: InputMaybe>; + readonly attributes?: InputMaybe>; /** Filter by the date of availability for purchase. */ - availableFrom?: InputMaybe; + readonly availableFrom?: InputMaybe; /** Filter by product category. */ - category?: InputMaybe; + readonly category?: InputMaybe; /** Filter by collection. */ - collection?: InputMaybe; + readonly collection?: InputMaybe; /** Filter on whether product is a gift card or not. */ - giftCard?: InputMaybe; + readonly giftCard?: InputMaybe; /** Filter by product with category assigned. */ - hasCategory?: InputMaybe; + readonly hasCategory?: InputMaybe; /** Filter by product with preordered variants. */ - hasPreorderedVariants?: InputMaybe; - ids?: InputMaybe>; + readonly hasPreorderedVariants?: InputMaybe; + readonly ids?: InputMaybe>; /** Filter by availability for purchase. */ - isAvailable?: InputMaybe; + readonly isAvailable?: InputMaybe; /** Filter by public visibility. */ - isPublished?: InputMaybe; + readonly isPublished?: InputMaybe; /** Filter by visibility on the channel. */ - isVisibleInListing?: InputMaybe; - metadata?: InputMaybe>; + readonly isVisibleInListing?: InputMaybe; + readonly metadata?: InputMaybe>; /** Filter by the lowest variant price after discounts. */ - minimalPrice?: InputMaybe; + readonly minimalPrice?: InputMaybe; /** Filter by product name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Filter by product variant price. */ - price?: InputMaybe; + readonly price?: InputMaybe; /** Filter by product type. */ - productType?: InputMaybe; + readonly productType?: InputMaybe; /** Filter by the publication date. */ - publishedFrom?: InputMaybe; + readonly publishedFrom?: InputMaybe; /** Filter by product slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; /** Filter by variants having specific stock status. */ - stockAvailability?: InputMaybe; + readonly stockAvailability?: InputMaybe; /** Filter by stock of the product variant. */ - stocks?: InputMaybe; + readonly stocks?: InputMaybe; /** Filter by when was the most recent update. */ - updatedAt?: InputMaybe; + readonly updatedAt?: InputMaybe; }; -/** - * Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. */ export type Promotion = Node & ObjectWithMetadata & { - __typename?: 'Promotion'; /** Date time of promotion creation. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** Description of the promotion. */ - description?: Maybe; + readonly description?: Maybe; /** End date of the promotion. */ - endDate?: Maybe; + readonly endDate?: Maybe; /** The list of events associated with the promotion. */ - events?: Maybe>; - id: Scalars['ID']; + readonly events?: Maybe>; + readonly id: Scalars['ID']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Name of the promotion. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** The list of promotion rules. */ - rules?: Maybe>; + readonly rules?: Maybe>; /** Start date of the promotion. */ - startDate: Scalars['DateTime']; + readonly startDate: Scalars['DateTime']; /** Returns translated promotion fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** * The type of the promotion. Implicate if the discount is applied on catalogue or order level. * @@ -23037,67 +20594,37 @@ export type Promotion = Node & ObjectWithMetadata & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - type?: Maybe; + readonly type?: Maybe; /** Date time of last update of promotion. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; }; -/** - * Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. */ export type PromotionMetafieldArgs = { key: Scalars['String']; }; -/** - * Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. */ export type PromotionMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; -/** - * Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. */ export type PromotionPrivateMetafieldArgs = { key: Scalars['String']; }; -/** - * Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. */ export type PromotionPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; -/** - * Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. */ export type PromotionTranslationArgs = { languageCode: LanguageCodeEnum; }; @@ -23105,46 +20632,35 @@ export type PromotionTranslationArgs = { /** * Deletes promotions. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_DELETED (async): A promotion was deleted. */ export type PromotionBulkDelete = { - __typename?: 'PromotionBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; export type PromotionCountableConnection = { - __typename?: 'PromotionCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type PromotionCountableEdge = { - __typename?: 'PromotionCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Promotion; + readonly node: Promotion; }; /** * Creates a new promotion. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: @@ -23152,201 +20668,158 @@ export type PromotionCountableEdge = { * - PROMOTION_STARTED (async): Optionally called if promotion was started. */ export type PromotionCreate = { - __typename?: 'PromotionCreate'; - errors: Array; - promotion?: Maybe; + readonly errors: ReadonlyArray; + readonly promotion?: Maybe; }; export type PromotionCreateError = { - __typename?: 'PromotionCreateError'; /** The error code. */ - code: PromotionCreateErrorCode; + readonly code: PromotionCreateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** Limit of gifts assigned to promotion rule. */ - giftsLimit?: Maybe; + readonly giftsLimit?: Maybe; /** Number of gifts defined for this promotion rule exceeding the limit. */ - giftsLimitExceedBy?: Maybe; + readonly giftsLimitExceedBy?: Maybe; /** Index of an input list item that caused the error. */ - index?: Maybe; + readonly index?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Limit of rules with orderPredicate defined. */ - rulesLimit?: Maybe; + readonly rulesLimit?: Maybe; /** Number of rules with orderPredicate defined exceeding the limit. */ - rulesLimitExceedBy?: Maybe; -}; - -/** An enumeration. */ -export type PromotionCreateErrorCode = - | 'GIFTS_NUMBER_LIMIT' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_GIFT_TYPE' - | 'INVALID_PRECISION' - | 'MISSING_CHANNELS' - | 'MULTIPLE_CURRENCIES_NOT_ALLOWED' - | 'NOT_FOUND' - | 'REQUIRED' - | 'RULES_NUMBER_LIMIT'; + readonly rulesLimitExceedBy?: Maybe; +}; + +export enum PromotionCreateErrorCode { + GiftsNumberLimit = 'GIFTS_NUMBER_LIMIT', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidGiftType = 'INVALID_GIFT_TYPE', + InvalidPrecision = 'INVALID_PRECISION', + MissingChannels = 'MISSING_CHANNELS', + MultipleCurrenciesNotAllowed = 'MULTIPLE_CURRENCIES_NOT_ALLOWED', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + RulesNumberLimit = 'RULES_NUMBER_LIMIT' +} export type PromotionCreateInput = { /** Promotion description. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** The end date of the promotion in ISO 8601 format. */ - endDate?: InputMaybe; + readonly endDate?: InputMaybe; /** Promotion name. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of promotion rules. */ - rules?: InputMaybe>; + readonly rules?: InputMaybe>; /** The start date of the promotion in ISO 8601 format. */ - startDate?: InputMaybe; + readonly startDate?: InputMaybe; /** * Defines the promotion type. Implicate the required promotion rules predicate type and whether the promotion rules will give the catalogue or order discount. * * Added in Saleor 3.19. */ - type: PromotionTypeEnum; + readonly type: PromotionTypeEnum; }; -/** - * Event sent when new promotion is created. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when new promotion is created. */ export type PromotionCreated = Event & { - __typename?: 'PromotionCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The promotion the event relates to. */ - promotion?: Maybe; + readonly promotion?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * History log of the promotion created event. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** History log of the promotion created event. */ export type PromotionCreatedEvent = Node & PromotionEventInterface & { - __typename?: 'PromotionCreatedEvent'; /** * User or App that created the promotion event. * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. */ - createdBy?: Maybe; + readonly createdBy?: Maybe; /** Date when event happened. */ - date: Scalars['DateTime']; - id: Scalars['ID']; + readonly date: Scalars['DateTime']; + readonly id: Scalars['ID']; /** Promotion event type. */ - type: PromotionEventsEnum; + readonly type: PromotionEventsEnum; }; /** * Deletes a promotion. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_DELETED (async): A promotion was deleted. */ export type PromotionDelete = { - __typename?: 'PromotionDelete'; - errors: Array; - promotion?: Maybe; + readonly errors: ReadonlyArray; + readonly promotion?: Maybe; }; export type PromotionDeleteError = { - __typename?: 'PromotionDeleteError'; /** The error code. */ - code: PromotionDeleteErrorCode; + readonly code: PromotionDeleteErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PromotionDeleteErrorCode = - | 'GRAPHQL_ERROR' - | 'NOT_FOUND'; +export enum PromotionDeleteErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + NotFound = 'NOT_FOUND' +} -/** - * Event sent when promotion is deleted. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when promotion is deleted. */ export type PromotionDeleted = Event & { - __typename?: 'PromotionDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The promotion the event relates to. */ - promotion?: Maybe; + readonly promotion?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * The event informs about the end of the promotion. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** The event informs about the end of the promotion. */ export type PromotionEnded = Event & { - __typename?: 'PromotionEnded'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The promotion the event relates to. */ - promotion?: Maybe; + readonly promotion?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * History log of the promotion ended event. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** History log of the promotion ended event. */ export type PromotionEndedEvent = Node & PromotionEventInterface & { - __typename?: 'PromotionEndedEvent'; /** * User or App that created the promotion event. * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. */ - createdBy?: Maybe; + readonly createdBy?: Maybe; /** Date when event happened. */ - date: Scalars['DateTime']; - id: Scalars['ID']; + readonly date: Scalars['DateTime']; + readonly id: Scalars['ID']; /** Promotion event type. */ - type: PromotionEventsEnum; + readonly type: PromotionEventsEnum; }; export type PromotionEvent = PromotionCreatedEvent | PromotionEndedEvent | PromotionRuleCreatedEvent | PromotionRuleDeletedEvent | PromotionRuleUpdatedEvent | PromotionStartedEvent | PromotionUpdatedEvent; @@ -23357,43 +20830,36 @@ export type PromotionEventInterface = { * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. */ - createdBy?: Maybe; + readonly createdBy?: Maybe; /** Date when event happened. */ - date: Scalars['DateTime']; - id: Scalars['ID']; + readonly date: Scalars['DateTime']; + readonly id: Scalars['ID']; /** Promotion event type. */ - type: PromotionEventsEnum; + readonly type: PromotionEventsEnum; }; -/** An enumeration. */ -export type PromotionEventsEnum = - | 'PROMOTION_CREATED' - | 'PROMOTION_ENDED' - | 'PROMOTION_STARTED' - | 'PROMOTION_UPDATED' - | 'RULE_CREATED' - | 'RULE_DELETED' - | 'RULE_UPDATED'; +export enum PromotionEventsEnum { + PromotionCreated = 'PROMOTION_CREATED', + PromotionEnded = 'PROMOTION_ENDED', + PromotionStarted = 'PROMOTION_STARTED', + PromotionUpdated = 'PROMOTION_UPDATED', + RuleCreated = 'RULE_CREATED', + RuleDeleted = 'RULE_DELETED', + RuleUpdated = 'RULE_UPDATED' +} -/** - * Represents the promotion rule that specifies the conditions that must be met to apply the promotion discount. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the promotion rule that specifies the conditions that must be met to apply the promotion discount. */ export type PromotionRule = Node & { - __typename?: 'PromotionRule'; /** The catalogue predicate that must be met to apply the rule reward. */ - cataloguePredicate?: Maybe; + readonly cataloguePredicate?: Maybe; /** * List of channels where the rule applies. * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** Description of the promotion rule. */ - description?: Maybe; + readonly description?: Maybe; /** * Product variant IDs available as a gift to choose. * @@ -23401,7 +20867,7 @@ export type PromotionRule = Node & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - giftIds?: Maybe>; + readonly giftIds?: Maybe>; /** * Defines the maximum number of gifts to choose from the gifts list. * @@ -23409,10 +20875,10 @@ export type PromotionRule = Node & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - giftsLimit?: Maybe; - id: Scalars['ID']; + readonly giftsLimit?: Maybe; + readonly id: Scalars['ID']; /** Name of the promotion rule. */ - name?: Maybe; + readonly name?: Maybe; /** * The checkout/order predicate that must be met to apply the rule reward. * @@ -23420,7 +20886,7 @@ export type PromotionRule = Node & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderPredicate?: Maybe; + readonly orderPredicate?: Maybe; /** * The type of the predicate that must be met to apply the reward. * @@ -23428,9 +20894,9 @@ export type PromotionRule = Node & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - predicateType?: Maybe; + readonly predicateType?: Maybe; /** Promotion to which the rule belongs. */ - promotion?: Maybe; + readonly promotion?: Maybe; /** * The reward type of the promotion rule. * @@ -23438,7 +20904,7 @@ export type PromotionRule = Node & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - rewardType?: Maybe; + readonly rewardType?: Maybe; /** * The reward value of the promotion rule. Defines the discount value applied when the rule conditions are met. * @@ -23446,21 +20912,15 @@ export type PromotionRule = Node & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - rewardValue?: Maybe; + readonly rewardValue?: Maybe; /** The type of reward value of the promotion rule. */ - rewardValueType?: Maybe; + readonly rewardValueType?: Maybe; /** Returns translated promotion rule fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; -/** - * Represents the promotion rule that specifies the conditions that must be met to apply the promotion discount. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents the promotion rule that specifies the conditions that must be met to apply the promotion discount. */ export type PromotionRuleTranslationArgs = { languageCode: LanguageCodeEnum; }; @@ -23468,59 +20928,53 @@ export type PromotionRuleTranslationArgs = { /** * Creates a new promotion rule. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_RULE_CREATED (async): A promotion rule was created. */ export type PromotionRuleCreate = { - __typename?: 'PromotionRuleCreate'; - errors: Array; - promotionRule?: Maybe; + readonly errors: ReadonlyArray; + readonly promotionRule?: Maybe; }; export type PromotionRuleCreateError = { - __typename?: 'PromotionRuleCreateError'; /** The error code. */ - code: PromotionRuleCreateErrorCode; + readonly code: PromotionRuleCreateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** Limit of gifts assigned to promotion rule. */ - giftsLimit?: Maybe; + readonly giftsLimit?: Maybe; /** Number of gifts defined for this promotion rule exceeding the limit. */ - giftsLimitExceedBy?: Maybe; + readonly giftsLimitExceedBy?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Limit of rules with orderPredicate defined. */ - rulesLimit?: Maybe; + readonly rulesLimit?: Maybe; /** Number of rules with orderPredicate defined exceeding the limit. */ - rulesLimitExceedBy?: Maybe; -}; - -/** An enumeration. */ -export type PromotionRuleCreateErrorCode = - | 'GIFTS_NUMBER_LIMIT' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_GIFT_TYPE' - | 'INVALID_PRECISION' - | 'MISSING_CHANNELS' - | 'MULTIPLE_CURRENCIES_NOT_ALLOWED' - | 'NOT_FOUND' - | 'REQUIRED' - | 'RULES_NUMBER_LIMIT'; + readonly rulesLimitExceedBy?: Maybe; +}; + +export enum PromotionRuleCreateErrorCode { + GiftsNumberLimit = 'GIFTS_NUMBER_LIMIT', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidGiftType = 'INVALID_GIFT_TYPE', + InvalidPrecision = 'INVALID_PRECISION', + MissingChannels = 'MISSING_CHANNELS', + MultipleCurrenciesNotAllowed = 'MULTIPLE_CURRENCIES_NOT_ALLOWED', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + RulesNumberLimit = 'RULES_NUMBER_LIMIT' +} export type PromotionRuleCreateInput = { /** Defines the conditions on the catalogue level that must be met for the reward to be applied. */ - cataloguePredicate?: InputMaybe; + readonly cataloguePredicate?: InputMaybe; /** List of channel ids to which the rule should apply to. */ - channels?: InputMaybe>; + readonly channels?: InputMaybe>; /** Promotion rule description. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** * Product variant IDs available as a gift to choose. * @@ -23528,9 +20982,9 @@ export type PromotionRuleCreateInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - gifts?: InputMaybe>; + readonly gifts?: InputMaybe>; /** Promotion rule name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** * Defines the conditions on the checkout/draft order level that must be met for the reward to be applied. * @@ -23538,9 +20992,9 @@ export type PromotionRuleCreateInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderPredicate?: InputMaybe; + readonly orderPredicate?: InputMaybe; /** The ID of the promotion that rule belongs to. */ - promotion: Scalars['ID']; + readonly promotion: Scalars['ID']; /** * Defines the reward type of the promotion rule. * @@ -23548,155 +21002,115 @@ export type PromotionRuleCreateInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - rewardType?: InputMaybe; + readonly rewardType?: InputMaybe; /** Defines the discount value. Required when catalogue predicate is provided. */ - rewardValue?: InputMaybe; + readonly rewardValue?: InputMaybe; /** Defines the promotion rule reward value type. Must be provided together with reward value. */ - rewardValueType?: InputMaybe; + readonly rewardValueType?: InputMaybe; }; -/** - * Event sent when new promotion rule is created. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when new promotion rule is created. */ export type PromotionRuleCreated = Event & { - __typename?: 'PromotionRuleCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The promotion rule the event relates to. */ - promotionRule?: Maybe; + readonly promotionRule?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * History log of the promotion rule created event. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** History log of the promotion rule created event. */ export type PromotionRuleCreatedEvent = Node & PromotionEventInterface & PromotionRuleEventInterface & { - __typename?: 'PromotionRuleCreatedEvent'; /** * User or App that created the promotion event. * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. */ - createdBy?: Maybe; + readonly createdBy?: Maybe; /** Date when event happened. */ - date: Scalars['DateTime']; - id: Scalars['ID']; + readonly date: Scalars['DateTime']; + readonly id: Scalars['ID']; /** The rule ID associated with the promotion event. */ - ruleId?: Maybe; + readonly ruleId?: Maybe; /** Promotion event type. */ - type: PromotionEventsEnum; + readonly type: PromotionEventsEnum; }; /** * Deletes a promotion rule. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_RULE_DELETED (async): A promotion rule was deleted. */ export type PromotionRuleDelete = { - __typename?: 'PromotionRuleDelete'; - errors: Array; - promotionRule?: Maybe; + readonly errors: ReadonlyArray; + readonly promotionRule?: Maybe; }; export type PromotionRuleDeleteError = { - __typename?: 'PromotionRuleDeleteError'; /** The error code. */ - code: PromotionRuleDeleteErrorCode; + readonly code: PromotionRuleDeleteErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PromotionRuleDeleteErrorCode = - | 'GRAPHQL_ERROR' - | 'NOT_FOUND'; +export enum PromotionRuleDeleteErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + NotFound = 'NOT_FOUND' +} -/** - * Event sent when new promotion rule is deleted. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when new promotion rule is deleted. */ export type PromotionRuleDeleted = Event & { - __typename?: 'PromotionRuleDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The promotion rule the event relates to. */ - promotionRule?: Maybe; + readonly promotionRule?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * History log of the promotion rule created event. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** History log of the promotion rule created event. */ export type PromotionRuleDeletedEvent = Node & PromotionEventInterface & PromotionRuleEventInterface & { - __typename?: 'PromotionRuleDeletedEvent'; /** * User or App that created the promotion event. * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. */ - createdBy?: Maybe; + readonly createdBy?: Maybe; /** Date when event happened. */ - date: Scalars['DateTime']; - id: Scalars['ID']; + readonly date: Scalars['DateTime']; + readonly id: Scalars['ID']; /** The rule ID associated with the promotion event. */ - ruleId?: Maybe; + readonly ruleId?: Maybe; /** Promotion event type. */ - type: PromotionEventsEnum; + readonly type: PromotionEventsEnum; }; -/** - * History log of the promotion event related to rule. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** History log of the promotion event related to rule. */ export type PromotionRuleEventInterface = { /** The rule ID associated with the promotion event. */ - ruleId?: Maybe; + readonly ruleId?: Maybe; }; export type PromotionRuleInput = { /** Defines the conditions on the catalogue level that must be met for the reward to be applied. */ - cataloguePredicate?: InputMaybe; + readonly cataloguePredicate?: InputMaybe; /** List of channel ids to which the rule should apply to. */ - channels?: InputMaybe>; + readonly channels?: InputMaybe>; /** Promotion rule description. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** * Product variant IDs available as a gift to choose. * @@ -23704,9 +21118,9 @@ export type PromotionRuleInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - gifts?: InputMaybe>; + readonly gifts?: InputMaybe>; /** Promotion rule name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** * Defines the conditions on the checkout/draft order level that must be met for the reward to be applied. * @@ -23714,7 +21128,7 @@ export type PromotionRuleInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderPredicate?: InputMaybe; + readonly orderPredicate?: InputMaybe; /** * Defines the reward type of the promotion rule. * @@ -23722,46 +21136,33 @@ export type PromotionRuleInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - rewardType?: InputMaybe; + readonly rewardType?: InputMaybe; /** Defines the discount value. Required when catalogue predicate is provided. */ - rewardValue?: InputMaybe; + readonly rewardValue?: InputMaybe; /** Defines the promotion rule reward value type. Must be provided together with reward value. */ - rewardValueType?: InputMaybe; + readonly rewardValueType?: InputMaybe; }; -/** - * Represents promotion rule's original translatable fields and related translations. - * - * Added in Saleor 3.17. - */ +/** Represents promotion rule's original translatable fields and related translations. */ export type PromotionRuleTranslatableContent = Node & { - __typename?: 'PromotionRuleTranslatableContent'; /** * Description of the promotion rule. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** ID of the promotion rule translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the promotion rule. */ - name?: Maybe; - /** - * ID of the promotion rule to translate. - * - * Added in Saleor 3.14. - */ - promotionRuleId: Scalars['ID']; + readonly name?: Maybe; + /** ID of the promotion rule to translate. */ + readonly promotionRuleId: Scalars['ID']; /** Returns translated promotion rule fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; -/** - * Represents promotion rule's original translatable fields and related translations. - * - * Added in Saleor 3.17. - */ +/** Represents promotion rule's original translatable fields and related translations. */ export type PromotionRuleTranslatableContentTranslationArgs = { languageCode: LanguageCodeEnum; }; @@ -23769,41 +21170,29 @@ export type PromotionRuleTranslatableContentTranslationArgs = { /** * Creates/updates translations for a promotion rule. * - * Added in Saleor 3.17. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type PromotionRuleTranslate = { - __typename?: 'PromotionRuleTranslate'; - errors: Array; - promotionRule?: Maybe; + readonly errors: ReadonlyArray; + readonly promotionRule?: Maybe; }; -/** - * Represents promotion rule translations. - * - * Added in Saleor 3.17. - */ +/** Represents promotion rule translations. */ export type PromotionRuleTranslation = Node & { - __typename?: 'PromotionRuleTranslation'; /** * Translated description of the promotion rule. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** ID of the promotion rule translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated name of the promotion rule. */ - name?: Maybe; - /** - * Represents the promotion rule fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly name?: Maybe; + /** Represents the promotion rule fields to translate. */ + readonly translatableContent?: Maybe; }; export type PromotionRuleTranslationInput = { @@ -23812,60 +21201,54 @@ export type PromotionRuleTranslationInput = { * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; - name?: InputMaybe; + readonly description?: InputMaybe; + readonly name?: InputMaybe; }; /** * Updates an existing promotion rule. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - PROMOTION_RULE_UPDATED (async): A promotion rule was updated. */ export type PromotionRuleUpdate = { - __typename?: 'PromotionRuleUpdate'; - errors: Array; - promotionRule?: Maybe; + readonly errors: ReadonlyArray; + readonly promotionRule?: Maybe; }; export type PromotionRuleUpdateError = { - __typename?: 'PromotionRuleUpdateError'; /** List of channel IDs which causes the error. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** The error code. */ - code: PromotionRuleUpdateErrorCode; + readonly code: PromotionRuleUpdateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** Limit of gifts assigned to promotion rule. */ - giftsLimit?: Maybe; + readonly giftsLimit?: Maybe; /** Number of gifts defined for this promotion rule exceeding the limit. */ - giftsLimitExceedBy?: Maybe; + readonly giftsLimitExceedBy?: Maybe; /** The error message. */ - message?: Maybe; -}; - -/** An enumeration. */ -export type PromotionRuleUpdateErrorCode = - | 'DUPLICATED_INPUT_ITEM' - | 'GIFTS_NUMBER_LIMIT' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_GIFT_TYPE' - | 'INVALID_PRECISION' - | 'MISSING_CHANNELS' - | 'MULTIPLE_CURRENCIES_NOT_ALLOWED' - | 'NOT_FOUND' - | 'REQUIRED'; + readonly message?: Maybe; +}; + +export enum PromotionRuleUpdateErrorCode { + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GiftsNumberLimit = 'GIFTS_NUMBER_LIMIT', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidGiftType = 'INVALID_GIFT_TYPE', + InvalidPrecision = 'INVALID_PRECISION', + MissingChannels = 'MISSING_CHANNELS', + MultipleCurrenciesNotAllowed = 'MULTIPLE_CURRENCIES_NOT_ALLOWED', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} export type PromotionRuleUpdateInput = { /** List of channel ids to add. */ - addChannels?: InputMaybe>; + readonly addChannels?: InputMaybe>; /** * List of variant IDs available as a gift to add. * @@ -23873,13 +21256,13 @@ export type PromotionRuleUpdateInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - addGifts?: InputMaybe>; + readonly addGifts?: InputMaybe>; /** Defines the conditions on the catalogue level that must be met for the reward to be applied. */ - cataloguePredicate?: InputMaybe; + readonly cataloguePredicate?: InputMaybe; /** Promotion rule description. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** Promotion rule name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** * Defines the conditions on the checkout/draft order level that must be met for the reward to be applied. * @@ -23887,9 +21270,9 @@ export type PromotionRuleUpdateInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderPredicate?: InputMaybe; + readonly orderPredicate?: InputMaybe; /** List of channel ids to remove. */ - removeChannels?: InputMaybe>; + readonly removeChannels?: InputMaybe>; /** * List of variant IDs available as a gift to remove. * @@ -23897,7 +21280,7 @@ export type PromotionRuleUpdateInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - removeGifts?: InputMaybe>; + readonly removeGifts?: InputMaybe>; /** * Defines the reward type of the promotion rule. * @@ -23905,147 +21288,111 @@ export type PromotionRuleUpdateInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - rewardType?: InputMaybe; + readonly rewardType?: InputMaybe; /** Defines the discount value. Required when catalogue predicate is provided. */ - rewardValue?: InputMaybe; + readonly rewardValue?: InputMaybe; /** Defines the promotion rule reward value type. Must be provided together with reward value. */ - rewardValueType?: InputMaybe; + readonly rewardValueType?: InputMaybe; }; -/** - * Event sent when new promotion rule is updated. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when new promotion rule is updated. */ export type PromotionRuleUpdated = Event & { - __typename?: 'PromotionRuleUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The promotion rule the event relates to. */ - promotionRule?: Maybe; + readonly promotionRule?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * History log of the promotion rule created event. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** History log of the promotion rule created event. */ export type PromotionRuleUpdatedEvent = Node & PromotionEventInterface & PromotionRuleEventInterface & { - __typename?: 'PromotionRuleUpdatedEvent'; /** * User or App that created the promotion event. * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. */ - createdBy?: Maybe; + readonly createdBy?: Maybe; /** Date when event happened. */ - date: Scalars['DateTime']; - id: Scalars['ID']; + readonly date: Scalars['DateTime']; + readonly id: Scalars['ID']; /** The rule ID associated with the promotion event. */ - ruleId?: Maybe; + readonly ruleId?: Maybe; /** Promotion event type. */ - type: PromotionEventsEnum; + readonly type: PromotionEventsEnum; }; -export type PromotionSortField = +export enum PromotionSortField { /** Sort promotions by created at. */ - | 'CREATED_AT' + CreatedAt = 'CREATED_AT', /** Sort promotions by end date. */ - | 'END_DATE' + EndDate = 'END_DATE', /** Sort promotions by name. */ - | 'NAME' + Name = 'NAME', /** Sort promotions by start date. */ - | 'START_DATE'; + StartDate = 'START_DATE' +} export type PromotionSortingInput = { /** Specifies the direction in which to sort promotions. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort promotions by the selected field. */ - field: PromotionSortField; + readonly field: PromotionSortField; }; -/** - * The event informs about the start of the promotion. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** The event informs about the start of the promotion. */ export type PromotionStarted = Event & { - __typename?: 'PromotionStarted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The promotion the event relates to. */ - promotion?: Maybe; + readonly promotion?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * History log of the promotion started event. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** History log of the promotion started event. */ export type PromotionStartedEvent = Node & PromotionEventInterface & { - __typename?: 'PromotionStartedEvent'; /** * User or App that created the promotion event. * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. */ - createdBy?: Maybe; + readonly createdBy?: Maybe; /** Date when event happened. */ - date: Scalars['DateTime']; - id: Scalars['ID']; + readonly date: Scalars['DateTime']; + readonly id: Scalars['ID']; /** Promotion event type. */ - type: PromotionEventsEnum; + readonly type: PromotionEventsEnum; }; -/** - * Represents promotion's original translatable fields and related translations. - * - * Added in Saleor 3.17. - */ +/** Represents promotion's original translatable fields and related translations. */ export type PromotionTranslatableContent = Node & { - __typename?: 'PromotionTranslatableContent'; /** * Description of the promotion. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** ID of the promotion translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the promotion. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** ID of the promotion to translate. */ - promotionId: Scalars['ID']; + readonly promotionId: Scalars['ID']; /** Returns translated promotion fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; -/** - * Represents promotion's original translatable fields and related translations. - * - * Added in Saleor 3.17. - */ +/** Represents promotion's original translatable fields and related translations. */ export type PromotionTranslatableContentTranslationArgs = { languageCode: LanguageCodeEnum; }; @@ -24053,41 +21400,29 @@ export type PromotionTranslatableContentTranslationArgs = { /** * Creates/updates translations for a promotion. * - * Added in Saleor 3.17. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type PromotionTranslate = { - __typename?: 'PromotionTranslate'; - errors: Array; - promotion?: Maybe; + readonly errors: ReadonlyArray; + readonly promotion?: Maybe; }; -/** - * Represents promotion translations. - * - * Added in Saleor 3.17. - */ +/** Represents promotion translations. */ export type PromotionTranslation = Node & { - __typename?: 'PromotionTranslation'; /** * Translated description of the promotion. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** ID of the promotion translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated name of the promotion. */ - name?: Maybe; - /** - * Represents the promotion fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly name?: Maybe; + /** Represents the promotion fields to translate. */ + readonly translatableContent?: Maybe; }; export type PromotionTranslationInput = { @@ -24096,29 +21431,25 @@ export type PromotionTranslationInput = { * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; - name?: InputMaybe; + readonly description?: InputMaybe; + readonly name?: InputMaybe; }; -/** An enumeration. */ -export type PromotionTypeEnum = - | 'CATALOGUE' - | 'ORDER'; +export enum PromotionTypeEnum { + Catalogue = 'CATALOGUE', + Order = 'ORDER' +} export type PromotionTypeEnumFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; }; /** * Updates an existing promotion. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: @@ -24127,558 +21458,508 @@ export type PromotionTypeEnumFilterInput = { * - PROMOTION_ENDED (async): Optionally called if promotion was ended. */ export type PromotionUpdate = { - __typename?: 'PromotionUpdate'; - errors: Array; - promotion?: Maybe; + readonly errors: ReadonlyArray; + readonly promotion?: Maybe; }; export type PromotionUpdateError = { - __typename?: 'PromotionUpdateError'; /** The error code. */ - code: PromotionUpdateErrorCode; + readonly code: PromotionUpdateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type PromotionUpdateErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum PromotionUpdateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} export type PromotionUpdateInput = { /** Promotion description. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** The end date of the promotion in ISO 8601 format. */ - endDate?: InputMaybe; + readonly endDate?: InputMaybe; /** Promotion name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** The start date of the promotion in ISO 8601 format. */ - startDate?: InputMaybe; + readonly startDate?: InputMaybe; }; -/** - * Event sent when promotion is updated. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when promotion is updated. */ export type PromotionUpdated = Event & { - __typename?: 'PromotionUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The promotion the event relates to. */ - promotion?: Maybe; + readonly promotion?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * History log of the promotion updated event. - * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** History log of the promotion updated event. */ export type PromotionUpdatedEvent = Node & PromotionEventInterface & { - __typename?: 'PromotionUpdatedEvent'; /** * User or App that created the promotion event. * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. */ - createdBy?: Maybe; + readonly createdBy?: Maybe; /** Date when event happened. */ - date: Scalars['DateTime']; - id: Scalars['ID']; + readonly date: Scalars['DateTime']; + readonly id: Scalars['ID']; /** Promotion event type. */ - type: PromotionEventsEnum; + readonly type: PromotionEventsEnum; }; export type PromotionWhereInput = { /** List of conditions that must be met. */ - AND?: InputMaybe>; + readonly AND?: InputMaybe>; /** A list of conditions of which at least one must be met. */ - OR?: InputMaybe>; + readonly OR?: InputMaybe>; /** Filter promotions by end date. */ - endDate?: InputMaybe; - ids?: InputMaybe>; - isOldSale?: InputMaybe; - metadata?: InputMaybe>; + readonly endDate?: InputMaybe; + readonly ids?: InputMaybe>; + readonly isOldSale?: InputMaybe; + readonly metadata?: InputMaybe>; /** Filter by promotion name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Filter promotions by start date. */ - startDate?: InputMaybe; - type?: InputMaybe; + readonly startDate?: InputMaybe; + readonly type?: InputMaybe; }; export type PublishableChannelListingInput = { /** ID of a channel. */ - channelId: Scalars['ID']; + readonly channelId: Scalars['ID']; /** Determines if object is visible to customers. */ - isPublished?: InputMaybe; + readonly isPublished?: InputMaybe; /** * Publication date. ISO 8601 standard. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. + * @deprecated Use `publishedAt` field instead. */ - publicationDate?: InputMaybe; - /** - * Publication date time. ISO 8601 standard. - * - * Added in Saleor 3.3. - */ - publishedAt?: InputMaybe; + readonly publicationDate?: InputMaybe; + /** Publication date time. ISO 8601 standard. */ + readonly publishedAt?: InputMaybe; }; export type Query = { - __typename?: 'Query'; - _entities?: Maybe>>; - _service?: Maybe<_Service>; + readonly _entities?: Maybe>>; + readonly _service?: Maybe<_Service>; /** * Look up an address by ID. * * Requires one of the following permissions: MANAGE_USERS, OWNER. */ - address?: Maybe
; + readonly address?: Maybe
; /** Returns address validation rules. */ - addressValidationRules?: Maybe; + readonly addressValidationRules?: Maybe; /** * Look up an app by ID. If ID is not provided, return the currently authenticated app. * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER AUTHENTICATED_APP. The authenticated app has access to its resources. Fetching different apps requires MANAGE_APPS permission. */ - app?: Maybe; + readonly app?: Maybe; /** * Look up an app extension by ID. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - appExtension?: Maybe; + readonly appExtension?: Maybe; /** * List of all extensions. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - appExtensions?: Maybe; + readonly appExtensions?: Maybe; /** * List of the apps. * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, MANAGE_APPS. */ - apps?: Maybe; + readonly apps?: Maybe; /** * List of all apps installations * * Requires one of the following permissions: MANAGE_APPS. */ - appsInstallations: Array; + readonly appsInstallations: ReadonlyArray; /** Look up an attribute by ID, slug or external reference. */ - attribute?: Maybe; + readonly attribute?: Maybe; /** List of the shop's attributes. */ - attributes?: Maybe; + readonly attributes?: Maybe; /** List of the shop's categories. */ - categories?: Maybe; + readonly categories?: Maybe; /** Look up a category by ID or slug. */ - category?: Maybe; + readonly category?: Maybe; /** Look up a channel by ID or slug. */ - channel?: Maybe; + readonly channel?: Maybe; /** * List of all channels. * * Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** * Look up a checkout by id. * * Requires one of the following permissions to query a checkout, if a checkout is in inactive channel: MANAGE_CHECKOUTS, IMPERSONATE_USER, HANDLE_PAYMENTS. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** - * List of checkout lines. + * List of checkout lines. The query will not initiate any external requests, including fetching external shipping methods, filtering available shipping methods, or performing external tax calculations. * * Requires one of the following permissions: MANAGE_CHECKOUTS. */ - checkoutLines?: Maybe; + readonly checkoutLines?: Maybe; /** - * List of checkouts. + * List of checkouts. The query will not initiate any external requests, including fetching external shipping methods, filtering available shipping methods, or performing external tax calculations. * * Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS. */ - checkouts?: Maybe; - /** Look up a collection by ID. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - collection?: Maybe; + readonly checkouts?: Maybe; + /** Look up a collection by ID or slug. If slugLanguageCode is provided, category will be fetched by slug translation. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ + readonly collection?: Maybe; /** List of the shop's collections. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - collections?: Maybe; + readonly collections?: Maybe; /** * List of the shop's customers. This list includes all users who registered through the accountRegister mutation. Additionally, staff users who have placed an order using their account will also appear in this list. * * Requires one of the following permissions: MANAGE_ORDERS, MANAGE_USERS. */ - customers?: Maybe; + readonly customers?: Maybe; /** * Look up digital content by ID. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - digitalContent?: Maybe; + readonly digitalContent?: Maybe; /** * List of digital content. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - digitalContents?: Maybe; + readonly digitalContents?: Maybe; /** - * List of draft orders. + * List of draft orders. The query will not initiate any external requests, including filtering available shipping methods, or performing external tax calculations. * * Requires one of the following permissions: MANAGE_ORDERS. */ - draftOrders?: Maybe; + readonly draftOrders?: Maybe; /** * Look up a export file by ID. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - exportFile?: Maybe; + readonly exportFile?: Maybe; /** * List of export files. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - exportFiles?: Maybe; + readonly exportFiles?: Maybe; /** * Look up a gift card by ID. * * Requires one of the following permissions: MANAGE_GIFT_CARD. */ - giftCard?: Maybe; + readonly giftCard?: Maybe; /** * List of gift card currencies. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. */ - giftCardCurrencies: Array; + readonly giftCardCurrencies: ReadonlyArray; /** * Gift card related settings from site settings. * * Requires one of the following permissions: MANAGE_GIFT_CARD. */ - giftCardSettings: GiftCardSettings; + readonly giftCardSettings: GiftCardSettings; /** * List of gift card tags. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_GIFT_CARD. */ - giftCardTags?: Maybe; + readonly giftCardTags?: Maybe; /** * List of gift cards. * * Requires one of the following permissions: MANAGE_GIFT_CARD. */ - giftCards?: Maybe; + readonly giftCards?: Maybe; /** * List of activity events to display on homepage (at the moment it only contains order-events). * * Requires one of the following permissions: MANAGE_ORDERS. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - homepageEvents?: Maybe; + readonly homepageEvents?: Maybe; /** Return the currently authenticated user. */ - me?: Maybe; + readonly me?: Maybe; /** Look up a navigation menu by ID or name. */ - menu?: Maybe; + readonly menu?: Maybe; /** Look up a menu item by ID. */ - menuItem?: Maybe; + readonly menuItem?: Maybe; /** List of the storefronts's menu items. */ - menuItems?: Maybe; + readonly menuItems?: Maybe; /** List of the storefront's menus. */ - menus?: Maybe; + readonly menus?: Maybe; /** Look up an order by ID or external reference. */ - order?: Maybe; + readonly order?: Maybe; /** * Look up an order by token. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - orderByToken?: Maybe; + readonly orderByToken?: Maybe; /** * Order related settings from site settings. Returns `orderSettings` for the first `channel` in alphabetical order. * * Requires one of the following permissions: MANAGE_ORDERS. - * @deprecated This field will be removed in Saleor 4.0. Use the `channel` query to fetch the `orderSettings` field instead. + * @deprecated Use the `channel` query to fetch the `orderSettings` field instead. */ - orderSettings?: Maybe; + readonly orderSettings?: Maybe; /** - * List of orders. + * List of orders. The query will not initiate any external requests, including filtering available shipping methods, or performing external tax calculations. * * Requires one of the following permissions: MANAGE_ORDERS. */ - orders?: Maybe; + readonly orders?: Maybe; /** * Return the total sales amount from a specific period. * * Requires one of the following permissions: MANAGE_ORDERS. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - ordersTotal?: Maybe; + readonly ordersTotal?: Maybe; /** Look up a page by ID or slug. */ - page?: Maybe; + readonly page?: Maybe; /** Look up a page type by ID. */ - pageType?: Maybe; + readonly pageType?: Maybe; /** List of the page types. */ - pageTypes?: Maybe; + readonly pageTypes?: Maybe; /** List of the shop's pages. */ - pages?: Maybe; + readonly pages?: Maybe; /** * Look up a payment by ID. * * Requires one of the following permissions: MANAGE_ORDERS. */ - payment?: Maybe; + readonly payment?: Maybe; /** * List of payments. * * Requires one of the following permissions: MANAGE_ORDERS. */ - payments?: Maybe; + readonly payments?: Maybe; /** * Look up permission group by ID. * * Requires one of the following permissions: MANAGE_STAFF. */ - permissionGroup?: Maybe; + readonly permissionGroup?: Maybe; /** * List of permission groups. * * Requires one of the following permissions: MANAGE_STAFF. */ - permissionGroups?: Maybe; + readonly permissionGroups?: Maybe; /** * Look up a plugin by ID. * * Requires one of the following permissions: MANAGE_PLUGINS. */ - plugin?: Maybe; + readonly plugin?: Maybe; /** * List of plugins. * * Requires one of the following permissions: MANAGE_PLUGINS. */ - plugins?: Maybe; + readonly plugins?: Maybe; /** Look up a product by ID. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - product?: Maybe; + readonly product?: Maybe; /** Look up a product type by ID. */ - productType?: Maybe; + readonly productType?: Maybe; /** List of the shop's product types. */ - productTypes?: Maybe; + readonly productTypes?: Maybe; /** Look up a product variant by ID or SKU. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - productVariant?: Maybe; + readonly productVariant?: Maybe; /** List of product variants. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - productVariants?: Maybe; + readonly productVariants?: Maybe; /** List of the shop's products. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. */ - products?: Maybe; + readonly products?: Maybe; /** * Look up a promotion by ID. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - promotion?: Maybe; + readonly promotion?: Maybe; /** * List of the promotions. * - * Added in Saleor 3.17. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - promotions?: Maybe; + readonly promotions?: Maybe; /** * List of top selling products. * * Requires one of the following permissions: MANAGE_PRODUCTS. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - reportProductSales?: Maybe; + readonly reportProductSales?: Maybe; /** * Look up a sale by ID. * * Requires one of the following permissions: MANAGE_DISCOUNTS. - * @deprecated This field will be removed in Saleor 4.0. Use the `promotion` query instead. + * @deprecated Use the `promotion` query instead. */ - sale?: Maybe; + readonly sale?: Maybe; /** * List of the shop's sales. * * Requires one of the following permissions: MANAGE_DISCOUNTS. - * @deprecated This field will be removed in Saleor 4.0. Use the `promotions` query instead. + * @deprecated Use the `promotions` query instead. */ - sales?: Maybe; + readonly sales?: Maybe; /** * Look up a shipping zone by ID. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; /** * List of the shop's shipping zones. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - shippingZones?: Maybe; + readonly shippingZones?: Maybe; /** Return information about the shop. */ - shop: Shop; + readonly shop: Shop; /** * List of the shop's staff users. * * Requires one of the following permissions: MANAGE_STAFF. */ - staffUsers?: Maybe; + readonly staffUsers?: Maybe; /** * Look up a stock by ID * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - stock?: Maybe; + readonly stock?: Maybe; /** * List of stocks. * * Requires one of the following permissions: MANAGE_PRODUCTS. */ - stocks?: Maybe; + readonly stocks?: Maybe; /** * Look up a tax class. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxClass?: Maybe; + readonly taxClass?: Maybe; /** * List of tax classes. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxClasses?: Maybe; + readonly taxClasses?: Maybe; /** * Look up a tax configuration. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxConfiguration?: Maybe; + readonly taxConfiguration?: Maybe; /** * List of tax configurations. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxConfigurations?: Maybe; + readonly taxConfigurations?: Maybe; /** * Tax class rates grouped by country. * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxCountryConfiguration?: Maybe; + readonly taxCountryConfiguration?: Maybe; /** \n\nRequires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxCountryConfigurations?: Maybe>; + readonly taxCountryConfigurations?: Maybe>; /** * List of all tax rates available from tax gateway. - * @deprecated This field will be removed in Saleor 4.0. Use `taxClasses` field instead. + * @deprecated Use `taxClasses` field instead. */ - taxTypes?: Maybe>; + readonly taxTypes?: Maybe>; /** * Look up a transaction by ID. * - * Added in Saleor 3.6. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: HANDLE_PAYMENTS. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** * Lookup a translatable item by ID. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - translation?: Maybe; + readonly translation?: Maybe; /** * Returns a list of all translatable items of a given kind. * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ - translations?: Maybe; + readonly translations?: Maybe; /** * Look up a user by ID or email address. * * Requires one of the following permissions: MANAGE_STAFF, MANAGE_USERS, MANAGE_ORDERS. */ - user?: Maybe; + readonly user?: Maybe; /** * Look up a voucher by ID. * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - voucher?: Maybe; + readonly voucher?: Maybe; /** * List of the shop's vouchers. * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - vouchers?: Maybe; + readonly vouchers?: Maybe; /** * Look up a warehouse by ID. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS, MANAGE_SHIPPING. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; /** * List of warehouses. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS, MANAGE_SHIPPING. */ - warehouses?: Maybe; + readonly warehouses?: Maybe; /** Look up a webhook by ID. Requires one of the following permissions: MANAGE_APPS, OWNER. */ - webhook?: Maybe; + readonly webhook?: Maybe; /** * List of all available webhook events. * * Requires one of the following permissions: MANAGE_APPS. - * @deprecated This field will be removed in Saleor 4.0. Use `WebhookEventTypeAsyncEnum` and `WebhookEventTypeSyncEnum` to get available event types. + * @deprecated Use `WebhookEventTypeAsyncEnum` and `WebhookEventTypeSyncEnum` to get available event types. */ - webhookEvents?: Maybe>; + readonly webhookEvents?: Maybe>; /** Retrieve a sample payload for a given webhook event based on real data. It can be useful for some integrations where sample payload is required. */ - webhookSamplePayload?: Maybe; + readonly webhookSamplePayload?: Maybe; }; export type Query_EntitiesArgs = { - representations?: InputMaybe>>; + representations?: InputMaybe>>; }; @@ -24759,6 +22040,7 @@ export type QueryCategoriesArgs = { export type QueryCategoryArgs = { id?: InputMaybe; slug?: InputMaybe; + slugLanguageCode?: InputMaybe; }; @@ -24797,6 +22079,7 @@ export type QueryCollectionArgs = { channel?: InputMaybe; id?: InputMaybe; slug?: InputMaybe; + slugLanguageCode?: InputMaybe; }; @@ -24960,6 +22243,7 @@ export type QueryOrdersTotalArgs = { export type QueryPageArgs = { id?: InputMaybe; slug?: InputMaybe; + slugLanguageCode?: InputMaybe; }; @@ -25037,6 +22321,7 @@ export type QueryProductArgs = { externalReference?: InputMaybe; id?: InputMaybe; slug?: InputMaybe; + slugLanguageCode?: InputMaybe; }; @@ -25069,7 +22354,7 @@ export type QueryProductVariantsArgs = { channel?: InputMaybe; filter?: InputMaybe; first?: InputMaybe; - ids?: InputMaybe>; + ids?: InputMaybe>; last?: InputMaybe; sortBy?: InputMaybe; where?: InputMaybe; @@ -25279,35 +22564,34 @@ export type QueryWebhookSamplePayloadArgs = { /** Represents a reduced VAT rate for a particular type of goods. */ export type ReducedRate = { - __typename?: 'ReducedRate'; /** Reduced VAT rate in percent. */ - rate: Scalars['Float']; + readonly rate: Scalars['Float']; /** A type of goods. */ - rateType: Scalars['String']; + readonly rateType: Scalars['String']; }; /** Refresh JWT token. Mutation tries to take refreshToken from the input. If it fails it will try to take `refreshToken` from the http-only cookie `refreshToken`. `csrfToken` is required when `refreshToken` is provided as a cookie. */ export type RefreshToken = { - __typename?: 'RefreshToken'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** JWT token, required to authenticate. */ - token?: Maybe; + readonly token?: Maybe; /** A user instance. */ - user?: Maybe; + readonly user?: Maybe; }; export type ReorderInput = { /** The ID of the item to move. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** The new relative sorting position of the item (from -inf to +inf). 1 moves the item one position forward, -1 moves the item one position backward, 0 leaves the item unchanged. */ - sortOrder?: InputMaybe; + readonly sortOrder?: InputMaybe; }; -export type ReportingPeriod = - | 'THIS_MONTH' - | 'TODAY'; +export enum ReportingPeriod { + ThisMonth = 'THIS_MONTH', + Today = 'TODAY' +} /** * Request email change of the logged in user. @@ -25319,12 +22603,11 @@ export type ReportingPeriod = * - ACCOUNT_CHANGE_EMAIL_REQUESTED (async): An account email change was requested. */ export type RequestEmailChange = { - __typename?: 'RequestEmailChange'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** A user instance. */ - user?: Maybe; + readonly user?: Maybe; }; /** @@ -25336,116 +22619,100 @@ export type RequestEmailChange = { * - STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. */ export type RequestPasswordReset = { - __typename?: 'RequestPasswordReset'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; -/** An enumeration. */ -export type RewardTypeEnum = - | 'GIFT' - | 'SUBTOTAL_DISCOUNT'; +export enum RewardTypeEnum { + Gift = 'GIFT', + SubtotalDiscount = 'SUBTOTAL_DISCOUNT' +} -/** An enumeration. */ -export type RewardValueTypeEnum = - | 'FIXED' - | 'PERCENTAGE'; +export enum RewardValueTypeEnum { + Fixed = 'FIXED', + Percentage = 'PERCENTAGE' +} /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type Sale = Node & ObjectWithMetadata & { - __typename?: 'Sale'; /** List of categories this sale applies to. */ - categories?: Maybe; + readonly categories?: Maybe; /** * List of channels available for the sale. * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - channelListings?: Maybe>; + readonly channelListings?: Maybe>; /** * List of collections this sale applies to. * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - collections?: Maybe; + readonly collections?: Maybe; /** The date and time when the sale was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** Currency code for sale. */ - currency?: Maybe; + readonly currency?: Maybe; /** Sale value. */ - discountValue?: Maybe; + readonly discountValue?: Maybe; /** The end date and time of the sale. */ - endDate?: Maybe; + readonly endDate?: Maybe; /** The ID of the sale. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** The name of the sale. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** * List of products this sale applies to. * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - products?: Maybe; + readonly products?: Maybe; /** The start date and time of the sale. */ - startDate: Scalars['DateTime']; + readonly startDate: Scalars['DateTime']; /** Returns translated sale fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** Type of the sale, fixed or percentage. */ - type: SaleType; + readonly type: SaleType; /** The date and time when the sale was updated. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; /** * List of product variants this sale applies to. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - variants?: Maybe; + readonly variants?: Maybe; }; /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SaleCategoriesArgs = { after?: InputMaybe; @@ -25458,7 +22725,7 @@ export type SaleCategoriesArgs = { /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SaleCollectionsArgs = { after?: InputMaybe; @@ -25471,7 +22738,7 @@ export type SaleCollectionsArgs = { /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SaleMetafieldArgs = { key: Scalars['String']; @@ -25481,17 +22748,17 @@ export type SaleMetafieldArgs = { /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SaleMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SalePrivateMetafieldArgs = { key: Scalars['String']; @@ -25501,17 +22768,17 @@ export type SalePrivateMetafieldArgs = { /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SalePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SaleProductsArgs = { after?: InputMaybe; @@ -25524,7 +22791,7 @@ export type SaleProductsArgs = { /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SaleTranslationArgs = { languageCode: LanguageCodeEnum; @@ -25534,7 +22801,7 @@ export type SaleTranslationArgs = { /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. + * DEPRECATED: this type will be removed. Use `Promotion` type instead. */ export type SaleVariantsArgs = { after?: InputMaybe; @@ -25546,20 +22813,17 @@ export type SaleVariantsArgs = { /** * Adds products, categories, collections to a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` mutation instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_UPDATED (async): A sale was updated. */ export type SaleAddCatalogues = { - __typename?: 'SaleAddCatalogues'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Sale of which catalogue IDs will be modified. */ - sale?: Maybe; + readonly sale?: Maybe; }; /** @@ -25571,124 +22835,109 @@ export type SaleAddCatalogues = { * - SALE_DELETED (async): A sale was deleted. */ export type SaleBulkDelete = { - __typename?: 'SaleBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; + readonly count: Scalars['Int']; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** * Represents sale channel listing. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionRule` type instead. + * DEPRECATED: this type will be removed. Use `PromotionRule` type instead. */ export type SaleChannelListing = Node & { - __typename?: 'SaleChannelListing'; /** The channel in which the sale is available. */ - channel: Channel; + readonly channel: Channel; /** The currency in which the discount value is specified. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; /** The value of the discount applied to the sale in the channel. */ - discountValue: Scalars['Float']; + readonly discountValue: Scalars['Float']; /** The ID of the channel listing. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; }; export type SaleChannelListingAddInput = { /** ID of a channel. */ - channelId: Scalars['ID']; + readonly channelId: Scalars['ID']; /** The value of the discount. */ - discountValue: Scalars['PositiveDecimal']; + readonly discountValue: Scalars['PositiveDecimal']; }; export type SaleChannelListingInput = { /** List of channels to which the sale should be assigned. */ - addChannels?: InputMaybe>; + readonly addChannels?: InputMaybe>; /** List of channels from which the sale should be unassigned. */ - removeChannels?: InputMaybe>; + readonly removeChannels?: InputMaybe>; }; /** * Manage sale's availability in channels. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` or `promotionRuleUpdate` mutations instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ export type SaleChannelListingUpdate = { - __typename?: 'SaleChannelListingUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** An updated sale instance. */ - sale?: Maybe; + readonly sale?: Maybe; }; export type SaleCountableConnection = { - __typename?: 'SaleCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type SaleCountableEdge = { - __typename?: 'SaleCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Sale; + readonly node: Sale; }; /** * Creates a new sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionCreate` mutation instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_CREATED (async): A sale was created. */ export type SaleCreate = { - __typename?: 'SaleCreate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; - sale?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly sale?: Maybe; }; /** * Event sent when new sale is created. * - * Added in Saleor 3.2. - * - * DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionCreated` event instead. + * DEPRECATED: this event will be removed. Use `PromotionCreated` event instead. */ export type SaleCreated = Event & { - __typename?: 'SaleCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The sale the event relates to. */ - sale?: Maybe; + readonly sale?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Event sent when new sale is created. * - * Added in Saleor 3.2. - * - * DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionCreated` event instead. + * DEPRECATED: this event will be removed. Use `PromotionCreated` event instead. */ export type SaleCreatedSaleArgs = { channel?: InputMaybe; @@ -25697,167 +22946,147 @@ export type SaleCreatedSaleArgs = { /** * Deletes a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionDelete` mutation instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_DELETED (async): A sale was deleted. */ export type SaleDelete = { - __typename?: 'SaleDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; - sale?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly sale?: Maybe; }; /** * Event sent when sale is deleted. * - * Added in Saleor 3.2. - * - * DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionDeleted` event instead. + * DEPRECATED: this event will be removed. Use `PromotionDeleted` event instead. */ export type SaleDeleted = Event & { - __typename?: 'SaleDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The sale the event relates to. */ - sale?: Maybe; + readonly sale?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Event sent when sale is deleted. * - * Added in Saleor 3.2. - * - * DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionDeleted` event instead. + * DEPRECATED: this event will be removed. Use `PromotionDeleted` event instead. */ export type SaleDeletedSaleArgs = { channel?: InputMaybe; }; export type SaleFilterInput = { - metadata?: InputMaybe>; - saleType?: InputMaybe; - search?: InputMaybe; - started?: InputMaybe; - status?: InputMaybe>; - updatedAt?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly saleType?: InputMaybe; + readonly search?: InputMaybe; + readonly started?: InputMaybe; + readonly status?: InputMaybe>; + readonly updatedAt?: InputMaybe; }; export type SaleInput = { /** Categories related to the discount. */ - categories?: InputMaybe>; + readonly categories?: InputMaybe>; /** Collections related to the discount. */ - collections?: InputMaybe>; + readonly collections?: InputMaybe>; /** End date of the voucher in ISO 8601 format. */ - endDate?: InputMaybe; + readonly endDate?: InputMaybe; /** Voucher name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Products related to the discount. */ - products?: InputMaybe>; + readonly products?: InputMaybe>; /** Start date of the voucher in ISO 8601 format. */ - startDate?: InputMaybe; + readonly startDate?: InputMaybe; /** Fixed or percentage. */ - type?: InputMaybe; + readonly type?: InputMaybe; /** Value of the voucher. */ - value?: InputMaybe; - variants?: InputMaybe>; + readonly value?: InputMaybe; + readonly variants?: InputMaybe>; }; /** * Removes products, categories, collections from a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleUpdate` or `promotionRuleDelete` mutations instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: * - SALE_UPDATED (async): A sale was updated. */ export type SaleRemoveCatalogues = { - __typename?: 'SaleRemoveCatalogues'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Sale of which catalogue IDs will be modified. */ - sale?: Maybe; + readonly sale?: Maybe; }; -export type SaleSortField = +export enum SaleSortField { /** Sort sales by created at. */ - | 'CREATED_AT' + CreatedAt = 'CREATED_AT', /** Sort sales by end date. */ - | 'END_DATE' + EndDate = 'END_DATE', /** Sort sales by last modified at. */ - | 'LAST_MODIFIED_AT' + LastModifiedAt = 'LAST_MODIFIED_AT', /** Sort sales by name. */ - | 'NAME' + Name = 'NAME', /** Sort sales by start date. */ - | 'START_DATE' + StartDate = 'START_DATE', /** Sort sales by type. */ - | 'TYPE' + Type = 'TYPE', /** * Sort sales by value. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'VALUE'; + Value = 'VALUE' +} export type SaleSortingInput = { /** * Specifies the channel in which to sort the data. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. + * @deprecated Use root-level channel argument instead. */ - channel?: InputMaybe; + readonly channel?: InputMaybe; /** Specifies the direction in which to sort sales. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort sales by the selected field. */ - field: SaleSortField; + readonly field: SaleSortField; }; /** * The event informs about the start or end of the sale. * - * Added in Saleor 3.5. - * - * DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionStarted` and `PromotionEnded` events instead. + * DEPRECATED: this event will be removed. Use `PromotionStarted` and `PromotionEnded` events instead. */ export type SaleToggle = Event & { - __typename?: 'SaleToggle'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; - /** - * The sale the event relates to. - * - * Added in Saleor 3.5. - */ - sale?: Maybe; + readonly recipient?: Maybe; + /** The sale the event relates to. */ + readonly sale?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * The event informs about the start or end of the sale. * - * Added in Saleor 3.5. - * - * DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionStarted` and `PromotionEnded` events instead. + * DEPRECATED: this event will be removed. Use `PromotionStarted` and `PromotionEnded` events instead. */ export type SaleToggleSaleArgs = { channel?: InputMaybe; @@ -25866,36 +23095,31 @@ export type SaleToggleSaleArgs = { /** * Represents sale's original translatable fields and related translations. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionTranslatableContent` instead. + * DEPRECATED: this type will be removed. Use `PromotionTranslatableContent` instead. */ export type SaleTranslatableContent = Node & { - __typename?: 'SaleTranslatableContent'; /** The ID of the sale translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Name of the sale to translate. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** * Sales allow creating discounts for categories, collections or products and are visible to all the customers. * * Requires one of the following permissions: MANAGE_DISCOUNTS. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. - */ - sale?: Maybe; - /** - * The ID of the sale to translate. - * - * Added in Saleor 3.14. + * @deprecated Get model fields from the root level queries. */ - saleId: Scalars['ID']; + readonly sale?: Maybe; + /** The ID of the sale to translate. */ + readonly saleId: Scalars['ID']; /** Returns translated sale fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; /** * Represents sale's original translatable fields and related translations. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionTranslatableContent` instead. + * DEPRECATED: this type will be removed. Use `PromotionTranslatableContent` instead. */ export type SaleTranslatableContentTranslationArgs = { languageCode: LanguageCodeEnum; @@ -25904,48 +23128,39 @@ export type SaleTranslatableContentTranslationArgs = { /** * Creates/updates translations for a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PromotionTranslate` mutation instead. - * * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type SaleTranslate = { - __typename?: 'SaleTranslate'; - errors: Array; - sale?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly errors: ReadonlyArray; + readonly sale?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; /** * Represents sale translations. * - * DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionTranslation` instead. + * DEPRECATED: this type will be removed. Use `PromotionTranslation` instead. */ export type SaleTranslation = Node & { - __typename?: 'SaleTranslation'; /** The ID of the sale translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated name of sale. */ - name?: Maybe; - /** - * Represents the sale fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly name?: Maybe; + /** Represents the sale fields to translate. */ + readonly translatableContent?: Maybe; }; -export type SaleType = - | 'FIXED' - | 'PERCENTAGE'; +export enum SaleType { + Fixed = 'FIXED', + Percentage = 'PERCENTAGE' +} /** * Updates a sale. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionUpdate` mutation instead. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. * * Triggers the following webhook events: @@ -25953,41 +23168,35 @@ export type SaleType = * - SALE_TOGGLE (async): Optionally triggered when a sale is started or stopped. */ export type SaleUpdate = { - __typename?: 'SaleUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; - sale?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly sale?: Maybe; }; /** * Event sent when sale is updated. * - * Added in Saleor 3.2. - * - * DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionUpdated` event instead. + * DEPRECATED: this event will be removed. Use `PromotionUpdated` event instead. */ export type SaleUpdated = Event & { - __typename?: 'SaleUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The sale the event relates to. */ - sale?: Maybe; + readonly sale?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Event sent when sale is updated. * - * Added in Saleor 3.2. - * - * DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionUpdated` event instead. + * DEPRECATED: this event will be removed. Use `PromotionUpdated` event instead. */ export type SaleUpdatedSaleArgs = { channel?: InputMaybe; @@ -25995,20 +23204,15 @@ export type SaleUpdatedSaleArgs = { /** Represents a custom attribute. */ export type SelectedAttribute = { - __typename?: 'SelectedAttribute'; /** Name of an attribute displayed in the interface. */ - attribute: Attribute; + readonly attribute: Attribute; /** Values of an attribute. */ - values: Array; + readonly values: ReadonlyArray; }; /** * Sends a notification confirmation. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: @@ -26016,164 +23220,150 @@ export type SelectedAttribute = { * - ACCOUNT_CONFIRMATION_REQUESTED (async): An account confirmation was requested. This event is always sent regardless of settings. */ export type SendConfirmationEmail = { - __typename?: 'SendConfirmationEmail'; - errors: Array; + readonly errors: ReadonlyArray; }; export type SendConfirmationEmailError = { - __typename?: 'SendConfirmationEmailError'; /** The error code. */ - code: SendConfirmationEmailErrorCode; + readonly code: SendConfirmationEmailErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type SendConfirmationEmailErrorCode = - | 'ACCOUNT_CONFIRMED' - | 'CONFIRMATION_ALREADY_REQUESTED' - | 'INVALID' - | 'MISSING_CHANNEL_SLUG'; +export enum SendConfirmationEmailErrorCode { + AccountConfirmed = 'ACCOUNT_CONFIRMED', + ConfirmationAlreadyRequested = 'CONFIRMATION_ALREADY_REQUESTED', + Invalid = 'INVALID', + MissingChannelSlug = 'MISSING_CHANNEL_SLUG' +} export type SeoInput = { /** SEO description. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** SEO title. */ - title?: InputMaybe; + readonly title?: InputMaybe; }; /** Sets the user's password from the token sent by email using the RequestPasswordReset mutation. */ export type SetPassword = { - __typename?: 'SetPassword'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; /** CSRF token required to re-generate access token. */ - csrfToken?: Maybe; - errors: Array; + readonly csrfToken?: Maybe; + readonly errors: ReadonlyArray; /** JWT refresh token, required to re-generate access token. */ - refreshToken?: Maybe; + readonly refreshToken?: Maybe; /** JWT token, required to authenticate. */ - token?: Maybe; + readonly token?: Maybe; /** A user instance. */ - user?: Maybe; + readonly user?: Maybe; }; export type ShippingError = { - __typename?: 'ShippingError'; /** List of channels IDs which causes the error. */ - channels?: Maybe>; + readonly channels?: Maybe>; /** The error code. */ - code: ShippingErrorCode; + readonly code: ShippingErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of warehouse IDs which causes the error. */ - warehouses?: Maybe>; -}; - -/** An enumeration. */ -export type ShippingErrorCode = - | 'ALREADY_EXISTS' - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'MAX_LESS_THAN_MIN' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; + readonly warehouses?: Maybe>; +}; + +export enum ShippingErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + MaxLessThanMin = 'MAX_LESS_THAN_MIN', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} -/** - * List shipping methods for checkout. - * - * Added in Saleor 3.6. - */ +/** List shipping methods for checkout. */ export type ShippingListMethodsForCheckout = Event & { - __typename?: 'ShippingListMethodsForCheckout'; /** The checkout the event relates to. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; - /** - * Shipping methods that can be used with this checkout. - * - * Added in Saleor 3.6. - */ - shippingMethods?: Maybe>; + readonly recipient?: Maybe; + /** Shipping methods that can be used with this checkout. */ + readonly shippingMethods?: Maybe>; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** Shipping methods that can be used as means of shipping for orders and checkouts. */ export type ShippingMethod = Node & ObjectWithMetadata & { - __typename?: 'ShippingMethod'; /** Describes if this shipping method is active and can be selected. */ - active: Scalars['Boolean']; + readonly active: Scalars['Boolean']; /** * Shipping method description. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** Unique ID of ShippingMethod available for Order. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Maximum delivery days for this shipping method. */ - maximumDeliveryDays?: Maybe; + readonly maximumDeliveryDays?: Maybe; /** Maximum order price for this shipping method. */ - maximumOrderPrice?: Maybe; + readonly maximumOrderPrice?: Maybe; /** * Maximum order weight for this shipping method. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - maximumOrderWeight?: Maybe; + readonly maximumOrderWeight?: Maybe; /** Message connected to this shipping method. */ - message?: Maybe; + readonly message?: Maybe; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. */ - metafield?: Maybe; + readonly metafield?: Maybe; /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ - metafields?: Maybe; + readonly metafields?: Maybe; /** Minimum delivery days for this shipping method. */ - minimumDeliveryDays?: Maybe; + readonly minimumDeliveryDays?: Maybe; /** Minimal order price for this shipping method. */ - minimumOrderPrice?: Maybe; + readonly minimumOrderPrice?: Maybe; /** * Minimum order weight for this shipping method. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - minimumOrderWeight?: Maybe; + readonly minimumOrderWeight?: Maybe; /** Shipping method name. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** The price of selected shipping method. */ - price: Money; + readonly price: Money; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. */ - privateMetafield?: Maybe; + readonly privateMetafield?: Maybe; /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ - privateMetafields?: Maybe; + readonly privateMetafields?: Maybe; /** Returns translated shipping method fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** * Type of the shipping method. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - type?: Maybe; + readonly type?: Maybe; }; @@ -26185,7 +23375,7 @@ export type ShippingMethodMetafieldArgs = { /** Shipping methods that can be used as means of shipping for orders and checkouts. */ export type ShippingMethodMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -26197,7 +23387,7 @@ export type ShippingMethodPrivateMetafieldArgs = { /** Shipping methods that can be used as means of shipping for orders and checkouts. */ export type ShippingMethodPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -26208,35 +23398,34 @@ export type ShippingMethodTranslationArgs = { /** Represents shipping method channel listing. */ export type ShippingMethodChannelListing = Node & { - __typename?: 'ShippingMethodChannelListing'; /** The channel associated with the shipping method channel listing. */ - channel: Channel; + readonly channel: Channel; /** The ID of shipping method channel listing. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Maximum order price. */ - maximumOrderPrice?: Maybe; + readonly maximumOrderPrice?: Maybe; /** Minimum order price. */ - minimumOrderPrice?: Maybe; + readonly minimumOrderPrice?: Maybe; /** Price of the shipping method in the associated channel. */ - price?: Maybe; + readonly price?: Maybe; }; export type ShippingMethodChannelListingAddInput = { /** ID of a channel. */ - channelId: Scalars['ID']; + readonly channelId: Scalars['ID']; /** Maximum order price to use this shipping method. */ - maximumOrderPrice?: InputMaybe; + readonly maximumOrderPrice?: InputMaybe; /** Minimum order price to use this shipping method. */ - minimumOrderPrice?: InputMaybe; + readonly minimumOrderPrice?: InputMaybe; /** Shipping price of the shipping method in this channel. */ - price?: InputMaybe; + readonly price?: InputMaybe; }; export type ShippingMethodChannelListingInput = { /** List of channels to which the shipping method should be assigned. */ - addChannels?: InputMaybe>; + readonly addChannels?: InputMaybe>; /** List of channels from which the shipping method should be unassigned. */ - removeChannels?: InputMaybe>; + readonly removeChannels?: InputMaybe>; }; /** @@ -26245,55 +23434,48 @@ export type ShippingMethodChannelListingInput = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingMethodChannelListingUpdate = { - __typename?: 'ShippingMethodChannelListingUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; /** An updated shipping method instance. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; }; /** Represents shipping method postal code rule. */ export type ShippingMethodPostalCodeRule = Node & { - __typename?: 'ShippingMethodPostalCodeRule'; /** End address range. */ - end?: Maybe; + readonly end?: Maybe; /** The ID of the object. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Inclusion type of the postal code rule. */ - inclusionType?: Maybe; + readonly inclusionType?: Maybe; /** Start address range. */ - start?: Maybe; + readonly start?: Maybe; }; /** Represents shipping method's original translatable fields and related translations. */ export type ShippingMethodTranslatableContent = Node & { - __typename?: 'ShippingMethodTranslatableContent'; /** * Shipping method description to translate. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** The ID of the shipping method translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Shipping method name to translate. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** * Shipping method are the methods you'll use to get customer's orders to them. They are directly exposed to the customers. * * Requires one of the following permissions: MANAGE_SHIPPING. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. + * @deprecated Get model fields from the root level queries. */ - shippingMethod?: Maybe; - /** - * The ID of the shipping method to translate. - * - * Added in Saleor 3.14. - */ - shippingMethodId: Scalars['ID']; + readonly shippingMethod?: Maybe; + /** The ID of the shipping method to translate. */ + readonly shippingMethodId: Scalars['ID']; /** Returns translated shipping method fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; }; @@ -26304,108 +23486,90 @@ export type ShippingMethodTranslatableContentTranslationArgs = { /** Represents shipping method translations. */ export type ShippingMethodTranslation = Node & { - __typename?: 'ShippingMethodTranslation'; /** * Translated description of the shipping method. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** The ID of the shipping method translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated shipping method name. */ - name?: Maybe; - /** - * Represents the shipping method fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly name?: Maybe; + /** Represents the shipping method fields to translate. */ + readonly translatableContent?: Maybe; }; /** Shipping method are the methods you'll use to get customer's orders to them. They are directly exposed to the customers. */ export type ShippingMethodType = Node & ObjectWithMetadata & { - __typename?: 'ShippingMethodType'; /** * List of channels available for the method. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - channelListings?: Maybe>; + readonly channelListings?: Maybe>; /** * Shipping method description. * * Rich text format. For reference see https://editorjs.io/ */ - description?: Maybe; + readonly description?: Maybe; /** * List of excluded products for the shipping method. * * Requires one of the following permissions: MANAGE_SHIPPING. */ - excludedProducts?: Maybe; + readonly excludedProducts?: Maybe; /** Shipping method ID. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Maximum number of days for delivery. */ - maximumDeliveryDays?: Maybe; + readonly maximumDeliveryDays?: Maybe; /** The price of the cheapest variant (including discounts). */ - maximumOrderPrice?: Maybe; + readonly maximumOrderPrice?: Maybe; /** Maximum order weight to use this shipping method. */ - maximumOrderWeight?: Maybe; + readonly maximumOrderWeight?: Maybe; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Minimal number of days for delivery. */ - minimumDeliveryDays?: Maybe; + readonly minimumDeliveryDays?: Maybe; /** The price of the cheapest variant (including discounts). */ - minimumOrderPrice?: Maybe; + readonly minimumOrderPrice?: Maybe; /** Minimum order weight to use this shipping method. */ - minimumOrderWeight?: Maybe; + readonly minimumOrderWeight?: Maybe; /** Shipping method name. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Postal code ranges rule of exclusion or inclusion of the shipping method. */ - postalCodeRules?: Maybe>; + readonly postalCodeRules?: Maybe>; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** * Tax class assigned to this shipping method. * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - taxClass?: Maybe; + readonly taxClass?: Maybe; /** Returns translated shipping method fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** Type of the shipping method. */ - type?: Maybe; + readonly type?: Maybe; }; @@ -26426,7 +23590,7 @@ export type ShippingMethodTypeMetafieldArgs = { /** Shipping method are the methods you'll use to get customer's orders to them. They are directly exposed to the customers. */ export type ShippingMethodTypeMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -26438,7 +23602,7 @@ export type ShippingMethodTypePrivateMetafieldArgs = { /** Shipping method are the methods you'll use to get customer's orders to them. They are directly exposed to the customers. */ export type ShippingMethodTypePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -26447,29 +23611,24 @@ export type ShippingMethodTypeTranslationArgs = { languageCode: LanguageCodeEnum; }; -/** An enumeration. */ -export type ShippingMethodTypeEnum = - | 'PRICE' - | 'WEIGHT'; +export enum ShippingMethodTypeEnum { + Price = 'PRICE', + Weight = 'WEIGHT' +} -/** - * List of shipping methods available for the country. - * - * Added in Saleor 3.6. - */ +/** List of shipping methods available for the country. */ export type ShippingMethodsPerCountry = { - __typename?: 'ShippingMethodsPerCountry'; /** The country code. */ - countryCode: CountryCode; + readonly countryCode: CountryCode; /** List of available shipping methods. */ - shippingMethods?: Maybe>; + readonly shippingMethods?: Maybe>; }; export type ShippingPostalCodeRulesCreateInputRange = { /** End range of the postal code. */ - end?: InputMaybe; + readonly end?: InputMaybe; /** Start range of the postal code. */ - start: Scalars['String']; + readonly start: Scalars['String']; }; /** @@ -26478,12 +23637,11 @@ export type ShippingPostalCodeRulesCreateInputRange = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingPriceBulkDelete = { - __typename?: 'ShippingPriceBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; }; /** @@ -26492,52 +23650,38 @@ export type ShippingPriceBulkDelete = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingPriceCreate = { - __typename?: 'ShippingPriceCreate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; - shippingMethod?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; + readonly shippingMethod?: Maybe; /** A shipping zone to which the shipping method belongs. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; }; -/** - * Event sent when new shipping price is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new shipping price is created. */ export type ShippingPriceCreated = Event & { - __typename?: 'ShippingPriceCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The shipping method the event relates to. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; /** The shipping zone the shipping method belongs to. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when new shipping price is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new shipping price is created. */ export type ShippingPriceCreatedShippingMethodArgs = { channel?: InputMaybe; }; -/** - * Event sent when new shipping price is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new shipping price is created. */ export type ShippingPriceCreatedShippingZoneArgs = { channel?: InputMaybe; }; @@ -26548,53 +23692,39 @@ export type ShippingPriceCreatedShippingZoneArgs = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingPriceDelete = { - __typename?: 'ShippingPriceDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; /** A shipping method to delete. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; /** A shipping zone to which the shipping method belongs. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; }; -/** - * Event sent when shipping price is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping price is deleted. */ export type ShippingPriceDeleted = Event & { - __typename?: 'ShippingPriceDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The shipping method the event relates to. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; /** The shipping zone the shipping method belongs to. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when shipping price is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping price is deleted. */ export type ShippingPriceDeletedShippingMethodArgs = { channel?: InputMaybe; }; -/** - * Event sent when shipping price is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping price is deleted. */ export type ShippingPriceDeletedShippingZoneArgs = { channel?: InputMaybe; }; @@ -26605,44 +23735,43 @@ export type ShippingPriceDeletedShippingZoneArgs = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingPriceExcludeProducts = { - __typename?: 'ShippingPriceExcludeProducts'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; /** A shipping method with new list of excluded products. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; }; export type ShippingPriceExcludeProductsInput = { /** List of products which will be excluded. */ - products: Array; + readonly products: ReadonlyArray; }; export type ShippingPriceInput = { /** Postal code rules to add. */ - addPostalCodeRules?: InputMaybe>; + readonly addPostalCodeRules?: InputMaybe>; /** Postal code rules to delete. */ - deletePostalCodeRules?: InputMaybe>; + readonly deletePostalCodeRules?: InputMaybe>; /** Shipping method description. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** Inclusion type for currently assigned postal code rules. */ - inclusionType?: InputMaybe; + readonly inclusionType?: InputMaybe; /** Maximum number of days for delivery. */ - maximumDeliveryDays?: InputMaybe; + readonly maximumDeliveryDays?: InputMaybe; /** Maximum order weight to use this shipping method. */ - maximumOrderWeight?: InputMaybe; + readonly maximumOrderWeight?: InputMaybe; /** Minimal number of days for delivery. */ - minimumDeliveryDays?: InputMaybe; + readonly minimumDeliveryDays?: InputMaybe; /** Minimum order weight to use this shipping method. */ - minimumOrderWeight?: InputMaybe; + readonly minimumOrderWeight?: InputMaybe; /** Name of the shipping method. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Shipping zone this method belongs to. */ - shippingZone?: InputMaybe; + readonly shippingZone?: InputMaybe; /** ID of a tax class to assign to this shipping method. If not provided, the default tax class will be used. */ - taxClass?: InputMaybe; + readonly taxClass?: InputMaybe; /** Shipping type: price or weight based. */ - type?: InputMaybe; + readonly type?: InputMaybe; }; /** @@ -26651,12 +23780,11 @@ export type ShippingPriceInput = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingPriceRemoveProductFromExclude = { - __typename?: 'ShippingPriceRemoveProductFromExclude'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; /** A shipping method with new list of excluded products. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; }; /** @@ -26665,11 +23793,10 @@ export type ShippingPriceRemoveProductFromExclude = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type ShippingPriceTranslate = { - __typename?: 'ShippingPriceTranslate'; - errors: Array; - shippingMethod?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly errors: ReadonlyArray; + readonly shippingMethod?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; export type ShippingPriceTranslationInput = { @@ -26678,8 +23805,8 @@ export type ShippingPriceTranslationInput = { * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; - name?: InputMaybe; + readonly description?: InputMaybe; + readonly name?: InputMaybe; }; /** @@ -26688,109 +23815,82 @@ export type ShippingPriceTranslationInput = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingPriceUpdate = { - __typename?: 'ShippingPriceUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; - shippingMethod?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; + readonly shippingMethod?: Maybe; /** A shipping zone to which the shipping method belongs. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; }; -/** - * Event sent when shipping price is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping price is updated. */ export type ShippingPriceUpdated = Event & { - __typename?: 'ShippingPriceUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The shipping method the event relates to. */ - shippingMethod?: Maybe; + readonly shippingMethod?: Maybe; /** The shipping zone the shipping method belongs to. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when shipping price is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping price is updated. */ export type ShippingPriceUpdatedShippingMethodArgs = { channel?: InputMaybe; }; -/** - * Event sent when shipping price is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping price is updated. */ export type ShippingPriceUpdatedShippingZoneArgs = { channel?: InputMaybe; }; /** Represents a shipping zone in the shop. Zones are the concept used only for grouping shipping methods in the dashboard, and are never exposed to the customers directly. */ export type ShippingZone = Node & ObjectWithMetadata & { - __typename?: 'ShippingZone'; /** List of channels for shipping zone. */ - channels: Array; + readonly channels: ReadonlyArray; /** List of countries available for the method. */ - countries: Array; + readonly countries: ReadonlyArray; /** Indicates if the shipping zone is default one. */ - default: Scalars['Boolean']; + readonly default: Scalars['Boolean']; /** Description of a shipping zone. */ - description?: Maybe; + readonly description?: Maybe; /** The ID of shipping zone. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Shipping zone name. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** Lowest and highest prices for the shipping. */ - priceRange?: Maybe; + readonly priceRange?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** List of shipping methods available for orders shipped to countries within this shipping zone. */ - shippingMethods?: Maybe>; + readonly shippingMethods?: Maybe>; /** List of warehouses for shipping zone. */ - warehouses: Array; + readonly warehouses: ReadonlyArray; }; @@ -26802,7 +23902,7 @@ export type ShippingZoneMetafieldArgs = { /** Represents a shipping zone in the shop. Zones are the concept used only for grouping shipping methods in the dashboard, and are never exposed to the customers directly. */ export type ShippingZoneMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -26814,7 +23914,7 @@ export type ShippingZonePrivateMetafieldArgs = { /** Represents a shipping zone in the shop. Zones are the concept used only for grouping shipping methods in the dashboard, and are never exposed to the customers directly. */ export type ShippingZonePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; /** @@ -26823,29 +23923,26 @@ export type ShippingZonePrivateMetafieldsArgs = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingZoneBulkDelete = { - __typename?: 'ShippingZoneBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; }; export type ShippingZoneCountableConnection = { - __typename?: 'ShippingZoneCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type ShippingZoneCountableEdge = { - __typename?: 'ShippingZoneCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: ShippingZone; + readonly node: ShippingZone; }; /** @@ -26854,53 +23951,43 @@ export type ShippingZoneCountableEdge = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingZoneCreate = { - __typename?: 'ShippingZoneCreate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; - shippingZone?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; + readonly shippingZone?: Maybe; }; export type ShippingZoneCreateInput = { /** List of channels to assign to the shipping zone. */ - addChannels?: InputMaybe>; + readonly addChannels?: InputMaybe>; /** List of warehouses to assign to a shipping zone */ - addWarehouses?: InputMaybe>; + readonly addWarehouses?: InputMaybe>; /** List of countries in this shipping zone. */ - countries?: InputMaybe>; + readonly countries?: InputMaybe>; /** Default shipping zone will be used for countries not covered by other zones. */ - default?: InputMaybe; + readonly default?: InputMaybe; /** Description of the shipping zone. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** Shipping zone's name. Visible only to the staff. */ - name?: InputMaybe; + readonly name?: InputMaybe; }; -/** - * Event sent when new shipping zone is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new shipping zone is created. */ export type ShippingZoneCreated = Event & { - __typename?: 'ShippingZoneCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The shipping zone the event relates to. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when new shipping zone is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new shipping zone is created. */ export type ShippingZoneCreatedShippingZoneArgs = { channel?: InputMaybe; }; @@ -26911,72 +23998,53 @@ export type ShippingZoneCreatedShippingZoneArgs = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingZoneDelete = { - __typename?: 'ShippingZoneDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; - shippingZone?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; + readonly shippingZone?: Maybe; }; -/** - * Event sent when shipping zone is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping zone is deleted. */ export type ShippingZoneDeleted = Event & { - __typename?: 'ShippingZoneDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The shipping zone the event relates to. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when shipping zone is deleted. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping zone is deleted. */ export type ShippingZoneDeletedShippingZoneArgs = { channel?: InputMaybe; }; export type ShippingZoneFilterInput = { - channels?: InputMaybe>; - search?: InputMaybe; + readonly channels?: InputMaybe>; + readonly search?: InputMaybe; }; -/** - * Event sent when shipping zone metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when shipping zone metadata is updated. */ export type ShippingZoneMetadataUpdated = Event & { - __typename?: 'ShippingZoneMetadataUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The shipping zone the event relates to. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when shipping zone metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when shipping zone metadata is updated. */ export type ShippingZoneMetadataUpdatedShippingZoneArgs = { channel?: InputMaybe; }; @@ -26987,84 +24055,71 @@ export type ShippingZoneMetadataUpdatedShippingZoneArgs = { * Requires one of the following permissions: MANAGE_SHIPPING. */ export type ShippingZoneUpdate = { - __typename?: 'ShippingZoneUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shippingErrors: Array; - shippingZone?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shippingErrors: ReadonlyArray; + readonly shippingZone?: Maybe; }; export type ShippingZoneUpdateInput = { /** List of channels to assign to the shipping zone. */ - addChannels?: InputMaybe>; + readonly addChannels?: InputMaybe>; /** List of warehouses to assign to a shipping zone */ - addWarehouses?: InputMaybe>; + readonly addWarehouses?: InputMaybe>; /** List of countries in this shipping zone. */ - countries?: InputMaybe>; + readonly countries?: InputMaybe>; /** Default shipping zone will be used for countries not covered by other zones. */ - default?: InputMaybe; + readonly default?: InputMaybe; /** Description of the shipping zone. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** Shipping zone's name. Visible only to the staff. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** List of channels to unassign from the shipping zone. */ - removeChannels?: InputMaybe>; + readonly removeChannels?: InputMaybe>; /** List of warehouses to unassign from a shipping zone */ - removeWarehouses?: InputMaybe>; + readonly removeWarehouses?: InputMaybe>; }; -/** - * Event sent when shipping zone is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping zone is updated. */ export type ShippingZoneUpdated = Event & { - __typename?: 'ShippingZoneUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The shipping zone the event relates to. */ - shippingZone?: Maybe; + readonly shippingZone?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when shipping zone is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when shipping zone is updated. */ export type ShippingZoneUpdatedShippingZoneArgs = { channel?: InputMaybe; }; /** Represents a shop resource containing general shop data and configuration. */ export type Shop = ObjectWithMetadata & { - __typename?: 'Shop'; /** * Determines if user can login without confirmation when `enableAccountConfirmation` is enabled. * - * Added in Saleor 3.15. - * * Requires one of the following permissions: MANAGE_SETTINGS. */ - allowLoginWithoutConfirmation?: Maybe; + readonly allowLoginWithoutConfirmation?: Maybe; /** * Enable automatic fulfillment for all digital products. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - automaticFulfillmentDigitalProducts?: Maybe; + readonly automaticFulfillmentDigitalProducts?: Maybe; /** List of available external authentications. */ - availableExternalAuthentications: Array; + readonly availableExternalAuthentications: ReadonlyArray; /** List of available payment gateways. */ - availablePaymentGateways: Array; + readonly availablePaymentGateways: ReadonlyArray; /** Shipping methods that are available for the shop. */ - availableShippingMethods?: Maybe>; + readonly availableShippingMethods?: Maybe>; /** * List of tax apps that can be assigned to the channel. The list will be calculated by Saleor based on the apps that are subscribed to webhooks related to tax calculations: CHECKOUT_CALCULATE_TAXES * @@ -27072,173 +24127,151 @@ export type Shop = ObjectWithMetadata & { * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, MANAGE_APPS. */ - availableTaxApps: Array; + readonly availableTaxApps: ReadonlyArray; /** * List of all currencies supported by shop's channels. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - channelCurrencies: Array; + readonly channelCurrencies: ReadonlyArray; /** * Charge taxes on shipping. - * @deprecated This field will be removed in Saleor 4.0. Use `ShippingMethodType.taxClass` to determine whether taxes are calculated for shipping methods; if a tax class is set, the taxes will be calculated, otherwise no tax rate will be applied. + * @deprecated Use `ShippingMethodType.taxClass` to determine whether taxes are calculated for shipping methods; if a tax class is set, the taxes will be calculated, otherwise no tax rate will be applied. */ - chargeTaxesOnShipping: Scalars['Boolean']; + readonly chargeTaxesOnShipping: Scalars['Boolean']; /** Company address. */ - companyAddress?: Maybe
; + readonly companyAddress?: Maybe
; /** List of countries available in the shop. */ - countries: Array; + readonly countries: ReadonlyArray; /** URL of a view where customers can set their password. */ - customerSetPasswordUrl?: Maybe; + readonly customerSetPasswordUrl?: Maybe; /** Shop's default country. */ - defaultCountry?: Maybe; + readonly defaultCountry?: Maybe; /** * Default number of max downloads per digital content URL. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - defaultDigitalMaxDownloads?: Maybe; + readonly defaultDigitalMaxDownloads?: Maybe; /** * Default number of days which digital content URL will be valid. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - defaultDigitalUrlValidDays?: Maybe; + readonly defaultDigitalUrlValidDays?: Maybe; /** * Default shop's email sender's address. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - defaultMailSenderAddress?: Maybe; + readonly defaultMailSenderAddress?: Maybe; /** * Default shop's email sender's name. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - defaultMailSenderName?: Maybe; + readonly defaultMailSenderName?: Maybe; /** Default weight unit. */ - defaultWeightUnit?: Maybe; + readonly defaultWeightUnit?: Maybe; /** Shop's description. */ - description?: Maybe; + readonly description?: Maybe; /** * Display prices with tax in store. - * @deprecated This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to determine whether to display gross or net prices. + * @deprecated Use `Channel.taxConfiguration` to determine whether to display gross or net prices. */ - displayGrossPrices: Scalars['Boolean']; + readonly displayGrossPrices: Scalars['Boolean']; /** Shop's domain data. */ - domain: Domain; + readonly domain: Domain; /** * Determines if account confirmation by email is enabled. * - * Added in Saleor 3.14. - * * Requires one of the following permissions: MANAGE_SETTINGS. */ - enableAccountConfirmationByEmail?: Maybe; - /** - * Allow to approve fulfillments which are unpaid. - * - * Added in Saleor 3.1. - */ - fulfillmentAllowUnpaid: Scalars['Boolean']; - /** - * Automatically approve all new fulfillments. - * - * Added in Saleor 3.1. - */ - fulfillmentAutoApprove: Scalars['Boolean']; + readonly enableAccountConfirmationByEmail?: Maybe; + /** Allow to approve fulfillments which are unpaid. */ + readonly fulfillmentAllowUnpaid: Scalars['Boolean']; + /** Automatically approve all new fulfillments. */ + readonly fulfillmentAutoApprove: Scalars['Boolean']; /** Header text. */ - headerText?: Maybe; + readonly headerText?: Maybe; /** ID of the shop. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** * Include taxes in prices. - * @deprecated This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration.pricesEnteredWithTax` to determine whether prices are entered with tax. + * @deprecated Use `Channel.taxConfiguration.pricesEnteredWithTax` to determine whether prices are entered with tax. */ - includeTaxesInPrices: Scalars['Boolean']; + readonly includeTaxesInPrices: Scalars['Boolean']; /** List of the shops's supported languages. */ - languages: Array; + readonly languages: ReadonlyArray; /** * Default number of maximum line quantity in single checkout (per single checkout line). * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_SETTINGS. */ - limitQuantityPerCheckout?: Maybe; + readonly limitQuantityPerCheckout?: Maybe; /** * Resource limitations and current usage if any set for a shop * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. - * @deprecated This field will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - limits: LimitInfo; + readonly limits: LimitInfo; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. */ - metafield?: Maybe; + readonly metafield?: Maybe; /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ - metafields?: Maybe; + readonly metafields?: Maybe; /** Shop's name. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of available permissions. */ - permissions: Array; + readonly permissions: ReadonlyArray; /** List of possible phone prefixes. */ - phonePrefixes: Array; + readonly phonePrefixes: ReadonlyArray; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. */ - privateMetafield?: Maybe; + readonly privateMetafield?: Maybe; /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ - privateMetafields?: Maybe; + readonly privateMetafields?: Maybe; /** * Default number of minutes stock will be reserved for anonymous checkout or null when stock reservation is disabled. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_SETTINGS. */ - reserveStockDurationAnonymousUser?: Maybe; + readonly reserveStockDurationAnonymousUser?: Maybe; /** * Default number of minutes stock will be reserved for authenticated checkout or null when stock reservation is disabled. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_SETTINGS. */ - reserveStockDurationAuthenticatedUser?: Maybe; - /** - * Minor Saleor API version. - * - * Added in Saleor 3.5. - */ - schemaVersion: Scalars['String']; + readonly reserveStockDurationAuthenticatedUser?: Maybe; + /** Minor Saleor API version. */ + readonly schemaVersion: Scalars['String']; /** * List of staff notification recipients. * * Requires one of the following permissions: MANAGE_SETTINGS. */ - staffNotificationRecipients?: Maybe>; + readonly staffNotificationRecipients?: Maybe>; /** This field is used as a default value for `ProductVariant.trackInventory`. */ - trackInventoryByDefault?: Maybe; + readonly trackInventoryByDefault?: Maybe; /** Returns translated shop fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** * Saleor API version. * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. */ - version: Scalars['String']; + readonly version: Scalars['String']; }; @@ -27271,7 +24304,7 @@ export type ShopMetafieldArgs = { /** Represents a shop resource containing general shop data and configuration. */ export type ShopMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -27283,7 +24316,7 @@ export type ShopPrivateMetafieldArgs = { /** Represents a shop resource containing general shop data and configuration. */ export type ShopPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -27298,49 +24331,44 @@ export type ShopTranslationArgs = { * Requires one of the following permissions: MANAGE_SETTINGS. */ export type ShopAddressUpdate = { - __typename?: 'ShopAddressUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated shop. */ - shop?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shopErrors: Array; + readonly shop?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly shopErrors: ReadonlyArray; }; /** * Updates site domain of the shop. * - * DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead. - * * Requires one of the following permissions: MANAGE_SETTINGS. */ export type ShopDomainUpdate = { - __typename?: 'ShopDomainUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated shop. */ - shop?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shopErrors: Array; + readonly shop?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly shopErrors: ReadonlyArray; }; export type ShopError = { - __typename?: 'ShopError'; /** The error code. */ - code: ShopErrorCode; + readonly code: ShopErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type ShopErrorCode = - | 'ALREADY_EXISTS' - | 'CANNOT_FETCH_TAX_RATES' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; +export enum ShopErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + CannotFetchTaxRates = 'CANNOT_FETCH_TAX_RATES', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} /** * Fetch tax rates. @@ -27348,126 +24376,89 @@ export type ShopErrorCode = * Requires one of the following permissions: MANAGE_SETTINGS. */ export type ShopFetchTaxRates = { - __typename?: 'ShopFetchTaxRates'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated shop. */ - shop?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shopErrors: Array; + readonly shop?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly shopErrors: ReadonlyArray; }; -/** - * Event sent when shop metadata is updated. - * - * Added in Saleor 3.15. - */ +/** Event sent when shop metadata is updated. */ export type ShopMetadataUpdated = Event & { - __typename?: 'ShopMetadataUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type ShopSettingsInput = { - /** - * Enable possibility to login without account confirmation. - * - * Added in Saleor 3.15. - */ - allowLoginWithoutConfirmation?: InputMaybe; + /** Enable possibility to login without account confirmation. */ + readonly allowLoginWithoutConfirmation?: InputMaybe; /** Enable automatic fulfillment for all digital products. */ - automaticFulfillmentDigitalProducts?: InputMaybe; + readonly automaticFulfillmentDigitalProducts?: InputMaybe; /** * Charge taxes on shipping. - * - * DEPRECATED: this field will be removed in Saleor 4.0. To enable taxes for a shipping method, assign a tax class to the shipping method with `shippingPriceCreate` or `shippingPriceUpdate` mutations. + * @deprecated To enable taxes for a shipping method, assign a tax class to the shipping method with `shippingPriceCreate` or `shippingPriceUpdate` mutations. */ - chargeTaxesOnShipping?: InputMaybe; + readonly chargeTaxesOnShipping?: InputMaybe; /** URL of a view where customers can set their password. */ - customerSetPasswordUrl?: InputMaybe; + readonly customerSetPasswordUrl?: InputMaybe; /** Default number of max downloads per digital content URL. */ - defaultDigitalMaxDownloads?: InputMaybe; + readonly defaultDigitalMaxDownloads?: InputMaybe; /** Default number of days which digital content URL will be valid. */ - defaultDigitalUrlValidDays?: InputMaybe; + readonly defaultDigitalUrlValidDays?: InputMaybe; /** Default email sender's address. */ - defaultMailSenderAddress?: InputMaybe; + readonly defaultMailSenderAddress?: InputMaybe; /** Default email sender's name. */ - defaultMailSenderName?: InputMaybe; + readonly defaultMailSenderName?: InputMaybe; /** Default weight unit. */ - defaultWeightUnit?: InputMaybe; + readonly defaultWeightUnit?: InputMaybe; /** SEO description. */ - description?: InputMaybe; + readonly description?: InputMaybe; /** * Display prices with tax in store. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `taxConfigurationUpdate` mutation to configure this setting per channel or country. - */ - displayGrossPrices?: InputMaybe; - /** - * Enable automatic account confirmation by email. - * - * Added in Saleor 3.14. - */ - enableAccountConfirmationByEmail?: InputMaybe; - /** - * Enable ability to approve fulfillments which are unpaid. - * - * Added in Saleor 3.1. - */ - fulfillmentAllowUnpaid?: InputMaybe; - /** - * Enable automatic approval of all new fulfillments. - * - * Added in Saleor 3.1. - */ - fulfillmentAutoApprove?: InputMaybe; + * @deprecated Use `taxConfigurationUpdate` mutation to configure this setting per channel or country. + */ + readonly displayGrossPrices?: InputMaybe; + /** Enable automatic account confirmation by email. */ + readonly enableAccountConfirmationByEmail?: InputMaybe; + /** Enable ability to approve fulfillments which are unpaid. */ + readonly fulfillmentAllowUnpaid?: InputMaybe; + /** Enable automatic approval of all new fulfillments. */ + readonly fulfillmentAutoApprove?: InputMaybe; /** Header text. */ - headerText?: InputMaybe; + readonly headerText?: InputMaybe; /** * Include taxes in prices. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `taxConfigurationUpdate` mutation to configure this setting per channel or country. - */ - includeTaxesInPrices?: InputMaybe; - /** - * Default number of maximum line quantity in single checkout. Minimum possible value is 1, default value is 50. - * - * Added in Saleor 3.1. + * @deprecated Use `taxConfigurationUpdate` mutation to configure this setting per channel or country. */ - limitQuantityPerCheckout?: InputMaybe; + readonly includeTaxesInPrices?: InputMaybe; + /** Default number of maximum line quantity in single checkout. Minimum possible value is 1, default value is 50. */ + readonly limitQuantityPerCheckout?: InputMaybe; /** - * Shop public metadata. + * Shop public metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.15. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** - * Shop private metadata. + * Shop private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.15. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; - /** - * Default number of minutes stock will be reserved for anonymous checkout. Enter 0 or null to disable. - * - * Added in Saleor 3.1. - */ - reserveStockDurationAnonymousUser?: InputMaybe; - /** - * Default number of minutes stock will be reserved for authenticated checkout. Enter 0 or null to disable. - * - * Added in Saleor 3.1. - */ - reserveStockDurationAuthenticatedUser?: InputMaybe; + readonly privateMetadata?: InputMaybe>; + /** Default number of minutes stock will be reserved for anonymous checkout. Enter 0 or null to disable. */ + readonly reserveStockDurationAnonymousUser?: InputMaybe; + /** Default number of minutes stock will be reserved for authenticated checkout. Enter 0 or null to disable. */ + readonly reserveStockDurationAuthenticatedUser?: InputMaybe; /** This field is used as a default value for `ProductVariant.trackInventory`. */ - trackInventoryByDefault?: InputMaybe; + readonly trackInventoryByDefault?: InputMaybe; }; /** @@ -27476,17 +24467,16 @@ export type ShopSettingsInput = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type ShopSettingsTranslate = { - __typename?: 'ShopSettingsTranslate'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated shop settings. */ - shop?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; + readonly shop?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; }; export type ShopSettingsTranslationInput = { - description?: InputMaybe; - headerText?: InputMaybe; + readonly description?: InputMaybe; + readonly headerText?: InputMaybe; }; /** @@ -27498,32 +24488,30 @@ export type ShopSettingsTranslationInput = { * - SHOP_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. */ export type ShopSettingsUpdate = { - __typename?: 'ShopSettingsUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated shop. */ - shop?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shopErrors: Array; + readonly shop?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly shopErrors: ReadonlyArray; }; /** Represents shop translations. */ export type ShopTranslation = Node & { - __typename?: 'ShopTranslation'; /** Translated description of sale. */ - description: Scalars['String']; + readonly description: Scalars['String']; /** Translated header text of sale. */ - headerText: Scalars['String']; + readonly headerText: Scalars['String']; /** The ID of the shop translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; }; export type SiteDomainInput = { /** Domain name for shop. */ - domain?: InputMaybe; + readonly domain?: InputMaybe; /** Shop site name. */ - name?: InputMaybe; + readonly name?: InputMaybe; }; /** @@ -27535,12 +24523,11 @@ export type SiteDomainInput = { * - STAFF_DELETED (async): A staff account was deleted. */ export type StaffBulkDelete = { - __typename?: 'StaffBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - staffErrors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly staffErrors: ReadonlyArray; }; /** @@ -27554,60 +24541,54 @@ export type StaffBulkDelete = { * - STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. */ export type StaffCreate = { - __typename?: 'StaffCreate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - staffErrors: Array; - user?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly staffErrors: ReadonlyArray; + readonly user?: Maybe; }; /** Fields required to create a staff user. */ export type StaffCreateInput = { /** List of permission group IDs to which user should be assigned. */ - addGroups?: InputMaybe>; + readonly addGroups?: InputMaybe>; /** The unique email address of the user. */ - email?: InputMaybe; + readonly email?: InputMaybe; /** Given name. */ - firstName?: InputMaybe; + readonly firstName?: InputMaybe; /** User account is active. */ - isActive?: InputMaybe; + readonly isActive?: InputMaybe; /** Family name. */ - lastName?: InputMaybe; + readonly lastName?: InputMaybe; /** - * Fields required to update the user metadata. + * Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** A note about the user. */ - note?: InputMaybe; + readonly note?: InputMaybe; /** - * Fields required to update the user private metadata. + * Fields required to update the user private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** URL of a view where users should be redirected to set the password. URL in RFC 1808 format. */ - redirectUrl?: InputMaybe; + readonly redirectUrl?: InputMaybe; }; -/** - * Event sent when new staff user is created. - * - * Added in Saleor 3.5. - */ +/** Event sent when new staff user is created. */ export type StaffCreated = Event & { - __typename?: 'StaffCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -27619,68 +24600,61 @@ export type StaffCreated = Event & { * - STAFF_DELETED (async): A staff account was deleted. */ export type StaffDelete = { - __typename?: 'StaffDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - staffErrors: Array; - user?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly staffErrors: ReadonlyArray; + readonly user?: Maybe; }; -/** - * Event sent when staff user is deleted. - * - * Added in Saleor 3.5. - */ +/** Event sent when staff user is deleted. */ export type StaffDeleted = Event & { - __typename?: 'StaffDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type StaffError = { - __typename?: 'StaffError'; /** A type of address that causes the error. */ - addressType?: Maybe; + readonly addressType?: Maybe; /** The error code. */ - code: AccountErrorCode; + readonly code: AccountErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** List of permission group IDs which cause the error. */ - groups?: Maybe>; + readonly groups?: Maybe>; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of permissions which causes the error. */ - permissions?: Maybe>; + readonly permissions?: Maybe>; /** List of user IDs which causes the error. */ - users?: Maybe>; + readonly users?: Maybe>; }; /** Represents status of a staff account. */ -export type StaffMemberStatus = +export enum StaffMemberStatus { /** User account has been activated. */ - | 'ACTIVE' + Active = 'ACTIVE', /** User account has not been activated yet. */ - | 'DEACTIVATED'; + Deactivated = 'DEACTIVATED' +} /** Represents a recipient of email notifications send by Saleor, such as notifications about new orders. Notifications can be assigned to staff users or arbitrary email addresses. */ export type StaffNotificationRecipient = Node & { - __typename?: 'StaffNotificationRecipient'; /** Determines if a notification active. */ - active?: Maybe; + readonly active?: Maybe; /** Returns email address of a user subscribed to email notifications. */ - email?: Maybe; + readonly email?: Maybe; /** The ID of the staff notification recipient. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Returns a user subscribed to email notifications. */ - user?: Maybe; + readonly user?: Maybe; }; /** @@ -27689,11 +24663,10 @@ export type StaffNotificationRecipient = Node & { * Requires one of the following permissions: MANAGE_SETTINGS. */ export type StaffNotificationRecipientCreate = { - __typename?: 'StaffNotificationRecipientCreate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shopErrors: Array; - staffNotificationRecipient?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shopErrors: ReadonlyArray; + readonly staffNotificationRecipient?: Maybe; }; /** @@ -27702,20 +24675,19 @@ export type StaffNotificationRecipientCreate = { * Requires one of the following permissions: MANAGE_SETTINGS. */ export type StaffNotificationRecipientDelete = { - __typename?: 'StaffNotificationRecipientDelete'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shopErrors: Array; - staffNotificationRecipient?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shopErrors: ReadonlyArray; + readonly staffNotificationRecipient?: Maybe; }; export type StaffNotificationRecipientInput = { /** Determines if a notification active. */ - active?: InputMaybe; + readonly active?: InputMaybe; /** Email address of a user subscribed to email notifications. */ - email?: InputMaybe; + readonly email?: InputMaybe; /** The ID of the user subscribed to email notifications.. */ - user?: InputMaybe; + readonly user?: InputMaybe; }; /** @@ -27724,38 +24696,32 @@ export type StaffNotificationRecipientInput = { * Requires one of the following permissions: MANAGE_SETTINGS. */ export type StaffNotificationRecipientUpdate = { - __typename?: 'StaffNotificationRecipientUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - shopErrors: Array; - staffNotificationRecipient?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly shopErrors: ReadonlyArray; + readonly staffNotificationRecipient?: Maybe; }; -/** - * Event sent when setting a new password for staff is requested. - * - * Added in Saleor 3.15. - */ +/** Event sent when setting a new password for staff is requested. */ export type StaffSetPasswordRequested = Event & { - __typename?: 'StaffSetPasswordRequested'; /** The channel data. */ - channel?: Maybe; + readonly channel?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The URL to redirect the user after he accepts the request. */ - redirectUrl?: Maybe; + readonly redirectUrl?: Maybe; /** Shop data. */ - shop?: Maybe; + readonly shop?: Maybe; /** The token required to confirm request. */ - token?: Maybe; + readonly token?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -27767,229 +24733,208 @@ export type StaffSetPasswordRequested = Event & { * - STAFF_UPDATED (async): A staff account was updated. */ export type StaffUpdate = { - __typename?: 'StaffUpdate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - staffErrors: Array; - user?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly staffErrors: ReadonlyArray; + readonly user?: Maybe; }; /** Fields required to update a staff user. */ export type StaffUpdateInput = { /** List of permission group IDs to which user should be assigned. */ - addGroups?: InputMaybe>; + readonly addGroups?: InputMaybe>; /** The unique email address of the user. */ - email?: InputMaybe; + readonly email?: InputMaybe; /** Given name. */ - firstName?: InputMaybe; + readonly firstName?: InputMaybe; /** User account is active. */ - isActive?: InputMaybe; + readonly isActive?: InputMaybe; /** Family name. */ - lastName?: InputMaybe; + readonly lastName?: InputMaybe; /** - * Fields required to update the user metadata. + * Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** A note about the user. */ - note?: InputMaybe; + readonly note?: InputMaybe; /** - * Fields required to update the user private metadata. + * Fields required to update the user private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** List of permission group IDs from which user should be unassigned. */ - removeGroups?: InputMaybe>; + readonly removeGroups?: InputMaybe>; }; -/** - * Event sent when staff user is updated. - * - * Added in Saleor 3.5. - */ +/** Event sent when staff user is updated. */ export type StaffUpdated = Event & { - __typename?: 'StaffUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user the event relates to. */ - user?: Maybe; + readonly user?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type StaffUserInput = { - ids?: InputMaybe>; - search?: InputMaybe; - status?: InputMaybe; + readonly ids?: InputMaybe>; + readonly search?: InputMaybe; + readonly status?: InputMaybe; }; /** Represents stock. */ export type Stock = Node & { - __typename?: 'Stock'; /** The ID of stock. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Information about the product variant. */ - productVariant: ProductVariant; + readonly productVariant: ProductVariant; /** * Quantity of a product in the warehouse's possession, including the allocated stock that is waiting for shipment. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** * Quantity allocated for orders. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. */ - quantityAllocated: Scalars['Int']; + readonly quantityAllocated: Scalars['Int']; /** * Quantity reserved for checkouts. * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. */ - quantityReserved: Scalars['Int']; + readonly quantityReserved: Scalars['Int']; /** The warehouse associated with the stock. */ - warehouse: Warehouse; + readonly warehouse: Warehouse; }; -export type StockAvailability = - | 'IN_STOCK' - | 'OUT_OF_STOCK'; +export enum StockAvailability { + InStock = 'IN_STOCK', + OutOfStock = 'OUT_OF_STOCK' +} export type StockBulkResult = { - __typename?: 'StockBulkResult'; /** List of errors occurred on create or update attempt. */ - errors?: Maybe>; + readonly errors?: Maybe>; /** Stock data. */ - stock?: Maybe; + readonly stock?: Maybe; }; /** * Updates stocks for a given variant and warehouse. Variant and warehouse selectors have to be the same for all stock inputs. Is not allowed to use 'variantId' in one input and 'variantExternalReference' in another. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: MANAGE_PRODUCTS. * * Triggers the following webhook events: * - PRODUCT_VARIANT_STOCK_UPDATED (async): A product variant stock details were updated. */ export type StockBulkUpdate = { - __typename?: 'StockBulkUpdate'; /** Returns how many objects were updated. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; /** List of the updated stocks. */ - results: Array; + readonly results: ReadonlyArray; }; export type StockBulkUpdateError = { - __typename?: 'StockBulkUpdateError'; /** The error code. */ - code: StockBulkUpdateErrorCode; + readonly code: StockBulkUpdateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type StockBulkUpdateErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum StockBulkUpdateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} export type StockBulkUpdateInput = { /** Quantity of items available for sell. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Variant external reference. */ - variantExternalReference?: InputMaybe; + readonly variantExternalReference?: InputMaybe; /** Variant ID. */ - variantId?: InputMaybe; + readonly variantId?: InputMaybe; /** Warehouse external reference. */ - warehouseExternalReference?: InputMaybe; + readonly warehouseExternalReference?: InputMaybe; /** Warehouse ID. */ - warehouseId?: InputMaybe; + readonly warehouseId?: InputMaybe; }; export type StockCountableConnection = { - __typename?: 'StockCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type StockCountableEdge = { - __typename?: 'StockCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Stock; + readonly node: Stock; }; export type StockError = { - __typename?: 'StockError'; /** The error code. */ - code: StockErrorCode; + readonly code: StockErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type StockErrorCode = - | 'ALREADY_EXISTS' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; +export enum StockErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type StockFilterInput = { - quantity?: InputMaybe; - search?: InputMaybe; + readonly quantity?: InputMaybe; + readonly search?: InputMaybe; }; export type StockInput = { /** Quantity of items available for sell. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Warehouse in which stock is located. */ - warehouse: Scalars['ID']; + readonly warehouse: Scalars['ID']; }; -/** - * Represents the channel stock settings. - * - * Added in Saleor 3.7. - */ +/** Represents the channel stock settings. */ export type StockSettings = { - __typename?: 'StockSettings'; /** Allocation strategy defines the preference of warehouses for allocations and reservations. */ - allocationStrategy: AllocationStrategyEnum; + readonly allocationStrategy: AllocationStrategyEnum; }; export type StockSettingsInput = { /** Allocation strategy options. Strategy defines the preference of warehouses for allocations and reservations. */ - allocationStrategy: AllocationStrategyEnum; + readonly allocationStrategy: AllocationStrategyEnum; }; export type StockUpdateInput = { /** Quantity of items available for sell. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** Stock. */ - stock: Scalars['ID']; + readonly stock: Scalars['ID']; }; /** @@ -27999,97 +24944,80 @@ export type StockUpdateInput = { * UPDATE - only do update, if there is enough stock. * FORCE - force update, if there is not enough stock. */ -export type StockUpdatePolicyEnum = - | 'FORCE' - | 'SKIP' - | 'UPDATE'; +export enum StockUpdatePolicyEnum { + Force = 'FORCE', + Skip = 'SKIP', + Update = 'UPDATE' +} /** Enum representing the type of a payment storage in a gateway. */ -export type StorePaymentMethodEnum = +export enum StorePaymentMethodEnum { /** Storage is disabled. The payment is not stored. */ - | 'NONE' + None = 'NONE', /** Off session storage type. The payment is stored to be reused even if the customer is absent. */ - | 'OFF_SESSION' + OffSession = 'OFF_SESSION', /** On session storage type. The payment is stored only to be reused when the customer is present in the checkout flow. */ - | 'ON_SESSION'; + OnSession = 'ON_SESSION' +} -/** - * Represents a payment method stored for user (tokenized) in payment gateway. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents a payment method stored for user (tokenized) in payment gateway. */ export type StoredPaymentMethod = { - __typename?: 'StoredPaymentMethod'; /** Stored credit card details if available. */ - creditCardInfo?: Maybe; + readonly creditCardInfo?: Maybe; /** JSON data returned by Payment Provider app for this payment method. */ - data?: Maybe; + readonly data?: Maybe; /** Payment gateway that stores this payment method. */ - gateway: PaymentGateway; + readonly gateway: PaymentGateway; /** Stored payment method ID. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Payment method name. Example: last 4 digits of credit card, obfuscated email, etc. */ - name?: Maybe; + readonly name?: Maybe; /** ID of stored payment method used to make payment actions. Note: method ID is unique only within the payment gateway. */ - paymentMethodId: Scalars['String']; - supportedPaymentFlows?: Maybe>; + readonly paymentMethodId: Scalars['String']; + readonly supportedPaymentFlows?: Maybe>; /** Type of the payment method. Example: credit card, wallet, etc. */ - type: Scalars['String']; + readonly type: Scalars['String']; }; -/** - * Event sent when user requests to delete a payment method. - * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when user requests to delete a payment method. */ export type StoredPaymentMethodDeleteRequested = Event & { - __typename?: 'StoredPaymentMethodDeleteRequested'; /** Channel related to the requested delete action. */ - channel: Channel; + readonly channel: Channel; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The ID of the payment method that should be deleted by the payment gateway. */ - paymentMethodId: Scalars['String']; + readonly paymentMethodId: Scalars['String']; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The user for which the app should proceed with payment method delete request. */ - user: User; + readonly user: User; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Request to delete a stored payment method on payment provider side. * - * Added in Saleor 3.16. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_USER. * * Triggers the following webhook events: * - STORED_PAYMENT_METHOD_DELETE_REQUESTED (sync): The customer requested to delete a payment method. */ export type StoredPaymentMethodRequestDelete = { - __typename?: 'StoredPaymentMethodRequestDelete'; - errors: Array; + readonly errors: ReadonlyArray; /** The result of deleting a stored payment method. */ - result: StoredPaymentMethodRequestDeleteResult; + readonly result: StoredPaymentMethodRequestDeleteResult; }; -/** An enumeration. */ -export type StoredPaymentMethodRequestDeleteErrorCode = - | 'CHANNEL_INACTIVE' - | 'GATEWAY_ERROR' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum StoredPaymentMethodRequestDeleteErrorCode { + ChannelInactive = 'CHANNEL_INACTIVE', + GatewayError = 'GATEWAY_ERROR', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} /** * Result of deleting a stored payment method. @@ -28100,27 +25028,53 @@ export type StoredPaymentMethodRequestDeleteErrorCode = * FAILED_TO_DELIVER - The request to delete the stored payment method was not * delivered. */ -export type StoredPaymentMethodRequestDeleteResult = - | 'FAILED_TO_DELETE' - | 'FAILED_TO_DELIVER' - | 'SUCCESSFULLY_DELETED'; +export enum StoredPaymentMethodRequestDeleteResult { + FailedToDelete = 'FAILED_TO_DELETE', + FailedToDeliver = 'FAILED_TO_DELIVER', + SuccessfullyDeleted = 'SUCCESSFULLY_DELETED' +} -/** - * Define the filtering options for string fields. - * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Define the filtering options for string fields. */ export type StringFilterInput = { /** The value equal to. */ - eq?: InputMaybe; + readonly eq?: InputMaybe; /** The value included in. */ - oneOf?: InputMaybe>; + readonly oneOf?: InputMaybe>; }; export type Subscription = { - __typename?: 'Subscription'; + /** + * Event sent when new checkout is created. + * + * Added in Saleor 3.21. + * + * Note: this API is currently in Feature Preview and can be subject to changes at later point. + */ + readonly checkoutCreated?: Maybe; + /** + * Event sent when checkout is fully-paid. + * + * Added in Saleor 3.21. + * + * Note: this API is currently in Feature Preview and can be subject to changes at later point. + */ + readonly checkoutFullyPaid?: Maybe; + /** + * Event sent when checkout metadata is updated. + * + * Added in Saleor 3.21. + * + * Note: this API is currently in Feature Preview and can be subject to changes at later point. + */ + readonly checkoutMetadataUpdated?: Maybe; + /** + * Event sent when checkout is updated. + * + * Added in Saleor 3.21. + * + * Note: this API is currently in Feature Preview and can be subject to changes at later point. + */ + readonly checkoutUpdated?: Maybe; /** * Event sent when new draft order is created. * @@ -28128,7 +25082,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - draftOrderCreated?: Maybe; + readonly draftOrderCreated?: Maybe; /** * Event sent when draft order is deleted. * @@ -28136,7 +25090,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - draftOrderDeleted?: Maybe; + readonly draftOrderDeleted?: Maybe; /** * Event sent when draft order is updated. * @@ -28144,13 +25098,9 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - draftOrderUpdated?: Maybe; - /** - * Look up subscription event. - * - * Added in Saleor 3.2. - */ - event?: Maybe; + readonly draftOrderUpdated?: Maybe; + /** Look up subscription event. */ + readonly event?: Maybe; /** * Event sent when orders are imported. * @@ -28158,7 +25108,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderBulkCreated?: Maybe; + readonly orderBulkCreated?: Maybe; /** * Event sent when order is cancelled. * @@ -28166,7 +25116,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderCancelled?: Maybe; + readonly orderCancelled?: Maybe; /** * Event sent when order is confirmed. * @@ -28174,7 +25124,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderConfirmed?: Maybe; + readonly orderConfirmed?: Maybe; /** * Event sent when new order is created. * @@ -28182,7 +25132,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderCreated?: Maybe; + readonly orderCreated?: Maybe; /** * Event sent when order becomes expired. * @@ -28190,7 +25140,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderExpired?: Maybe; + readonly orderExpired?: Maybe; /** * Event sent when order is fulfilled. * @@ -28198,7 +25148,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderFulfilled?: Maybe; + readonly orderFulfilled?: Maybe; /** * Event sent when order is fully paid. * @@ -28206,7 +25156,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderFullyPaid?: Maybe; + readonly orderFullyPaid?: Maybe; /** * The order is fully refunded. * @@ -28214,7 +25164,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderFullyRefunded?: Maybe; + readonly orderFullyRefunded?: Maybe; /** * Event sent when order metadata is updated. * @@ -28222,7 +25172,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderMetadataUpdated?: Maybe; + readonly orderMetadataUpdated?: Maybe; /** * Payment has been made. The order may be partially or fully paid. * @@ -28230,7 +25180,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderPaid?: Maybe; + readonly orderPaid?: Maybe; /** * The order received a refund. The order may be partially or fully refunded. * @@ -28238,7 +25188,7 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderRefunded?: Maybe; + readonly orderRefunded?: Maybe; /** * Event sent when order is updated. * @@ -28246,661 +25196,594 @@ export type Subscription = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - orderUpdated?: Maybe; + readonly orderUpdated?: Maybe; +}; + + +export type SubscriptionCheckoutCreatedArgs = { + channels?: InputMaybe>; +}; + + +export type SubscriptionCheckoutFullyPaidArgs = { + channels?: InputMaybe>; +}; + + +export type SubscriptionCheckoutMetadataUpdatedArgs = { + channels?: InputMaybe>; +}; + + +export type SubscriptionCheckoutUpdatedArgs = { + channels?: InputMaybe>; }; export type SubscriptionDraftOrderCreatedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionDraftOrderDeletedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionDraftOrderUpdatedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderBulkCreatedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderCancelledArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderConfirmedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderCreatedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderExpiredArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderFulfilledArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderFullyPaidArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderFullyRefundedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderMetadataUpdatedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderPaidArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderRefundedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; export type SubscriptionOrderUpdatedArgs = { - channels?: InputMaybe>; + channels?: InputMaybe>; }; -export type TaxCalculationStrategy = - | 'FLAT_RATES' - | 'TAX_APP'; +export enum TaxCalculationStrategy { + FlatRates = 'FLAT_RATES', + TaxApp = 'TAX_APP' +} -/** - * Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. - * - * Added in Saleor 3.9. - */ +/** Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. */ export type TaxClass = Node & ObjectWithMetadata & { - __typename?: 'TaxClass'; /** Country-specific tax rates for this tax class. */ - countries: Array; + readonly countries: ReadonlyArray; /** The ID of the object. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Name of the tax class. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; }; -/** - * Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. - * - * Added in Saleor 3.9. - */ +/** Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. */ export type TaxClassMetafieldArgs = { key: Scalars['String']; }; -/** - * Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. - * - * Added in Saleor 3.9. - */ +/** Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. */ export type TaxClassMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; -/** - * Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. - * - * Added in Saleor 3.9. - */ +/** Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. */ export type TaxClassPrivateMetafieldArgs = { key: Scalars['String']; }; -/** - * Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. - * - * Added in Saleor 3.9. - */ +/** Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. */ export type TaxClassPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; export type TaxClassCountableConnection = { - __typename?: 'TaxClassCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type TaxClassCountableEdge = { - __typename?: 'TaxClassCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: TaxClass; + readonly node: TaxClass; }; -/** - * Tax rate for a country. When tax class is null, it represents the default tax rate for that country; otherwise it's a country tax rate specific to the given tax class. - * - * Added in Saleor 3.9. - */ +/** Tax rate for a country. When tax class is null, it represents the default tax rate for that country; otherwise it's a country tax rate specific to the given tax class. */ export type TaxClassCountryRate = { - __typename?: 'TaxClassCountryRate'; /** Country in which this tax rate applies. */ - country: CountryDisplay; + readonly country: CountryDisplay; /** Tax rate value. */ - rate: Scalars['Float']; + readonly rate: Scalars['Float']; /** Related tax class. */ - taxClass?: Maybe; + readonly taxClass?: Maybe; }; /** * Create a tax class. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ export type TaxClassCreate = { - __typename?: 'TaxClassCreate'; - errors: Array; - taxClass?: Maybe; + readonly errors: ReadonlyArray; + readonly taxClass?: Maybe; }; export type TaxClassCreateError = { - __typename?: 'TaxClassCreateError'; /** The error code. */ - code: TaxClassCreateErrorCode; + readonly code: TaxClassCreateErrorCode; /** List of country codes for which the configuration is invalid. */ - countryCodes: Array; + readonly countryCodes: ReadonlyArray; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TaxClassCreateErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum TaxClassCreateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} export type TaxClassCreateInput = { /** List of country-specific tax rates to create for this tax class. */ - createCountryRates?: InputMaybe>; + readonly createCountryRates?: InputMaybe>; /** Name of the tax class. */ - name: Scalars['String']; + readonly name: Scalars['String']; }; /** * Delete a tax class. After deleting the tax class any products, product types or shipping methods using it are updated to use the default tax class. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ export type TaxClassDelete = { - __typename?: 'TaxClassDelete'; - errors: Array; - taxClass?: Maybe; + readonly errors: ReadonlyArray; + readonly taxClass?: Maybe; }; export type TaxClassDeleteError = { - __typename?: 'TaxClassDeleteError'; /** The error code. */ - code: TaxClassDeleteErrorCode; + readonly code: TaxClassDeleteErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TaxClassDeleteErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum TaxClassDeleteErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} export type TaxClassFilterInput = { - countries?: InputMaybe>; - ids?: InputMaybe>; - metadata?: InputMaybe>; + readonly countries?: InputMaybe>; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; }; export type TaxClassRateInput = { /** Tax rate value. */ - rate?: InputMaybe; + readonly rate?: InputMaybe; /** ID of a tax class for which to update the tax rate */ - taxClassId?: InputMaybe; + readonly taxClassId?: InputMaybe; }; -export type TaxClassSortField = +export enum TaxClassSortField { /** Sort tax classes by name. */ - | 'NAME'; + Name = 'NAME' +} export type TaxClassSortingInput = { /** Specifies the direction in which to sort tax classes. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort tax classes by the selected field. */ - field: TaxClassSortField; + readonly field: TaxClassSortField; }; /** * Update a tax class. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ export type TaxClassUpdate = { - __typename?: 'TaxClassUpdate'; - errors: Array; - taxClass?: Maybe; + readonly errors: ReadonlyArray; + readonly taxClass?: Maybe; }; export type TaxClassUpdateError = { - __typename?: 'TaxClassUpdateError'; /** The error code. */ - code: TaxClassUpdateErrorCode; + readonly code: TaxClassUpdateErrorCode; /** List of country codes for which the configuration is invalid. */ - countryCodes: Array; + readonly countryCodes: ReadonlyArray; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TaxClassUpdateErrorCode = - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum TaxClassUpdateErrorCode { + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} export type TaxClassUpdateInput = { /** Name of the tax class. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** List of country codes for which to remove the tax class rates. Note: It removes all rates for given country code. */ - removeCountryRates?: InputMaybe>; + readonly removeCountryRates?: InputMaybe>; /** List of country-specific tax rates to create or update for this tax class. */ - updateCountryRates?: InputMaybe>; + readonly updateCountryRates?: InputMaybe>; }; -/** - * Channel-specific tax configuration. - * - * Added in Saleor 3.9. - */ +/** Channel-specific tax configuration. */ export type TaxConfiguration = Node & ObjectWithMetadata & { - __typename?: 'TaxConfiguration'; /** A channel to which the tax configuration applies to. */ - channel: Channel; + readonly channel: Channel; /** Determines whether taxes are charged in the given channel. */ - chargeTaxes: Scalars['Boolean']; + readonly chargeTaxes: Scalars['Boolean']; /** List of country-specific exceptions in tax configuration. */ - countries: Array; + readonly countries: ReadonlyArray; /** Determines whether displayed prices should include taxes. */ - displayGrossPrices: Scalars['Boolean']; + readonly displayGrossPrices: Scalars['Boolean']; /** The ID of the object. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Determines whether prices are entered with the tax included. */ - pricesEnteredWithTax: Scalars['Boolean']; + readonly pricesEnteredWithTax: Scalars['Boolean']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** * The tax app `App.identifier` that will be used to calculate the taxes for the given channel. Empty value for `TAX_APP` set as `taxCalculationStrategy` means that Saleor will iterate over all installed tax apps. If multiple tax apps exist with provided tax app id use the `App` with newest `created` date. Will become mandatory in 4.0 for `TAX_APP` `taxCalculationStrategy`. * * Added in Saleor 3.19. */ - taxAppId?: Maybe; + readonly taxAppId?: Maybe; /** The default strategy to use for tax calculation in the given channel. Taxes can be calculated either using user-defined flat rates or with a tax app. Empty value means that no method is selected and taxes are not calculated. */ - taxCalculationStrategy?: Maybe; + readonly taxCalculationStrategy?: Maybe; + /** + * Determines whether to use weighted tax for shipping. When set to true, the tax rate for shipping will be calculated based on the weighted average of tax rates from the order or checkout lines. + * + * Added in Saleor 3.21. + */ + readonly useWeightedTaxForShipping?: Maybe; }; -/** - * Channel-specific tax configuration. - * - * Added in Saleor 3.9. - */ +/** Channel-specific tax configuration. */ export type TaxConfigurationMetafieldArgs = { key: Scalars['String']; }; -/** - * Channel-specific tax configuration. - * - * Added in Saleor 3.9. - */ +/** Channel-specific tax configuration. */ export type TaxConfigurationMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; -/** - * Channel-specific tax configuration. - * - * Added in Saleor 3.9. - */ +/** Channel-specific tax configuration. */ export type TaxConfigurationPrivateMetafieldArgs = { key: Scalars['String']; }; -/** - * Channel-specific tax configuration. - * - * Added in Saleor 3.9. - */ +/** Channel-specific tax configuration. */ export type TaxConfigurationPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; export type TaxConfigurationCountableConnection = { - __typename?: 'TaxConfigurationCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type TaxConfigurationCountableEdge = { - __typename?: 'TaxConfigurationCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: TaxConfiguration; + readonly node: TaxConfiguration; }; export type TaxConfigurationFilterInput = { - ids?: InputMaybe>; - metadata?: InputMaybe>; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; }; -/** - * Country-specific exceptions of a channel's tax configuration. - * - * Added in Saleor 3.9. - */ +/** Country-specific exceptions of a channel's tax configuration. */ export type TaxConfigurationPerCountry = { - __typename?: 'TaxConfigurationPerCountry'; /** Determines whether taxes are charged in this country. */ - chargeTaxes: Scalars['Boolean']; + readonly chargeTaxes: Scalars['Boolean']; /** Country in which this configuration applies. */ - country: CountryDisplay; + readonly country: CountryDisplay; /** Determines whether displayed prices should include taxes for this country. */ - displayGrossPrices: Scalars['Boolean']; + readonly displayGrossPrices: Scalars['Boolean']; /** * The tax app `App.identifier` that will be used to calculate the taxes for the given channel and country. If not provided, use the value from the channel's tax configuration. * * Added in Saleor 3.19. */ - taxAppId?: Maybe; + readonly taxAppId?: Maybe; /** A country-specific strategy to use for tax calculation. Taxes can be calculated either using user-defined flat rates or with a tax app. If not provided, use the value from the channel's tax configuration. */ - taxCalculationStrategy?: Maybe; + readonly taxCalculationStrategy?: Maybe; + /** + * Determines whether to use weighted tax for shipping. When set to true, the tax rate for shipping will be calculated based on the weighted average of tax rates from the order or checkout lines. + * + * Added in Saleor 3.21. + */ + readonly useWeightedTaxForShipping?: Maybe; }; export type TaxConfigurationPerCountryInput = { /** Determines whether taxes are charged in this country. */ - chargeTaxes: Scalars['Boolean']; + readonly chargeTaxes: Scalars['Boolean']; /** Country in which this configuration applies. */ - countryCode: CountryCode; + readonly countryCode: CountryCode; /** Determines whether displayed prices should include taxes for this country. */ - displayGrossPrices: Scalars['Boolean']; + readonly displayGrossPrices: Scalars['Boolean']; /** * The tax app `App.identifier` that will be used to calculate the taxes for the given channel and country. If not provided, use the value from the channel's tax configuration. * * Added in Saleor 3.19. */ - taxAppId?: InputMaybe; + readonly taxAppId?: InputMaybe; /** A country-specific strategy to use for tax calculation. Taxes can be calculated either using user-defined flat rates or with a tax app. If not provided, use the value from the channel's tax configuration. */ - taxCalculationStrategy?: InputMaybe; + readonly taxCalculationStrategy?: InputMaybe; + /** + * Determines whether to use weighted tax for shipping. When set to true, the tax rate for shipping will be calculated based on the weighted average of tax rates from the order or checkout lines. Default value is `False`.Can be used only with `taxCalculationStrategy` set to `FLAT_RATES`. + * + * Added in Saleor 3.21. + */ + readonly useWeightedTaxForShipping?: InputMaybe; }; /** * Update tax configuration for a channel. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ export type TaxConfigurationUpdate = { - __typename?: 'TaxConfigurationUpdate'; - errors: Array; - taxConfiguration?: Maybe; + readonly errors: ReadonlyArray; + readonly taxConfiguration?: Maybe; }; export type TaxConfigurationUpdateError = { - __typename?: 'TaxConfigurationUpdateError'; /** The error code. */ - code: TaxConfigurationUpdateErrorCode; + readonly code: TaxConfigurationUpdateErrorCode; /** List of country codes for which the configuration is invalid. */ - countryCodes: Array; + readonly countryCodes: ReadonlyArray; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TaxConfigurationUpdateErrorCode = - | 'DUPLICATED_INPUT_ITEM' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum TaxConfigurationUpdateErrorCode { + DuplicatedInputItem = 'DUPLICATED_INPUT_ITEM', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} export type TaxConfigurationUpdateInput = { /** Determines whether taxes are charged in the given channel. */ - chargeTaxes?: InputMaybe; + readonly chargeTaxes?: InputMaybe; /** Determines whether displayed prices should include taxes. */ - displayGrossPrices?: InputMaybe; + readonly displayGrossPrices?: InputMaybe; /** Determines whether prices are entered with the tax included. */ - pricesEnteredWithTax?: InputMaybe; + readonly pricesEnteredWithTax?: InputMaybe; /** List of country codes for which to remove the tax configuration. */ - removeCountriesConfiguration?: InputMaybe>; + readonly removeCountriesConfiguration?: InputMaybe>; /** * The tax app `App.identifier` that will be used to calculate the taxes for the given channel. Empty value for `TAX_APP` set as `taxCalculationStrategy` means that Saleor will iterate over all installed tax apps. If multiple tax apps exist with provided tax app id use the `App` with newest `created` date. It's possible to set plugin by using prefix `plugin:` with `PLUGIN_ID` e.g. with Avalara `plugin:mirumee.taxes.avalara`.Will become mandatory in 4.0 for `TAX_APP` `taxCalculationStrategy`. * * Added in Saleor 3.19. */ - taxAppId?: InputMaybe; + readonly taxAppId?: InputMaybe; /** The default strategy to use for tax calculation in the given channel. Taxes can be calculated either using user-defined flat rates or with a tax app. Empty value means that no method is selected and taxes are not calculated. */ - taxCalculationStrategy?: InputMaybe; + readonly taxCalculationStrategy?: InputMaybe; /** List of tax country configurations to create or update (identified by a country code). */ - updateCountriesConfiguration?: InputMaybe>; + readonly updateCountriesConfiguration?: InputMaybe>; + /** + * Determines whether to use weighted tax for shipping. When set to true, the tax rate for shipping will be calculated based on the weighted average of tax rates from the order or checkout lines. Default value is `False`.Can be used only with `taxCalculationStrategy` set to `FLAT_RATES`. + * + * Added in Saleor 3.21. + */ + readonly useWeightedTaxForShipping?: InputMaybe; }; -/** - * Tax class rates grouped by country. - * - * Added in Saleor 3.9. - */ +/** Tax class rates grouped by country. */ export type TaxCountryConfiguration = { - __typename?: 'TaxCountryConfiguration'; /** A country for which tax class rates are grouped. */ - country: CountryDisplay; + readonly country: CountryDisplay; /** List of tax class rates. */ - taxClassCountryRates: Array; + readonly taxClassCountryRates: ReadonlyArray; }; /** * Remove all tax class rates for a specific country. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ export type TaxCountryConfigurationDelete = { - __typename?: 'TaxCountryConfigurationDelete'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated tax class rates grouped by a country. */ - taxCountryConfiguration?: Maybe; + readonly taxCountryConfiguration?: Maybe; }; export type TaxCountryConfigurationDeleteError = { - __typename?: 'TaxCountryConfigurationDeleteError'; /** The error code. */ - code: TaxCountryConfigurationDeleteErrorCode; + readonly code: TaxCountryConfigurationDeleteErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TaxCountryConfigurationDeleteErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum TaxCountryConfigurationDeleteErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} /** * Update tax class rates for a specific country. * - * Added in Saleor 3.9. - * * Requires one of the following permissions: MANAGE_TAXES. */ export type TaxCountryConfigurationUpdate = { - __typename?: 'TaxCountryConfigurationUpdate'; - errors: Array; + readonly errors: ReadonlyArray; /** Updated tax class rates grouped by a country. */ - taxCountryConfiguration?: Maybe; + readonly taxCountryConfiguration?: Maybe; }; export type TaxCountryConfigurationUpdateError = { - __typename?: 'TaxCountryConfigurationUpdateError'; /** The error code. */ - code: TaxCountryConfigurationUpdateErrorCode; + readonly code: TaxCountryConfigurationUpdateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of tax class IDs for which the update failed. */ - taxClassIds: Array; + readonly taxClassIds: ReadonlyArray; }; -/** An enumeration. */ -export type TaxCountryConfigurationUpdateErrorCode = - | 'CANNOT_CREATE_NEGATIVE_RATE' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'ONLY_ONE_DEFAULT_COUNTRY_RATE_ALLOWED'; +export enum TaxCountryConfigurationUpdateErrorCode { + CannotCreateNegativeRate = 'CANNOT_CREATE_NEGATIVE_RATE', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + OnlyOneDefaultCountryRateAllowed = 'ONLY_ONE_DEFAULT_COUNTRY_RATE_ALLOWED' +} /** * Exempt checkout or order from charging the taxes. When tax exemption is enabled, taxes won't be charged for the checkout or order. Taxes may still be calculated in cases when product prices are entered with the tax included and the net price needs to be known. * - * Added in Saleor 3.8. - * * Requires one of the following permissions: MANAGE_TAXES. */ export type TaxExemptionManage = { - __typename?: 'TaxExemptionManage'; - errors: Array; - taxableObject?: Maybe; + readonly errors: ReadonlyArray; + readonly taxableObject?: Maybe; }; export type TaxExemptionManageError = { - __typename?: 'TaxExemptionManageError'; /** The error code. */ - code: TaxExemptionManageErrorCode; + readonly code: TaxExemptionManageErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TaxExemptionManageErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_EDITABLE_ORDER' - | 'NOT_FOUND'; +export enum TaxExemptionManageErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotEditableOrder = 'NOT_EDITABLE_ORDER', + NotFound = 'NOT_FOUND' +} export type TaxSourceLine = CheckoutLine | OrderLine; @@ -28908,166 +25791,139 @@ export type TaxSourceObject = Checkout | Order; /** Representation of tax types fetched from tax gateway. */ export type TaxType = { - __typename?: 'TaxType'; /** Description of the tax type. */ - description?: Maybe; + readonly description?: Maybe; /** External tax code used to identify given tax group. */ - taxCode?: Maybe; + readonly taxCode?: Maybe; }; /** Taxable object. */ export type TaxableObject = { - __typename?: 'TaxableObject'; /** The address data. */ - address?: Maybe
; - channel: Channel; + readonly address?: Maybe
; + readonly channel: Channel; /** The currency of the object. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; /** List of discounts. */ - discounts: Array; + readonly discounts: ReadonlyArray; /** List of lines assigned to the object. */ - lines: Array; + readonly lines: ReadonlyArray; /** Determines if prices contain entered tax.. */ - pricesEnteredWithTax: Scalars['Boolean']; + readonly pricesEnteredWithTax: Scalars['Boolean']; /** The price of shipping method, includes shipping voucher discount if applied. */ - shippingPrice: Money; + readonly shippingPrice: Money; /** The source object related to this tax object. */ - sourceObject: TaxSourceObject; + readonly sourceObject: TaxSourceObject; }; /** Taxable object discount. */ export type TaxableObjectDiscount = { - __typename?: 'TaxableObjectDiscount'; /** The amount of the discount. */ - amount: Money; + readonly amount: Money; /** The name of the discount. */ - name?: Maybe; + readonly name?: Maybe; /** Indicates which part of the order the discount should affect: SUBTOTAL or SHIPPING. */ - type: TaxableObjectDiscountTypeEnum; + readonly type: TaxableObjectDiscountTypeEnum; }; /** Indicates which part of the order the discount should affect: SUBTOTAL or SHIPPING. */ -export type TaxableObjectDiscountTypeEnum = - | 'SHIPPING' - | 'SUBTOTAL'; +export enum TaxableObjectDiscountTypeEnum { + Shipping = 'SHIPPING', + Subtotal = 'SUBTOTAL' +} export type TaxableObjectLine = { - __typename?: 'TaxableObjectLine'; /** Determines if taxes are being charged for the product. */ - chargeTaxes: Scalars['Boolean']; + readonly chargeTaxes: Scalars['Boolean']; /** The product name. */ - productName: Scalars['String']; + readonly productName: Scalars['String']; /** The product sku. */ - productSku?: Maybe; + readonly productSku?: Maybe; /** Number of items. */ - quantity: Scalars['Int']; + readonly quantity: Scalars['Int']; /** The source line related to this tax line. */ - sourceLine: TaxSourceLine; + readonly sourceLine: TaxSourceLine; /** Price of the order line. The price includes catalogue promotions, specific product and applied once per order voucher discounts. The price does not include the entire order discount. */ - totalPrice: Money; + readonly totalPrice: Money; /** Price of the single item in the order line. The price includes catalogue promotions, specific product and applied once per order voucher discounts. The price does not include the entire order discount. */ - unitPrice: Money; + readonly unitPrice: Money; /** The variant name. */ - variantName: Scalars['String']; + readonly variantName: Scalars['String']; }; /** Represents a monetary value with taxes. In cases where taxes were not applied, net and gross values will be equal. */ export type TaxedMoney = { - __typename?: 'TaxedMoney'; /** Currency code. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; /** Amount of money including taxes. */ - gross: Money; + readonly gross: Money; /** Amount of money without taxes. */ - net: Money; + readonly net: Money; /** Amount of taxes. */ - tax: Money; + readonly tax: Money; }; export type TaxedMoneyInput = { /** Gross value of an item. */ - gross: Scalars['PositiveDecimal']; + readonly gross: Scalars['PositiveDecimal']; /** Net value of an item. */ - net: Scalars['PositiveDecimal']; + readonly net: Scalars['PositiveDecimal']; }; /** Represents a range of monetary values. */ export type TaxedMoneyRange = { - __typename?: 'TaxedMoneyRange'; /** Lower bound of a price range. */ - start?: Maybe; + readonly start?: Maybe; /** Upper bound of a price range. */ - stop?: Maybe; + readonly stop?: Maybe; }; -/** - * Event sent when thumbnail is created. - * - * Added in Saleor 3.12. - */ +/** Event sent when thumbnail is created. */ export type ThumbnailCreated = Event & { - __typename?: 'ThumbnailCreated'; - /** - * Thumbnail id. - * - * Added in Saleor 3.12. - */ - id?: Maybe; + /** Thumbnail id. */ + readonly id?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; - /** - * Original media url. - * - * Added in Saleor 3.12. - */ - mediaUrl?: Maybe; - /** - * Object the thumbnail refers to. - * - * Added in Saleor 3.12. - */ - objectId?: Maybe; + readonly issuingPrincipal?: Maybe; + /** Original media url. */ + readonly mediaUrl?: Maybe; + /** Object the thumbnail refers to. */ + readonly objectId?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; - /** - * Thumbnail url. - * - * Added in Saleor 3.12. - */ - url?: Maybe; + readonly recipient?: Maybe; + /** Thumbnail url. */ + readonly url?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** An enumeration. */ -export type ThumbnailFormatEnum = - | 'AVIF' - | 'ORIGINAL' - | 'WEBP'; +export enum ThumbnailFormatEnum { + Avif = 'AVIF', + Original = 'ORIGINAL', + Webp = 'WEBP' +} export type TimePeriod = { - __typename?: 'TimePeriod'; /** The length of the period. */ - amount: Scalars['Int']; + readonly amount: Scalars['Int']; /** The type of the period. */ - type: TimePeriodTypeEnum; + readonly type: TimePeriodTypeEnum; }; export type TimePeriodInputType = { /** The length of the period. */ - amount: Scalars['Int']; + readonly amount: Scalars['Int']; /** The type of the period. */ - type: TimePeriodTypeEnum; + readonly type: TimePeriodTypeEnum; }; -/** An enumeration. */ -export type TimePeriodTypeEnum = - | 'DAY' - | 'MONTH' - | 'WEEK' - | 'YEAR'; +export enum TimePeriodTypeEnum { + Day = 'DAY', + Month = 'MONTH', + Week = 'WEEK', + Year = 'YEAR' +} /** * Represents possible tokenized payment flows that can be used to process payment. @@ -29076,44 +25932,39 @@ export type TimePeriodTypeEnum = * INTERACTIVE - Payment method can be used for 1 click checkout - it's prefilled in * checkout form (might require additional authentication from user) */ -export type TokenizedPaymentFlowEnum = - | 'INTERACTIVE'; +export enum TokenizedPaymentFlowEnum { + Interactive = 'INTERACTIVE' +} /** An object representing a single payment. */ export type Transaction = Node & { - __typename?: 'Transaction'; /** Total amount of the transaction. */ - amount?: Maybe; + readonly amount?: Maybe; /** Date and time at which transaction was created. */ - created: Scalars['DateTime']; + readonly created: Scalars['DateTime']; /** Error associated with transaction, if any. */ - error?: Maybe; + readonly error?: Maybe; /** Response returned by payment gateway. */ - gatewayResponse: Scalars['JSONString']; + readonly gatewayResponse: Scalars['JSONString']; /** ID of the transaction. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Determines if the transaction was successful. */ - isSuccess: Scalars['Boolean']; + readonly isSuccess: Scalars['Boolean']; /** Determines the type of transaction. */ - kind: TransactionKind; + readonly kind: TransactionKind; /** Determines the payment associated with a transaction. */ - payment: Payment; + readonly payment: Payment; /** Unique token associated with a transaction. */ - token: Scalars['String']; + readonly token: Scalars['String']; }; export type TransactionAction = { - __typename?: 'TransactionAction'; /** Determines the action type. */ - actionType: TransactionActionEnum; - /** Transaction request amount. Null when action type is VOID. */ - amount?: Maybe; - /** - * Currency code. - * - * Added in Saleor 3.16. - */ - currency: Scalars['String']; + readonly actionType: TransactionActionEnum; + /** Transaction request amount. */ + readonly amount: Scalars['PositiveDecimal']; + /** Currency code. */ + readonly currency: Scalars['String']; }; /** @@ -29124,240 +25975,171 @@ export type TransactionAction = { * REFUND - Represents a refund action. * CANCEL - Represents a cancel action. Added in Saleor 3.12. */ -export type TransactionActionEnum = - | 'CANCEL' - | 'CHARGE' - | 'REFUND'; +export enum TransactionActionEnum { + Cancel = 'CANCEL', + Charge = 'CHARGE', + Refund = 'REFUND' +} -/** - * Event sent when transaction cancelation is requested. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when transaction cancelation is requested. */ export type TransactionCancelationRequested = Event & { - __typename?: 'TransactionCancelationRequested'; /** Requested action data. */ - action: TransactionAction; + readonly action: TransactionAction; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Look up a transaction. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when transaction charge is requested. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when transaction charge is requested. */ export type TransactionChargeRequested = Event & { - __typename?: 'TransactionChargeRequested'; /** Requested action data. */ - action: TransactionAction; + readonly action: TransactionAction; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Look up a transaction. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Create transaction for checkout or order. * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: HANDLE_PAYMENTS. */ export type TransactionCreate = { - __typename?: 'TransactionCreate'; - errors: Array; - transaction?: Maybe; + readonly errors: ReadonlyArray; + readonly transaction?: Maybe; }; export type TransactionCreateError = { - __typename?: 'TransactionCreateError'; /** The error code. */ - code: TransactionCreateErrorCode; + readonly code: TransactionCreateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TransactionCreateErrorCode = - | 'GRAPHQL_ERROR' - | 'INCORRECT_CURRENCY' - | 'INVALID' - | 'METADATA_KEY_REQUIRED' - | 'NOT_FOUND' - | 'UNIQUE'; +export enum TransactionCreateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + IncorrectCurrency = 'INCORRECT_CURRENCY', + Invalid = 'INVALID', + MetadataKeyRequired = 'METADATA_KEY_REQUIRED', + NotFound = 'NOT_FOUND', + Unique = 'UNIQUE' +} export type TransactionCreateInput = { /** Amount authorized by this transaction. */ - amountAuthorized?: InputMaybe; - /** - * Amount canceled by this transaction. - * - * Added in Saleor 3.13. - */ - amountCanceled?: InputMaybe; + readonly amountAuthorized?: InputMaybe; + /** Amount canceled by this transaction. */ + readonly amountCanceled?: InputMaybe; /** Amount charged by this transaction. */ - amountCharged?: InputMaybe; + readonly amountCharged?: InputMaybe; /** Amount refunded by this transaction. */ - amountRefunded?: InputMaybe; + readonly amountRefunded?: InputMaybe; /** List of all possible actions for the transaction */ - availableActions?: InputMaybe>; + readonly availableActions?: InputMaybe>; + /** The url that will allow to redirect user to payment provider page with transaction event details. */ + readonly externalUrl?: InputMaybe; + /** The message of the transaction. */ + readonly message?: InputMaybe; /** - * The url that will allow to redirect user to payment provider page with transaction event details. + * Payment public metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.13. + * Warning: never store sensitive information, including financial data such as credit card details. */ - externalUrl?: InputMaybe; + readonly metadata?: InputMaybe>; + /** Payment name of the transaction. */ + readonly name?: InputMaybe; /** - * The message of the transaction. + * Payment private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.13. + * Warning: never store sensitive information, including financial data such as credit card details. */ - message?: InputMaybe; - /** Payment public metadata. */ - metadata?: InputMaybe>; - /** - * Payment name of the transaction. - * - * Added in Saleor 3.13. - */ - name?: InputMaybe; - /** Payment private metadata. */ - privateMetadata?: InputMaybe>; - /** - * PSP Reference of the transaction. - * - * Added in Saleor 3.13. - */ - pspReference?: InputMaybe; + readonly privateMetadata?: InputMaybe>; + /** PSP Reference of the transaction. */ + readonly pspReference?: InputMaybe; }; /** Represents transaction's event. */ export type TransactionEvent = Node & { - __typename?: 'TransactionEvent'; - /** - * The amount related to this event. - * - * Added in Saleor 3.13. - */ - amount: Money; + /** The amount related to this event. */ + readonly amount: Money; /** Date and time at which a transaction event was created. */ - createdAt: Scalars['DateTime']; - /** - * User or App that created the transaction event. - * - * Added in Saleor 3.13. - */ - createdBy?: Maybe; - /** - * The url that will allow to redirect user to payment provider page with transaction details. - * - * Added in Saleor 3.13. - */ - externalUrl: Scalars['String']; + readonly createdAt: Scalars['DateTime']; + /** User or App that created the transaction event. */ + readonly createdBy?: Maybe; + /** The url that will allow to redirect user to payment provider page with transaction details. */ + readonly externalUrl: Scalars['String']; /** The ID of the object. */ - id: Scalars['ID']; - /** - * Idempotency key assigned to the event. - * - * Added in Saleor 3.14. - */ - idempotencyKey?: Maybe; - /** - * Message related to the transaction's event. - * - * Added in Saleor 3.13. - */ - message: Scalars['String']; - /** - * PSP reference of transaction. - * - * Added in Saleor 3.13. - */ - pspReference: Scalars['String']; - /** - * The type of action related to this event. - * - * Added in Saleor 3.13. - */ - type?: Maybe; + readonly id: Scalars['ID']; + /** Idempotency key assigned to the event. */ + readonly idempotencyKey?: Maybe; + /** Message related to the transaction's event. */ + readonly message: Scalars['String']; + /** PSP reference of transaction. */ + readonly pspReference: Scalars['String']; + /** The type of action related to this event. */ + readonly type?: Maybe; }; export type TransactionEventInput = { - /** - * The message related to the event. - * - * Added in Saleor 3.13. - */ - message?: InputMaybe; - /** - * PSP Reference related to this action. - * - * Added in Saleor 3.13. - */ - pspReference?: InputMaybe; + /** The message related to the event. */ + readonly message?: InputMaybe; + /** PSP Reference related to this action. */ + readonly pspReference?: InputMaybe; }; /** * Report the event for the transaction. * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. + * + * Triggers the following webhook events: + * - TRANSACTION_ITEM_METADATA_UPDATED (async): Optionally called when transaction's metadata was updated. + * - CHECKOUT_FULLY_PAID (async): Optionally called when the checkout charge status changed to `FULL` or `OVERCHARGED`. + * - ORDER_UPDATED (async): Optionally called when the transaction is related to the order and the order was updated. */ export type TransactionEventReport = { - __typename?: 'TransactionEventReport'; /** Defines if the reported event hasn't been processed earlier. */ - alreadyProcessed?: Maybe; - errors: Array; + readonly alreadyProcessed?: Maybe; + readonly errors: ReadonlyArray; /** The transaction related to the reported event. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** The event assigned to this report. if `alreadyProcessed` is set to `true`, the previously processed event will be returned. */ - transactionEvent?: Maybe; + readonly transactionEvent?: Maybe; }; export type TransactionEventReportError = { - __typename?: 'TransactionEventReportError'; /** The error code. */ - code: TransactionEventReportErrorCode; + readonly code: TransactionEventReportErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TransactionEventReportErrorCode = - | 'ALREADY_EXISTS' - | 'GRAPHQL_ERROR' - | 'INCORRECT_DETAILS' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum TransactionEventReportErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + GraphqlError = 'GRAPHQL_ERROR', + IncorrectDetails = 'INCORRECT_DETAILS', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED' +} /** * Represents possible event types. @@ -29386,25 +26168,26 @@ export type TransactionEventReportErrorCode = * CANCEL_REQUEST - represents cancel request. * INFO - represents info event. */ -export type TransactionEventTypeEnum = - | 'AUTHORIZATION_ACTION_REQUIRED' - | 'AUTHORIZATION_ADJUSTMENT' - | 'AUTHORIZATION_FAILURE' - | 'AUTHORIZATION_REQUEST' - | 'AUTHORIZATION_SUCCESS' - | 'CANCEL_FAILURE' - | 'CANCEL_REQUEST' - | 'CANCEL_SUCCESS' - | 'CHARGE_ACTION_REQUIRED' - | 'CHARGE_BACK' - | 'CHARGE_FAILURE' - | 'CHARGE_REQUEST' - | 'CHARGE_SUCCESS' - | 'INFO' - | 'REFUND_FAILURE' - | 'REFUND_REQUEST' - | 'REFUND_REVERSE' - | 'REFUND_SUCCESS'; +export enum TransactionEventTypeEnum { + AuthorizationActionRequired = 'AUTHORIZATION_ACTION_REQUIRED', + AuthorizationAdjustment = 'AUTHORIZATION_ADJUSTMENT', + AuthorizationFailure = 'AUTHORIZATION_FAILURE', + AuthorizationRequest = 'AUTHORIZATION_REQUEST', + AuthorizationSuccess = 'AUTHORIZATION_SUCCESS', + CancelFailure = 'CANCEL_FAILURE', + CancelRequest = 'CANCEL_REQUEST', + CancelSuccess = 'CANCEL_SUCCESS', + ChargeActionRequired = 'CHARGE_ACTION_REQUIRED', + ChargeBack = 'CHARGE_BACK', + ChargeFailure = 'CHARGE_FAILURE', + ChargeRequest = 'CHARGE_REQUEST', + ChargeSuccess = 'CHARGE_SUCCESS', + Info = 'INFO', + RefundFailure = 'REFUND_FAILURE', + RefundRequest = 'REFUND_REQUEST', + RefundReverse = 'REFUND_REVERSE', + RefundSuccess = 'REFUND_SUCCESS' +} /** * Determine the transaction flow strategy. @@ -29412,632 +26195,445 @@ export type TransactionEventTypeEnum = * AUTHORIZATION - the processed transaction should be only authorized * CHARGE - the processed transaction should be charged. */ -export type TransactionFlowStrategyEnum = - | 'AUTHORIZATION' - | 'CHARGE'; +export enum TransactionFlowStrategyEnum { + Authorization = 'AUTHORIZATION', + Charge = 'CHARGE' +} -/** - * Initializes a transaction session. It triggers the webhook `TRANSACTION_INITIALIZE_SESSION`, to the requested `paymentGateways`. There is a limit of 100 transaction items per checkout / order. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Initializes a transaction session. It triggers the webhook `TRANSACTION_INITIALIZE_SESSION`, to the requested `paymentGateways`. There is a limit of 100 transaction items per checkout / order. */ export type TransactionInitialize = { - __typename?: 'TransactionInitialize'; /** The JSON data required to finalize the payment. */ - data?: Maybe; - errors: Array; + readonly data?: Maybe; + readonly errors: ReadonlyArray; /** The initialized transaction. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** The event created for the initialized transaction. */ - transactionEvent?: Maybe; + readonly transactionEvent?: Maybe; }; export type TransactionInitializeError = { - __typename?: 'TransactionInitializeError'; /** The error code. */ - code: TransactionInitializeErrorCode; + readonly code: TransactionInitializeErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TransactionInitializeErrorCode = - | 'CHECKOUT_COMPLETION_IN_PROGRESS' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'UNIQUE'; +export enum TransactionInitializeErrorCode { + CheckoutCompletionInProgress = 'CHECKOUT_COMPLETION_IN_PROGRESS', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Unique = 'UNIQUE' +} -/** - * Event sent when user starts processing the payment. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when user starts processing the payment. */ export type TransactionInitializeSession = Event & { - __typename?: 'TransactionInitializeSession'; /** Action to proceed for the transaction */ - action: TransactionProcessAction; - /** - * The customer's IP address. If not provided as a parameter in the mutation, Saleor will try to determine the customer's IP address on its own. - * - * Added in Saleor 3.16. - */ - customerIpAddress?: Maybe; + readonly action: TransactionProcessAction; + /** The customer's IP address. If not provided as a parameter in the mutation, Saleor will try to determine the customer's IP address on its own. */ + readonly customerIpAddress?: Maybe; /** Payment gateway data in JSON format, received from storefront. */ - data?: Maybe; - /** - * Idempotency key assigned to the transaction initialize. - * - * Added in Saleor 3.14. - */ - idempotencyKey: Scalars['String']; + readonly data?: Maybe; + /** Idempotency key assigned to the transaction initialize. */ + readonly idempotencyKey: Scalars['String']; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** Merchant reference assigned to this payment. */ - merchantReference: Scalars['String']; + readonly merchantReference: Scalars['String']; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Checkout or order */ - sourceObject: OrderOrCheckout; + readonly sourceObject: OrderOrCheckout; /** Look up a transaction. */ - transaction: TransactionItem; + readonly transaction: TransactionItem; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Represents a payment transaction. - * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents a payment transaction. */ export type TransactionItem = Node & ObjectWithMetadata & { - __typename?: 'TransactionItem'; /** List of actions that can be performed in the current state of a payment. */ - actions: Array; - /** - * Total amount of ongoing authorization requests for the transaction. - * - * Added in Saleor 3.13. - */ - authorizePendingAmount: Money; + readonly actions: ReadonlyArray; + /** Total amount of ongoing authorization requests for the transaction. */ + readonly authorizePendingAmount: Money; /** Total amount authorized for this payment. */ - authorizedAmount: Money; - /** - * Total amount of ongoing cancel requests for the transaction. - * - * Added in Saleor 3.13. - */ - cancelPendingAmount: Money; - /** - * Total amount canceled for this payment. - * - * Added in Saleor 3.13. - */ - canceledAmount: Money; - /** - * Total amount of ongoing charge requests for the transaction. - * - * Added in Saleor 3.13. - */ - chargePendingAmount: Money; + readonly authorizedAmount: Money; + /** Total amount of ongoing cancel requests for the transaction. */ + readonly cancelPendingAmount: Money; + /** Total amount canceled for this payment. */ + readonly canceledAmount: Money; + /** Total amount of ongoing charge requests for the transaction. */ + readonly chargePendingAmount: Money; /** Total amount charged for this payment. */ - chargedAmount: Money; - /** - * The related checkout. - * - * Added in Saleor 3.14. - */ - checkout?: Maybe; + readonly chargedAmount: Money; + /** The related checkout. */ + readonly checkout?: Maybe; /** Date and time at which payment transaction was created. */ - createdAt: Scalars['DateTime']; - /** - * User or App that created the transaction. - * - * Added in Saleor 3.13. - */ - createdBy?: Maybe; + readonly createdAt: Scalars['DateTime']; + /** User or App that created the transaction. */ + readonly createdBy?: Maybe; /** List of all transaction's events. */ - events: Array; - /** - * The url that will allow to redirect user to payment provider page with transaction details. - * - * Added in Saleor 3.13. - */ - externalUrl: Scalars['String']; + readonly events: ReadonlyArray; + /** The url that will allow to redirect user to payment provider page with transaction details. */ + readonly externalUrl: Scalars['String']; /** The ID of the object. */ - id: Scalars['ID']; - /** - * Message related to the transaction. - * - * Added in Saleor 3.13. - */ - message: Scalars['String']; + readonly id: Scalars['ID']; + /** Message related to the transaction. */ + readonly message: Scalars['String']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Date and time at which payment transaction was modified. */ - modifiedAt: Scalars['DateTime']; - /** - * Name of the transaction. - * - * Added in Saleor 3.13. - */ - name: Scalars['String']; - /** - * The related order. - * - * Added in Saleor 3.6. - */ - order?: Maybe; + readonly modifiedAt: Scalars['DateTime']; + /** Name of the transaction. */ + readonly name: Scalars['String']; + /** The related order. */ + readonly order?: Maybe; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; - /** - * PSP reference of transaction. - * - * Added in Saleor 3.13. - */ - pspReference: Scalars['String']; - /** - * Total amount of ongoing refund requests for the transaction. - * - * Added in Saleor 3.13. - */ - refundPendingAmount: Money; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** PSP reference of transaction. */ + readonly pspReference: Scalars['String']; + /** Total amount of ongoing refund requests for the transaction. */ + readonly refundPendingAmount: Money; /** Total amount refunded for this payment. */ - refundedAmount: Money; - /** - * The transaction token. - * - * Added in Saleor 3.14. - */ - token: Scalars['UUID']; + readonly refundedAmount: Money; + /** The transaction token. */ + readonly token: Scalars['UUID']; }; -/** - * Represents a payment transaction. - * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents a payment transaction. */ export type TransactionItemMetafieldArgs = { key: Scalars['String']; }; -/** - * Represents a payment transaction. - * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents a payment transaction. */ export type TransactionItemMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; -/** - * Represents a payment transaction. - * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents a payment transaction. */ export type TransactionItemPrivateMetafieldArgs = { key: Scalars['String']; }; -/** - * Represents a payment transaction. - * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Represents a payment transaction. */ export type TransactionItemPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; -/** - * Event sent when transaction item metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when transaction item metadata is updated. */ export type TransactionItemMetadataUpdated = Event & { - __typename?: 'TransactionItemMetadataUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Look up a transaction. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; -}; - -/** An enumeration. */ -export type TransactionKind = - | 'ACTION_TO_CONFIRM' - | 'AUTH' - | 'CANCEL' - | 'CAPTURE' - | 'CONFIRM' - | 'EXTERNAL' - | 'PENDING' - | 'REFUND' - | 'REFUND_ONGOING' - | 'VOID'; + readonly version?: Maybe; +}; + +export enum TransactionKind { + ActionToConfirm = 'ACTION_TO_CONFIRM', + Auth = 'AUTH', + Cancel = 'CANCEL', + Capture = 'CAPTURE', + Confirm = 'CONFIRM', + External = 'EXTERNAL', + Pending = 'PENDING', + Refund = 'REFUND', + RefundOngoing = 'REFUND_ONGOING', + Void = 'VOID' +} -/** - * Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. */ export type TransactionProcess = { - __typename?: 'TransactionProcess'; /** The json data required to finalize the payment. */ - data?: Maybe; - errors: Array; + readonly data?: Maybe; + readonly errors: ReadonlyArray; /** The processed transaction. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** The event created for the processed transaction. */ - transactionEvent?: Maybe; + readonly transactionEvent?: Maybe; }; export type TransactionProcessAction = { - __typename?: 'TransactionProcessAction'; - actionType: TransactionFlowStrategyEnum; + readonly actionType: TransactionFlowStrategyEnum; /** Transaction amount to process. */ - amount: Scalars['PositiveDecimal']; + readonly amount: Scalars['PositiveDecimal']; /** Currency of the amount. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; }; export type TransactionProcessError = { - __typename?: 'TransactionProcessError'; /** The error code. */ - code: TransactionProcessErrorCode; + readonly code: TransactionProcessErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TransactionProcessErrorCode = - | 'CHECKOUT_COMPLETION_IN_PROGRESS' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'MISSING_PAYMENT_APP' - | 'MISSING_PAYMENT_APP_RELATION' - | 'NOT_FOUND' - | 'TRANSACTION_ALREADY_PROCESSED'; +export enum TransactionProcessErrorCode { + CheckoutCompletionInProgress = 'CHECKOUT_COMPLETION_IN_PROGRESS', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + MissingPaymentApp = 'MISSING_PAYMENT_APP', + MissingPaymentAppRelation = 'MISSING_PAYMENT_APP_RELATION', + NotFound = 'NOT_FOUND', + TransactionAlreadyProcessed = 'TRANSACTION_ALREADY_PROCESSED' +} -/** - * Event sent when user has additional payment action to process. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when user has additional payment action to process. */ export type TransactionProcessSession = Event & { - __typename?: 'TransactionProcessSession'; /** Action to proceed for the transaction */ - action: TransactionProcessAction; - /** - * The customer's IP address. If not provided as a parameter in the mutation, Saleor will try to determine the customer's IP address on its own. - * - * Added in Saleor 3.16. - */ - customerIpAddress?: Maybe; + readonly action: TransactionProcessAction; + /** The customer's IP address. If not provided as a parameter in the mutation, Saleor will try to determine the customer's IP address on its own. */ + readonly customerIpAddress?: Maybe; /** Payment gateway data in JSON format, received from storefront. */ - data?: Maybe; + readonly data?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** Merchant reference assigned to this payment. */ - merchantReference: Scalars['String']; + readonly merchantReference: Scalars['String']; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Checkout or order */ - sourceObject: OrderOrCheckout; + readonly sourceObject: OrderOrCheckout; /** Look up a transaction. */ - transaction: TransactionItem; + readonly transaction: TransactionItem; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; -/** - * Event sent when transaction refund is requested. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ +/** Event sent when transaction refund is requested. */ export type TransactionRefundRequested = Event & { - __typename?: 'TransactionRefundRequested'; /** Requested action data. */ - action: TransactionAction; + readonly action: TransactionAction; /** * Granted refund related to refund request. * - * Added in Saleor 3.15. - * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - grantedRefund?: Maybe; + readonly grantedRefund?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Look up a transaction. */ - transaction?: Maybe; + readonly transaction?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** * Request an action for payment transaction. * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: HANDLE_PAYMENTS. */ export type TransactionRequestAction = { - __typename?: 'TransactionRequestAction'; - errors: Array; - transaction?: Maybe; + readonly errors: ReadonlyArray; + readonly transaction?: Maybe; }; export type TransactionRequestActionError = { - __typename?: 'TransactionRequestActionError'; /** The error code. */ - code: TransactionRequestActionErrorCode; + readonly code: TransactionRequestActionErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TransactionRequestActionErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'MISSING_TRANSACTION_ACTION_REQUEST_WEBHOOK' - | 'NOT_FOUND'; +export enum TransactionRequestActionErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + MissingTransactionActionRequestWebhook = 'MISSING_TRANSACTION_ACTION_REQUEST_WEBHOOK', + NotFound = 'NOT_FOUND' +} /** * Request a refund for payment transaction based on granted refund. * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: HANDLE_PAYMENTS. */ export type TransactionRequestRefundForGrantedRefund = { - __typename?: 'TransactionRequestRefundForGrantedRefund'; - errors: Array; - transaction?: Maybe; + readonly errors: ReadonlyArray; + readonly transaction?: Maybe; }; export type TransactionRequestRefundForGrantedRefundError = { - __typename?: 'TransactionRequestRefundForGrantedRefundError'; /** The error code. */ - code: TransactionRequestRefundForGrantedRefundErrorCode; + readonly code: TransactionRequestRefundForGrantedRefundErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TransactionRequestRefundForGrantedRefundErrorCode = - | 'AMOUNT_GREATER_THAN_AVAILABLE' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'MISSING_TRANSACTION_ACTION_REQUEST_WEBHOOK' - | 'NOT_FOUND' - | 'REFUND_ALREADY_PROCESSED' - | 'REFUND_IS_PENDING'; +export enum TransactionRequestRefundForGrantedRefundErrorCode { + AmountGreaterThanAvailable = 'AMOUNT_GREATER_THAN_AVAILABLE', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + MissingTransactionActionRequestWebhook = 'MISSING_TRANSACTION_ACTION_REQUEST_WEBHOOK', + NotFound = 'NOT_FOUND', + RefundAlreadyProcessed = 'REFUND_ALREADY_PROCESSED', + RefundIsPending = 'REFUND_IS_PENDING' +} /** * Update transaction. * - * Added in Saleor 3.4. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. */ export type TransactionUpdate = { - __typename?: 'TransactionUpdate'; - errors: Array; - transaction?: Maybe; + readonly errors: ReadonlyArray; + readonly transaction?: Maybe; }; export type TransactionUpdateError = { - __typename?: 'TransactionUpdateError'; /** The error code. */ - code: TransactionUpdateErrorCode; + readonly code: TransactionUpdateErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TransactionUpdateErrorCode = - | 'GRAPHQL_ERROR' - | 'INCORRECT_CURRENCY' - | 'INVALID' - | 'METADATA_KEY_REQUIRED' - | 'NOT_FOUND' - | 'UNIQUE'; +export enum TransactionUpdateErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + IncorrectCurrency = 'INCORRECT_CURRENCY', + Invalid = 'INVALID', + MetadataKeyRequired = 'METADATA_KEY_REQUIRED', + NotFound = 'NOT_FOUND', + Unique = 'UNIQUE' +} export type TransactionUpdateInput = { /** Amount authorized by this transaction. */ - amountAuthorized?: InputMaybe; - /** - * Amount canceled by this transaction. - * - * Added in Saleor 3.13. - */ - amountCanceled?: InputMaybe; + readonly amountAuthorized?: InputMaybe; + /** Amount canceled by this transaction. */ + readonly amountCanceled?: InputMaybe; /** Amount charged by this transaction. */ - amountCharged?: InputMaybe; + readonly amountCharged?: InputMaybe; /** Amount refunded by this transaction. */ - amountRefunded?: InputMaybe; + readonly amountRefunded?: InputMaybe; /** List of all possible actions for the transaction */ - availableActions?: InputMaybe>; + readonly availableActions?: InputMaybe>; + /** The url that will allow to redirect user to payment provider page with transaction event details. */ + readonly externalUrl?: InputMaybe; + /** The message of the transaction. */ + readonly message?: InputMaybe; /** - * The url that will allow to redirect user to payment provider page with transaction event details. + * Payment public metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.13. + * Warning: never store sensitive information, including financial data such as credit card details. */ - externalUrl?: InputMaybe; + readonly metadata?: InputMaybe>; + /** Payment name of the transaction. */ + readonly name?: InputMaybe; /** - * The message of the transaction. + * Payment private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.13. + * Warning: never store sensitive information, including financial data such as credit card details. */ - message?: InputMaybe; - /** Payment public metadata. */ - metadata?: InputMaybe>; - /** - * Payment name of the transaction. - * - * Added in Saleor 3.13. - */ - name?: InputMaybe; - /** Payment private metadata. */ - privateMetadata?: InputMaybe>; - /** - * PSP Reference of the transaction. - * - * Added in Saleor 3.13. - */ - pspReference?: InputMaybe; + readonly privateMetadata?: InputMaybe>; + /** PSP Reference of the transaction. */ + readonly pspReference?: InputMaybe; }; export type TranslatableItem = AttributeTranslatableContent | AttributeValueTranslatableContent | CategoryTranslatableContent | CollectionTranslatableContent | MenuItemTranslatableContent | PageTranslatableContent | ProductTranslatableContent | ProductVariantTranslatableContent | PromotionRuleTranslatableContent | PromotionTranslatableContent | SaleTranslatableContent | ShippingMethodTranslatableContent | VoucherTranslatableContent; export type TranslatableItemConnection = { - __typename?: 'TranslatableItemConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type TranslatableItemEdge = { - __typename?: 'TranslatableItemEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: TranslatableItem; -}; - -export type TranslatableKinds = - | 'ATTRIBUTE' - | 'ATTRIBUTE_VALUE' - | 'CATEGORY' - | 'COLLECTION' - | 'MENU_ITEM' - | 'PAGE' - | 'PRODUCT' - | 'PROMOTION' - | 'PROMOTION_RULE' - | 'SALE' - | 'SHIPPING_METHOD' - | 'VARIANT' - | 'VOUCHER'; + readonly node: TranslatableItem; +}; + +export enum TranslatableKinds { + Attribute = 'ATTRIBUTE', + AttributeValue = 'ATTRIBUTE_VALUE', + Category = 'CATEGORY', + Collection = 'COLLECTION', + MenuItem = 'MENU_ITEM', + Page = 'PAGE', + Product = 'PRODUCT', + Promotion = 'PROMOTION', + PromotionRule = 'PROMOTION_RULE', + Sale = 'SALE', + ShippingMethod = 'SHIPPING_METHOD', + Variant = 'VARIANT', + Voucher = 'VOUCHER' +} -/** - * Event sent when new translation is created. - * - * Added in Saleor 3.2. - */ +/** Event sent when new translation is created. */ export type TranslationCreated = Event & { - __typename?: 'TranslationCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The translation the event relates to. */ - translation?: Maybe; + readonly translation?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type TranslationError = { - __typename?: 'TranslationError'; /** The error code. */ - code: TranslationErrorCode; + readonly code: TranslationErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type TranslationErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED'; +export enum TranslationErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type TranslationInput = { /** @@ -30045,225 +26641,183 @@ export type TranslationInput = { * * Rich text format. For reference see https://editorjs.io/ */ - description?: InputMaybe; - name?: InputMaybe; - seoDescription?: InputMaybe; - seoTitle?: InputMaybe; + readonly description?: InputMaybe; + readonly name?: InputMaybe; + readonly seoDescription?: InputMaybe; + readonly seoTitle?: InputMaybe; + readonly slug?: InputMaybe; }; export type TranslationTypes = AttributeTranslation | AttributeValueTranslation | CategoryTranslation | CollectionTranslation | MenuItemTranslation | PageTranslation | ProductTranslation | ProductVariantTranslation | PromotionRuleTranslation | PromotionTranslation | SaleTranslation | ShippingMethodTranslation | VoucherTranslation; -/** - * Event sent when translation is updated. - * - * Added in Saleor 3.2. - */ +/** Event sent when translation is updated. */ export type TranslationUpdated = Event & { - __typename?: 'TranslationUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** The translation the event relates to. */ - translation?: Maybe; + readonly translation?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; export type UpdateInvoiceInput = { /** - * Fields required to update the invoice metadata. + * Fields required to update the invoice metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** Invoice number */ - number?: InputMaybe; + readonly number?: InputMaybe; /** - * Fields required to update the invoice private metadata. + * Fields required to update the invoice private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** URL of an invoice to download. */ - url?: InputMaybe; + readonly url?: InputMaybe; }; -/** Updates metadata of an object. To use it, you need to have access to the modified object. */ +/** + * Updates metadata of an object.Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ export type UpdateMetadata = { - __typename?: 'UpdateMetadata'; - errors: Array; - item?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - metadataErrors: Array; + readonly errors: ReadonlyArray; + readonly item?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly metadataErrors: ReadonlyArray; }; -/** Updates private metadata of an object. To use it, you need to be an authenticated staff user or an app and have access to the modified object. */ +/** + * Updates private metadata of an object. Requires permissions to modify and to read the metadata of the object it's attached to. + * + * Warning: never store sensitive information, including financial data such as credit card details. + */ export type UpdatePrivateMetadata = { - __typename?: 'UpdatePrivateMetadata'; - errors: Array; - item?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - metadataErrors: Array; + readonly errors: ReadonlyArray; + readonly item?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly metadataErrors: ReadonlyArray; }; export type UploadError = { - __typename?: 'UploadError'; /** The error code. */ - code: UploadErrorCode; + readonly code: UploadErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; }; -/** An enumeration. */ -export type UploadErrorCode = - | 'GRAPHQL_ERROR'; +export enum UploadErrorCode { + GraphqlError = 'GRAPHQL_ERROR' +} /** Represents user data. */ export type User = Node & ObjectWithMetadata & { - __typename?: 'User'; - /** - * List of channels the user has access to. The sum of channels from all user groups. If at least one group has `restrictedAccessToChannels` set to False - all channels are returned. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - accessibleChannels?: Maybe>; + /** List of channels the user has access to. The sum of channels from all user groups. If at least one group has `restrictedAccessToChannels` set to False - all channels are returned. */ + readonly accessibleChannels?: Maybe>; /** List of all user's addresses. */ - addresses: Array
; + readonly addresses: ReadonlyArray
; /** The avatar of the user. */ - avatar?: Maybe; + readonly avatar?: Maybe; /** * Returns the last open checkout of this user. - * @deprecated This field will be removed in Saleor 4.0. Use the `checkoutTokens` field to fetch the user checkouts. + * @deprecated Use the `checkoutTokens` field to fetch the user checkouts. */ - checkout?: Maybe; + readonly checkout?: Maybe; /** Returns the checkout ID's assigned to this user. */ - checkoutIds?: Maybe>; + readonly checkoutIds?: Maybe>; /** * Returns the checkout UUID's assigned to this user. - * @deprecated This field will be removed in Saleor 4.0. Use `checkoutIds` instead. + * @deprecated Use `checkoutIds` instead. */ - checkoutTokens?: Maybe>; - /** - * Returns checkouts assigned to this user. - * - * Added in Saleor 3.8. - */ - checkouts?: Maybe; + readonly checkoutTokens?: Maybe>; + /** Returns checkouts assigned to this user. The query will not initiate any external requests, including fetching external shipping methods, filtering available shipping methods, or performing external tax calculations. */ + readonly checkouts?: Maybe; /** The data when the user create account. */ - dateJoined: Scalars['DateTime']; + readonly dateJoined: Scalars['DateTime']; /** The default billing address of the user. */ - defaultBillingAddress?: Maybe
; + readonly defaultBillingAddress?: Maybe
; /** The default shipping address of the user. */ - defaultShippingAddress?: Maybe
; + readonly defaultShippingAddress?: Maybe
; /** List of user's permission groups which user can manage. */ - editableGroups?: Maybe>; + readonly editableGroups?: Maybe>; /** The email address of the user. */ - email: Scalars['String']; + readonly email: Scalars['String']; /** * List of events associated with the user. * * Requires one of the following permissions: MANAGE_USERS, MANAGE_STAFF. */ - events?: Maybe>; - /** - * External ID of this user. - * - * Added in Saleor 3.10. - */ - externalReference?: Maybe; + readonly events?: Maybe>; + /** External ID of this user. */ + readonly externalReference?: Maybe; /** The given name of the address. */ - firstName: Scalars['String']; + readonly firstName: Scalars['String']; /** List of the user gift cards. */ - giftCards?: Maybe; + readonly giftCards?: Maybe; /** The ID of the user. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Determine if the user is active. */ - isActive: Scalars['Boolean']; - /** - * Determines if user has confirmed email. - * - * Added in Saleor 3.15. - */ - isConfirmed: Scalars['Boolean']; + readonly isActive: Scalars['Boolean']; + /** Determines if user has confirmed email. */ + readonly isConfirmed: Scalars['Boolean']; /** Determine if the user is a staff admin. */ - isStaff: Scalars['Boolean']; + readonly isStaff: Scalars['Boolean']; /** User language code. */ - languageCode: LanguageCodeEnum; + readonly languageCode: LanguageCodeEnum; /** The date when the user last time log in to the system. */ - lastLogin?: Maybe; + readonly lastLogin?: Maybe; /** The family name of the address. */ - lastName: Scalars['String']; + readonly lastName: Scalars['String']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** * A note about the customer. * * Requires one of the following permissions: MANAGE_USERS, MANAGE_STAFF. */ - note?: Maybe; - /** List of user's orders. Requires one of the following permissions: MANAGE_STAFF, OWNER. */ - orders?: Maybe; + readonly note?: Maybe; + /** List of user's orders. The query will not initiate any external requests, including filtering available shipping methods, or performing external tax calculations. Requires one of the following permissions: MANAGE_STAFF, OWNER. */ + readonly orders?: Maybe; /** List of user's permission groups. */ - permissionGroups?: Maybe>; + readonly permissionGroups?: Maybe>; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. - */ - privateMetafields?: Maybe; - /** - * Determine if user have restricted access to channels. False if at least one user group has `restrictedAccessToChannels` set to False. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - restrictedAccessToChannels: Scalars['Boolean']; - /** - * Returns a list of user's stored payment methods that can be used in provided channel. The field returns a list of stored payment methods by payment apps. When `amount` is not provided, 0 will be used as default value. - * - * Added in Saleor 3.15. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - storedPaymentMethods?: Maybe>; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; + /** Determine if user have restricted access to channels. False if at least one user group has `restrictedAccessToChannels` set to False. */ + readonly restrictedAccessToChannels: Scalars['Boolean']; + /** Returns a list of user's stored payment methods that can be used in provided channel. The field returns a list of stored payment methods by payment apps. When `amount` is not provided, 0 will be used as default value. */ + readonly storedPaymentMethods?: Maybe>; /** List of stored payment sources. The field returns a list of payment sources stored for payment plugins. */ - storedPaymentSources?: Maybe>; + readonly storedPaymentSources?: Maybe>; /** The data when the user last update the account information. */ - updatedAt: Scalars['DateTime']; + readonly updatedAt: Scalars['DateTime']; /** List of user's permissions. */ - userPermissions?: Maybe>; + readonly userPermissions?: Maybe>; }; @@ -30313,7 +26867,7 @@ export type UserMetafieldArgs = { /** Represents user data. */ export type UserMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -30334,7 +26888,7 @@ export type UserPrivateMetafieldArgs = { /** Represents user data. */ export type UserPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -30355,12 +26909,11 @@ export type UserStoredPaymentSourcesArgs = { * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. */ export type UserAvatarDelete = { - __typename?: 'UserAvatarDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** An updated user instance. */ - user?: Maybe; + readonly user?: Maybe; }; /** @@ -30369,12 +26922,11 @@ export type UserAvatarDelete = { * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. */ export type UserAvatarUpdate = { - __typename?: 'UserAvatarUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** An updated user instance. */ - user?: Maybe; + readonly user?: Maybe; }; /** @@ -30383,93 +26935,80 @@ export type UserAvatarUpdate = { * Requires one of the following permissions: MANAGE_USERS. */ export type UserBulkSetActive = { - __typename?: 'UserBulkSetActive'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; /** Returns how many objects were affected. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; export type UserCountableConnection = { - __typename?: 'UserCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type UserCountableEdge = { - __typename?: 'UserCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: User; + readonly node: User; }; export type UserCreateInput = { /** Slug of a channel which will be used for notify user. Optional when only one channel exists. */ - channel?: InputMaybe; + readonly channel?: InputMaybe; /** Billing address of the customer. */ - defaultBillingAddress?: InputMaybe; + readonly defaultBillingAddress?: InputMaybe; /** Shipping address of the customer. */ - defaultShippingAddress?: InputMaybe; + readonly defaultShippingAddress?: InputMaybe; /** The unique email address of the user. */ - email?: InputMaybe; - /** - * External ID of the customer. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly email?: InputMaybe; + /** External ID of the customer. */ + readonly externalReference?: InputMaybe; /** Given name. */ - firstName?: InputMaybe; + readonly firstName?: InputMaybe; /** User account is active. */ - isActive?: InputMaybe; + readonly isActive?: InputMaybe; /** * User account is confirmed. - * - * Added in Saleor 3.15. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - * - * The user will be always set as unconfirmed. The confirmation will take place when the user sets the password. + * @deprecated The user will be always set as unconfirmed. The confirmation will take place when the user sets the password. */ - isConfirmed?: InputMaybe; + readonly isConfirmed?: InputMaybe; /** User language code. */ - languageCode?: InputMaybe; + readonly languageCode?: InputMaybe; /** Family name. */ - lastName?: InputMaybe; + readonly lastName?: InputMaybe; /** - * Fields required to update the user metadata. + * Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - metadata?: InputMaybe>; + readonly metadata?: InputMaybe>; /** A note about the user. */ - note?: InputMaybe; + readonly note?: InputMaybe; /** - * Fields required to update the user private metadata. + * Fields required to update the user private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. * - * Added in Saleor 3.14. + * Warning: never store sensitive information, including financial data such as credit card details. */ - privateMetadata?: InputMaybe>; + readonly privateMetadata?: InputMaybe>; /** URL of a view where users should be redirected to set the password. URL in RFC 1808 format. */ - redirectUrl?: InputMaybe; + readonly redirectUrl?: InputMaybe; }; export type UserOrApp = App | User; /** Represents user's permissions. */ export type UserPermission = { - __typename?: 'UserPermission'; /** Internal code for permission. */ - code: PermissionEnum; + readonly code: PermissionEnum; /** Describe action(s) allowed to do by permission. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of user permission groups which contains this permission. */ - sourcePermissionGroups?: Maybe>; + readonly sourcePermissionGroups?: Maybe>; }; @@ -30478,42 +27017,43 @@ export type UserPermissionSourcePermissionGroupsArgs = { userId: Scalars['ID']; }; -export type UserSortField = +export enum UserSortField { /** Sort users by created at. */ - | 'CREATED_AT' + CreatedAt = 'CREATED_AT', /** Sort users by email. */ - | 'EMAIL' + Email = 'EMAIL', /** Sort users by first name. */ - | 'FIRST_NAME' + FirstName = 'FIRST_NAME', /** Sort users by last modified at. */ - | 'LAST_MODIFIED_AT' + LastModifiedAt = 'LAST_MODIFIED_AT', /** Sort users by last name. */ - | 'LAST_NAME' + LastName = 'LAST_NAME', /** Sort users by order count. */ - | 'ORDER_COUNT'; + OrderCount = 'ORDER_COUNT' +} export type UserSortingInput = { /** Specifies the direction in which to sort users. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort users by the selected field. */ - field: UserSortField; + readonly field: UserSortField; }; /** Represents a VAT rate for a country. */ export type Vat = { - __typename?: 'VAT'; /** Country code. */ - countryCode: Scalars['String']; + readonly countryCode: Scalars['String']; /** Country's VAT rate exceptions for specific types of goods. */ - reducedRates: Array; + readonly reducedRates: ReadonlyArray; /** Standard VAT rate in percent. */ - standardRate?: Maybe; + readonly standardRate?: Maybe; }; -export type VariantAttributeScope = - | 'ALL' - | 'NOT_VARIANT_SELECTION' - | 'VARIANT_SELECTION'; +export enum VariantAttributeScope { + All = 'ALL', + NotVariantSelection = 'NOT_VARIANT_SELECTION', + VariantSelection = 'VARIANT_SELECTION' +} /** * Assign an media to a product variant. @@ -30521,12 +27061,11 @@ export type VariantAttributeScope = * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type VariantMediaAssign = { - __typename?: 'VariantMediaAssign'; - errors: Array; - media?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - productVariant?: Maybe; + readonly errors: ReadonlyArray; + readonly media?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly productVariant?: Maybe; }; /** @@ -30535,154 +27074,150 @@ export type VariantMediaAssign = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type VariantMediaUnassign = { - __typename?: 'VariantMediaUnassign'; - errors: Array; - media?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - productErrors: Array; - productVariant?: Maybe; + readonly errors: ReadonlyArray; + readonly media?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly productErrors: ReadonlyArray; + readonly productVariant?: Maybe; }; /** Represents availability of a variant in the storefront. */ export type VariantPricingInfo = { - __typename?: 'VariantPricingInfo'; /** The discount amount if in sale (null otherwise). */ - discount?: Maybe; + readonly discount?: Maybe; /** * The discount amount in the local currency. - * @deprecated This field will be removed in Saleor 4.0. Always returns `null`. + * @deprecated Always returns `null`. */ - discountLocalCurrency?: Maybe; + readonly discountLocalCurrency?: Maybe; + /** + * The discount amount compared to prior price. Null if product is not on sale or prior price was not provided in VariantChannelListing + * + * Added in Saleor 3.21. + */ + readonly discountPrior?: Maybe; /** Whether it is in sale or not. */ - onSale?: Maybe; + readonly onSale?: Maybe; /** The price, with any discount subtracted. */ - price?: Maybe; + readonly price?: Maybe; /** * The discounted price in the local currency. - * @deprecated This field will be removed in Saleor 4.0. Always returns `null`. + * @deprecated Always returns `null`. */ - priceLocalCurrency?: Maybe; + readonly priceLocalCurrency?: Maybe; + /** + * The price prior to discount. + * + * Added in Saleor 3.21. + */ + readonly pricePrior?: Maybe; /** The price without any discount. */ - priceUndiscounted?: Maybe; + readonly priceUndiscounted?: Maybe; }; /** Verify JWT token. */ export type VerifyToken = { - __typename?: 'VerifyToken'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - accountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly accountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Determine if token is valid or not. */ - isValid: Scalars['Boolean']; + readonly isValid: Scalars['Boolean']; /** JWT payload. */ - payload?: Maybe; + readonly payload?: Maybe; /** User assigned to token. */ - user?: Maybe; -}; - -/** An enumeration. */ -export type VolumeUnitsEnum = - | 'ACRE_FT' - | 'ACRE_IN' - | 'CUBIC_CENTIMETER' - | 'CUBIC_DECIMETER' - | 'CUBIC_FOOT' - | 'CUBIC_INCH' - | 'CUBIC_METER' - | 'CUBIC_MILLIMETER' - | 'CUBIC_YARD' - | 'FL_OZ' - | 'LITER' - | 'PINT' - | 'QT'; + readonly user?: Maybe; +}; + +export enum VolumeUnitsEnum { + AcreFt = 'ACRE_FT', + AcreIn = 'ACRE_IN', + CubicCentimeter = 'CUBIC_CENTIMETER', + CubicDecimeter = 'CUBIC_DECIMETER', + CubicFoot = 'CUBIC_FOOT', + CubicInch = 'CUBIC_INCH', + CubicMeter = 'CUBIC_METER', + CubicMillimeter = 'CUBIC_MILLIMETER', + CubicYard = 'CUBIC_YARD', + FlOz = 'FL_OZ', + Liter = 'LITER', + Pint = 'PINT', + Qt = 'QT' +} /** Vouchers allow giving discounts to particular customers on categories, collections or specific products. They can be used during checkout by providing valid voucher codes. */ export type Voucher = Node & ObjectWithMetadata & { - __typename?: 'Voucher'; /** Determine if the voucher usage should be limited to one use per customer. */ - applyOncePerCustomer: Scalars['Boolean']; + readonly applyOncePerCustomer: Scalars['Boolean']; /** Determine if the voucher should be applied once per order. If set to True, the voucher is applied to a single cheapest eligible product in checkout. */ - applyOncePerOrder: Scalars['Boolean']; + readonly applyOncePerOrder: Scalars['Boolean']; /** List of categories this voucher applies to. */ - categories?: Maybe; + readonly categories?: Maybe; /** * List of availability in channels for the voucher. * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - channelListings?: Maybe>; - /** The code of the voucher.This field will be removed in Saleor 4.0. */ - code?: Maybe; + readonly channelListings?: Maybe>; + /** The code of the voucher. */ + readonly code?: Maybe; /** * List of codes available for this voucher. * * Added in Saleor 3.18. */ - codes?: Maybe; + readonly codes?: Maybe; /** * List of collections this voucher applies to. * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - collections?: Maybe; + readonly collections?: Maybe; /** List of countries available for the shipping voucher. */ - countries?: Maybe>; + readonly countries?: Maybe>; /** Currency code for voucher. */ - currency?: Maybe; + readonly currency?: Maybe; /** Voucher value. */ - discountValue?: Maybe; + readonly discountValue?: Maybe; /** Determines a type of discount for voucher - value or percentage */ - discountValueType: DiscountValueTypeEnum; + readonly discountValueType: DiscountValueTypeEnum; /** The end date and time of voucher. */ - endDate?: Maybe; + readonly endDate?: Maybe; /** The ID of the voucher. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Determine minimum quantity of items for checkout. */ - minCheckoutItemsQuantity?: Maybe; + readonly minCheckoutItemsQuantity?: Maybe; /** Minimum order value to apply voucher. */ - minSpent?: Maybe; + readonly minSpent?: Maybe; /** The name of the voucher. */ - name?: Maybe; + readonly name?: Maybe; /** Determine if the voucher is available only for staff members. */ - onlyForStaff: Scalars['Boolean']; + readonly onlyForStaff: Scalars['Boolean']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** * List of products this voucher applies to. * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - products?: Maybe; + readonly products?: Maybe; /** * Determine if the voucher codes can be used once or multiple times. * @@ -30690,25 +27225,23 @@ export type Voucher = Node & ObjectWithMetadata & { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - singleUse: Scalars['Boolean']; + readonly singleUse: Scalars['Boolean']; /** The start date and time of voucher. */ - startDate: Scalars['DateTime']; + readonly startDate: Scalars['DateTime']; /** Returns translated voucher fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** Determines a type of voucher. */ - type: VoucherTypeEnum; + readonly type: VoucherTypeEnum; /** The number of times a voucher can be used. */ - usageLimit?: Maybe; + readonly usageLimit?: Maybe; /** Usage count of the voucher. */ - used: Scalars['Int']; + readonly used: Scalars['Int']; /** * List of product variants this voucher applies to. * - * Added in Saleor 3.1. - * * Requires one of the following permissions: MANAGE_DISCOUNTS. */ - variants?: Maybe; + readonly variants?: Maybe; }; @@ -30747,7 +27280,7 @@ export type VoucherMetafieldArgs = { /** Vouchers allow giving discounts to particular customers on categories, collections or specific products. They can be used during checkout by providing valid voucher codes. */ export type VoucherMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -30759,7 +27292,7 @@ export type VoucherPrivateMetafieldArgs = { /** Vouchers allow giving discounts to particular customers on categories, collections or specific products. They can be used during checkout by providing valid voucher codes. */ export type VoucherPrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -30795,12 +27328,11 @@ export type VoucherVariantsArgs = { * - VOUCHER_UPDATED (async): A voucher was updated. */ export type VoucherAddCatalogues = { - __typename?: 'VoucherAddCatalogues'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Voucher of which catalogue IDs will be modified. */ - voucher?: Maybe; + readonly voucher?: Maybe; }; /** @@ -30812,43 +27344,41 @@ export type VoucherAddCatalogues = { * - VOUCHER_DELETED (async): A voucher was deleted. */ export type VoucherBulkDelete = { - __typename?: 'VoucherBulkDelete'; /** Returns how many objects were affected. */ - count: Scalars['Int']; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; + readonly count: Scalars['Int']; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; }; /** Represents voucher channel listing. */ export type VoucherChannelListing = Node & { - __typename?: 'VoucherChannelListing'; /** The channel in which voucher can be applied. */ - channel: Channel; + readonly channel: Channel; /** Currency code for voucher in a channel. */ - currency: Scalars['String']; + readonly currency: Scalars['String']; /** The value of the discount on voucher in a channel. */ - discountValue: Scalars['Float']; + readonly discountValue: Scalars['Float']; /** The ID of channel listing. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Minimum order value for voucher to apply in channel. */ - minSpent?: Maybe; + readonly minSpent?: Maybe; }; export type VoucherChannelListingAddInput = { /** ID of a channel. */ - channelId: Scalars['ID']; + readonly channelId: Scalars['ID']; /** Value of the voucher. */ - discountValue?: InputMaybe; + readonly discountValue?: InputMaybe; /** Min purchase amount required to apply the voucher. */ - minAmountSpent?: InputMaybe; + readonly minAmountSpent?: InputMaybe; }; export type VoucherChannelListingInput = { /** List of channels to which the voucher should be assigned. */ - addChannels?: InputMaybe>; + readonly addChannels?: InputMaybe>; /** List of channels from which the voucher should be unassigned. */ - removeChannels?: InputMaybe>; + readonly removeChannels?: InputMaybe>; }; /** @@ -30860,12 +27390,11 @@ export type VoucherChannelListingInput = { * - VOUCHER_UPDATED (async): A voucher was updated. */ export type VoucherChannelListingUpdate = { - __typename?: 'VoucherChannelListingUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** An updated voucher instance. */ - voucher?: Maybe; + readonly voucher?: Maybe; }; /** @@ -30876,17 +27405,16 @@ export type VoucherChannelListingUpdate = { * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ export type VoucherCode = { - __typename?: 'VoucherCode'; /** Code to use the voucher. */ - code?: Maybe; + readonly code?: Maybe; /** Date time of code creation. */ - createdAt: Scalars['DateTime']; + readonly createdAt: Scalars['DateTime']; /** The ID of the voucher code. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Whether a code is active or not. */ - isActive?: Maybe; + readonly isActive?: Maybe; /** Number of times a code has been used. */ - used?: Maybe; + readonly used?: Maybe; }; /** @@ -30900,45 +27428,41 @@ export type VoucherCode = { * - VOUCHER_CODES_DELETED (async): A voucher codes were deleted. */ export type VoucherCodeBulkDelete = { - __typename?: 'VoucherCodeBulkDelete'; /** Returns how many codes were deleted. */ - count: Scalars['Int']; - errors: Array; + readonly count: Scalars['Int']; + readonly errors: ReadonlyArray; }; export type VoucherCodeBulkDeleteError = { - __typename?: 'VoucherCodeBulkDeleteError'; /** The error code. */ - code: VoucherCodeBulkDeleteErrorCode; + readonly code: VoucherCodeBulkDeleteErrorCode; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - path?: Maybe; + readonly path?: Maybe; /** List of voucher codes which causes the error. */ - voucherCodes?: Maybe>; + readonly voucherCodes?: Maybe>; }; -/** An enumeration. */ -export type VoucherCodeBulkDeleteErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND'; +export enum VoucherCodeBulkDeleteErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND' +} export type VoucherCodeCountableConnection = { - __typename?: 'VoucherCodeCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type VoucherCodeCountableEdge = { - __typename?: 'VoucherCodeCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: VoucherCode; + readonly node: VoucherCode; }; /** @@ -30947,17 +27471,16 @@ export type VoucherCodeCountableEdge = { * Added in Saleor 3.18. */ export type VoucherCodeExportCompleted = Event & { - __typename?: 'VoucherCodeExportCompleted'; /** The export file for voucher codes. */ - export?: Maybe; + readonly export?: Maybe; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; }; /** @@ -30966,17 +27489,16 @@ export type VoucherCodeExportCompleted = Event & { * Added in Saleor 3.19. */ export type VoucherCodesCreated = Event & { - __typename?: 'VoucherCodesCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The voucher codes the event relates to. */ - voucherCodes?: Maybe>; + readonly voucherCodes?: Maybe>; }; /** @@ -30985,34 +27507,31 @@ export type VoucherCodesCreated = Event & { * Added in Saleor 3.19. */ export type VoucherCodesDeleted = Event & { - __typename?: 'VoucherCodesDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The voucher codes the event relates to. */ - voucherCodes?: Maybe>; + readonly voucherCodes?: Maybe>; }; export type VoucherCountableConnection = { - __typename?: 'VoucherCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type VoucherCountableEdge = { - __typename?: 'VoucherCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Voucher; + readonly node: Voucher; }; /** @@ -31025,38 +27544,28 @@ export type VoucherCountableEdge = { * - VOUCHER_CODES_CREATED (async): A voucher codes were created. */ export type VoucherCreate = { - __typename?: 'VoucherCreate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; - voucher?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly voucher?: Maybe; }; -/** - * Event sent when new voucher is created. - * - * Added in Saleor 3.4. - */ +/** Event sent when new voucher is created. */ export type VoucherCreated = Event & { - __typename?: 'VoucherCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The voucher the event relates to. */ - voucher?: Maybe; + readonly voucher?: Maybe; }; -/** - * Event sent when new voucher is created. - * - * Added in Saleor 3.4. - */ +/** Event sent when new voucher is created. */ export type VoucherCreatedVoucherArgs = { channel?: InputMaybe; }; @@ -31070,55 +27579,46 @@ export type VoucherCreatedVoucherArgs = { * - VOUCHER_DELETED (async): A voucher was deleted. */ export type VoucherDelete = { - __typename?: 'VoucherDelete'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; - voucher?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly voucher?: Maybe; }; -/** - * Event sent when voucher is deleted. - * - * Added in Saleor 3.4. - */ +/** Event sent when voucher is deleted. */ export type VoucherDeleted = Event & { - __typename?: 'VoucherDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The voucher the event relates to. */ - voucher?: Maybe; + readonly voucher?: Maybe; }; -/** - * Event sent when voucher is deleted. - * - * Added in Saleor 3.4. - */ +/** Event sent when voucher is deleted. */ export type VoucherDeletedVoucherArgs = { channel?: InputMaybe; }; -export type VoucherDiscountType = - | 'FIXED' - | 'PERCENTAGE' - | 'SHIPPING'; +export enum VoucherDiscountType { + Fixed = 'FIXED', + Percentage = 'PERCENTAGE', + Shipping = 'SHIPPING' +} export type VoucherFilterInput = { - discountType?: InputMaybe>; - ids?: InputMaybe>; - metadata?: InputMaybe>; - search?: InputMaybe; - started?: InputMaybe; - status?: InputMaybe>; - timesUsed?: InputMaybe; + readonly discountType?: InputMaybe>; + readonly ids?: InputMaybe>; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; + readonly started?: InputMaybe; + readonly status?: InputMaybe>; + readonly timesUsed?: InputMaybe; }; export type VoucherInput = { @@ -31129,31 +27629,34 @@ export type VoucherInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - addCodes?: InputMaybe>; + readonly addCodes?: InputMaybe>; /** Voucher should be applied once per customer. */ - applyOncePerCustomer?: InputMaybe; + readonly applyOncePerCustomer?: InputMaybe; /** Voucher should be applied to the cheapest item or entire order. */ - applyOncePerOrder?: InputMaybe; + readonly applyOncePerOrder?: InputMaybe; /** Categories discounted by the voucher. */ - categories?: InputMaybe>; - /** Code to use the voucher. This field will be removed in Saleor 4.0. Use `addCodes` instead. */ - code?: InputMaybe; + readonly categories?: InputMaybe>; + /** + * Code to use the voucher. + * @deprecated Use `addCodes` instead. + */ + readonly code?: InputMaybe; /** Collections discounted by the voucher. */ - collections?: InputMaybe>; + readonly collections?: InputMaybe>; /** Country codes that can be used with the shipping voucher. */ - countries?: InputMaybe>; + readonly countries?: InputMaybe>; /** Choices: fixed or percentage. */ - discountValueType?: InputMaybe; + readonly discountValueType?: InputMaybe; /** End date of the voucher in ISO 8601 format. */ - endDate?: InputMaybe; + readonly endDate?: InputMaybe; /** Minimal quantity of checkout items required to apply the voucher. */ - minCheckoutItemsQuantity?: InputMaybe; + readonly minCheckoutItemsQuantity?: InputMaybe; /** Voucher name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Voucher can be used only by staff user. */ - onlyForStaff?: InputMaybe; + readonly onlyForStaff?: InputMaybe; /** Products discounted by the voucher. */ - products?: InputMaybe>; + readonly products?: InputMaybe>; /** * When set to 'True', each voucher code can be used only once; otherwise, codes can be used multiple times depending on `usageLimit`. * @@ -31163,46 +27666,33 @@ export type VoucherInput = { * * Note: this API is currently in Feature Preview and can be subject to changes at later point. */ - singleUse?: InputMaybe; + readonly singleUse?: InputMaybe; /** Start date of the voucher in ISO 8601 format. */ - startDate?: InputMaybe; + readonly startDate?: InputMaybe; /** Voucher type: PRODUCT, CATEGORY SHIPPING or ENTIRE_ORDER. */ - type?: InputMaybe; + readonly type?: InputMaybe; /** Limit number of times this voucher can be used in total. */ - usageLimit?: InputMaybe; - /** - * Variants discounted by the voucher. - * - * Added in Saleor 3.1. - */ - variants?: InputMaybe>; + readonly usageLimit?: InputMaybe; + /** Variants discounted by the voucher. */ + readonly variants?: InputMaybe>; }; -/** - * Event sent when voucher metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when voucher metadata is updated. */ export type VoucherMetadataUpdated = Event & { - __typename?: 'VoucherMetadataUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The voucher the event relates to. */ - voucher?: Maybe; + readonly voucher?: Maybe; }; -/** - * Event sent when voucher metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when voucher metadata is updated. */ export type VoucherMetadataUpdatedVoucherArgs = { channel?: InputMaybe; }; @@ -31216,83 +27706,73 @@ export type VoucherMetadataUpdatedVoucherArgs = { * - VOUCHER_UPDATED (async): A voucher was updated. */ export type VoucherRemoveCatalogues = { - __typename?: 'VoucherRemoveCatalogues'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; /** Voucher of which catalogue IDs will be modified. */ - voucher?: Maybe; + readonly voucher?: Maybe; }; -export type VoucherSortField = - /** - * Sort vouchers by code. - * - * DEPRECATED: this field will be removed in Saleor 4.0. - */ - | 'CODE' +export enum VoucherSortField { + /** Sort vouchers by code. */ + Code = 'CODE', /** Sort vouchers by end date. */ - | 'END_DATE' + EndDate = 'END_DATE', /** * Sort vouchers by minimum spent amount. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'MINIMUM_SPENT_AMOUNT' + MinimumSpentAmount = 'MINIMUM_SPENT_AMOUNT', /** * Sort vouchers by name. * * Added in Saleor 3.18. */ - | 'NAME' + Name = 'NAME', /** Sort vouchers by start date. */ - | 'START_DATE' + StartDate = 'START_DATE', /** Sort vouchers by type. */ - | 'TYPE' + Type = 'TYPE', /** Sort vouchers by usage limit. */ - | 'USAGE_LIMIT' + UsageLimit = 'USAGE_LIMIT', /** * Sort vouchers by value. * * This option requires a channel filter to work as the values can vary between channels. */ - | 'VALUE'; + Value = 'VALUE' +} export type VoucherSortingInput = { /** * Specifies the channel in which to sort the data. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. + * @deprecated Use root-level channel argument instead. */ - channel?: InputMaybe; + readonly channel?: InputMaybe; /** Specifies the direction in which to sort vouchers. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort vouchers by the selected field. */ - field: VoucherSortField; + readonly field: VoucherSortField; }; /** Represents voucher's original translatable fields and related translations. */ export type VoucherTranslatableContent = Node & { - __typename?: 'VoucherTranslatableContent'; /** The ID of the voucher translatable content. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Voucher name to translate. */ - name?: Maybe; + readonly name?: Maybe; /** Returns translated voucher fields for the given language code. */ - translation?: Maybe; + readonly translation?: Maybe; /** * Vouchers allow giving discounts to particular customers on categories, collections or specific products. They can be used during checkout by providing valid voucher codes. * * Requires one of the following permissions: MANAGE_DISCOUNTS. - * @deprecated This field will be removed in Saleor 4.0. Get model fields from the root level queries. + * @deprecated Get model fields from the root level queries. */ - voucher?: Maybe; - /** - * The ID of the voucher to translate. - * - * Added in Saleor 3.14. - */ - voucherId: Scalars['ID']; + readonly voucher?: Maybe; + /** The ID of the voucher to translate. */ + readonly voucherId: Scalars['ID']; }; @@ -31307,34 +27787,29 @@ export type VoucherTranslatableContentTranslationArgs = { * Requires one of the following permissions: MANAGE_TRANSLATIONS. */ export type VoucherTranslate = { - __typename?: 'VoucherTranslate'; - errors: Array; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - translationErrors: Array; - voucher?: Maybe; + readonly errors: ReadonlyArray; + /** @deprecated Use `errors` field instead. */ + readonly translationErrors: ReadonlyArray; + readonly voucher?: Maybe; }; /** Represents voucher translations. */ export type VoucherTranslation = Node & { - __typename?: 'VoucherTranslation'; /** The ID of the voucher translation. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Translation language. */ - language: LanguageDisplay; + readonly language: LanguageDisplay; /** Translated voucher name. */ - name?: Maybe; - /** - * Represents the voucher fields to translate. - * - * Added in Saleor 3.14. - */ - translatableContent?: Maybe; + readonly name?: Maybe; + /** Represents the voucher fields to translate. */ + readonly translatableContent?: Maybe; }; -export type VoucherTypeEnum = - | 'ENTIRE_ORDER' - | 'SHIPPING' - | 'SPECIFIC_PRODUCT'; +export enum VoucherTypeEnum { + EntireOrder = 'ENTIRE_ORDER', + Shipping = 'SHIPPING', + SpecificProduct = 'SPECIFIC_PRODUCT' +} /** * Updates a voucher. @@ -31346,108 +27821,77 @@ export type VoucherTypeEnum = * - VOUCHER_CODES_CREATED (async): A voucher code was created. */ export type VoucherUpdate = { - __typename?: 'VoucherUpdate'; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - discountErrors: Array; - errors: Array; - voucher?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly discountErrors: ReadonlyArray; + readonly errors: ReadonlyArray; + readonly voucher?: Maybe; }; -/** - * Event sent when voucher is updated. - * - * Added in Saleor 3.4. - */ +/** Event sent when voucher is updated. */ export type VoucherUpdated = Event & { - __typename?: 'VoucherUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The voucher the event relates to. */ - voucher?: Maybe; + readonly voucher?: Maybe; }; -/** - * Event sent when voucher is updated. - * - * Added in Saleor 3.4. - */ +/** Event sent when voucher is updated. */ export type VoucherUpdatedVoucherArgs = { channel?: InputMaybe; }; /** Represents warehouse. */ export type Warehouse = Node & ObjectWithMetadata & { - __typename?: 'Warehouse'; /** Address of the warehouse. */ - address: Address; - /** - * Click and collect options: local, all or disabled. - * - * Added in Saleor 3.1. - */ - clickAndCollectOption: WarehouseClickAndCollectOptionEnum; + readonly address: Address; + /** Click and collect options: local, all or disabled. */ + readonly clickAndCollectOption: WarehouseClickAndCollectOptionEnum; /** * Warehouse company name. - * @deprecated This field will be removed in Saleor 4.0. Use `Address.companyName` instead. + * @deprecated Use `Address.companyName` instead. */ - companyName: Scalars['String']; + readonly companyName: Scalars['String']; /** Warehouse email. */ - email: Scalars['String']; - /** - * External ID of this warehouse. - * - * Added in Saleor 3.10. - */ - externalReference?: Maybe; + readonly email: Scalars['String']; + /** External ID of this warehouse. */ + readonly externalReference?: Maybe; /** The ID of the warehouse. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Determine if the warehouse is private. */ - isPrivate: Scalars['Boolean']; + readonly isPrivate: Scalars['Boolean']; /** List of public metadata items. Can be accessed without permissions. */ - metadata: Array; + readonly metadata: ReadonlyArray; /** * A single key from public metadata. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - metafield?: Maybe; - /** - * Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - metafields?: Maybe; + readonly metafield?: Maybe; + /** Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly metafields?: Maybe; /** Warehouse name. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** List of private metadata items. Requires staff permissions to access. */ - privateMetadata: Array; + readonly privateMetadata: ReadonlyArray; /** * A single key from private metadata. Requires staff permissions to access. * * Tip: Use GraphQL aliases to fetch multiple keys. - * - * Added in Saleor 3.3. - */ - privateMetafield?: Maybe; - /** - * Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - * - * Added in Saleor 3.3. */ - privateMetafields?: Maybe; + readonly privateMetafield?: Maybe; + /** Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. */ + readonly privateMetafields?: Maybe; /** Shipping zones supported by the warehouse. */ - shippingZones: ShippingZoneCountableConnection; + readonly shippingZones: ShippingZoneCountableConnection; /** Warehouse slug. */ - slug: Scalars['String']; + readonly slug: Scalars['String']; /** * Stocks that belong to this warehouse. * @@ -31455,7 +27899,7 @@ export type Warehouse = Node & ObjectWithMetadata & { * * Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. */ - stocks?: Maybe; + readonly stocks?: Maybe; }; @@ -31467,7 +27911,7 @@ export type WarehouseMetafieldArgs = { /** Represents warehouse. */ export type WarehouseMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -31479,7 +27923,7 @@ export type WarehousePrivateMetafieldArgs = { /** Represents warehouse. */ export type WarehousePrivateMetafieldsArgs = { - keys?: InputMaybe>; + keys?: InputMaybe>; }; @@ -31500,27 +27944,25 @@ export type WarehouseStocksArgs = { last?: InputMaybe; }; -/** An enumeration. */ -export type WarehouseClickAndCollectOptionEnum = - | 'ALL' - | 'DISABLED' - | 'LOCAL'; +export enum WarehouseClickAndCollectOptionEnum { + All = 'ALL', + Disabled = 'DISABLED', + Local = 'LOCAL' +} export type WarehouseCountableConnection = { - __typename?: 'WarehouseCountableConnection'; - edges: Array; + readonly edges: ReadonlyArray; /** Pagination data for this connection. */ - pageInfo: PageInfo; + readonly pageInfo: PageInfo; /** A total count of items in the collection. */ - totalCount?: Maybe; + readonly totalCount?: Maybe; }; export type WarehouseCountableEdge = { - __typename?: 'WarehouseCountableEdge'; /** A cursor for use in pagination. */ - cursor: Scalars['String']; + readonly cursor: Scalars['String']; /** The item at the end of the edge. */ - node: Warehouse; + readonly node: Warehouse; }; /** @@ -31529,53 +27971,42 @@ export type WarehouseCountableEdge = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type WarehouseCreate = { - __typename?: 'WarehouseCreate'; - errors: Array; - warehouse?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - warehouseErrors: Array; + readonly errors: ReadonlyArray; + readonly warehouse?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly warehouseErrors: ReadonlyArray; }; export type WarehouseCreateInput = { /** Address of the warehouse. */ - address: AddressInput; + readonly address: AddressInput; /** The email address of the warehouse. */ - email?: InputMaybe; - /** - * External ID of the warehouse. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; + readonly email?: InputMaybe; + /** External ID of the warehouse. */ + readonly externalReference?: InputMaybe; /** Warehouse name. */ - name: Scalars['String']; + readonly name: Scalars['String']; /** * Shipping zones supported by the warehouse. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Providing the zone ids will raise a ValidationError. + * @deprecated Providing the zone ids will raise a ValidationError. */ - shippingZones?: InputMaybe>; + readonly shippingZones?: InputMaybe>; /** Warehouse slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; -/** - * Event sent when new warehouse is created. - * - * Added in Saleor 3.4. - */ +/** Event sent when new warehouse is created. */ export type WarehouseCreated = Event & { - __typename?: 'WarehouseCreated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The warehouse the event relates to. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; /** @@ -31584,80 +28015,68 @@ export type WarehouseCreated = Event & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type WarehouseDelete = { - __typename?: 'WarehouseDelete'; - errors: Array; - warehouse?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - warehouseErrors: Array; + readonly errors: ReadonlyArray; + readonly warehouse?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly warehouseErrors: ReadonlyArray; }; -/** - * Event sent when warehouse is deleted. - * - * Added in Saleor 3.4. - */ +/** Event sent when warehouse is deleted. */ export type WarehouseDeleted = Event & { - __typename?: 'WarehouseDeleted'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The warehouse the event relates to. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; export type WarehouseError = { - __typename?: 'WarehouseError'; /** The error code. */ - code: WarehouseErrorCode; + readonly code: WarehouseErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; + readonly message?: Maybe; /** List of shipping zones IDs which causes the error. */ - shippingZones?: Maybe>; + readonly shippingZones?: Maybe>; }; -/** An enumeration. */ -export type WarehouseErrorCode = - | 'ALREADY_EXISTS' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'NOT_FOUND' - | 'REQUIRED' - | 'UNIQUE'; +export enum WarehouseErrorCode { + AlreadyExists = 'ALREADY_EXISTS', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Unique = 'UNIQUE' +} export type WarehouseFilterInput = { - channels?: InputMaybe>; - clickAndCollectOption?: InputMaybe; - ids?: InputMaybe>; - isPrivate?: InputMaybe; - metadata?: InputMaybe>; - search?: InputMaybe; - slugs?: InputMaybe>; + readonly channels?: InputMaybe>; + readonly clickAndCollectOption?: InputMaybe; + readonly ids?: InputMaybe>; + readonly isPrivate?: InputMaybe; + readonly metadata?: InputMaybe>; + readonly search?: InputMaybe; + readonly slugs?: InputMaybe>; }; -/** - * Event sent when warehouse metadata is updated. - * - * Added in Saleor 3.8. - */ +/** Event sent when warehouse metadata is updated. */ export type WarehouseMetadataUpdated = Event & { - __typename?: 'WarehouseMetadataUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The warehouse the event relates to. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; /** @@ -31666,11 +28085,10 @@ export type WarehouseMetadataUpdated = Event & { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type WarehouseShippingZoneAssign = { - __typename?: 'WarehouseShippingZoneAssign'; - errors: Array; - warehouse?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - warehouseErrors: Array; + readonly errors: ReadonlyArray; + readonly warehouse?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly warehouseErrors: ReadonlyArray; }; /** @@ -31679,22 +28097,22 @@ export type WarehouseShippingZoneAssign = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type WarehouseShippingZoneUnassign = { - __typename?: 'WarehouseShippingZoneUnassign'; - errors: Array; - warehouse?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - warehouseErrors: Array; + readonly errors: ReadonlyArray; + readonly warehouse?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly warehouseErrors: ReadonlyArray; }; -export type WarehouseSortField = +export enum WarehouseSortField { /** Sort warehouses by name. */ - | 'NAME'; + Name = 'NAME' +} export type WarehouseSortingInput = { /** Specifies the direction in which to sort warehouses. */ - direction: OrderDirection; + readonly direction: OrderDirection; /** Sort warehouses by the selected field. */ - field: WarehouseSortField; + readonly field: WarehouseSortField; }; /** @@ -31703,100 +28121,75 @@ export type WarehouseSortingInput = { * Requires one of the following permissions: MANAGE_PRODUCTS. */ export type WarehouseUpdate = { - __typename?: 'WarehouseUpdate'; - errors: Array; - warehouse?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - warehouseErrors: Array; + readonly errors: ReadonlyArray; + readonly warehouse?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly warehouseErrors: ReadonlyArray; }; export type WarehouseUpdateInput = { /** Address of the warehouse. */ - address?: InputMaybe; - /** - * Click and collect options: local, all or disabled. - * - * Added in Saleor 3.1. - */ - clickAndCollectOption?: InputMaybe; + readonly address?: InputMaybe; + /** Click and collect options: local, all or disabled. */ + readonly clickAndCollectOption?: InputMaybe; /** The email address of the warehouse. */ - email?: InputMaybe; - /** - * External ID of the warehouse. - * - * Added in Saleor 3.10. - */ - externalReference?: InputMaybe; - /** - * Visibility of warehouse stocks. - * - * Added in Saleor 3.1. - */ - isPrivate?: InputMaybe; + readonly email?: InputMaybe; + /** External ID of the warehouse. */ + readonly externalReference?: InputMaybe; + /** Visibility of warehouse stocks. */ + readonly isPrivate?: InputMaybe; /** Warehouse name. */ - name?: InputMaybe; + readonly name?: InputMaybe; /** Warehouse slug. */ - slug?: InputMaybe; + readonly slug?: InputMaybe; }; -/** - * Event sent when warehouse is updated. - * - * Added in Saleor 3.4. - */ +/** Event sent when warehouse is updated. */ export type WarehouseUpdated = Event & { - __typename?: 'WarehouseUpdated'; /** Time of the event. */ - issuedAt?: Maybe; + readonly issuedAt?: Maybe; /** The user or application that triggered the event. */ - issuingPrincipal?: Maybe; + readonly issuingPrincipal?: Maybe; /** The application receiving the webhook. */ - recipient?: Maybe; + readonly recipient?: Maybe; /** Saleor version that triggered the event. */ - version?: Maybe; + readonly version?: Maybe; /** The warehouse the event relates to. */ - warehouse?: Maybe; + readonly warehouse?: Maybe; }; /** Webhook. */ export type Webhook = Node & { - __typename?: 'Webhook'; /** The app associated with Webhook. */ - app: App; + readonly app: App; /** List of asynchronous webhook events. */ - asyncEvents: Array; - /** - * Custom headers, which will be added to HTTP request. - * - * Added in Saleor 3.12. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - customHeaders?: Maybe; + readonly asyncEvents: ReadonlyArray; + /** Custom headers, which will be added to HTTP request. */ + readonly customHeaders?: Maybe; /** Event deliveries. */ - eventDeliveries?: Maybe; + readonly eventDeliveries?: Maybe; /** * List of webhook events. - * @deprecated This field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead. + * @deprecated Use `asyncEvents` or `syncEvents` instead. */ - events: Array; + readonly events: ReadonlyArray; /** The ID of webhook. */ - id: Scalars['ID']; + readonly id: Scalars['ID']; /** Informs if webhook is activated. */ - isActive: Scalars['Boolean']; + readonly isActive: Scalars['Boolean']; /** The name of webhook. */ - name?: Maybe; + readonly name?: Maybe; /** * Used to create a hash signature for each payload. - * @deprecated This field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. + * @deprecated As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. */ - secretKey?: Maybe; + readonly secretKey?: Maybe; /** Used to define payloads for specific events. */ - subscriptionQuery?: Maybe; + readonly subscriptionQuery?: Maybe; /** List of synchronous webhook events. */ - syncEvents: Array; + readonly syncEvents: ReadonlyArray; /** Target URL for webhook. */ - targetUrl: Scalars['String']; + readonly targetUrl: Scalars['String']; }; @@ -31816,52 +28209,39 @@ export type WebhookEventDeliveriesArgs = { * Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. */ export type WebhookCreate = { - __typename?: 'WebhookCreate'; - errors: Array; - webhook?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - webhookErrors: Array; + readonly errors: ReadonlyArray; + readonly webhook?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly webhookErrors: ReadonlyArray; }; export type WebhookCreateInput = { /** ID of the app to which webhook belongs. */ - app?: InputMaybe; + readonly app?: InputMaybe; /** The asynchronous events that webhook wants to subscribe. */ - asyncEvents?: InputMaybe>; - /** - * Custom headers, which will be added to HTTP request. There is a limitation of 5 headers per webhook and 998 characters per header.Only `X-*`, `Authorization*`, and `BrokerProperties` keys are allowed. - * - * Added in Saleor 3.12. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - customHeaders?: InputMaybe; + readonly asyncEvents?: InputMaybe>; + /** Custom headers, which will be added to HTTP request. There is a limitation of 5 headers per webhook and 998 characters per header.Only `X-*`, `Authorization*`, and `BrokerProperties` keys are allowed. */ + readonly customHeaders?: InputMaybe; /** * The events that webhook wants to subscribe. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead. + * @deprecated Use `asyncEvents` or `syncEvents` instead. */ - events?: InputMaybe>; + readonly events?: InputMaybe>; /** Determine if webhook will be set active or not. */ - isActive?: InputMaybe; + readonly isActive?: InputMaybe; /** The name of the webhook. */ - name?: InputMaybe; - /** - * Subscription query used to define a webhook payload. - * - * Added in Saleor 3.2. - */ - query?: InputMaybe; + readonly name?: InputMaybe; + /** Subscription query used to define a webhook payload. */ + readonly query?: InputMaybe; /** * The secret key used to create a hash signature with each payload. - * - * DEPRECATED: this field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. + * @deprecated As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. */ - secretKey?: InputMaybe; + readonly secretKey?: InputMaybe; /** The synchronous events that webhook wants to subscribe. */ - syncEvents?: InputMaybe>; + readonly syncEvents?: InputMaybe>; /** The url to receive the payload. */ - targetUrl?: InputMaybe; + readonly targetUrl?: InputMaybe; }; /** @@ -31870,1217 +28250,935 @@ export type WebhookCreateInput = { * Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. */ export type WebhookDelete = { - __typename?: 'WebhookDelete'; - errors: Array; - webhook?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - webhookErrors: Array; + readonly errors: ReadonlyArray; + readonly webhook?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly webhookErrors: ReadonlyArray; }; /** * Performs a dry run of a webhook event. Supports a single event (the first, if multiple provided in the `query`). Requires permission relevant to processed event. * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. */ export type WebhookDryRun = { - __typename?: 'WebhookDryRun'; - errors: Array; + readonly errors: ReadonlyArray; /** JSON payload, that would be sent out to webhook's target URL. */ - payload?: Maybe; + readonly payload?: Maybe; }; export type WebhookDryRunError = { - __typename?: 'WebhookDryRunError'; /** The error code. */ - code: WebhookDryRunErrorCode; + readonly code: WebhookDryRunErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; -}; - -/** An enumeration. */ -export type WebhookDryRunErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID_ID' - | 'MISSING_EVENT' - | 'MISSING_PERMISSION' - | 'MISSING_SUBSCRIPTION' - | 'NOT_FOUND' - | 'SYNTAX' - | 'TYPE_NOT_SUPPORTED' - | 'UNABLE_TO_PARSE'; + readonly message?: Maybe; +}; + +export enum WebhookDryRunErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + InvalidId = 'INVALID_ID', + MissingEvent = 'MISSING_EVENT', + MissingPermission = 'MISSING_PERMISSION', + MissingSubscription = 'MISSING_SUBSCRIPTION', + NotFound = 'NOT_FOUND', + Syntax = 'SYNTAX', + TypeNotSupported = 'TYPE_NOT_SUPPORTED', + UnableToParse = 'UNABLE_TO_PARSE' +} export type WebhookError = { - __typename?: 'WebhookError'; /** The error code. */ - code: WebhookErrorCode; + readonly code: WebhookErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; -}; - -/** An enumeration. */ -export type WebhookErrorCode = - | 'DELETE_FAILED' - | 'GRAPHQL_ERROR' - | 'INVALID' - | 'INVALID_CUSTOM_HEADERS' - | 'INVALID_NOTIFY_WITH_SUBSCRIPTION' - | 'MISSING_EVENT' - | 'MISSING_SUBSCRIPTION' - | 'NOT_FOUND' - | 'REQUIRED' - | 'SYNTAX' - | 'UNABLE_TO_PARSE' - | 'UNIQUE'; + readonly message?: Maybe; +}; + +export enum WebhookErrorCode { + DeleteFailed = 'DELETE_FAILED', + GraphqlError = 'GRAPHQL_ERROR', + Invalid = 'INVALID', + InvalidCustomHeaders = 'INVALID_CUSTOM_HEADERS', + InvalidNotifyWithSubscription = 'INVALID_NOTIFY_WITH_SUBSCRIPTION', + MissingEvent = 'MISSING_EVENT', + MissingSubscription = 'MISSING_SUBSCRIPTION', + NotFound = 'NOT_FOUND', + Required = 'REQUIRED', + Syntax = 'SYNTAX', + UnableToParse = 'UNABLE_TO_PARSE', + Unique = 'UNIQUE' +} /** Webhook event. */ export type WebhookEvent = { - __typename?: 'WebhookEvent'; /** Internal name of the event type. */ - eventType: WebhookEventTypeEnum; + readonly eventType: WebhookEventTypeEnum; /** Display name of the event. */ - name: Scalars['String']; + readonly name: Scalars['String']; }; /** Asynchronous webhook event. */ export type WebhookEventAsync = { - __typename?: 'WebhookEventAsync'; /** Internal name of the event type. */ - eventType: WebhookEventTypeAsyncEnum; + readonly eventType: WebhookEventTypeAsyncEnum; /** Display name of the event. */ - name: Scalars['String']; + readonly name: Scalars['String']; }; /** Synchronous webhook event. */ export type WebhookEventSync = { - __typename?: 'WebhookEventSync'; /** Internal name of the event type. */ - eventType: WebhookEventTypeSyncEnum; + readonly eventType: WebhookEventTypeSyncEnum; /** Display name of the event. */ - name: Scalars['String']; + readonly name: Scalars['String']; }; /** Enum determining type of webhook. */ -export type WebhookEventTypeAsyncEnum = +export enum WebhookEventTypeAsyncEnum { /** An account email change is requested. */ - | 'ACCOUNT_CHANGE_EMAIL_REQUESTED' + AccountChangeEmailRequested = 'ACCOUNT_CHANGE_EMAIL_REQUESTED', /** An account confirmation is requested. */ - | 'ACCOUNT_CONFIRMATION_REQUESTED' + AccountConfirmationRequested = 'ACCOUNT_CONFIRMATION_REQUESTED', /** An account is confirmed. */ - | 'ACCOUNT_CONFIRMED' + AccountConfirmed = 'ACCOUNT_CONFIRMED', /** An account is deleted. */ - | 'ACCOUNT_DELETED' + AccountDeleted = 'ACCOUNT_DELETED', /** An account delete is requested. */ - | 'ACCOUNT_DELETE_REQUESTED' + AccountDeleteRequested = 'ACCOUNT_DELETE_REQUESTED', /** An account email was changed */ - | 'ACCOUNT_EMAIL_CHANGED' + AccountEmailChanged = 'ACCOUNT_EMAIL_CHANGED', /** Setting a new password for the account is requested. */ - | 'ACCOUNT_SET_PASSWORD_REQUESTED' + AccountSetPasswordRequested = 'ACCOUNT_SET_PASSWORD_REQUESTED', /** A new address created. */ - | 'ADDRESS_CREATED' + AddressCreated = 'ADDRESS_CREATED', /** An address deleted. */ - | 'ADDRESS_DELETED' + AddressDeleted = 'ADDRESS_DELETED', /** An address updated. */ - | 'ADDRESS_UPDATED' + AddressUpdated = 'ADDRESS_UPDATED', /** * All the events. - * - * DEPRECATED: this value will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - | 'ANY_EVENTS' + AnyEvents = 'ANY_EVENTS', /** An app deleted. */ - | 'APP_DELETED' + AppDeleted = 'APP_DELETED', /** A new app installed. */ - | 'APP_INSTALLED' + AppInstalled = 'APP_INSTALLED', /** An app status is changed. */ - | 'APP_STATUS_CHANGED' + AppStatusChanged = 'APP_STATUS_CHANGED', /** An app updated. */ - | 'APP_UPDATED' + AppUpdated = 'APP_UPDATED', /** A new attribute is created. */ - | 'ATTRIBUTE_CREATED' + AttributeCreated = 'ATTRIBUTE_CREATED', /** An attribute is deleted. */ - | 'ATTRIBUTE_DELETED' + AttributeDeleted = 'ATTRIBUTE_DELETED', /** An attribute is updated. */ - | 'ATTRIBUTE_UPDATED' + AttributeUpdated = 'ATTRIBUTE_UPDATED', /** A new attribute value is created. */ - | 'ATTRIBUTE_VALUE_CREATED' + AttributeValueCreated = 'ATTRIBUTE_VALUE_CREATED', /** An attribute value is deleted. */ - | 'ATTRIBUTE_VALUE_DELETED' + AttributeValueDeleted = 'ATTRIBUTE_VALUE_DELETED', /** An attribute value is updated. */ - | 'ATTRIBUTE_VALUE_UPDATED' + AttributeValueUpdated = 'ATTRIBUTE_VALUE_UPDATED', /** A new category created. */ - | 'CATEGORY_CREATED' + CategoryCreated = 'CATEGORY_CREATED', /** A category is deleted. */ - | 'CATEGORY_DELETED' + CategoryDeleted = 'CATEGORY_DELETED', /** A category is updated. */ - | 'CATEGORY_UPDATED' + CategoryUpdated = 'CATEGORY_UPDATED', /** A new channel created. */ - | 'CHANNEL_CREATED' + ChannelCreated = 'CHANNEL_CREATED', /** A channel is deleted. */ - | 'CHANNEL_DELETED' + ChannelDeleted = 'CHANNEL_DELETED', /** A channel metadata is updated. */ - | 'CHANNEL_METADATA_UPDATED' + ChannelMetadataUpdated = 'CHANNEL_METADATA_UPDATED', /** A channel status is changed. */ - | 'CHANNEL_STATUS_CHANGED' + ChannelStatusChanged = 'CHANNEL_STATUS_CHANGED', /** A channel is updated. */ - | 'CHANNEL_UPDATED' + ChannelUpdated = 'CHANNEL_UPDATED', /** A new checkout is created. */ - | 'CHECKOUT_CREATED' - | 'CHECKOUT_FULLY_PAID' - /** - * A checkout metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'CHECKOUT_METADATA_UPDATED' + CheckoutCreated = 'CHECKOUT_CREATED', + CheckoutFullyPaid = 'CHECKOUT_FULLY_PAID', + /** A checkout metadata is updated. */ + CheckoutMetadataUpdated = 'CHECKOUT_METADATA_UPDATED', /** A checkout is updated. It also triggers all updates related to the checkout. */ - | 'CHECKOUT_UPDATED' + CheckoutUpdated = 'CHECKOUT_UPDATED', /** A new collection is created. */ - | 'COLLECTION_CREATED' + CollectionCreated = 'COLLECTION_CREATED', /** A collection is deleted. */ - | 'COLLECTION_DELETED' - /** - * A collection metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'COLLECTION_METADATA_UPDATED' + CollectionDeleted = 'COLLECTION_DELETED', + /** A collection metadata is updated. */ + CollectionMetadataUpdated = 'COLLECTION_METADATA_UPDATED', /** A collection is updated. */ - | 'COLLECTION_UPDATED' + CollectionUpdated = 'COLLECTION_UPDATED', /** A new customer account is created. */ - | 'CUSTOMER_CREATED' + CustomerCreated = 'CUSTOMER_CREATED', /** A customer account is deleted. */ - | 'CUSTOMER_DELETED' - /** - * A customer account metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'CUSTOMER_METADATA_UPDATED' + CustomerDeleted = 'CUSTOMER_DELETED', + /** A customer account metadata is updated. */ + CustomerMetadataUpdated = 'CUSTOMER_METADATA_UPDATED', /** A customer account is updated. */ - | 'CUSTOMER_UPDATED' + CustomerUpdated = 'CUSTOMER_UPDATED', /** A draft order is created. */ - | 'DRAFT_ORDER_CREATED' + DraftOrderCreated = 'DRAFT_ORDER_CREATED', /** A draft order is deleted. */ - | 'DRAFT_ORDER_DELETED' + DraftOrderDeleted = 'DRAFT_ORDER_DELETED', /** A draft order is updated. */ - | 'DRAFT_ORDER_UPDATED' + DraftOrderUpdated = 'DRAFT_ORDER_UPDATED', /** A fulfillment is approved. */ - | 'FULFILLMENT_APPROVED' + FulfillmentApproved = 'FULFILLMENT_APPROVED', /** A fulfillment is cancelled. */ - | 'FULFILLMENT_CANCELED' + FulfillmentCanceled = 'FULFILLMENT_CANCELED', /** A new fulfillment is created. */ - | 'FULFILLMENT_CREATED' - /** - * A fulfillment metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'FULFILLMENT_METADATA_UPDATED' - | 'FULFILLMENT_TRACKING_NUMBER_UPDATED' + FulfillmentCreated = 'FULFILLMENT_CREATED', + /** A fulfillment metadata is updated. */ + FulfillmentMetadataUpdated = 'FULFILLMENT_METADATA_UPDATED', + FulfillmentTrackingNumberUpdated = 'FULFILLMENT_TRACKING_NUMBER_UPDATED', /** A new gift card created. */ - | 'GIFT_CARD_CREATED' + GiftCardCreated = 'GIFT_CARD_CREATED', /** A gift card is deleted. */ - | 'GIFT_CARD_DELETED' - /** - * A gift card export is completed. - * - * Added in Saleor 3.16. - */ - | 'GIFT_CARD_EXPORT_COMPLETED' - /** - * A gift card metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'GIFT_CARD_METADATA_UPDATED' - /** - * A gift card has been sent. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'GIFT_CARD_SENT' + GiftCardDeleted = 'GIFT_CARD_DELETED', + /** A gift card export is completed. */ + GiftCardExportCompleted = 'GIFT_CARD_EXPORT_COMPLETED', + /** A gift card metadata is updated. */ + GiftCardMetadataUpdated = 'GIFT_CARD_METADATA_UPDATED', + /** A gift card has been sent. */ + GiftCardSent = 'GIFT_CARD_SENT', /** A gift card status is changed. */ - | 'GIFT_CARD_STATUS_CHANGED' + GiftCardStatusChanged = 'GIFT_CARD_STATUS_CHANGED', /** A gift card is updated. */ - | 'GIFT_CARD_UPDATED' + GiftCardUpdated = 'GIFT_CARD_UPDATED', /** An invoice is deleted. */ - | 'INVOICE_DELETED' + InvoiceDeleted = 'INVOICE_DELETED', /** An invoice for order requested. */ - | 'INVOICE_REQUESTED' + InvoiceRequested = 'INVOICE_REQUESTED', /** Invoice has been sent. */ - | 'INVOICE_SENT' + InvoiceSent = 'INVOICE_SENT', /** A new menu created. */ - | 'MENU_CREATED' + MenuCreated = 'MENU_CREATED', /** A menu is deleted. */ - | 'MENU_DELETED' + MenuDeleted = 'MENU_DELETED', /** A new menu item created. */ - | 'MENU_ITEM_CREATED' + MenuItemCreated = 'MENU_ITEM_CREATED', /** A menu item is deleted. */ - | 'MENU_ITEM_DELETED' + MenuItemDeleted = 'MENU_ITEM_DELETED', /** A menu item is updated. */ - | 'MENU_ITEM_UPDATED' + MenuItemUpdated = 'MENU_ITEM_UPDATED', /** A menu is updated. */ - | 'MENU_UPDATED' + MenuUpdated = 'MENU_UPDATED', /** * User notification triggered. - * - * DEPRECATED: this value will be removed in Saleor 4.0. See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/docs/next/upgrade-guides/notify-user-deprecation + * @deprecated See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/upgrade-guides/core/3-16-to-3-17#migrating-from-notify_user */ - | 'NOTIFY_USER' + NotifyUser = 'NOTIFY_USER', /** An observability event is created. */ - | 'OBSERVABILITY' - /** - * Orders are imported. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'ORDER_BULK_CREATED' + Observability = 'OBSERVABILITY', + /** Orders are imported. */ + OrderBulkCreated = 'ORDER_BULK_CREATED', /** An order is cancelled. */ - | 'ORDER_CANCELLED' + OrderCancelled = 'ORDER_CANCELLED', /** An order is confirmed (status change unconfirmed -> unfulfilled) by a staff user using the OrderConfirm mutation. It also triggers when the user completes the checkout and the shop setting `automatically_confirm_all_new_orders` is enabled. */ - | 'ORDER_CONFIRMED' + OrderConfirmed = 'ORDER_CONFIRMED', /** A new order is placed. */ - | 'ORDER_CREATED' + OrderCreated = 'ORDER_CREATED', /** An order is expired. */ - | 'ORDER_EXPIRED' + OrderExpired = 'ORDER_EXPIRED', /** An order is fulfilled. */ - | 'ORDER_FULFILLED' + OrderFulfilled = 'ORDER_FULFILLED', /** Payment is made and an order is fully paid. */ - | 'ORDER_FULLY_PAID' - /** - * The order is fully refunded. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'ORDER_FULLY_REFUNDED' - /** - * An order metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'ORDER_METADATA_UPDATED' - /** - * Payment has been made. The order may be partially or fully paid. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'ORDER_PAID' - /** - * The order received a refund. The order may be partially or fully refunded. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'ORDER_REFUNDED' + OrderFullyPaid = 'ORDER_FULLY_PAID', + /** The order is fully refunded. */ + OrderFullyRefunded = 'ORDER_FULLY_REFUNDED', + /** An order metadata is updated. */ + OrderMetadataUpdated = 'ORDER_METADATA_UPDATED', + /** Payment has been made. The order may be partially or fully paid. */ + OrderPaid = 'ORDER_PAID', + /** The order received a refund. The order may be partially or fully refunded. */ + OrderRefunded = 'ORDER_REFUNDED', /** An order is updated; triggered for all changes related to an order; covers all other order webhooks, except for ORDER_CREATED. */ - | 'ORDER_UPDATED' + OrderUpdated = 'ORDER_UPDATED', /** A new page is created. */ - | 'PAGE_CREATED' + PageCreated = 'PAGE_CREATED', /** A page is deleted. */ - | 'PAGE_DELETED' + PageDeleted = 'PAGE_DELETED', /** A new page type is created. */ - | 'PAGE_TYPE_CREATED' + PageTypeCreated = 'PAGE_TYPE_CREATED', /** A page type is deleted. */ - | 'PAGE_TYPE_DELETED' + PageTypeDeleted = 'PAGE_TYPE_DELETED', /** A page type is updated. */ - | 'PAGE_TYPE_UPDATED' + PageTypeUpdated = 'PAGE_TYPE_UPDATED', /** A page is updated. */ - | 'PAGE_UPDATED' + PageUpdated = 'PAGE_UPDATED', /** A new permission group is created. */ - | 'PERMISSION_GROUP_CREATED' + PermissionGroupCreated = 'PERMISSION_GROUP_CREATED', /** A permission group is deleted. */ - | 'PERMISSION_GROUP_DELETED' + PermissionGroupDeleted = 'PERMISSION_GROUP_DELETED', /** A permission group is updated. */ - | 'PERMISSION_GROUP_UPDATED' + PermissionGroupUpdated = 'PERMISSION_GROUP_UPDATED', /** A new product is created. */ - | 'PRODUCT_CREATED' + ProductCreated = 'PRODUCT_CREATED', /** A product is deleted. */ - | 'PRODUCT_DELETED' - /** - * A product export is completed. - * - * Added in Saleor 3.16. - */ - | 'PRODUCT_EXPORT_COMPLETED' - /** - * A new product media is created. - * - * Added in Saleor 3.12. - */ - | 'PRODUCT_MEDIA_CREATED' - /** - * A product media is deleted. - * - * Added in Saleor 3.12. - */ - | 'PRODUCT_MEDIA_DELETED' - /** - * A product media is updated. - * - * Added in Saleor 3.12. - */ - | 'PRODUCT_MEDIA_UPDATED' - /** - * A product metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'PRODUCT_METADATA_UPDATED' + ProductDeleted = 'PRODUCT_DELETED', + /** A product export is completed. */ + ProductExportCompleted = 'PRODUCT_EXPORT_COMPLETED', + /** A new product media is created. */ + ProductMediaCreated = 'PRODUCT_MEDIA_CREATED', + /** A product media is deleted. */ + ProductMediaDeleted = 'PRODUCT_MEDIA_DELETED', + /** A product media is updated. */ + ProductMediaUpdated = 'PRODUCT_MEDIA_UPDATED', + /** A product metadata is updated. */ + ProductMetadataUpdated = 'PRODUCT_METADATA_UPDATED', /** A product is updated. */ - | 'PRODUCT_UPDATED' + ProductUpdated = 'PRODUCT_UPDATED', /** A product variant is back in stock. */ - | 'PRODUCT_VARIANT_BACK_IN_STOCK' + ProductVariantBackInStock = 'PRODUCT_VARIANT_BACK_IN_STOCK', /** A new product variant is created. */ - | 'PRODUCT_VARIANT_CREATED' + ProductVariantCreated = 'PRODUCT_VARIANT_CREATED', /** A product variant is deleted. Warning: this event will not be executed when parent product has been deleted. Check PRODUCT_DELETED. */ - | 'PRODUCT_VARIANT_DELETED' - /** - * A product variant metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'PRODUCT_VARIANT_METADATA_UPDATED' + ProductVariantDeleted = 'PRODUCT_VARIANT_DELETED', + /** A product variant metadata is updated. */ + ProductVariantMetadataUpdated = 'PRODUCT_VARIANT_METADATA_UPDATED', /** A product variant is out of stock. */ - | 'PRODUCT_VARIANT_OUT_OF_STOCK' + ProductVariantOutOfStock = 'PRODUCT_VARIANT_OUT_OF_STOCK', /** A product variant stock is updated */ - | 'PRODUCT_VARIANT_STOCK_UPDATED' + ProductVariantStockUpdated = 'PRODUCT_VARIANT_STOCK_UPDATED', /** A product variant is updated. */ - | 'PRODUCT_VARIANT_UPDATED' + ProductVariantUpdated = 'PRODUCT_VARIANT_UPDATED', /** A promotion is created. */ - | 'PROMOTION_CREATED' + PromotionCreated = 'PROMOTION_CREATED', /** A promotion is deleted. */ - | 'PROMOTION_DELETED' + PromotionDeleted = 'PROMOTION_DELETED', /** A promotion is deactivated. */ - | 'PROMOTION_ENDED' + PromotionEnded = 'PROMOTION_ENDED', /** A promotion rule is created. */ - | 'PROMOTION_RULE_CREATED' + PromotionRuleCreated = 'PROMOTION_RULE_CREATED', /** A promotion rule is deleted. */ - | 'PROMOTION_RULE_DELETED' + PromotionRuleDeleted = 'PROMOTION_RULE_DELETED', /** A promotion rule is updated. */ - | 'PROMOTION_RULE_UPDATED' + PromotionRuleUpdated = 'PROMOTION_RULE_UPDATED', /** A promotion is activated. */ - | 'PROMOTION_STARTED' + PromotionStarted = 'PROMOTION_STARTED', /** A promotion is updated. */ - | 'PROMOTION_UPDATED' + PromotionUpdated = 'PROMOTION_UPDATED', /** A sale is created. */ - | 'SALE_CREATED' + SaleCreated = 'SALE_CREATED', /** A sale is deleted. */ - | 'SALE_DELETED' + SaleDeleted = 'SALE_DELETED', /** A sale is activated or deactivated. */ - | 'SALE_TOGGLE' + SaleToggle = 'SALE_TOGGLE', /** A sale is updated. */ - | 'SALE_UPDATED' + SaleUpdated = 'SALE_UPDATED', /** A new shipping price is created. */ - | 'SHIPPING_PRICE_CREATED' + ShippingPriceCreated = 'SHIPPING_PRICE_CREATED', /** A shipping price is deleted. */ - | 'SHIPPING_PRICE_DELETED' + ShippingPriceDeleted = 'SHIPPING_PRICE_DELETED', /** A shipping price is updated. */ - | 'SHIPPING_PRICE_UPDATED' + ShippingPriceUpdated = 'SHIPPING_PRICE_UPDATED', /** A new shipping zone is created. */ - | 'SHIPPING_ZONE_CREATED' + ShippingZoneCreated = 'SHIPPING_ZONE_CREATED', /** A shipping zone is deleted. */ - | 'SHIPPING_ZONE_DELETED' - /** - * A shipping zone metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'SHIPPING_ZONE_METADATA_UPDATED' + ShippingZoneDeleted = 'SHIPPING_ZONE_DELETED', + /** A shipping zone metadata is updated. */ + ShippingZoneMetadataUpdated = 'SHIPPING_ZONE_METADATA_UPDATED', /** A shipping zone is updated. */ - | 'SHIPPING_ZONE_UPDATED' - /** - * Shop metadata is updated. - * - * Added in Saleor 3.15. - */ - | 'SHOP_METADATA_UPDATED' + ShippingZoneUpdated = 'SHIPPING_ZONE_UPDATED', + /** Shop metadata is updated. */ + ShopMetadataUpdated = 'SHOP_METADATA_UPDATED', /** A new staff user is created. */ - | 'STAFF_CREATED' + StaffCreated = 'STAFF_CREATED', /** A staff user is deleted. */ - | 'STAFF_DELETED' + StaffDeleted = 'STAFF_DELETED', /** Setting a new password for the staff account is requested. */ - | 'STAFF_SET_PASSWORD_REQUESTED' + StaffSetPasswordRequested = 'STAFF_SET_PASSWORD_REQUESTED', /** A staff user is updated. */ - | 'STAFF_UPDATED' - /** - * A thumbnail is created. - * - * Added in Saleor 3.12. - */ - | 'THUMBNAIL_CREATED' - /** - * Transaction item metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'TRANSACTION_ITEM_METADATA_UPDATED' + StaffUpdated = 'STAFF_UPDATED', + /** A thumbnail is created. */ + ThumbnailCreated = 'THUMBNAIL_CREATED', + /** Transaction item metadata is updated. */ + TransactionItemMetadataUpdated = 'TRANSACTION_ITEM_METADATA_UPDATED', /** A new translation is created. */ - | 'TRANSLATION_CREATED' + TranslationCreated = 'TRANSLATION_CREATED', /** A translation is updated. */ - | 'TRANSLATION_UPDATED' - | 'VOUCHER_CODES_CREATED' - | 'VOUCHER_CODES_DELETED' + TranslationUpdated = 'TRANSLATION_UPDATED', + VoucherCodesCreated = 'VOUCHER_CODES_CREATED', + VoucherCodesDeleted = 'VOUCHER_CODES_DELETED', /** * A voucher code export is completed. * * Added in Saleor 3.18. */ - | 'VOUCHER_CODE_EXPORT_COMPLETED' + VoucherCodeExportCompleted = 'VOUCHER_CODE_EXPORT_COMPLETED', /** A new voucher created. */ - | 'VOUCHER_CREATED' + VoucherCreated = 'VOUCHER_CREATED', /** A voucher is deleted. */ - | 'VOUCHER_DELETED' - /** - * A voucher metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'VOUCHER_METADATA_UPDATED' + VoucherDeleted = 'VOUCHER_DELETED', + /** A voucher metadata is updated. */ + VoucherMetadataUpdated = 'VOUCHER_METADATA_UPDATED', /** A voucher is updated. */ - | 'VOUCHER_UPDATED' + VoucherUpdated = 'VOUCHER_UPDATED', /** A new warehouse created. */ - | 'WAREHOUSE_CREATED' + WarehouseCreated = 'WAREHOUSE_CREATED', /** A warehouse is deleted. */ - | 'WAREHOUSE_DELETED' - /** - * A warehouse metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'WAREHOUSE_METADATA_UPDATED' + WarehouseDeleted = 'WAREHOUSE_DELETED', + /** A warehouse metadata is updated. */ + WarehouseMetadataUpdated = 'WAREHOUSE_METADATA_UPDATED', /** A warehouse is updated. */ - | 'WAREHOUSE_UPDATED'; + WarehouseUpdated = 'WAREHOUSE_UPDATED' +} /** Enum determining type of webhook. */ -export type WebhookEventTypeEnum = +export enum WebhookEventTypeEnum { /** An account email change is requested. */ - | 'ACCOUNT_CHANGE_EMAIL_REQUESTED' + AccountChangeEmailRequested = 'ACCOUNT_CHANGE_EMAIL_REQUESTED', /** An account confirmation is requested. */ - | 'ACCOUNT_CONFIRMATION_REQUESTED' + AccountConfirmationRequested = 'ACCOUNT_CONFIRMATION_REQUESTED', /** An account is confirmed. */ - | 'ACCOUNT_CONFIRMED' + AccountConfirmed = 'ACCOUNT_CONFIRMED', /** An account is deleted. */ - | 'ACCOUNT_DELETED' + AccountDeleted = 'ACCOUNT_DELETED', /** An account delete is requested. */ - | 'ACCOUNT_DELETE_REQUESTED' + AccountDeleteRequested = 'ACCOUNT_DELETE_REQUESTED', /** An account email was changed */ - | 'ACCOUNT_EMAIL_CHANGED' + AccountEmailChanged = 'ACCOUNT_EMAIL_CHANGED', /** Setting a new password for the account is requested. */ - | 'ACCOUNT_SET_PASSWORD_REQUESTED' + AccountSetPasswordRequested = 'ACCOUNT_SET_PASSWORD_REQUESTED', /** A new address created. */ - | 'ADDRESS_CREATED' + AddressCreated = 'ADDRESS_CREATED', /** An address deleted. */ - | 'ADDRESS_DELETED' + AddressDeleted = 'ADDRESS_DELETED', /** An address updated. */ - | 'ADDRESS_UPDATED' + AddressUpdated = 'ADDRESS_UPDATED', /** * All the events. - * - * DEPRECATED: this value will be removed in Saleor 4.0. + * @deprecated Field no longer supported */ - | 'ANY_EVENTS' + AnyEvents = 'ANY_EVENTS', /** An app deleted. */ - | 'APP_DELETED' + AppDeleted = 'APP_DELETED', /** A new app installed. */ - | 'APP_INSTALLED' + AppInstalled = 'APP_INSTALLED', /** An app status is changed. */ - | 'APP_STATUS_CHANGED' + AppStatusChanged = 'APP_STATUS_CHANGED', /** An app updated. */ - | 'APP_UPDATED' + AppUpdated = 'APP_UPDATED', /** A new attribute is created. */ - | 'ATTRIBUTE_CREATED' + AttributeCreated = 'ATTRIBUTE_CREATED', /** An attribute is deleted. */ - | 'ATTRIBUTE_DELETED' + AttributeDeleted = 'ATTRIBUTE_DELETED', /** An attribute is updated. */ - | 'ATTRIBUTE_UPDATED' + AttributeUpdated = 'ATTRIBUTE_UPDATED', /** A new attribute value is created. */ - | 'ATTRIBUTE_VALUE_CREATED' + AttributeValueCreated = 'ATTRIBUTE_VALUE_CREATED', /** An attribute value is deleted. */ - | 'ATTRIBUTE_VALUE_DELETED' + AttributeValueDeleted = 'ATTRIBUTE_VALUE_DELETED', /** An attribute value is updated. */ - | 'ATTRIBUTE_VALUE_UPDATED' + AttributeValueUpdated = 'ATTRIBUTE_VALUE_UPDATED', /** A new category created. */ - | 'CATEGORY_CREATED' + CategoryCreated = 'CATEGORY_CREATED', /** A category is deleted. */ - | 'CATEGORY_DELETED' + CategoryDeleted = 'CATEGORY_DELETED', /** A category is updated. */ - | 'CATEGORY_UPDATED' + CategoryUpdated = 'CATEGORY_UPDATED', /** A new channel created. */ - | 'CHANNEL_CREATED' + ChannelCreated = 'CHANNEL_CREATED', /** A channel is deleted. */ - | 'CHANNEL_DELETED' + ChannelDeleted = 'CHANNEL_DELETED', /** A channel metadata is updated. */ - | 'CHANNEL_METADATA_UPDATED' + ChannelMetadataUpdated = 'CHANNEL_METADATA_UPDATED', /** A channel status is changed. */ - | 'CHANNEL_STATUS_CHANGED' + ChannelStatusChanged = 'CHANNEL_STATUS_CHANGED', /** A channel is updated. */ - | 'CHANNEL_UPDATED' - /** - * Event called for checkout tax calculation. - * - * Added in Saleor 3.6. - */ - | 'CHECKOUT_CALCULATE_TAXES' + ChannelUpdated = 'CHANNEL_UPDATED', + /** Event called for checkout tax calculation. */ + CheckoutCalculateTaxes = 'CHECKOUT_CALCULATE_TAXES', /** A new checkout is created. */ - | 'CHECKOUT_CREATED' + CheckoutCreated = 'CHECKOUT_CREATED', /** Filter shipping methods for checkout. */ - | 'CHECKOUT_FILTER_SHIPPING_METHODS' - | 'CHECKOUT_FULLY_PAID' - /** - * A checkout metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'CHECKOUT_METADATA_UPDATED' + CheckoutFilterShippingMethods = 'CHECKOUT_FILTER_SHIPPING_METHODS', + CheckoutFullyPaid = 'CHECKOUT_FULLY_PAID', + /** A checkout metadata is updated. */ + CheckoutMetadataUpdated = 'CHECKOUT_METADATA_UPDATED', /** A checkout is updated. It also triggers all updates related to the checkout. */ - | 'CHECKOUT_UPDATED' + CheckoutUpdated = 'CHECKOUT_UPDATED', /** A new collection is created. */ - | 'COLLECTION_CREATED' + CollectionCreated = 'COLLECTION_CREATED', /** A collection is deleted. */ - | 'COLLECTION_DELETED' - /** - * A collection metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'COLLECTION_METADATA_UPDATED' + CollectionDeleted = 'COLLECTION_DELETED', + /** A collection metadata is updated. */ + CollectionMetadataUpdated = 'COLLECTION_METADATA_UPDATED', /** A collection is updated. */ - | 'COLLECTION_UPDATED' + CollectionUpdated = 'COLLECTION_UPDATED', /** A new customer account is created. */ - | 'CUSTOMER_CREATED' + CustomerCreated = 'CUSTOMER_CREATED', /** A customer account is deleted. */ - | 'CUSTOMER_DELETED' - /** - * A customer account metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'CUSTOMER_METADATA_UPDATED' + CustomerDeleted = 'CUSTOMER_DELETED', + /** A customer account metadata is updated. */ + CustomerMetadataUpdated = 'CUSTOMER_METADATA_UPDATED', /** A customer account is updated. */ - | 'CUSTOMER_UPDATED' + CustomerUpdated = 'CUSTOMER_UPDATED', /** A draft order is created. */ - | 'DRAFT_ORDER_CREATED' + DraftOrderCreated = 'DRAFT_ORDER_CREATED', /** A draft order is deleted. */ - | 'DRAFT_ORDER_DELETED' + DraftOrderDeleted = 'DRAFT_ORDER_DELETED', /** A draft order is updated. */ - | 'DRAFT_ORDER_UPDATED' + DraftOrderUpdated = 'DRAFT_ORDER_UPDATED', /** A fulfillment is approved. */ - | 'FULFILLMENT_APPROVED' + FulfillmentApproved = 'FULFILLMENT_APPROVED', /** A fulfillment is cancelled. */ - | 'FULFILLMENT_CANCELED' + FulfillmentCanceled = 'FULFILLMENT_CANCELED', /** A new fulfillment is created. */ - | 'FULFILLMENT_CREATED' - /** - * A fulfillment metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'FULFILLMENT_METADATA_UPDATED' - | 'FULFILLMENT_TRACKING_NUMBER_UPDATED' + FulfillmentCreated = 'FULFILLMENT_CREATED', + /** A fulfillment metadata is updated. */ + FulfillmentMetadataUpdated = 'FULFILLMENT_METADATA_UPDATED', + FulfillmentTrackingNumberUpdated = 'FULFILLMENT_TRACKING_NUMBER_UPDATED', /** A new gift card created. */ - | 'GIFT_CARD_CREATED' + GiftCardCreated = 'GIFT_CARD_CREATED', /** A gift card is deleted. */ - | 'GIFT_CARD_DELETED' - /** - * A gift card export is completed. - * - * Added in Saleor 3.16. - */ - | 'GIFT_CARD_EXPORT_COMPLETED' - /** - * A gift card metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'GIFT_CARD_METADATA_UPDATED' - /** - * A gift card has been sent. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'GIFT_CARD_SENT' + GiftCardDeleted = 'GIFT_CARD_DELETED', + /** A gift card export is completed. */ + GiftCardExportCompleted = 'GIFT_CARD_EXPORT_COMPLETED', + /** A gift card metadata is updated. */ + GiftCardMetadataUpdated = 'GIFT_CARD_METADATA_UPDATED', + /** A gift card has been sent. */ + GiftCardSent = 'GIFT_CARD_SENT', /** A gift card status is changed. */ - | 'GIFT_CARD_STATUS_CHANGED' + GiftCardStatusChanged = 'GIFT_CARD_STATUS_CHANGED', /** A gift card is updated. */ - | 'GIFT_CARD_UPDATED' + GiftCardUpdated = 'GIFT_CARD_UPDATED', /** An invoice is deleted. */ - | 'INVOICE_DELETED' + InvoiceDeleted = 'INVOICE_DELETED', /** An invoice for order requested. */ - | 'INVOICE_REQUESTED' + InvoiceRequested = 'INVOICE_REQUESTED', /** Invoice has been sent. */ - | 'INVOICE_SENT' - | 'LIST_STORED_PAYMENT_METHODS' + InvoiceSent = 'INVOICE_SENT', + ListStoredPaymentMethods = 'LIST_STORED_PAYMENT_METHODS', /** A new menu created. */ - | 'MENU_CREATED' + MenuCreated = 'MENU_CREATED', /** A menu is deleted. */ - | 'MENU_DELETED' + MenuDeleted = 'MENU_DELETED', /** A new menu item created. */ - | 'MENU_ITEM_CREATED' + MenuItemCreated = 'MENU_ITEM_CREATED', /** A menu item is deleted. */ - | 'MENU_ITEM_DELETED' + MenuItemDeleted = 'MENU_ITEM_DELETED', /** A menu item is updated. */ - | 'MENU_ITEM_UPDATED' + MenuItemUpdated = 'MENU_ITEM_UPDATED', /** A menu is updated. */ - | 'MENU_UPDATED' + MenuUpdated = 'MENU_UPDATED', /** * User notification triggered. - * - * DEPRECATED: this value will be removed in Saleor 4.0. See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/docs/next/upgrade-guides/notify-user-deprecation + * @deprecated See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/upgrade-guides/core/3-16-to-3-17#migrating-from-notify_user */ - | 'NOTIFY_USER' + NotifyUser = 'NOTIFY_USER', /** An observability event is created. */ - | 'OBSERVABILITY' - /** - * Orders are imported. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'ORDER_BULK_CREATED' - /** - * Event called for order tax calculation. - * - * Added in Saleor 3.6. - */ - | 'ORDER_CALCULATE_TAXES' + Observability = 'OBSERVABILITY', + /** Orders are imported. */ + OrderBulkCreated = 'ORDER_BULK_CREATED', + /** Event called for order tax calculation. */ + OrderCalculateTaxes = 'ORDER_CALCULATE_TAXES', /** An order is cancelled. */ - | 'ORDER_CANCELLED' + OrderCancelled = 'ORDER_CANCELLED', /** An order is confirmed (status change unconfirmed -> unfulfilled) by a staff user using the OrderConfirm mutation. It also triggers when the user completes the checkout and the shop setting `automatically_confirm_all_new_orders` is enabled. */ - | 'ORDER_CONFIRMED' + OrderConfirmed = 'ORDER_CONFIRMED', /** A new order is placed. */ - | 'ORDER_CREATED' + OrderCreated = 'ORDER_CREATED', /** An order is expired. */ - | 'ORDER_EXPIRED' + OrderExpired = 'ORDER_EXPIRED', /** Filter shipping methods for order. */ - | 'ORDER_FILTER_SHIPPING_METHODS' + OrderFilterShippingMethods = 'ORDER_FILTER_SHIPPING_METHODS', /** An order is fulfilled. */ - | 'ORDER_FULFILLED' + OrderFulfilled = 'ORDER_FULFILLED', /** Payment is made and an order is fully paid. */ - | 'ORDER_FULLY_PAID' - /** - * The order is fully refunded. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'ORDER_FULLY_REFUNDED' - /** - * An order metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'ORDER_METADATA_UPDATED' - /** - * Payment has been made. The order may be partially or fully paid. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'ORDER_PAID' - /** - * The order received a refund. The order may be partially or fully refunded. - * - * Added in Saleor 3.14. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'ORDER_REFUNDED' + OrderFullyPaid = 'ORDER_FULLY_PAID', + /** The order is fully refunded. */ + OrderFullyRefunded = 'ORDER_FULLY_REFUNDED', + /** An order metadata is updated. */ + OrderMetadataUpdated = 'ORDER_METADATA_UPDATED', + /** Payment has been made. The order may be partially or fully paid. */ + OrderPaid = 'ORDER_PAID', + /** The order received a refund. The order may be partially or fully refunded. */ + OrderRefunded = 'ORDER_REFUNDED', /** An order is updated; triggered for all changes related to an order; covers all other order webhooks, except for ORDER_CREATED. */ - | 'ORDER_UPDATED' + OrderUpdated = 'ORDER_UPDATED', /** A new page is created. */ - | 'PAGE_CREATED' + PageCreated = 'PAGE_CREATED', /** A page is deleted. */ - | 'PAGE_DELETED' + PageDeleted = 'PAGE_DELETED', /** A new page type is created. */ - | 'PAGE_TYPE_CREATED' + PageTypeCreated = 'PAGE_TYPE_CREATED', /** A page type is deleted. */ - | 'PAGE_TYPE_DELETED' + PageTypeDeleted = 'PAGE_TYPE_DELETED', /** A page type is updated. */ - | 'PAGE_TYPE_UPDATED' + PageTypeUpdated = 'PAGE_TYPE_UPDATED', /** A page is updated. */ - | 'PAGE_UPDATED' + PageUpdated = 'PAGE_UPDATED', /** Authorize payment. */ - | 'PAYMENT_AUTHORIZE' + PaymentAuthorize = 'PAYMENT_AUTHORIZE', /** Capture payment. */ - | 'PAYMENT_CAPTURE' + PaymentCapture = 'PAYMENT_CAPTURE', /** Confirm payment. */ - | 'PAYMENT_CONFIRM' - | 'PAYMENT_GATEWAY_INITIALIZE_SESSION' - | 'PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION' + PaymentConfirm = 'PAYMENT_CONFIRM', + PaymentGatewayInitializeSession = 'PAYMENT_GATEWAY_INITIALIZE_SESSION', + PaymentGatewayInitializeTokenizationSession = 'PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION', /** Listing available payment gateways. */ - | 'PAYMENT_LIST_GATEWAYS' - | 'PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION' - | 'PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION' + PaymentListGateways = 'PAYMENT_LIST_GATEWAYS', + PaymentMethodInitializeTokenizationSession = 'PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION', + PaymentMethodProcessTokenizationSession = 'PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION', /** Process payment. */ - | 'PAYMENT_PROCESS' + PaymentProcess = 'PAYMENT_PROCESS', /** Refund payment. */ - | 'PAYMENT_REFUND' + PaymentRefund = 'PAYMENT_REFUND', /** Void payment. */ - | 'PAYMENT_VOID' + PaymentVoid = 'PAYMENT_VOID', /** A new permission group is created. */ - | 'PERMISSION_GROUP_CREATED' + PermissionGroupCreated = 'PERMISSION_GROUP_CREATED', /** A permission group is deleted. */ - | 'PERMISSION_GROUP_DELETED' + PermissionGroupDeleted = 'PERMISSION_GROUP_DELETED', /** A permission group is updated. */ - | 'PERMISSION_GROUP_UPDATED' + PermissionGroupUpdated = 'PERMISSION_GROUP_UPDATED', /** A new product is created. */ - | 'PRODUCT_CREATED' + ProductCreated = 'PRODUCT_CREATED', /** A product is deleted. */ - | 'PRODUCT_DELETED' - /** - * A product export is completed. - * - * Added in Saleor 3.16. - */ - | 'PRODUCT_EXPORT_COMPLETED' - /** - * A new product media is created. - * - * Added in Saleor 3.12. - */ - | 'PRODUCT_MEDIA_CREATED' - /** - * A product media is deleted. - * - * Added in Saleor 3.12. - */ - | 'PRODUCT_MEDIA_DELETED' - /** - * A product media is updated. - * - * Added in Saleor 3.12. - */ - | 'PRODUCT_MEDIA_UPDATED' - /** - * A product metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'PRODUCT_METADATA_UPDATED' + ProductDeleted = 'PRODUCT_DELETED', + /** A product export is completed. */ + ProductExportCompleted = 'PRODUCT_EXPORT_COMPLETED', + /** A new product media is created. */ + ProductMediaCreated = 'PRODUCT_MEDIA_CREATED', + /** A product media is deleted. */ + ProductMediaDeleted = 'PRODUCT_MEDIA_DELETED', + /** A product media is updated. */ + ProductMediaUpdated = 'PRODUCT_MEDIA_UPDATED', + /** A product metadata is updated. */ + ProductMetadataUpdated = 'PRODUCT_METADATA_UPDATED', /** A product is updated. */ - | 'PRODUCT_UPDATED' + ProductUpdated = 'PRODUCT_UPDATED', /** A product variant is back in stock. */ - | 'PRODUCT_VARIANT_BACK_IN_STOCK' + ProductVariantBackInStock = 'PRODUCT_VARIANT_BACK_IN_STOCK', /** A new product variant is created. */ - | 'PRODUCT_VARIANT_CREATED' + ProductVariantCreated = 'PRODUCT_VARIANT_CREATED', /** A product variant is deleted. Warning: this event will not be executed when parent product has been deleted. Check PRODUCT_DELETED. */ - | 'PRODUCT_VARIANT_DELETED' - /** - * A product variant metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'PRODUCT_VARIANT_METADATA_UPDATED' + ProductVariantDeleted = 'PRODUCT_VARIANT_DELETED', + /** A product variant metadata is updated. */ + ProductVariantMetadataUpdated = 'PRODUCT_VARIANT_METADATA_UPDATED', /** A product variant is out of stock. */ - | 'PRODUCT_VARIANT_OUT_OF_STOCK' + ProductVariantOutOfStock = 'PRODUCT_VARIANT_OUT_OF_STOCK', /** A product variant stock is updated */ - | 'PRODUCT_VARIANT_STOCK_UPDATED' + ProductVariantStockUpdated = 'PRODUCT_VARIANT_STOCK_UPDATED', /** A product variant is updated. */ - | 'PRODUCT_VARIANT_UPDATED' + ProductVariantUpdated = 'PRODUCT_VARIANT_UPDATED', /** A promotion is created. */ - | 'PROMOTION_CREATED' + PromotionCreated = 'PROMOTION_CREATED', /** A promotion is deleted. */ - | 'PROMOTION_DELETED' + PromotionDeleted = 'PROMOTION_DELETED', /** A promotion is deactivated. */ - | 'PROMOTION_ENDED' + PromotionEnded = 'PROMOTION_ENDED', /** A promotion rule is created. */ - | 'PROMOTION_RULE_CREATED' + PromotionRuleCreated = 'PROMOTION_RULE_CREATED', /** A promotion rule is deleted. */ - | 'PROMOTION_RULE_DELETED' + PromotionRuleDeleted = 'PROMOTION_RULE_DELETED', /** A promotion rule is updated. */ - | 'PROMOTION_RULE_UPDATED' + PromotionRuleUpdated = 'PROMOTION_RULE_UPDATED', /** A promotion is activated. */ - | 'PROMOTION_STARTED' + PromotionStarted = 'PROMOTION_STARTED', /** A promotion is updated. */ - | 'PROMOTION_UPDATED' + PromotionUpdated = 'PROMOTION_UPDATED', /** A sale is created. */ - | 'SALE_CREATED' + SaleCreated = 'SALE_CREATED', /** A sale is deleted. */ - | 'SALE_DELETED' + SaleDeleted = 'SALE_DELETED', /** A sale is activated or deactivated. */ - | 'SALE_TOGGLE' + SaleToggle = 'SALE_TOGGLE', /** A sale is updated. */ - | 'SALE_UPDATED' + SaleUpdated = 'SALE_UPDATED', /** Fetch external shipping methods for checkout. */ - | 'SHIPPING_LIST_METHODS_FOR_CHECKOUT' + ShippingListMethodsForCheckout = 'SHIPPING_LIST_METHODS_FOR_CHECKOUT', /** A new shipping price is created. */ - | 'SHIPPING_PRICE_CREATED' + ShippingPriceCreated = 'SHIPPING_PRICE_CREATED', /** A shipping price is deleted. */ - | 'SHIPPING_PRICE_DELETED' + ShippingPriceDeleted = 'SHIPPING_PRICE_DELETED', /** A shipping price is updated. */ - | 'SHIPPING_PRICE_UPDATED' + ShippingPriceUpdated = 'SHIPPING_PRICE_UPDATED', /** A new shipping zone is created. */ - | 'SHIPPING_ZONE_CREATED' + ShippingZoneCreated = 'SHIPPING_ZONE_CREATED', /** A shipping zone is deleted. */ - | 'SHIPPING_ZONE_DELETED' - /** - * A shipping zone metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'SHIPPING_ZONE_METADATA_UPDATED' + ShippingZoneDeleted = 'SHIPPING_ZONE_DELETED', + /** A shipping zone metadata is updated. */ + ShippingZoneMetadataUpdated = 'SHIPPING_ZONE_METADATA_UPDATED', /** A shipping zone is updated. */ - | 'SHIPPING_ZONE_UPDATED' - /** - * Shop metadata is updated. - * - * Added in Saleor 3.15. - */ - | 'SHOP_METADATA_UPDATED' + ShippingZoneUpdated = 'SHIPPING_ZONE_UPDATED', + /** Shop metadata is updated. */ + ShopMetadataUpdated = 'SHOP_METADATA_UPDATED', /** A new staff user is created. */ - | 'STAFF_CREATED' + StaffCreated = 'STAFF_CREATED', /** A staff user is deleted. */ - | 'STAFF_DELETED' + StaffDeleted = 'STAFF_DELETED', /** Setting a new password for the staff account is requested. */ - | 'STAFF_SET_PASSWORD_REQUESTED' + StaffSetPasswordRequested = 'STAFF_SET_PASSWORD_REQUESTED', /** A staff user is updated. */ - | 'STAFF_UPDATED' - | 'STORED_PAYMENT_METHOD_DELETE_REQUESTED' - /** - * A thumbnail is created. - * - * Added in Saleor 3.12. - */ - | 'THUMBNAIL_CREATED' - /** - * Event called when cancel has been requested for transaction. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'TRANSACTION_CANCELATION_REQUESTED' - /** - * Event called when charge has been requested for transaction. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'TRANSACTION_CHARGE_REQUESTED' - | 'TRANSACTION_INITIALIZE_SESSION' - /** - * Transaction item metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'TRANSACTION_ITEM_METADATA_UPDATED' - | 'TRANSACTION_PROCESS_SESSION' - /** - * Event called when refund has been requested for transaction. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'TRANSACTION_REFUND_REQUESTED' + StaffUpdated = 'STAFF_UPDATED', + StoredPaymentMethodDeleteRequested = 'STORED_PAYMENT_METHOD_DELETE_REQUESTED', + /** A thumbnail is created. */ + ThumbnailCreated = 'THUMBNAIL_CREATED', + /** Event called when cancel has been requested for transaction. */ + TransactionCancelationRequested = 'TRANSACTION_CANCELATION_REQUESTED', + /** Event called when charge has been requested for transaction. */ + TransactionChargeRequested = 'TRANSACTION_CHARGE_REQUESTED', + TransactionInitializeSession = 'TRANSACTION_INITIALIZE_SESSION', + /** Transaction item metadata is updated. */ + TransactionItemMetadataUpdated = 'TRANSACTION_ITEM_METADATA_UPDATED', + TransactionProcessSession = 'TRANSACTION_PROCESS_SESSION', + /** Event called when refund has been requested for transaction. */ + TransactionRefundRequested = 'TRANSACTION_REFUND_REQUESTED', /** A new translation is created. */ - | 'TRANSLATION_CREATED' + TranslationCreated = 'TRANSLATION_CREATED', /** A translation is updated. */ - | 'TRANSLATION_UPDATED' - | 'VOUCHER_CODES_CREATED' - | 'VOUCHER_CODES_DELETED' + TranslationUpdated = 'TRANSLATION_UPDATED', + VoucherCodesCreated = 'VOUCHER_CODES_CREATED', + VoucherCodesDeleted = 'VOUCHER_CODES_DELETED', /** * A voucher code export is completed. * * Added in Saleor 3.18. */ - | 'VOUCHER_CODE_EXPORT_COMPLETED' + VoucherCodeExportCompleted = 'VOUCHER_CODE_EXPORT_COMPLETED', /** A new voucher created. */ - | 'VOUCHER_CREATED' + VoucherCreated = 'VOUCHER_CREATED', /** A voucher is deleted. */ - | 'VOUCHER_DELETED' - /** - * A voucher metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'VOUCHER_METADATA_UPDATED' + VoucherDeleted = 'VOUCHER_DELETED', + /** A voucher metadata is updated. */ + VoucherMetadataUpdated = 'VOUCHER_METADATA_UPDATED', /** A voucher is updated. */ - | 'VOUCHER_UPDATED' + VoucherUpdated = 'VOUCHER_UPDATED', /** A new warehouse created. */ - | 'WAREHOUSE_CREATED' + WarehouseCreated = 'WAREHOUSE_CREATED', /** A warehouse is deleted. */ - | 'WAREHOUSE_DELETED' - /** - * A warehouse metadata is updated. - * - * Added in Saleor 3.8. - */ - | 'WAREHOUSE_METADATA_UPDATED' + WarehouseDeleted = 'WAREHOUSE_DELETED', + /** A warehouse metadata is updated. */ + WarehouseMetadataUpdated = 'WAREHOUSE_METADATA_UPDATED', /** A warehouse is updated. */ - | 'WAREHOUSE_UPDATED'; + WarehouseUpdated = 'WAREHOUSE_UPDATED' +} /** Enum determining type of webhook. */ -export type WebhookEventTypeSyncEnum = - /** - * Event called for checkout tax calculation. - * - * Added in Saleor 3.6. - */ - | 'CHECKOUT_CALCULATE_TAXES' +export enum WebhookEventTypeSyncEnum { + /** Event called for checkout tax calculation. */ + CheckoutCalculateTaxes = 'CHECKOUT_CALCULATE_TAXES', /** Filter shipping methods for checkout. */ - | 'CHECKOUT_FILTER_SHIPPING_METHODS' - | 'LIST_STORED_PAYMENT_METHODS' - /** - * Event called for order tax calculation. - * - * Added in Saleor 3.6. - */ - | 'ORDER_CALCULATE_TAXES' + CheckoutFilterShippingMethods = 'CHECKOUT_FILTER_SHIPPING_METHODS', + ListStoredPaymentMethods = 'LIST_STORED_PAYMENT_METHODS', + /** Event called for order tax calculation. */ + OrderCalculateTaxes = 'ORDER_CALCULATE_TAXES', /** Filter shipping methods for order. */ - | 'ORDER_FILTER_SHIPPING_METHODS' + OrderFilterShippingMethods = 'ORDER_FILTER_SHIPPING_METHODS', /** Authorize payment. */ - | 'PAYMENT_AUTHORIZE' + PaymentAuthorize = 'PAYMENT_AUTHORIZE', /** Capture payment. */ - | 'PAYMENT_CAPTURE' + PaymentCapture = 'PAYMENT_CAPTURE', /** Confirm payment. */ - | 'PAYMENT_CONFIRM' - | 'PAYMENT_GATEWAY_INITIALIZE_SESSION' - | 'PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION' + PaymentConfirm = 'PAYMENT_CONFIRM', + PaymentGatewayInitializeSession = 'PAYMENT_GATEWAY_INITIALIZE_SESSION', + PaymentGatewayInitializeTokenizationSession = 'PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION', /** Listing available payment gateways. */ - | 'PAYMENT_LIST_GATEWAYS' - | 'PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION' - | 'PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION' + PaymentListGateways = 'PAYMENT_LIST_GATEWAYS', + PaymentMethodInitializeTokenizationSession = 'PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION', + PaymentMethodProcessTokenizationSession = 'PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION', /** Process payment. */ - | 'PAYMENT_PROCESS' + PaymentProcess = 'PAYMENT_PROCESS', /** Refund payment. */ - | 'PAYMENT_REFUND' + PaymentRefund = 'PAYMENT_REFUND', /** Void payment. */ - | 'PAYMENT_VOID' + PaymentVoid = 'PAYMENT_VOID', /** Fetch external shipping methods for checkout. */ - | 'SHIPPING_LIST_METHODS_FOR_CHECKOUT' - | 'STORED_PAYMENT_METHOD_DELETE_REQUESTED' - /** - * Event called when cancel has been requested for transaction. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'TRANSACTION_CANCELATION_REQUESTED' - /** - * Event called when charge has been requested for transaction. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'TRANSACTION_CHARGE_REQUESTED' - | 'TRANSACTION_INITIALIZE_SESSION' - | 'TRANSACTION_PROCESS_SESSION' - /** - * Event called when refund has been requested for transaction. - * - * Added in Saleor 3.13. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - | 'TRANSACTION_REFUND_REQUESTED'; - -/** An enumeration. */ -export type WebhookSampleEventTypeEnum = - | 'ACCOUNT_CHANGE_EMAIL_REQUESTED' - | 'ACCOUNT_CONFIRMATION_REQUESTED' - | 'ACCOUNT_CONFIRMED' - | 'ACCOUNT_DELETED' - | 'ACCOUNT_DELETE_REQUESTED' - | 'ACCOUNT_EMAIL_CHANGED' - | 'ACCOUNT_SET_PASSWORD_REQUESTED' - | 'ADDRESS_CREATED' - | 'ADDRESS_DELETED' - | 'ADDRESS_UPDATED' - | 'APP_DELETED' - | 'APP_INSTALLED' - | 'APP_STATUS_CHANGED' - | 'APP_UPDATED' - | 'ATTRIBUTE_CREATED' - | 'ATTRIBUTE_DELETED' - | 'ATTRIBUTE_UPDATED' - | 'ATTRIBUTE_VALUE_CREATED' - | 'ATTRIBUTE_VALUE_DELETED' - | 'ATTRIBUTE_VALUE_UPDATED' - | 'CATEGORY_CREATED' - | 'CATEGORY_DELETED' - | 'CATEGORY_UPDATED' - | 'CHANNEL_CREATED' - | 'CHANNEL_DELETED' - | 'CHANNEL_METADATA_UPDATED' - | 'CHANNEL_STATUS_CHANGED' - | 'CHANNEL_UPDATED' - | 'CHECKOUT_CREATED' - | 'CHECKOUT_FULLY_PAID' - | 'CHECKOUT_METADATA_UPDATED' - | 'CHECKOUT_UPDATED' - | 'COLLECTION_CREATED' - | 'COLLECTION_DELETED' - | 'COLLECTION_METADATA_UPDATED' - | 'COLLECTION_UPDATED' - | 'CUSTOMER_CREATED' - | 'CUSTOMER_DELETED' - | 'CUSTOMER_METADATA_UPDATED' - | 'CUSTOMER_UPDATED' - | 'DRAFT_ORDER_CREATED' - | 'DRAFT_ORDER_DELETED' - | 'DRAFT_ORDER_UPDATED' - | 'FULFILLMENT_APPROVED' - | 'FULFILLMENT_CANCELED' - | 'FULFILLMENT_CREATED' - | 'FULFILLMENT_METADATA_UPDATED' - | 'FULFILLMENT_TRACKING_NUMBER_UPDATED' - | 'GIFT_CARD_CREATED' - | 'GIFT_CARD_DELETED' - | 'GIFT_CARD_EXPORT_COMPLETED' - | 'GIFT_CARD_METADATA_UPDATED' - | 'GIFT_CARD_SENT' - | 'GIFT_CARD_STATUS_CHANGED' - | 'GIFT_CARD_UPDATED' - | 'INVOICE_DELETED' - | 'INVOICE_REQUESTED' - | 'INVOICE_SENT' - | 'MENU_CREATED' - | 'MENU_DELETED' - | 'MENU_ITEM_CREATED' - | 'MENU_ITEM_DELETED' - | 'MENU_ITEM_UPDATED' - | 'MENU_UPDATED' - | 'NOTIFY_USER' - | 'OBSERVABILITY' - | 'ORDER_BULK_CREATED' - | 'ORDER_CANCELLED' - | 'ORDER_CONFIRMED' - | 'ORDER_CREATED' - | 'ORDER_EXPIRED' - | 'ORDER_FULFILLED' - | 'ORDER_FULLY_PAID' - | 'ORDER_FULLY_REFUNDED' - | 'ORDER_METADATA_UPDATED' - | 'ORDER_PAID' - | 'ORDER_REFUNDED' - | 'ORDER_UPDATED' - | 'PAGE_CREATED' - | 'PAGE_DELETED' - | 'PAGE_TYPE_CREATED' - | 'PAGE_TYPE_DELETED' - | 'PAGE_TYPE_UPDATED' - | 'PAGE_UPDATED' - | 'PERMISSION_GROUP_CREATED' - | 'PERMISSION_GROUP_DELETED' - | 'PERMISSION_GROUP_UPDATED' - | 'PRODUCT_CREATED' - | 'PRODUCT_DELETED' - | 'PRODUCT_EXPORT_COMPLETED' - | 'PRODUCT_MEDIA_CREATED' - | 'PRODUCT_MEDIA_DELETED' - | 'PRODUCT_MEDIA_UPDATED' - | 'PRODUCT_METADATA_UPDATED' - | 'PRODUCT_UPDATED' - | 'PRODUCT_VARIANT_BACK_IN_STOCK' - | 'PRODUCT_VARIANT_CREATED' - | 'PRODUCT_VARIANT_DELETED' - | 'PRODUCT_VARIANT_METADATA_UPDATED' - | 'PRODUCT_VARIANT_OUT_OF_STOCK' - | 'PRODUCT_VARIANT_STOCK_UPDATED' - | 'PRODUCT_VARIANT_UPDATED' - | 'PROMOTION_CREATED' - | 'PROMOTION_DELETED' - | 'PROMOTION_ENDED' - | 'PROMOTION_RULE_CREATED' - | 'PROMOTION_RULE_DELETED' - | 'PROMOTION_RULE_UPDATED' - | 'PROMOTION_STARTED' - | 'PROMOTION_UPDATED' - | 'SALE_CREATED' - | 'SALE_DELETED' - | 'SALE_TOGGLE' - | 'SALE_UPDATED' - | 'SHIPPING_PRICE_CREATED' - | 'SHIPPING_PRICE_DELETED' - | 'SHIPPING_PRICE_UPDATED' - | 'SHIPPING_ZONE_CREATED' - | 'SHIPPING_ZONE_DELETED' - | 'SHIPPING_ZONE_METADATA_UPDATED' - | 'SHIPPING_ZONE_UPDATED' - | 'SHOP_METADATA_UPDATED' - | 'STAFF_CREATED' - | 'STAFF_DELETED' - | 'STAFF_SET_PASSWORD_REQUESTED' - | 'STAFF_UPDATED' - | 'THUMBNAIL_CREATED' - | 'TRANSACTION_ITEM_METADATA_UPDATED' - | 'TRANSLATION_CREATED' - | 'TRANSLATION_UPDATED' - | 'VOUCHER_CODES_CREATED' - | 'VOUCHER_CODES_DELETED' - | 'VOUCHER_CODE_EXPORT_COMPLETED' - | 'VOUCHER_CREATED' - | 'VOUCHER_DELETED' - | 'VOUCHER_METADATA_UPDATED' - | 'VOUCHER_UPDATED' - | 'WAREHOUSE_CREATED' - | 'WAREHOUSE_DELETED' - | 'WAREHOUSE_METADATA_UPDATED' - | 'WAREHOUSE_UPDATED'; + ShippingListMethodsForCheckout = 'SHIPPING_LIST_METHODS_FOR_CHECKOUT', + StoredPaymentMethodDeleteRequested = 'STORED_PAYMENT_METHOD_DELETE_REQUESTED', + /** Event called when cancel has been requested for transaction. */ + TransactionCancelationRequested = 'TRANSACTION_CANCELATION_REQUESTED', + /** Event called when charge has been requested for transaction. */ + TransactionChargeRequested = 'TRANSACTION_CHARGE_REQUESTED', + TransactionInitializeSession = 'TRANSACTION_INITIALIZE_SESSION', + TransactionProcessSession = 'TRANSACTION_PROCESS_SESSION', + /** Event called when refund has been requested for transaction. */ + TransactionRefundRequested = 'TRANSACTION_REFUND_REQUESTED' +} + +export enum WebhookSampleEventTypeEnum { + AccountChangeEmailRequested = 'ACCOUNT_CHANGE_EMAIL_REQUESTED', + AccountConfirmationRequested = 'ACCOUNT_CONFIRMATION_REQUESTED', + AccountConfirmed = 'ACCOUNT_CONFIRMED', + AccountDeleted = 'ACCOUNT_DELETED', + AccountDeleteRequested = 'ACCOUNT_DELETE_REQUESTED', + AccountEmailChanged = 'ACCOUNT_EMAIL_CHANGED', + AccountSetPasswordRequested = 'ACCOUNT_SET_PASSWORD_REQUESTED', + AddressCreated = 'ADDRESS_CREATED', + AddressDeleted = 'ADDRESS_DELETED', + AddressUpdated = 'ADDRESS_UPDATED', + AppDeleted = 'APP_DELETED', + AppInstalled = 'APP_INSTALLED', + AppStatusChanged = 'APP_STATUS_CHANGED', + AppUpdated = 'APP_UPDATED', + AttributeCreated = 'ATTRIBUTE_CREATED', + AttributeDeleted = 'ATTRIBUTE_DELETED', + AttributeUpdated = 'ATTRIBUTE_UPDATED', + AttributeValueCreated = 'ATTRIBUTE_VALUE_CREATED', + AttributeValueDeleted = 'ATTRIBUTE_VALUE_DELETED', + AttributeValueUpdated = 'ATTRIBUTE_VALUE_UPDATED', + CategoryCreated = 'CATEGORY_CREATED', + CategoryDeleted = 'CATEGORY_DELETED', + CategoryUpdated = 'CATEGORY_UPDATED', + ChannelCreated = 'CHANNEL_CREATED', + ChannelDeleted = 'CHANNEL_DELETED', + ChannelMetadataUpdated = 'CHANNEL_METADATA_UPDATED', + ChannelStatusChanged = 'CHANNEL_STATUS_CHANGED', + ChannelUpdated = 'CHANNEL_UPDATED', + CheckoutCreated = 'CHECKOUT_CREATED', + CheckoutFullyPaid = 'CHECKOUT_FULLY_PAID', + CheckoutMetadataUpdated = 'CHECKOUT_METADATA_UPDATED', + CheckoutUpdated = 'CHECKOUT_UPDATED', + CollectionCreated = 'COLLECTION_CREATED', + CollectionDeleted = 'COLLECTION_DELETED', + CollectionMetadataUpdated = 'COLLECTION_METADATA_UPDATED', + CollectionUpdated = 'COLLECTION_UPDATED', + CustomerCreated = 'CUSTOMER_CREATED', + CustomerDeleted = 'CUSTOMER_DELETED', + CustomerMetadataUpdated = 'CUSTOMER_METADATA_UPDATED', + CustomerUpdated = 'CUSTOMER_UPDATED', + DraftOrderCreated = 'DRAFT_ORDER_CREATED', + DraftOrderDeleted = 'DRAFT_ORDER_DELETED', + DraftOrderUpdated = 'DRAFT_ORDER_UPDATED', + FulfillmentApproved = 'FULFILLMENT_APPROVED', + FulfillmentCanceled = 'FULFILLMENT_CANCELED', + FulfillmentCreated = 'FULFILLMENT_CREATED', + FulfillmentMetadataUpdated = 'FULFILLMENT_METADATA_UPDATED', + FulfillmentTrackingNumberUpdated = 'FULFILLMENT_TRACKING_NUMBER_UPDATED', + GiftCardCreated = 'GIFT_CARD_CREATED', + GiftCardDeleted = 'GIFT_CARD_DELETED', + GiftCardExportCompleted = 'GIFT_CARD_EXPORT_COMPLETED', + GiftCardMetadataUpdated = 'GIFT_CARD_METADATA_UPDATED', + GiftCardSent = 'GIFT_CARD_SENT', + GiftCardStatusChanged = 'GIFT_CARD_STATUS_CHANGED', + GiftCardUpdated = 'GIFT_CARD_UPDATED', + InvoiceDeleted = 'INVOICE_DELETED', + InvoiceRequested = 'INVOICE_REQUESTED', + InvoiceSent = 'INVOICE_SENT', + MenuCreated = 'MENU_CREATED', + MenuDeleted = 'MENU_DELETED', + MenuItemCreated = 'MENU_ITEM_CREATED', + MenuItemDeleted = 'MENU_ITEM_DELETED', + MenuItemUpdated = 'MENU_ITEM_UPDATED', + MenuUpdated = 'MENU_UPDATED', + NotifyUser = 'NOTIFY_USER', + Observability = 'OBSERVABILITY', + OrderBulkCreated = 'ORDER_BULK_CREATED', + OrderCancelled = 'ORDER_CANCELLED', + OrderConfirmed = 'ORDER_CONFIRMED', + OrderCreated = 'ORDER_CREATED', + OrderExpired = 'ORDER_EXPIRED', + OrderFulfilled = 'ORDER_FULFILLED', + OrderFullyPaid = 'ORDER_FULLY_PAID', + OrderFullyRefunded = 'ORDER_FULLY_REFUNDED', + OrderMetadataUpdated = 'ORDER_METADATA_UPDATED', + OrderPaid = 'ORDER_PAID', + OrderRefunded = 'ORDER_REFUNDED', + OrderUpdated = 'ORDER_UPDATED', + PageCreated = 'PAGE_CREATED', + PageDeleted = 'PAGE_DELETED', + PageTypeCreated = 'PAGE_TYPE_CREATED', + PageTypeDeleted = 'PAGE_TYPE_DELETED', + PageTypeUpdated = 'PAGE_TYPE_UPDATED', + PageUpdated = 'PAGE_UPDATED', + PermissionGroupCreated = 'PERMISSION_GROUP_CREATED', + PermissionGroupDeleted = 'PERMISSION_GROUP_DELETED', + PermissionGroupUpdated = 'PERMISSION_GROUP_UPDATED', + ProductCreated = 'PRODUCT_CREATED', + ProductDeleted = 'PRODUCT_DELETED', + ProductExportCompleted = 'PRODUCT_EXPORT_COMPLETED', + ProductMediaCreated = 'PRODUCT_MEDIA_CREATED', + ProductMediaDeleted = 'PRODUCT_MEDIA_DELETED', + ProductMediaUpdated = 'PRODUCT_MEDIA_UPDATED', + ProductMetadataUpdated = 'PRODUCT_METADATA_UPDATED', + ProductUpdated = 'PRODUCT_UPDATED', + ProductVariantBackInStock = 'PRODUCT_VARIANT_BACK_IN_STOCK', + ProductVariantCreated = 'PRODUCT_VARIANT_CREATED', + ProductVariantDeleted = 'PRODUCT_VARIANT_DELETED', + ProductVariantMetadataUpdated = 'PRODUCT_VARIANT_METADATA_UPDATED', + ProductVariantOutOfStock = 'PRODUCT_VARIANT_OUT_OF_STOCK', + ProductVariantStockUpdated = 'PRODUCT_VARIANT_STOCK_UPDATED', + ProductVariantUpdated = 'PRODUCT_VARIANT_UPDATED', + PromotionCreated = 'PROMOTION_CREATED', + PromotionDeleted = 'PROMOTION_DELETED', + PromotionEnded = 'PROMOTION_ENDED', + PromotionRuleCreated = 'PROMOTION_RULE_CREATED', + PromotionRuleDeleted = 'PROMOTION_RULE_DELETED', + PromotionRuleUpdated = 'PROMOTION_RULE_UPDATED', + PromotionStarted = 'PROMOTION_STARTED', + PromotionUpdated = 'PROMOTION_UPDATED', + SaleCreated = 'SALE_CREATED', + SaleDeleted = 'SALE_DELETED', + SaleToggle = 'SALE_TOGGLE', + SaleUpdated = 'SALE_UPDATED', + ShippingPriceCreated = 'SHIPPING_PRICE_CREATED', + ShippingPriceDeleted = 'SHIPPING_PRICE_DELETED', + ShippingPriceUpdated = 'SHIPPING_PRICE_UPDATED', + ShippingZoneCreated = 'SHIPPING_ZONE_CREATED', + ShippingZoneDeleted = 'SHIPPING_ZONE_DELETED', + ShippingZoneMetadataUpdated = 'SHIPPING_ZONE_METADATA_UPDATED', + ShippingZoneUpdated = 'SHIPPING_ZONE_UPDATED', + ShopMetadataUpdated = 'SHOP_METADATA_UPDATED', + StaffCreated = 'STAFF_CREATED', + StaffDeleted = 'STAFF_DELETED', + StaffSetPasswordRequested = 'STAFF_SET_PASSWORD_REQUESTED', + StaffUpdated = 'STAFF_UPDATED', + ThumbnailCreated = 'THUMBNAIL_CREATED', + TransactionItemMetadataUpdated = 'TRANSACTION_ITEM_METADATA_UPDATED', + TranslationCreated = 'TRANSLATION_CREATED', + TranslationUpdated = 'TRANSLATION_UPDATED', + VoucherCodesCreated = 'VOUCHER_CODES_CREATED', + VoucherCodesDeleted = 'VOUCHER_CODES_DELETED', + VoucherCodeExportCompleted = 'VOUCHER_CODE_EXPORT_COMPLETED', + VoucherCreated = 'VOUCHER_CREATED', + VoucherDeleted = 'VOUCHER_DELETED', + VoucherMetadataUpdated = 'VOUCHER_METADATA_UPDATED', + VoucherUpdated = 'VOUCHER_UPDATED', + WarehouseCreated = 'WAREHOUSE_CREATED', + WarehouseDeleted = 'WAREHOUSE_DELETED', + WarehouseMetadataUpdated = 'WAREHOUSE_METADATA_UPDATED', + WarehouseUpdated = 'WAREHOUSE_UPDATED' +} /** * Trigger a webhook event. Supports a single event (the first, if multiple provided in the `webhook.subscription_query`). Requires permission relevant to processed event. Successfully delivered webhook returns `delivery` with status='PENDING' and empty payload. * - * Added in Saleor 3.11. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - * * Requires one of the following permissions: AUTHENTICATED_STAFF_USER. */ export type WebhookTrigger = { - __typename?: 'WebhookTrigger'; - delivery?: Maybe; - errors: Array; + readonly delivery?: Maybe; + readonly errors: ReadonlyArray; }; export type WebhookTriggerError = { - __typename?: 'WebhookTriggerError'; /** The error code. */ - code: WebhookTriggerErrorCode; + readonly code: WebhookTriggerErrorCode; /** Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. */ - field?: Maybe; + readonly field?: Maybe; /** The error message. */ - message?: Maybe; -}; - -/** An enumeration. */ -export type WebhookTriggerErrorCode = - | 'GRAPHQL_ERROR' - | 'INVALID_ID' - | 'MISSING_EVENT' - | 'MISSING_PERMISSION' - | 'MISSING_QUERY' - | 'MISSING_SUBSCRIPTION' - | 'NOT_FOUND' - | 'SYNTAX' - | 'TYPE_NOT_SUPPORTED' - | 'UNABLE_TO_PARSE'; + readonly message?: Maybe; +}; + +export enum WebhookTriggerErrorCode { + GraphqlError = 'GRAPHQL_ERROR', + InvalidId = 'INVALID_ID', + MissingEvent = 'MISSING_EVENT', + MissingPermission = 'MISSING_PERMISSION', + MissingQuery = 'MISSING_QUERY', + MissingSubscription = 'MISSING_SUBSCRIPTION', + NotFound = 'NOT_FOUND', + Syntax = 'SYNTAX', + TypeNotSupported = 'TYPE_NOT_SUPPORTED', + UnableToParse = 'UNABLE_TO_PARSE' +} /** * Updates a webhook subscription. @@ -33088,91 +29186,83 @@ export type WebhookTriggerErrorCode = * Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. */ export type WebhookUpdate = { - __typename?: 'WebhookUpdate'; - errors: Array; - webhook?: Maybe; - /** @deprecated This field will be removed in Saleor 4.0. Use `errors` field instead. */ - webhookErrors: Array; + readonly errors: ReadonlyArray; + readonly webhook?: Maybe; + /** @deprecated Use `errors` field instead. */ + readonly webhookErrors: ReadonlyArray; }; export type WebhookUpdateInput = { /** ID of the app to which webhook belongs. */ - app?: InputMaybe; + readonly app?: InputMaybe; /** The asynchronous events that webhook wants to subscribe. */ - asyncEvents?: InputMaybe>; - /** - * Custom headers, which will be added to HTTP request. There is a limitation of 5 headers per webhook and 998 characters per header.Only `X-*`, `Authorization*`, and `BrokerProperties` keys are allowed. - * - * Added in Saleor 3.12. - * - * Note: this API is currently in Feature Preview and can be subject to changes at later point. - */ - customHeaders?: InputMaybe; + readonly asyncEvents?: InputMaybe>; + /** Custom headers, which will be added to HTTP request. There is a limitation of 5 headers per webhook and 998 characters per header.Only `X-*`, `Authorization*`, and `BrokerProperties` keys are allowed. */ + readonly customHeaders?: InputMaybe; /** * The events that webhook wants to subscribe. - * - * DEPRECATED: this field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead. + * @deprecated Use `asyncEvents` or `syncEvents` instead. */ - events?: InputMaybe>; + readonly events?: InputMaybe>; /** Determine if webhook will be set active or not. */ - isActive?: InputMaybe; + readonly isActive?: InputMaybe; /** The new name of the webhook. */ - name?: InputMaybe; - /** - * Subscription query used to define a webhook payload. - * - * Added in Saleor 3.2. - */ - query?: InputMaybe; + readonly name?: InputMaybe; + /** Subscription query used to define a webhook payload. */ + readonly query?: InputMaybe; /** * Use to create a hash signature with each payload. - * - * DEPRECATED: this field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. + * @deprecated As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. */ - secretKey?: InputMaybe; + readonly secretKey?: InputMaybe; /** The synchronous events that webhook wants to subscribe. */ - syncEvents?: InputMaybe>; + readonly syncEvents?: InputMaybe>; /** The url to receive the payload. */ - targetUrl?: InputMaybe; + readonly targetUrl?: InputMaybe; }; /** Represents weight value in a specific weight unit. */ export type Weight = { - __typename?: 'Weight'; /** Weight unit. */ - unit: WeightUnitsEnum; + readonly unit: WeightUnitsEnum; /** Weight value. Returns a value with maximal three decimal places */ - value: Scalars['Float']; + readonly value: Scalars['Float']; }; -/** An enumeration. */ -export type WeightUnitsEnum = - | 'G' - | 'KG' - | 'LB' - | 'OZ' - | 'TONNE'; +export enum WeightUnitsEnum { + G = 'G', + Kg = 'KG', + Lb = 'LB', + Oz = 'OZ', + Tonne = 'TONNE' +} /** _Entity union as defined by Federation spec. */ export type _Entity = Address | App | Category | Collection | Group | Order | PageType | Product | ProductMedia | ProductType | ProductVariant | User; /** _Service manifest as defined by Federation spec. */ export type _Service = { - __typename?: '_Service'; - sdl?: Maybe; + readonly sdl?: Maybe; }; -export type OrderCreatedWebhookPayloadFragment = { __typename?: 'OrderCreated', order?: { __typename?: 'Order', userEmail?: string | null, id: string, number: string, user?: { __typename?: 'User', email: string, firstName: string, lastName: string } | null } | null }; +export type OrderCreatedWebhookPayloadFragment = { readonly order?: { readonly userEmail?: string | null, readonly id: string, readonly number: string, readonly user?: { readonly email: string, readonly firstName: string, readonly lastName: string } | null } | null }; + +export type OrderFilterShippingMethodsPayloadFragment = { readonly order?: { readonly id: string } | null, readonly shippingMethods?: ReadonlyArray<{ readonly id: string, readonly name: string }> | null }; + +export type LastOrderQueryVariables = Exact<{ [key: string]: never; }>; + + +export type LastOrderQuery = { readonly orders?: { readonly edges: ReadonlyArray<{ readonly node: { readonly id: string, readonly number: string, readonly created: string, readonly user?: { readonly firstName: string, readonly lastName: string } | null, readonly shippingAddress?: { readonly country: { readonly country: string } } | null, readonly total: { readonly gross: { readonly amount: number, readonly currency: string } }, readonly lines: ReadonlyArray<{ readonly id: string }> } }> } | null }; export type OrderCreatedSubscriptionSubscriptionVariables = Exact<{ [key: string]: never; }>; -export type OrderCreatedSubscriptionSubscription = { __typename?: 'Subscription', event?: { __typename?: 'AccountChangeEmailRequested' } | { __typename?: 'AccountConfirmationRequested' } | { __typename?: 'AccountConfirmed' } | { __typename?: 'AccountDeleteRequested' } | { __typename?: 'AccountDeleted' } | { __typename?: 'AccountEmailChanged' } | { __typename?: 'AccountSetPasswordRequested' } | { __typename?: 'AddressCreated' } | { __typename?: 'AddressDeleted' } | { __typename?: 'AddressUpdated' } | { __typename?: 'AppDeleted' } | { __typename?: 'AppInstalled' } | { __typename?: 'AppStatusChanged' } | { __typename?: 'AppUpdated' } | { __typename?: 'AttributeCreated' } | { __typename?: 'AttributeDeleted' } | { __typename?: 'AttributeUpdated' } | { __typename?: 'AttributeValueCreated' } | { __typename?: 'AttributeValueDeleted' } | { __typename?: 'AttributeValueUpdated' } | { __typename?: 'CalculateTaxes' } | { __typename?: 'CategoryCreated' } | { __typename?: 'CategoryDeleted' } | { __typename?: 'CategoryUpdated' } | { __typename?: 'ChannelCreated' } | { __typename?: 'ChannelDeleted' } | { __typename?: 'ChannelMetadataUpdated' } | { __typename?: 'ChannelStatusChanged' } | { __typename?: 'ChannelUpdated' } | { __typename?: 'CheckoutCreated' } | { __typename?: 'CheckoutFilterShippingMethods' } | { __typename?: 'CheckoutFullyPaid' } | { __typename?: 'CheckoutMetadataUpdated' } | { __typename?: 'CheckoutUpdated' } | { __typename?: 'CollectionCreated' } | { __typename?: 'CollectionDeleted' } | { __typename?: 'CollectionMetadataUpdated' } | { __typename?: 'CollectionUpdated' } | { __typename?: 'CustomerCreated' } | { __typename?: 'CustomerMetadataUpdated' } | { __typename?: 'CustomerUpdated' } | { __typename?: 'DraftOrderCreated' } | { __typename?: 'DraftOrderDeleted' } | { __typename?: 'DraftOrderUpdated' } | { __typename?: 'FulfillmentApproved' } | { __typename?: 'FulfillmentCanceled' } | { __typename?: 'FulfillmentCreated' } | { __typename?: 'FulfillmentMetadataUpdated' } | { __typename?: 'FulfillmentTrackingNumberUpdated' } | { __typename?: 'GiftCardCreated' } | { __typename?: 'GiftCardDeleted' } | { __typename?: 'GiftCardExportCompleted' } | { __typename?: 'GiftCardMetadataUpdated' } | { __typename?: 'GiftCardSent' } | { __typename?: 'GiftCardStatusChanged' } | { __typename?: 'GiftCardUpdated' } | { __typename?: 'InvoiceDeleted' } | { __typename?: 'InvoiceRequested' } | { __typename?: 'InvoiceSent' } | { __typename?: 'ListStoredPaymentMethods' } | { __typename?: 'MenuCreated' } | { __typename?: 'MenuDeleted' } | { __typename?: 'MenuItemCreated' } | { __typename?: 'MenuItemDeleted' } | { __typename?: 'MenuItemUpdated' } | { __typename?: 'MenuUpdated' } | { __typename?: 'OrderBulkCreated' } | { __typename?: 'OrderCancelled' } | { __typename?: 'OrderConfirmed' } | { __typename?: 'OrderCreated', order?: { __typename?: 'Order', userEmail?: string | null, id: string, number: string, user?: { __typename?: 'User', email: string, firstName: string, lastName: string } | null } | null } | { __typename?: 'OrderExpired' } | { __typename?: 'OrderFilterShippingMethods' } | { __typename?: 'OrderFulfilled' } | { __typename?: 'OrderFullyPaid' } | { __typename?: 'OrderFullyRefunded' } | { __typename?: 'OrderMetadataUpdated' } | { __typename?: 'OrderPaid' } | { __typename?: 'OrderRefunded' } | { __typename?: 'OrderUpdated' } | { __typename?: 'PageCreated' } | { __typename?: 'PageDeleted' } | { __typename?: 'PageTypeCreated' } | { __typename?: 'PageTypeDeleted' } | { __typename?: 'PageTypeUpdated' } | { __typename?: 'PageUpdated' } | { __typename?: 'PaymentAuthorize' } | { __typename?: 'PaymentCaptureEvent' } | { __typename?: 'PaymentConfirmEvent' } | { __typename?: 'PaymentGatewayInitializeSession' } | { __typename?: 'PaymentGatewayInitializeTokenizationSession' } | { __typename?: 'PaymentListGateways' } | { __typename?: 'PaymentMethodInitializeTokenizationSession' } | { __typename?: 'PaymentMethodProcessTokenizationSession' } | { __typename?: 'PaymentProcessEvent' } | { __typename?: 'PaymentRefundEvent' } | { __typename?: 'PaymentVoidEvent' } | { __typename?: 'PermissionGroupCreated' } | { __typename?: 'PermissionGroupDeleted' } | { __typename?: 'PermissionGroupUpdated' } | { __typename?: 'ProductCreated' } | { __typename?: 'ProductDeleted' } | { __typename?: 'ProductExportCompleted' } | { __typename?: 'ProductMediaCreated' } | { __typename?: 'ProductMediaDeleted' } | { __typename?: 'ProductMediaUpdated' } | { __typename?: 'ProductMetadataUpdated' } | { __typename?: 'ProductUpdated' } | { __typename?: 'ProductVariantBackInStock' } | { __typename?: 'ProductVariantCreated' } | { __typename?: 'ProductVariantDeleted' } | { __typename?: 'ProductVariantMetadataUpdated' } | { __typename?: 'ProductVariantOutOfStock' } | { __typename?: 'ProductVariantStockUpdated' } | { __typename?: 'ProductVariantUpdated' } | { __typename?: 'PromotionCreated' } | { __typename?: 'PromotionDeleted' } | { __typename?: 'PromotionEnded' } | { __typename?: 'PromotionRuleCreated' } | { __typename?: 'PromotionRuleDeleted' } | { __typename?: 'PromotionRuleUpdated' } | { __typename?: 'PromotionStarted' } | { __typename?: 'PromotionUpdated' } | { __typename?: 'SaleCreated' } | { __typename?: 'SaleDeleted' } | { __typename?: 'SaleToggle' } | { __typename?: 'SaleUpdated' } | { __typename?: 'ShippingListMethodsForCheckout' } | { __typename?: 'ShippingPriceCreated' } | { __typename?: 'ShippingPriceDeleted' } | { __typename?: 'ShippingPriceUpdated' } | { __typename?: 'ShippingZoneCreated' } | { __typename?: 'ShippingZoneDeleted' } | { __typename?: 'ShippingZoneMetadataUpdated' } | { __typename?: 'ShippingZoneUpdated' } | { __typename?: 'ShopMetadataUpdated' } | { __typename?: 'StaffCreated' } | { __typename?: 'StaffDeleted' } | { __typename?: 'StaffSetPasswordRequested' } | { __typename?: 'StaffUpdated' } | { __typename?: 'StoredPaymentMethodDeleteRequested' } | { __typename?: 'ThumbnailCreated' } | { __typename?: 'TransactionCancelationRequested' } | { __typename?: 'TransactionChargeRequested' } | { __typename?: 'TransactionInitializeSession' } | { __typename?: 'TransactionItemMetadataUpdated' } | { __typename?: 'TransactionProcessSession' } | { __typename?: 'TransactionRefundRequested' } | { __typename?: 'TranslationCreated' } | { __typename?: 'TranslationUpdated' } | { __typename?: 'VoucherCodeExportCompleted' } | { __typename?: 'VoucherCodesCreated' } | { __typename?: 'VoucherCodesDeleted' } | { __typename?: 'VoucherCreated' } | { __typename?: 'VoucherDeleted' } | { __typename?: 'VoucherMetadataUpdated' } | { __typename?: 'VoucherUpdated' } | { __typename?: 'WarehouseCreated' } | { __typename?: 'WarehouseDeleted' } | { __typename?: 'WarehouseMetadataUpdated' } | { __typename?: 'WarehouseUpdated' } | null }; +export type OrderCreatedSubscriptionSubscription = { readonly event?: { readonly order?: { readonly userEmail?: string | null, readonly id: string, readonly number: string, readonly user?: { readonly email: string, readonly firstName: string, readonly lastName: string } | null } | null } | {} | null }; -export type LastOrderQueryVariables = Exact<{ [key: string]: never; }>; +export type OrderFilterShippingMethodsSubscriptionSubscriptionVariables = Exact<{ [key: string]: never; }>; -export type LastOrderQuery = { __typename?: 'Query', orders?: { __typename?: 'OrderCountableConnection', edges: Array<{ __typename?: 'OrderCountableEdge', node: { __typename?: 'Order', id: string, number: string, created: any, user?: { __typename?: 'User', firstName: string, lastName: string } | null, shippingAddress?: { __typename?: 'Address', country: { __typename?: 'CountryDisplay', country: string } } | null, total: { __typename?: 'TaxedMoney', gross: { __typename?: 'Money', amount: number, currency: string } }, lines: Array<{ __typename?: 'OrderLine', id: string }> } }> } | null }; +export type OrderFilterShippingMethodsSubscriptionSubscription = { readonly event?: { readonly order?: { readonly id: string } | null, readonly shippingMethods?: ReadonlyArray<{ readonly id: string, readonly name: string }> | null } | {} | null }; import { IntrospectionQuery } from 'graphql'; export default { @@ -35326,6 +31416,25 @@ export default { }, "args": [] }, + { + "name": "breakerLastStateChange", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, + { + "name": "breakerState", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + }, + "args": [] + }, { "name": "configurationUrl", "type": { @@ -36780,6 +32889,58 @@ export default { ], "interfaces": [] }, + { + "kind": "OBJECT", + "name": "AppReenableSyncWebhooks", + "fields": [ + { + "name": "app", + "type": { + "kind": "OBJECT", + "name": "App", + "ofType": null + }, + "args": [] + }, + { + "name": "appErrors", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "AppError", + "ofType": null + } + } + } + }, + "args": [] + }, + { + "name": "errors", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "AppError", + "ofType": null + } + } + } + }, + "args": [] + } + ], + "interfaces": [] + }, { "kind": "OBJECT", "name": "AppRetryInstall", @@ -40808,6 +36969,14 @@ export default { }, "args": [] }, + { + "name": "slug", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "translation", "type": { @@ -40955,6 +37124,14 @@ export default { }, "args": [] }, + { + "name": "slug", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "translatableContent", "type": { @@ -42156,6 +38333,17 @@ export default { }, "args": [] }, + { + "name": "customerNote", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + }, + "args": [] + }, { "name": "deliveryMethod", "type": { @@ -43248,6 +39436,58 @@ export default { ], "interfaces": [] }, + { + "kind": "OBJECT", + "name": "CheckoutCustomerNoteUpdate", + "fields": [ + { + "name": "checkout", + "type": { + "kind": "OBJECT", + "name": "Checkout", + "ofType": null + }, + "args": [] + }, + { + "name": "checkoutErrors", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "CheckoutError", + "ofType": null + } + } + } + }, + "args": [] + }, + { + "name": "errors", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "CheckoutError", + "ofType": null + } + } + } + }, + "args": [] + } + ], + "interfaces": [] + }, { "kind": "OBJECT", "name": "CheckoutDeliveryMethodUpdate", @@ -43663,6 +39903,24 @@ export default { } ] }, + { + "name": "priorTotalPrice", + "type": { + "kind": "OBJECT", + "name": "Money", + "ofType": null + }, + "args": [] + }, + { + "name": "priorUnitPrice", + "type": { + "kind": "OBJECT", + "name": "Money", + "ofType": null + }, + "args": [] + }, { "name": "privateMetadata", "type": { @@ -44354,6 +40612,17 @@ export default { "kind": "OBJECT", "name": "CheckoutSettings", "fields": [ + { + "name": "automaticallyCompleteFullyPaidCheckouts", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + }, + "args": [] + }, { "name": "useLegacyErrorFlow", "type": { @@ -45769,6 +42038,14 @@ export default { }, "args": [] }, + { + "name": "slug", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "translation", "type": { @@ -45916,6 +42193,14 @@ export default { }, "args": [] }, + { + "name": "slug", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "translatableContent", "type": { @@ -56720,6 +53005,26 @@ export default { } ] }, + { + "name": "appReenableSyncWebhooks", + "type": { + "kind": "OBJECT", + "name": "AppReenableSyncWebhooks", + "ofType": null + }, + "args": [ + { + "name": "appId", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + } + } + ] + }, { "name": "appRetryInstall", "type": { @@ -57670,13 +53975,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -57693,13 +53991,6 @@ export default { "name": "Any" } } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -57721,13 +54012,6 @@ export default { } } }, - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -57736,7 +54020,7 @@ export default { } }, { - "name": "token", + "name": "saveAddress", "type": { "kind": "SCALAR", "name": "Any" @@ -57759,13 +54043,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -57799,20 +54076,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "storeSource", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -57864,13 +54127,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "customerId", "type": { @@ -57884,13 +54140,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -57903,24 +54152,40 @@ export default { }, "args": [ { - "name": "checkoutId", + "name": "id", "type": { "kind": "SCALAR", "name": "Any" } - }, + } + ] + }, + { + "name": "checkoutCustomerNoteUpdate", + "type": { + "kind": "OBJECT", + "name": "CheckoutCustomerNoteUpdate", + "ofType": null + }, + "args": [ { - "name": "id", + "name": "customerNote", "type": { - "kind": "SCALAR", - "name": "Any" + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } } }, { - "name": "token", + "name": "id", "type": { - "kind": "SCALAR", - "name": "Any" + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } } } ] @@ -57946,13 +54211,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -57964,13 +54222,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "email", "type": { @@ -57987,13 +54238,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -58005,13 +54249,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -58028,13 +54265,6 @@ export default { "name": "Any" } } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -58046,13 +54276,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -58066,13 +54289,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -58084,13 +54300,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -58113,13 +54322,6 @@ export default { } } } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -58153,13 +54355,6 @@ export default { } } } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -58171,13 +54366,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -58200,13 +54388,6 @@ export default { } } } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -58218,13 +54399,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -58241,13 +54415,6 @@ export default { "name": "Any" } } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -58259,13 +54426,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -58286,13 +54446,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -58305,14 +54458,14 @@ export default { }, "args": [ { - "name": "checkoutId", + "name": "id", "type": { "kind": "SCALAR", "name": "Any" } }, { - "name": "id", + "name": "saveAddress", "type": { "kind": "SCALAR", "name": "Any" @@ -58328,13 +54481,6 @@ export default { } } }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "validationRules", "type": { @@ -58352,13 +54498,6 @@ export default { "ofType": null }, "args": [ - { - "name": "checkoutId", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "id", "type": { @@ -58372,13 +54511,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -64833,6 +60965,32 @@ export default { "name": "Any" } }, + { + "name": "transactionMetadata", + "type": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + } + } + }, + { + "name": "transactionPrivateMetadata", + "type": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + } + } + }, { "name": "type", "type": { @@ -67343,9 +63501,12 @@ export default { { "name": "undiscountedShippingPrice", "type": { - "kind": "OBJECT", - "name": "Money", - "ofType": null + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "Money", + "ofType": null + } }, "args": [] }, @@ -68257,6 +64418,18 @@ export default { }, "args": [] }, + { + "name": "total", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "Money", + "ofType": null + } + }, + "args": [] + }, { "name": "translatedName", "type": { @@ -69830,6 +66003,21 @@ export default { }, "args": [] }, + { + "name": "discounts", + "type": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "OrderLineDiscount", + "ofType": null + } + } + }, + "args": [] + }, { "name": "id", "type": { @@ -70352,6 +66540,105 @@ export default { ], "interfaces": [] }, + { + "kind": "OBJECT", + "name": "OrderLineDiscount", + "fields": [ + { + "name": "id", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + }, + "args": [] + }, + { + "name": "name", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, + { + "name": "reason", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, + { + "name": "total", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "Money", + "ofType": null + } + }, + "args": [] + }, + { + "name": "translatedName", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, + { + "name": "type", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + }, + "args": [] + }, + { + "name": "unit", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "OBJECT", + "name": "Money", + "ofType": null + } + }, + "args": [] + }, + { + "name": "value", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + }, + "args": [] + }, + { + "name": "valueType", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + }, + "args": [] + } + ], + "interfaces": [] + }, { "kind": "OBJECT", "name": "OrderLineDiscountRemove", @@ -71081,6 +67368,14 @@ export default { }, "args": [] }, + { + "name": "draftOrderLinePriceFreezePeriod", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "expireOrdersAfter", "type": { @@ -71110,6 +67405,17 @@ export default { } }, "args": [] + }, + { + "name": "useLegacyLineDiscountPropagation", + "type": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + }, + "args": [] } ], "interfaces": [] @@ -72446,6 +68752,14 @@ export default { }, "args": [] }, + { + "name": "slug", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "title", "type": { @@ -72596,6 +68910,14 @@ export default { }, "args": [] }, + { + "name": "slug", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "title", "type": { @@ -76751,6 +73073,65 @@ export default { }, "args": [] }, + { + "name": "productVariants", + "type": { + "kind": "OBJECT", + "name": "ProductVariantCountableConnection", + "ofType": null + }, + "args": [ + { + "name": "after", + "type": { + "kind": "SCALAR", + "name": "Any" + } + }, + { + "name": "before", + "type": { + "kind": "SCALAR", + "name": "Any" + } + }, + { + "name": "filter", + "type": { + "kind": "SCALAR", + "name": "Any" + } + }, + { + "name": "first", + "type": { + "kind": "SCALAR", + "name": "Any" + } + }, + { + "name": "last", + "type": { + "kind": "SCALAR", + "name": "Any" + } + }, + { + "name": "sortBy", + "type": { + "kind": "SCALAR", + "name": "Any" + } + }, + { + "name": "where", + "type": { + "kind": "SCALAR", + "name": "Any" + } + } + ] + }, { "name": "rating", "type": { @@ -78989,6 +75370,15 @@ export default { }, "args": [] }, + { + "name": "discountPrior", + "type": { + "kind": "OBJECT", + "name": "TaxedMoney", + "ofType": null + }, + "args": [] + }, { "name": "displayGrossPrices", "type": { @@ -79026,6 +75416,15 @@ export default { }, "args": [] }, + { + "name": "priceRangePrior", + "type": { + "kind": "OBJECT", + "name": "TaxedMoneyRange", + "ofType": null + }, + "args": [] + }, { "name": "priceRangeUndiscounted", "type": { @@ -79186,6 +75585,14 @@ export default { }, "args": [] }, + { + "name": "slug", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "translation", "type": { @@ -79333,6 +75740,14 @@ export default { }, "args": [] }, + { + "name": "slug", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] + }, { "name": "translatableContent", "type": { @@ -80517,13 +76932,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "countryCode", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -80588,13 +76996,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "countryCode", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -81268,6 +77669,15 @@ export default { "ofType": null }, "args": [] + }, + { + "name": "priorPrice", + "type": { + "kind": "OBJECT", + "name": "Money", + "ofType": null + }, + "args": [] } ], "interfaces": [ @@ -85333,6 +81743,13 @@ export default { "kind": "SCALAR", "name": "Any" } + }, + { + "name": "slugLanguageCode", + "type": { + "kind": "SCALAR", + "name": "Any" + } } ] }, @@ -85389,13 +81806,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "token", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -85524,6 +81934,13 @@ export default { "kind": "SCALAR", "name": "Any" } + }, + { + "name": "slugLanguageCode", + "type": { + "kind": "SCALAR", + "name": "Any" + } } ] }, @@ -86367,6 +82784,13 @@ export default { "kind": "SCALAR", "name": "Any" } + }, + { + "name": "slugLanguageCode", + "type": { + "kind": "SCALAR", + "name": "Any" + } } ] }, @@ -86738,6 +83162,13 @@ export default { "kind": "SCALAR", "name": "Any" } + }, + { + "name": "slugLanguageCode", + "type": { + "kind": "SCALAR", + "name": "Any" + } } ] }, @@ -87210,13 +83641,6 @@ export default { "name": "Any" } }, - { - "name": "query", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "sortBy", "type": { @@ -87831,13 +84255,6 @@ export default { "name": "Any" } }, - { - "name": "query", - "type": { - "kind": "SCALAR", - "name": "Any" - } - }, { "name": "sortBy", "type": { @@ -92223,13 +88640,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "currency", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -92344,13 +88754,6 @@ export default { "kind": "SCALAR", "name": "Any" } - }, - { - "name": "languageCode", - "type": { - "kind": "SCALAR", - "name": "Any" - } } ] }, @@ -94489,6 +90892,98 @@ export default { "kind": "OBJECT", "name": "Subscription", "fields": [ + { + "name": "checkoutCreated", + "type": { + "kind": "OBJECT", + "name": "CheckoutCreated", + "ofType": null + }, + "args": [ + { + "name": "channels", + "type": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + } + } + } + ] + }, + { + "name": "checkoutFullyPaid", + "type": { + "kind": "OBJECT", + "name": "CheckoutFullyPaid", + "ofType": null + }, + "args": [ + { + "name": "channels", + "type": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + } + } + } + ] + }, + { + "name": "checkoutMetadataUpdated", + "type": { + "kind": "OBJECT", + "name": "CheckoutMetadataUpdated", + "ofType": null + }, + "args": [ + { + "name": "channels", + "type": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + } + } + } + ] + }, + { + "name": "checkoutUpdated", + "type": { + "kind": "OBJECT", + "name": "CheckoutUpdated", + "ofType": null + }, + "args": [ + { + "name": "channels", + "type": { + "kind": "LIST", + "ofType": { + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } + } + } + } + ] + }, { "name": "draftOrderCreated", "type": { @@ -95583,6 +92078,14 @@ export default { "name": "Any" }, "args": [] + }, + { + "name": "useWeightedTaxForShipping", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] } ], "interfaces": [ @@ -95724,6 +92227,14 @@ export default { "name": "Any" }, "args": [] + }, + { + "name": "useWeightedTaxForShipping", + "type": { + "kind": "SCALAR", + "name": "Any" + }, + "args": [] } ], "interfaces": [] @@ -96676,8 +93187,11 @@ export default { { "name": "amount", "type": { - "kind": "SCALAR", - "name": "Any" + "kind": "NON_NULL", + "ofType": { + "kind": "SCALAR", + "name": "Any" + } }, "args": [] }, @@ -99840,6 +96354,15 @@ export default { }, "args": [] }, + { + "name": "discountPrior", + "type": { + "kind": "OBJECT", + "name": "TaxedMoney", + "ofType": null + }, + "args": [] + }, { "name": "onSale", "type": { @@ -99866,6 +96389,15 @@ export default { }, "args": [] }, + { + "name": "pricePrior", + "type": { + "kind": "OBJECT", + "name": "TaxedMoney", + "ofType": null + }, + "args": [] + }, { "name": "priceUndiscounted", "type": { @@ -103450,17 +99982,17 @@ export const UntypedOrderCreatedWebhookPayloadFragmentDoc = gql` } } `; -export const UntypedOrderCreatedSubscriptionDocument = gql` - subscription OrderCreatedSubscription { - event { - ...OrderCreatedWebhookPayload +export const UntypedOrderFilterShippingMethodsPayloadFragmentDoc = gql` + fragment OrderFilterShippingMethodsPayload on OrderFilterShippingMethods { + order { + id + } + shippingMethods { + id + name } } - ${UntypedOrderCreatedWebhookPayloadFragmentDoc}`; - -export function useOrderCreatedSubscriptionSubscription(options: Omit, 'query'> = {}, handler?: Urql.SubscriptionHandler) { - return Urql.useSubscription({ query: UntypedOrderCreatedSubscriptionDocument, ...options }, handler); -}; + `; export const UntypedLastOrderDocument = gql` query LastOrder { orders(first: 1) { @@ -103496,6 +100028,30 @@ export const UntypedLastOrderDocument = gql` export function useLastOrderQuery(options?: Omit, 'query'>) { return Urql.useQuery({ query: UntypedLastOrderDocument, ...options }); }; +export const UntypedOrderCreatedSubscriptionDocument = gql` + subscription OrderCreatedSubscription { + event { + ...OrderCreatedWebhookPayload + } +} + ${UntypedOrderCreatedWebhookPayloadFragmentDoc}`; + +export function useOrderCreatedSubscriptionSubscription(options: Omit, 'query'> = {}, handler?: Urql.SubscriptionHandler) { + return Urql.useSubscription({ query: UntypedOrderCreatedSubscriptionDocument, ...options }, handler); +}; +export const UntypedOrderFilterShippingMethodsSubscriptionDocument = gql` + subscription OrderFilterShippingMethodsSubscription { + event { + ...OrderFilterShippingMethodsPayload + } +} + ${UntypedOrderFilterShippingMethodsPayloadFragmentDoc}`; + +export function useOrderFilterShippingMethodsSubscriptionSubscription(options: Omit, 'query'> = {}, handler?: Urql.SubscriptionHandler) { + return Urql.useSubscription({ query: UntypedOrderFilterShippingMethodsSubscriptionDocument, ...options }, handler); +}; export const OrderCreatedWebhookPayloadFragmentDoc = {"kind":"Document","definitions":[{"kind":"FragmentDefinition","name":{"kind":"Name","value":"OrderCreatedWebhookPayload"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"OrderCreated"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"order"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"userEmail"}},{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"number"}},{"kind":"Field","name":{"kind":"Name","value":"user"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"email"}},{"kind":"Field","name":{"kind":"Name","value":"firstName"}},{"kind":"Field","name":{"kind":"Name","value":"lastName"}}]}}]}}]}}]} as unknown as DocumentNode; +export const OrderFilterShippingMethodsPayloadFragmentDoc = {"kind":"Document","definitions":[{"kind":"FragmentDefinition","name":{"kind":"Name","value":"OrderFilterShippingMethodsPayload"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"OrderFilterShippingMethods"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"order"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"shippingMethods"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}}]}}]}}]} as unknown as DocumentNode; +export const LastOrderDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"LastOrder"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"orders"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"first"},"value":{"kind":"IntValue","value":"1"}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"edges"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"node"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"number"}},{"kind":"Field","name":{"kind":"Name","value":"created"}},{"kind":"Field","name":{"kind":"Name","value":"user"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"firstName"}},{"kind":"Field","name":{"kind":"Name","value":"lastName"}}]}},{"kind":"Field","name":{"kind":"Name","value":"shippingAddress"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"country"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"country"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"total"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"gross"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"amount"}},{"kind":"Field","name":{"kind":"Name","value":"currency"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"lines"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]}}]}}]}}]} as unknown as DocumentNode; export const OrderCreatedSubscriptionDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"subscription","name":{"kind":"Name","value":"OrderCreatedSubscription"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"event"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"FragmentSpread","name":{"kind":"Name","value":"OrderCreatedWebhookPayload"}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"OrderCreatedWebhookPayload"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"OrderCreated"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"order"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"userEmail"}},{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"number"}},{"kind":"Field","name":{"kind":"Name","value":"user"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"email"}},{"kind":"Field","name":{"kind":"Name","value":"firstName"}},{"kind":"Field","name":{"kind":"Name","value":"lastName"}}]}}]}}]}}]} as unknown as DocumentNode; -export const LastOrderDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"LastOrder"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"orders"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"first"},"value":{"kind":"IntValue","value":"1"}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"edges"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"node"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"number"}},{"kind":"Field","name":{"kind":"Name","value":"created"}},{"kind":"Field","name":{"kind":"Name","value":"user"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"firstName"}},{"kind":"Field","name":{"kind":"Name","value":"lastName"}}]}},{"kind":"Field","name":{"kind":"Name","value":"shippingAddress"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"country"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"country"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"total"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"gross"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"amount"}},{"kind":"Field","name":{"kind":"Name","value":"currency"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"lines"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]}}]}}]}}]} as unknown as DocumentNode; \ No newline at end of file +export const OrderFilterShippingMethodsSubscriptionDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"subscription","name":{"kind":"Name","value":"OrderFilterShippingMethodsSubscription"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"event"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"FragmentSpread","name":{"kind":"Name","value":"OrderFilterShippingMethodsPayload"}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"OrderFilterShippingMethodsPayload"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"OrderFilterShippingMethods"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"order"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"shippingMethods"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}}]}}]}}]} as unknown as DocumentNode; \ No newline at end of file diff --git a/generated/schema.graphql b/generated/schema.graphql deleted file mode 100644 index 07da8c7e..00000000 --- a/generated/schema.graphql +++ /dev/null @@ -1,36894 +0,0 @@ -"""Groups fields and operations into named groups.""" -directive @doc( - """Name of the grouping category""" - category: String! -) on ENUM | FIELD | FIELD_DEFINITION | INPUT_OBJECT | OBJECT - -"""Webhook events triggered by a specific location.""" -directive @webhookEventsInfo( - """List of asynchronous webhook events triggered by a specific location.""" - asyncEvents: [WebhookEventTypeAsyncEnum!]! - - """List of synchronous webhook events triggered by a specific location.""" - syncEvents: [WebhookEventTypeSyncEnum!]! -) on FIELD | FIELD_DEFINITION | INPUT_OBJECT | OBJECT - -""" -Create a new address for the customer. - -Requires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER. - -Triggers the following webhook events: -- CUSTOMER_UPDATED (async): A customer account was updated. -- ADDRESS_CREATED (async): An address was created. -""" -type AccountAddressCreate { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - address: Address - errors: [AccountError!]! - - """A user instance for which the address was created.""" - user: User -} - -""" -Delete an address of the logged-in user. Requires one of the following permissions: MANAGE_USERS, IS_OWNER. - -Triggers the following webhook events: -- ADDRESS_DELETED (async): An address was deleted. -""" -type AccountAddressDelete { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - address: Address - errors: [AccountError!]! - - """A user instance for which the address was deleted.""" - user: User -} - -""" -Updates an address of the logged-in user. Requires one of the following permissions: MANAGE_USERS, IS_OWNER. - -Triggers the following webhook events: -- ADDRESS_UPDATED (async): An address was updated. -""" -type AccountAddressUpdate { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - address: Address - errors: [AccountError!]! - - """A user object for which the address was edited.""" - user: User -} - -""" -Event sent when account change email is requested. - -Added in Saleor 3.15. -""" -type AccountChangeEmailRequested implements Event { - """The channel data.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The new email address the user wants to change to.""" - newEmail: String - - """The application receiving the webhook.""" - recipient: App - - """The URL to redirect the user after he accepts the request.""" - redirectUrl: String - - """Shop data.""" - shop: Shop - - """The token required to confirm request.""" - token: String - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when account confirmation requested. This event is always sent. enableAccountConfirmationByEmail flag set to True is not required. - -Added in Saleor 3.15. -""" -type AccountConfirmationRequested implements Event { - """The channel data.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The URL to redirect the user after he accepts the request.""" - redirectUrl: String - - """Shop data.""" - shop: Shop - - """The token required to confirm request.""" - token: String - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when account is confirmed. - -Added in Saleor 3.15. -""" -type AccountConfirmed implements Event { - """The channel data.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The URL to redirect the user after he accepts the request.""" - redirectUrl: String - - """Shop data.""" - shop: Shop - - """The token required to confirm request.""" - token: String - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Remove user account. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- ACCOUNT_DELETED (async): Account was deleted. -""" -type AccountDelete { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - user: User -} - -""" -Event sent when account delete is requested. - -Added in Saleor 3.15. -""" -type AccountDeleteRequested implements Event { - """The channel data.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The URL to redirect the user after he accepts the request.""" - redirectUrl: String - - """Shop data.""" - shop: Shop - - """The token required to confirm request.""" - token: String - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when account is deleted. - -Added in Saleor 3.15. -""" -type AccountDeleted implements Event { - """The channel data.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The URL to redirect the user after he accepts the request.""" - redirectUrl: String - - """Shop data.""" - shop: Shop - - """The token required to confirm request.""" - token: String - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when account email is changed. - -Added in Saleor 3.15. -""" -type AccountEmailChanged implements Event { - """The channel data.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The new email address.""" - newEmail: String - - """The application receiving the webhook.""" - recipient: App - - """The URL to redirect the user after he accepts the request.""" - redirectUrl: String - - """Shop data.""" - shop: Shop - - """The token required to confirm request.""" - token: String - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents errors in account mutations.""" -type AccountError { - """A type of address that causes the error.""" - addressType: AddressTypeEnum - - """The error code.""" - code: AccountErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum AccountErrorCode { - ACCOUNT_NOT_CONFIRMED - ACTIVATE_OWN_ACCOUNT - ACTIVATE_SUPERUSER_ACCOUNT - CHANNEL_INACTIVE - DEACTIVATE_OWN_ACCOUNT - DEACTIVATE_SUPERUSER_ACCOUNT - DELETE_NON_STAFF_USER - DELETE_OWN_ACCOUNT - DELETE_STAFF_ACCOUNT - DELETE_SUPERUSER_ACCOUNT - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INACTIVE - INVALID - INVALID_CREDENTIALS - INVALID_PASSWORD - JWT_DECODE_ERROR - JWT_INVALID_CSRF_TOKEN - JWT_INVALID_TOKEN - JWT_MISSING_TOKEN - JWT_SIGNATURE_EXPIRED - LEFT_NOT_MANAGEABLE_PERMISSION - LOGIN_ATTEMPT_DELAYED - MISSING_CHANNEL_SLUG - NOT_FOUND - OUT_OF_SCOPE_GROUP - OUT_OF_SCOPE_PERMISSION - OUT_OF_SCOPE_USER - PASSWORD_ENTIRELY_NUMERIC - PASSWORD_RESET_ALREADY_REQUESTED - PASSWORD_TOO_COMMON - PASSWORD_TOO_SHORT - PASSWORD_TOO_SIMILAR - REQUIRED - UNIQUE - UNKNOWN_IP_ADDRESS -} - -"""Fields required to update the user.""" -input AccountInput { - """Billing address of the customer.""" - defaultBillingAddress: AddressInput - - """Shipping address of the customer.""" - defaultShippingAddress: AddressInput - - """Given name.""" - firstName: String - - """User language code.""" - languageCode: LanguageCodeEnum - - """Family name.""" - lastName: String - - """ - Fields required to update the user metadata. - - Added in Saleor 3.14. - """ - metadata: [MetadataInput!] -} - -""" -Register a new user. - -Triggers the following webhook events: -- CUSTOMER_CREATED (async): A new customer account was created. -- NOTIFY_USER (async): A notification for account confirmation. -- ACCOUNT_CONFIRMATION_REQUESTED (async): An user confirmation was requested. This event is always sent regardless of settings. -""" -type AccountRegister { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """Informs whether users need to confirm their email address.""" - requiresConfirmation: Boolean - user: User -} - -"""Fields required to create a user.""" -input AccountRegisterInput { - """ - Slug of a channel which will be used to notify users. Optional when only one channel exists. - """ - channel: String - - """The email address of the user.""" - email: String! - - """Given name.""" - firstName: String - - """User language code.""" - languageCode: LanguageCodeEnum - - """Family name.""" - lastName: String - - """User public metadata.""" - metadata: [MetadataInput!] - - """Password.""" - password: String! - - """ - Base of frontend URL that will be needed to create confirmation URL. Required when account confirmation is enabled. - """ - redirectUrl: String -} - -""" -Sends an email with the account removal link for the logged-in user. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- NOTIFY_USER (async): A notification for account delete request. -- ACCOUNT_DELETE_REQUESTED (async): An account delete requested. -""" -type AccountRequestDeletion { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! -} - -""" -Sets a default address for the authenticated user. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- CUSTOMER_UPDATED (async): A customer's address was updated. -""" -type AccountSetDefaultAddress { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """An updated user instance.""" - user: User -} - -""" -Event sent when setting a new password is requested. - -Added in Saleor 3.15. -""" -type AccountSetPasswordRequested implements Event { - """The channel data.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The URL to redirect the user after he accepts the request.""" - redirectUrl: String - - """Shop data.""" - shop: Shop - - """The token required to confirm request.""" - token: String - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Updates the account of the logged-in user. - -Requires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER. - -Triggers the following webhook events: -- CUSTOMER_UPDATED (async): A customer account was updated. -- CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. -""" -type AccountUpdate { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - user: User -} - -"""Represents user address data.""" -type Address implements Node & ObjectWithMetadata { - """The city of the address.""" - city: String! - - """The district of the address.""" - cityArea: String! - - """Company or organization name.""" - companyName: String! - - """The country of the address.""" - country: CountryDisplay! - - """The country area of the address.""" - countryArea: String! - - """The given name of the address.""" - firstName: String! - - """The ID of the address.""" - id: ID! - - """Address is user's default billing address.""" - isDefaultBillingAddress: Boolean - - """Address is user's default shipping address.""" - isDefaultShippingAddress: Boolean - - """The family name of the address.""" - lastName: String! - - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.10. - """ - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.10. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.10. - """ - metafields(keys: [String!]): Metadata - - """The phone number assigned the address.""" - phone: String - - """The postal code of the address.""" - postalCode: String! - - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.10. - """ - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.10. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.10. - """ - privateMetafields(keys: [String!]): Metadata - - """The first line of the address.""" - streetAddress1: String! - - """The second line of the address.""" - streetAddress2: String! -} - -""" -Creates user address. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- ADDRESS_CREATED (async): A new address was created. -""" -type AddressCreate { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - address: Address - errors: [AccountError!]! - - """A user instance for which the address was created.""" - user: User -} - -""" -Event sent when new address is created. - -Added in Saleor 3.5. -""" -type AddressCreated implements Event { - """The address the event relates to.""" - address: Address - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes an address. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- ADDRESS_DELETED (async): An address was deleted. -""" -type AddressDelete { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - address: Address - errors: [AccountError!]! - - """A user instance for which the address was deleted.""" - user: User -} - -""" -Event sent when address is deleted. - -Added in Saleor 3.5. -""" -type AddressDeleted implements Event { - """The address the event relates to.""" - address: Address - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input AddressInput { - """City.""" - city: String - - """District.""" - cityArea: String - - """Company or organization.""" - companyName: String - - """Country.""" - country: CountryCode - - """State or province.""" - countryArea: String - - """Given name.""" - firstName: String - - """Family name.""" - lastName: String - - """ - Address public metadata. - - Added in Saleor 3.15. - """ - metadata: [MetadataInput!] - - """ - Phone number. - - Phone numbers are validated with Google's [libphonenumber](https://github.com/google/libphonenumber) library. - """ - phone: String - - """Postal code.""" - postalCode: String - - """ - Determine if the address should be validated. By default, Saleor accepts only address inputs matching ruleset from [Google Address Data]{https://chromium-i18n.appspot.com/ssl-address), using [i18naddress](https://github.com/mirumee/google-i18n-address) library. Some mutations may require additional permissions to use the the field. More info about permissions can be found in relevant mutation. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - skipValidation: Boolean = false - - """Address.""" - streetAddress1: String - - """Address.""" - streetAddress2: String -} - -""" -Sets a default address for the given user. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- CUSTOMER_UPDATED (async): A customer was updated. -""" -type AddressSetDefault { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """An updated user instance.""" - user: User -} - -"""An enumeration.""" -enum AddressTypeEnum { - BILLING - SHIPPING -} - -""" -Updates an address. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- ADDRESS_UPDATED (async): An address was updated. -""" -type AddressUpdate { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - address: Address - errors: [AccountError!]! - - """A user object for which the address was edited.""" - user: User -} - -""" -Event sent when address is updated. - -Added in Saleor 3.5. -""" -type AddressUpdated implements Event { - """The address the event relates to.""" - address: Address - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents address validation rules for a country.""" -type AddressValidationData { - """ - The address format of the address validation rule. - - Many fields in the JSON refer to address fields by one-letter abbreviations. These are defined as follows: - - - `N`: Name - - `O`: Organization - - `A`: Street Address Line(s) - - `D`: Dependent locality (may be an inner-city district or a suburb) - - `C`: City or Locality - - `S`: Administrative area such as a state, province, island etc - - `Z`: Zip or postal code - - `X`: Sorting code - - [Click here for more information.](https://github.com/google/libaddressinput/wiki/AddressValidationMetadata) - """ - addressFormat: String! - - """ - The latin address format of the address validation rule. - - Many fields in the JSON refer to address fields by one-letter abbreviations. These are defined as follows: - - - `N`: Name - - `O`: Organization - - `A`: Street Address Line(s) - - `D`: Dependent locality (may be an inner-city district or a suburb) - - `C`: City or Locality - - `S`: Administrative area such as a state, province, island etc - - `Z`: Zip or postal code - - `X`: Sorting code - - [Click here for more information.](https://github.com/google/libaddressinput/wiki/AddressValidationMetadata) - """ - addressLatinFormat: String! - - """The allowed fields to use in address.""" - allowedFields: [String!]! - - """ - The available choices for the city area of the address validation rule. - """ - cityAreaChoices: [ChoiceValue!]! - - """The formal name of the city area of the address validation rule.""" - cityAreaType: String! - - """The available choices for the city of the address validation rule.""" - cityChoices: [ChoiceValue!]! - - """The formal name of the city of the address validation rule.""" - cityType: String! - - """ - The available choices for the country area of the address validation rule. - """ - countryAreaChoices: [ChoiceValue!]! - - """The formal name of the county area of the address validation rule.""" - countryAreaType: String! - - """The country code of the address validation rule.""" - countryCode: String! - - """The country name of the address validation rule.""" - countryName: String! - - """The example postal code of the address validation rule.""" - postalCodeExamples: [String!]! - - """The regular expression for postal code validation.""" - postalCodeMatchers: [String!]! - - """The postal code prefix of the address validation rule.""" - postalCodePrefix: String! - - """The formal name of the postal code of the address validation rule.""" - postalCodeType: String! - - """The required fields to create a valid address.""" - requiredFields: [String!]! - - """ - The list of fields that should be in upper case for address validation rule. - """ - upperFields: [String!]! -} - -"""Represents allocation.""" -type Allocation implements Node { - """The ID of allocation.""" - id: ID! - - """ - Quantity allocated for orders. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. - """ - quantity: Int! - - """ - The warehouse were items were allocated. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. - """ - warehouse: Warehouse! -} - -""" -Determine the allocation strategy for the channel. - - PRIORITIZE_SORTING_ORDER - allocate stocks according to the warehouses' order - within the channel - - PRIORITIZE_HIGH_STOCK - allocate stock in a warehouse with the most stock -""" -enum AllocationStrategyEnum { - PRIORITIZE_HIGH_STOCK - PRIORITIZE_SORTING_ORDER -} - -"""Represents app data.""" -type App implements Node & ObjectWithMetadata { - """Description of this app.""" - aboutApp: String - - """JWT token used to authenticate by third-party app.""" - accessToken: String - - """URL to iframe with the app.""" - appUrl: String - - """ - The App's author name. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - author: String - - """ - App's brand data. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - brand: AppBrand - - """URL to iframe with the configuration for the app.""" - configurationUrl: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `appUrl` instead.") - - """The date and time when the app was created.""" - created: DateTime - - """Description of the data privacy defined for this app.""" - dataPrivacy: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `dataPrivacyUrl` instead.") - - """URL to details about the privacy policy on the app owner page.""" - dataPrivacyUrl: String - - """ - App's dashboard extensions. - - Added in Saleor 3.1. - """ - extensions: [AppExtension!]! - - """Homepage of the app.""" - homepageUrl: String - - """The ID of the app.""" - id: ID! - - """ - Canonical app ID from the manifest - - Added in Saleor 3.19. - """ - identifier: String - - """Determine if app will be set active or not.""" - isActive: Boolean - - """ - URL to manifest used during app's installation. - - Added in Saleor 3.5. - """ - manifestUrl: String - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Name of the app.""" - name: String - - """List of the app's permissions.""" - permissions: [Permission!] - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Support page for the app.""" - supportUrl: String - - """ - Last 4 characters of the tokens. - - Requires one of the following permissions: MANAGE_APPS, OWNER. - """ - tokens: [AppToken!] - - """Type of the app.""" - type: AppTypeEnum - - """Version number of the app.""" - version: String - - """ - List of webhooks assigned to this app. - - Requires one of the following permissions: MANAGE_APPS, OWNER. - """ - webhooks: [Webhook!] -} - -""" -Activate the app. - -Requires one of the following permissions: MANAGE_APPS. - -Triggers the following webhook events: -- APP_STATUS_CHANGED (async): An app was activated. -""" -type AppActivate { - app: App - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AppError!]! -} - -""" -Represents the app's brand data. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type AppBrand { - """ - App's logos details. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - logo: AppBrandLogo! -} - -""" -Represents the app's brand logo data. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type AppBrandLogo { - """ - URL to the default logo image. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - default( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - format: IconThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): String! -} - -type AppCountableConnection { - edges: [AppCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type AppCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: App! -} - -""" -Creates a new app. Requires the following permissions: AUTHENTICATED_STAFF_USER and MANAGE_APPS. - -Triggers the following webhook events: -- APP_INSTALLED (async): An app was installed. -""" -type AppCreate { - app: App - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """The newly created authentication token.""" - authToken: String - errors: [AppError!]! -} - -""" -Deactivate the app. - -Requires one of the following permissions: MANAGE_APPS. - -Triggers the following webhook events: -- APP_STATUS_CHANGED (async): An app was deactivated. -""" -type AppDeactivate { - app: App - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AppError!]! -} - -""" -Deletes an app. - -Requires one of the following permissions: MANAGE_APPS. - -Triggers the following webhook events: -- APP_DELETED (async): An app was deleted. -""" -type AppDelete { - app: App - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AppError!]! -} - -""" -Delete failed installation. - -Requires one of the following permissions: MANAGE_APPS. -""" -type AppDeleteFailedInstallation { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - appInstallation: AppInstallation - errors: [AppError!]! -} - -""" -Event sent when app is deleted. - -Added in Saleor 3.4. -""" -type AppDeleted implements Event { - """The application the event relates to.""" - app: App - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type AppError { - """The error code.""" - code: AppErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of permissions which causes the error.""" - permissions: [PermissionEnum!] -} - -"""An enumeration.""" -enum AppErrorCode { - FORBIDDEN - GRAPHQL_ERROR - INVALID - INVALID_CUSTOM_HEADERS - INVALID_MANIFEST_FORMAT - INVALID_PERMISSION - INVALID_STATUS - INVALID_URL_FORMAT - MANIFEST_URL_CANT_CONNECT - NOT_FOUND - OUT_OF_SCOPE_APP - OUT_OF_SCOPE_PERMISSION - REQUIRED - UNIQUE - UNSUPPORTED_SALEOR_VERSION -} - -"""Represents app data.""" -type AppExtension implements Node { - """JWT token used to authenticate by third-party app extension.""" - accessToken: String - - """The app assigned to app extension.""" - app: App! - - """The ID of the app extension.""" - id: ID! - - """Label of the extension to show in the dashboard.""" - label: String! - - """Place where given extension will be mounted.""" - mount: AppExtensionMountEnum! - - """List of the app extension's permissions.""" - permissions: [Permission!]! - - """Type of way how app extension will be opened.""" - target: AppExtensionTargetEnum! - - """URL of a view where extension's iframe is placed.""" - url: String! -} - -type AppExtensionCountableConnection { - edges: [AppExtensionCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type AppExtensionCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: AppExtension! -} - -input AppExtensionFilterInput { - mount: [AppExtensionMountEnum!] - target: AppExtensionTargetEnum -} - -"""All places where app extension can be mounted.""" -enum AppExtensionMountEnum { - CUSTOMER_DETAILS_MORE_ACTIONS - CUSTOMER_OVERVIEW_CREATE - CUSTOMER_OVERVIEW_MORE_ACTIONS - NAVIGATION_CATALOG - NAVIGATION_CUSTOMERS - NAVIGATION_DISCOUNTS - NAVIGATION_ORDERS - NAVIGATION_PAGES - NAVIGATION_TRANSLATIONS - ORDER_DETAILS_MORE_ACTIONS - ORDER_OVERVIEW_CREATE - ORDER_OVERVIEW_MORE_ACTIONS - PRODUCT_DETAILS_MORE_ACTIONS - PRODUCT_OVERVIEW_CREATE - PRODUCT_OVERVIEW_MORE_ACTIONS -} - -""" -All available ways of opening an app extension. - - POPUP - app's extension will be mounted as a popup window - APP_PAGE - redirect to app's page -""" -enum AppExtensionTargetEnum { - APP_PAGE - POPUP -} - -""" -Fetch and validate manifest. - -Requires one of the following permissions: MANAGE_APPS. -""" -type AppFetchManifest { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AppError!]! - - """The validated manifest.""" - manifest: Manifest -} - -input AppFilterInput { - isActive: Boolean - search: String - type: AppTypeEnum -} - -input AppInput { - """ - Canonical app ID. If not provided, the identifier will be generated based on app.id. - - Added in Saleor 3.19. - """ - identifier: String - - """Name of the app.""" - name: String - - """List of permission code names to assign to this app.""" - permissions: [PermissionEnum!] -} - -""" -Install new app by using app manifest. Requires the following permissions: AUTHENTICATED_STAFF_USER and MANAGE_APPS. -""" -type AppInstall { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - appInstallation: AppInstallation - errors: [AppError!]! -} - -input AppInstallInput { - """Determine if app will be set active or not.""" - activateAfterInstallation: Boolean = true - - """Name of the app to install.""" - appName: String - - """URL to app's manifest in JSON format.""" - manifestUrl: String - - """List of permission code names to assign to this app.""" - permissions: [PermissionEnum!] -} - -"""Represents ongoing installation of app.""" -type AppInstallation implements Job & Node { - """The name of the app installation.""" - appName: String! - - """ - App's brand data. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - brand: AppBrand - - """Created date time of job in ISO 8601 format.""" - createdAt: DateTime! - - """The ID of the app installation.""" - id: ID! - - """The URL address of manifest for the app installation.""" - manifestUrl: String! - - """Job message.""" - message: String - - """Job status.""" - status: JobStatusEnum! - - """Date time of job last update in ISO 8601 format.""" - updatedAt: DateTime! -} - -""" -Event sent when new app is installed. - -Added in Saleor 3.4. -""" -type AppInstalled implements Event { - """The application the event relates to.""" - app: App - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Represents the app's manifest brand data. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type AppManifestBrand { - """ - App's logos details. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - logo: AppManifestBrandLogo! -} - -""" -Represents the app's manifest brand data. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type AppManifestBrandLogo { - """ - Data URL with a base64 encoded logo image. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - default( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - format: IconThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): String! -} - -type AppManifestExtension { - """Label of the extension to show in the dashboard.""" - label: String! - - """Place where given extension will be mounted.""" - mount: AppExtensionMountEnum! - - """List of the app extension's permissions.""" - permissions: [Permission!]! - - """Type of way how app extension will be opened.""" - target: AppExtensionTargetEnum! - - """URL of a view where extension's iframe is placed.""" - url: String! -} - -type AppManifestRequiredSaleorVersion { - """ - Required Saleor version as semver range. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - constraint: String! - - """ - Informs if the Saleor version matches the required one. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - satisfied: Boolean! -} - -type AppManifestWebhook { - """The asynchronous events that webhook wants to subscribe.""" - asyncEvents: [WebhookEventTypeAsyncEnum!] - - """The name of the webhook.""" - name: String! - - """Subscription query of a webhook""" - query: String! - - """The synchronous events that webhook wants to subscribe.""" - syncEvents: [WebhookEventTypeSyncEnum!] - - """The url to receive the payload.""" - targetUrl: String! -} - -""" -Retry failed installation of new app. - -Requires one of the following permissions: MANAGE_APPS. - -Triggers the following webhook events: -- APP_INSTALLED (async): An app was installed. -""" -type AppRetryInstall { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - appInstallation: AppInstallation - errors: [AppError!]! -} - -enum AppSortField { - """Sort apps by creation date.""" - CREATION_DATE - - """Sort apps by name.""" - NAME -} - -input AppSortingInput { - """Specifies the direction in which to sort apps.""" - direction: OrderDirection! - - """Sort apps by the selected field.""" - field: AppSortField! -} - -""" -Event sent when app status has changed. - -Added in Saleor 3.4. -""" -type AppStatusChanged implements Event { - """The application the event relates to.""" - app: App - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents token data.""" -type AppToken implements Node { - """Last 4 characters of the token.""" - authToken: String - - """The ID of the app token.""" - id: ID! - - """Name of the authenticated token.""" - name: String -} - -""" -Creates a new token. - -Requires one of the following permissions: MANAGE_APPS. -""" -type AppTokenCreate { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - appToken: AppToken - - """The newly created authentication token.""" - authToken: String - errors: [AppError!]! -} - -""" -Deletes an authentication token assigned to app. - -Requires one of the following permissions: MANAGE_APPS. -""" -type AppTokenDelete { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - appToken: AppToken - errors: [AppError!]! -} - -input AppTokenInput { - """ID of app.""" - app: ID! - - """Name of the token.""" - name: String -} - -"""Verify provided app token.""" -type AppTokenVerify { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AppError!]! - - """Determine if token is valid or not.""" - valid: Boolean! -} - -"""Enum determining type of your App.""" -enum AppTypeEnum { - """ - Local Saleor App. The app is fully manageable from dashboard. You can change assigned permissions, add webhooks, or authentication token - """ - LOCAL - - """ - Third party external App. Installation is fully automated. Saleor uses a defined App manifest to gather all required information. - """ - THIRDPARTY -} - -""" -Updates an existing app. - -Requires one of the following permissions: MANAGE_APPS. - -Triggers the following webhook events: -- APP_UPDATED (async): An app was updated. -""" -type AppUpdate { - app: App - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AppError!]! -} - -""" -Event sent when app is updated. - -Added in Saleor 3.4. -""" -type AppUpdated implements Event { - """The application the event relates to.""" - app: App - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""An enumeration.""" -enum AreaUnitsEnum { - SQ_CM - SQ_DM - SQ_FT - SQ_INCH - SQ_KM - SQ_M - SQ_MM - SQ_YD -} - -""" -Assigns storefront's navigation menus. - -Requires one of the following permissions: MANAGE_MENUS, MANAGE_SETTINGS. -""" -type AssignNavigation { - errors: [MenuError!]! - - """Assigned navigation menu.""" - menu: Menu - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Represents assigned attribute to variant with variant selection attached. - -Added in Saleor 3.1. -""" -type AssignedVariantAttribute { - """Attribute assigned to variant.""" - attribute: Attribute! - - """ - Determines, whether assigned attribute is allowed for variant selection. Supported variant types for variant selection are: ['dropdown', 'boolean', 'swatch', 'numeric'] - """ - variantSelection: Boolean! -} - -""" -Custom attribute of a product. Attributes can be assigned to products and variants at the product type level. -""" -type Attribute implements Node & ObjectWithMetadata { - """ - Whether the attribute can be displayed in the admin product list. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - availableInGrid: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """List of attribute's values.""" - choices( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for attribute choices.""" - filter: AttributeValueFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort attribute choices.""" - sortBy: AttributeChoicesSortingInput - ): AttributeValueCountableConnection - - """The entity type which can be used as a reference.""" - entityType: AttributeEntityTypeEnum - - """ - External ID of this attribute. - - Added in Saleor 3.10. - """ - externalReference: String - - """ - Whether the attribute can be filtered in dashboard. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - filterableInDashboard: Boolean! - - """ - Whether the attribute can be filtered in storefront. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - filterableInStorefront: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """The ID of the attribute.""" - id: ID! - - """The input type to use for entering attribute values in the dashboard.""" - inputType: AttributeInputTypeEnum - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Name of an attribute displayed in the interface.""" - name: String - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - A list of product types that use this attribute as a product attribute. - """ - productTypes( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ProductTypeCountableConnection! - - """ - A list of product types that use this attribute as a product variant attribute. - """ - productVariantTypes( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ProductTypeCountableConnection! - - """Internal representation of an attribute name.""" - slug: String - - """ - The position of the attribute in the storefront navigation (0 by default). Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - storefrontSearchPosition: Int! @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """Returns translated attribute fields for the given language code.""" - translation( - """A language code to return the translation for attribute.""" - languageCode: LanguageCodeEnum! - ): AttributeTranslation - - """The attribute type.""" - type: AttributeTypeEnum - - """The unit of attribute values.""" - unit: MeasurementUnitsEnum - - """ - Whether the attribute requires values to be passed or not. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - valueRequired: Boolean! - - """ - Whether the attribute should be visible or not in storefront. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - visibleInStorefront: Boolean! - - """Flag indicating that attribute has predefined choices.""" - withChoices: Boolean! -} - -""" -Creates attributes. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Triggers the following webhook events: -- ATTRIBUTE_CREATED (async): An attribute was created. -""" -type AttributeBulkCreate { - """Returns how many objects were created.""" - count: Int! - errors: [AttributeBulkCreateError!]! - - """List of the created attributes.""" - results: [AttributeBulkCreateResult!]! -} - -type AttributeBulkCreateError { - """The error code.""" - code: AttributeBulkCreateErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String -} - -"""An enumeration.""" -enum AttributeBulkCreateErrorCode { - ALREADY_EXISTS - BLANK - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - MAX_LENGTH - NOT_FOUND - REQUIRED - UNIQUE -} - -type AttributeBulkCreateResult { - """Attribute data.""" - attribute: Attribute - - """List of errors occurred on create attempt.""" - errors: [AttributeBulkCreateError!] -} - -""" -Deletes attributes. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - -Triggers the following webhook events: -- ATTRIBUTE_DELETED (async): An attribute was deleted. -""" -type AttributeBulkDelete { - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Returns how many objects were affected.""" - count: Int! - errors: [AttributeError!]! -} - -""" -Creates/updates translations for attributes. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type AttributeBulkTranslate { - """Returns how many translations were created/updated.""" - count: Int! - errors: [AttributeBulkTranslateError!]! - - """List of the translations.""" - results: [AttributeBulkTranslateResult!]! -} - -type AttributeBulkTranslateError { - """The error code.""" - code: AttributeTranslateErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String -} - -input AttributeBulkTranslateInput { - """External reference of an attribute.""" - externalReference: String - - """Attribute ID.""" - id: ID - - """Translation language code.""" - languageCode: LanguageCodeEnum! - - """Translation fields.""" - translationFields: NameTranslationInput! -} - -type AttributeBulkTranslateResult { - """List of errors occurred on translation attempt.""" - errors: [AttributeBulkTranslateError!] - - """Attribute translation data.""" - translation: AttributeTranslation -} - -""" -Updates attributes. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Triggers the following webhook events: -- ATTRIBUTE_UPDATED (async): An attribute was updated. Optionally called when new attribute value was created or deleted. -- ATTRIBUTE_VALUE_CREATED (async): Called optionally when an attribute value was created. -- ATTRIBUTE_VALUE_DELETED (async): Called optionally when an attribute value was deleted. -""" -type AttributeBulkUpdate { - """Returns how many objects were updated.""" - count: Int! - errors: [AttributeBulkUpdateError!]! - - """List of the updated attributes.""" - results: [AttributeBulkUpdateResult!]! -} - -type AttributeBulkUpdateError { - """The error code.""" - code: AttributeBulkUpdateErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String -} - -"""An enumeration.""" -enum AttributeBulkUpdateErrorCode { - ALREADY_EXISTS - BLANK - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - MAX_LENGTH - NOT_FOUND - REQUIRED - UNIQUE -} - -input AttributeBulkUpdateInput { - """External ID of this attribute.""" - externalReference: String - - """Fields to update.""" - fields: AttributeUpdateInput! - - """ID of an attribute to update.""" - id: ID -} - -type AttributeBulkUpdateResult { - """Attribute data.""" - attribute: Attribute - - """List of errors occurred on update attempt.""" - errors: [AttributeBulkUpdateError!] -} - -enum AttributeChoicesSortField { - """Sort attribute choice by name.""" - NAME - - """Sort attribute choice by slug.""" - SLUG -} - -input AttributeChoicesSortingInput { - """Specifies the direction in which to sort attribute choices.""" - direction: OrderDirection! - - """Sort attribute choices by the selected field.""" - field: AttributeChoicesSortField! -} - -type AttributeCountableConnection { - edges: [AttributeCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type AttributeCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Attribute! -} - -""" -Creates an attribute. - -Triggers the following webhook events: -- ATTRIBUTE_CREATED (async): An attribute was created. -""" -type AttributeCreate { - attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AttributeError!]! -} - -""" -Represents an input for create of attribute. - -NOTE: Deprecated fields `filterableInStorefront`, `storefrontSearchPosition` and `availableInGrid` are not supported in bulk mutations: `attributeBulkCreate`, `attributeBulkUpdate`. -""" -input AttributeCreateInput { - """ - Whether the attribute can be displayed in the admin product list. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - availableInGrid: Boolean - - """The entity type which can be used as a reference.""" - entityType: AttributeEntityTypeEnum - - """ - External ID of this attribute. - - Added in Saleor 3.10. - """ - externalReference: String - - """Whether the attribute can be filtered in dashboard.""" - filterableInDashboard: Boolean - - """ - Whether the attribute can be filtered in storefront. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - filterableInStorefront: Boolean - - """The input type to use for entering attribute values in the dashboard.""" - inputType: AttributeInputTypeEnum - - """Whether the attribute is for variants only.""" - isVariantOnly: Boolean - - """Name of an attribute displayed in the interface.""" - name: String! - - """Internal representation of an attribute name.""" - slug: String - - """ - The position of the attribute in the storefront navigation (0 by default). - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - storefrontSearchPosition: Int - - """The attribute type.""" - type: AttributeTypeEnum! - - """The unit of attribute values.""" - unit: MeasurementUnitsEnum - - """Whether the attribute requires values to be passed or not.""" - valueRequired: Boolean - - """List of attribute's values.""" - values: [AttributeValueCreateInput!] - - """Whether the attribute should be visible or not in storefront.""" - visibleInStorefront: Boolean -} - -""" -Event sent when new attribute is created. - -Added in Saleor 3.5. -""" -type AttributeCreated implements Event { - """The attribute the event relates to.""" - attribute: Attribute - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes an attribute. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - -Triggers the following webhook events: -- ATTRIBUTE_DELETED (async): An attribute was deleted. -""" -type AttributeDelete { - attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AttributeError!]! -} - -""" -Event sent when attribute is deleted. - -Added in Saleor 3.5. -""" -type AttributeDeleted implements Event { - """The attribute the event relates to.""" - attribute: Attribute - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""An enumeration.""" -enum AttributeEntityTypeEnum { - PAGE - PRODUCT - PRODUCT_VARIANT -} - -input AttributeEntityTypeEnumFilterInput { - """The value equal to.""" - eq: AttributeEntityTypeEnum - - """The value included in.""" - oneOf: [AttributeEntityTypeEnum!] -} - -type AttributeError { - """The error code.""" - code: AttributeErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum AttributeErrorCode { - ALREADY_EXISTS - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE -} - -input AttributeFilterInput { - availableInGrid: Boolean - - """ - Specifies the channel by which the data should be filtered. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String - filterableInDashboard: Boolean - filterableInStorefront: Boolean - ids: [ID!] - inCategory: ID - inCollection: ID - isVariantOnly: Boolean - metadata: [MetadataFilter!] - search: String - slugs: [String!] - type: AttributeTypeEnum - valueRequired: Boolean - visibleInStorefront: Boolean -} - -input AttributeInput { - """The boolean value of the attribute.""" - boolean: Boolean - - """ - The date range that the returned values should be in. In case of date/time attributes, the UTC midnight of the given date is used. - """ - date: DateRangeInput - - """The date/time range that the returned values should be in.""" - dateTime: DateTimeRangeInput - - """Internal representation of an attribute name.""" - slug: String! - - """Internal representation of a value (unique per attribute).""" - values: [String!] - - """The range that the returned values should be in.""" - valuesRange: IntRangeInput -} - -"""An enumeration.""" -enum AttributeInputTypeEnum { - BOOLEAN - DATE - DATE_TIME - DROPDOWN - FILE - MULTISELECT - NUMERIC - PLAIN_TEXT - REFERENCE - RICH_TEXT - SWATCH -} - -input AttributeInputTypeEnumFilterInput { - """The value equal to.""" - eq: AttributeInputTypeEnum - - """The value included in.""" - oneOf: [AttributeInputTypeEnum!] -} - -""" -Reorder the values of an attribute. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - -Triggers the following webhook events: -- ATTRIBUTE_VALUE_UPDATED (async): An attribute value was updated. -- ATTRIBUTE_UPDATED (async): An attribute was updated. -""" -type AttributeReorderValues { - """Attribute from which values are reordered.""" - attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AttributeError!]! -} - -enum AttributeSortField { - """ - Sort attributes based on whether they can be displayed or not in a product grid. - """ - AVAILABLE_IN_GRID - - """Sort attributes by the filterable in dashboard flag""" - FILTERABLE_IN_DASHBOARD - - """Sort attributes by the filterable in storefront flag""" - FILTERABLE_IN_STOREFRONT - - """Sort attributes by the variant only flag""" - IS_VARIANT_ONLY - - """Sort attributes by name""" - NAME - - """Sort attributes by slug""" - SLUG - - """Sort attributes by their position in storefront""" - STOREFRONT_SEARCH_POSITION - - """Sort attributes by the value required flag""" - VALUE_REQUIRED - - """Sort attributes by visibility in the storefront""" - VISIBLE_IN_STOREFRONT -} - -input AttributeSortingInput { - """Specifies the direction in which to sort attributes.""" - direction: OrderDirection! - - """Sort attributes by the selected field.""" - field: AttributeSortField! -} - -""" -Represents attribute's original translatable fields and related translations. -""" -type AttributeTranslatableContent implements Node { - """Custom attribute of a product.""" - attribute: Attribute @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the attribute to translate. - - Added in Saleor 3.14. - """ - attributeId: ID! - - """The ID of the attribute translatable content.""" - id: ID! - - """Name of the attribute to translate.""" - name: String! - - """Returns translated attribute fields for the given language code.""" - translation( - """A language code to return the translation for attribute.""" - languageCode: LanguageCodeEnum! - ): AttributeTranslation -} - -""" -Creates/updates translations for an attribute. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type AttributeTranslate { - attribute: Attribute - errors: [TranslationError!]! - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""An enumeration.""" -enum AttributeTranslateErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED -} - -"""Represents attribute translations.""" -type AttributeTranslation implements Node { - """The ID of the attribute translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated attribute name.""" - name: String! - - """ - Represents the attribute fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: AttributeTranslatableContent -} - -"""An enumeration.""" -enum AttributeTypeEnum { - PAGE_TYPE - PRODUCT_TYPE -} - -input AttributeTypeEnumFilterInput { - """The value equal to.""" - eq: AttributeTypeEnum - - """The value included in.""" - oneOf: [AttributeTypeEnum!] -} - -""" -Updates attribute. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - -Triggers the following webhook events: -- ATTRIBUTE_UPDATED (async): An attribute was updated. -""" -type AttributeUpdate { - attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AttributeError!]! -} - -""" -Represents an input for update of attribute. - -NOTE: Deprecated fields `filterableInStorefront`, `storefrontSearchPosition` and `availableInGrid` are not supported in bulk mutations: `attributeBulkCreate`, `attributeBulkUpdate`. -""" -input AttributeUpdateInput { - """New values to be created for this attribute.""" - addValues: [AttributeValueUpdateInput!] - - """ - Whether the attribute can be displayed in the admin product list. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - availableInGrid: Boolean - - """ - External ID of this product. - - Added in Saleor 3.10. - """ - externalReference: String - - """Whether the attribute can be filtered in dashboard.""" - filterableInDashboard: Boolean - - """ - Whether the attribute can be filtered in storefront. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - filterableInStorefront: Boolean - - """Whether the attribute is for variants only.""" - isVariantOnly: Boolean - - """Name of an attribute displayed in the interface.""" - name: String - - """IDs of values to be removed from this attribute.""" - removeValues: [ID!] - - """Internal representation of an attribute name.""" - slug: String - - """ - The position of the attribute in the storefront navigation (0 by default). - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - storefrontSearchPosition: Int - - """The unit of attribute values.""" - unit: MeasurementUnitsEnum - - """Whether the attribute requires values to be passed or not.""" - valueRequired: Boolean - - """Whether the attribute should be visible or not in storefront.""" - visibleInStorefront: Boolean -} - -""" -Event sent when attribute is updated. - -Added in Saleor 3.5. -""" -type AttributeUpdated implements Event { - """The attribute the event relates to.""" - attribute: Attribute - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents a value of an attribute.""" -type AttributeValue implements Node { - """Represents the boolean value of the attribute value.""" - boolean: Boolean - - """Represents the date value of the attribute value.""" - date: Date - - """Represents the date/time value of the attribute value.""" - dateTime: DateTime - - """ - External ID of this attribute value. - - Added in Saleor 3.10. - """ - externalReference: String - - """Represents file URL and content type (if attribute value is a file).""" - file: File - - """The ID of the attribute value.""" - id: ID! - - """The input type to use for entering attribute values in the dashboard.""" - inputType: AttributeInputTypeEnum - - """Name of a value displayed in the interface.""" - name: String - - """ - Represents the text of the attribute value, plain text without formatting. - """ - plainText: String - - """The ID of the attribute reference.""" - reference: ID - - """ - Represents the text of the attribute value, includes formatting. - - Rich text format. For reference see https://editorjs.io/ - """ - richText: JSONString - - """Internal representation of a value (unique per attribute).""" - slug: String - - """Returns translated attribute value fields for the given language code.""" - translation( - """A language code to return the translation for attribute value.""" - languageCode: LanguageCodeEnum! - ): AttributeValueTranslation - - """ - Represent value of the attribute value (e.g. color values for swatch attributes). - """ - value: String -} - -""" -Deletes values of attributes. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - -Triggers the following webhook events: -- ATTRIBUTE_VALUE_DELETED (async): An attribute value was deleted. -- ATTRIBUTE_UPDATED (async): An attribute was updated. -""" -type AttributeValueBulkDelete { - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Returns how many objects were affected.""" - count: Int! - errors: [AttributeError!]! -} - -""" -Creates/updates translations for attributes values. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type AttributeValueBulkTranslate { - """Returns how many translations were created/updated.""" - count: Int! - errors: [AttributeValueBulkTranslateError!]! - - """List of the translations.""" - results: [AttributeValueBulkTranslateResult!]! -} - -type AttributeValueBulkTranslateError { - """The error code.""" - code: AttributeValueTranslateErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String -} - -input AttributeValueBulkTranslateInput { - """External reference of an attribute value.""" - externalReference: String - - """Attribute value ID.""" - id: ID - - """Translation language code.""" - languageCode: LanguageCodeEnum! - - """Translation fields.""" - translationFields: AttributeValueTranslationInput! -} - -type AttributeValueBulkTranslateResult { - """List of errors occurred on translation attempt.""" - errors: [AttributeValueBulkTranslateError!] - - """Attribute value translation data.""" - translation: AttributeValueTranslation -} - -type AttributeValueCountableConnection { - edges: [AttributeValueCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type AttributeValueCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: AttributeValue! -} - -""" -Creates a value for an attribute. - -Requires one of the following permissions: MANAGE_PRODUCTS. - -Triggers the following webhook events: -- ATTRIBUTE_VALUE_CREATED (async): An attribute value was created. -- ATTRIBUTE_UPDATED (async): An attribute was updated. -""" -type AttributeValueCreate { - """The updated attribute.""" - attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - attributeValue: AttributeValue - errors: [AttributeError!]! -} - -input AttributeValueCreateInput { - """File content type.""" - contentType: String - - """ - External ID of this attribute value. - - Added in Saleor 3.10. - """ - externalReference: String - - """URL of the file attribute. Every time, a new value is created.""" - fileUrl: String - - """Name of a value displayed in the interface.""" - name: String! - - """ - Represents the text of the attribute value, plain text without formatting. - - DEPRECATED: this field will be removed in Saleor 4.0.The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. - """ - plainText: String - - """ - Represents the text of the attribute value, includes formatting. - - Rich text format. For reference see https://editorjs.io/ - - DEPRECATED: this field will be removed in Saleor 4.0.The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. - """ - richText: JSONString - - """ - Represent value of the attribute value (e.g. color values for swatch attributes). - """ - value: String -} - -""" -Event sent when new attribute value is created. - -Added in Saleor 3.5. -""" -type AttributeValueCreated implements Event { - """The attribute value the event relates to.""" - attributeValue: AttributeValue - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a value of an attribute. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - -Triggers the following webhook events: -- ATTRIBUTE_VALUE_DELETED (async): An attribute value was deleted. -- ATTRIBUTE_UPDATED (async): An attribute was updated. -""" -type AttributeValueDelete { - """The updated attribute.""" - attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - attributeValue: AttributeValue - errors: [AttributeError!]! -} - -""" -Event sent when attribute value is deleted. - -Added in Saleor 3.5. -""" -type AttributeValueDeleted implements Event { - """The attribute value the event relates to.""" - attributeValue: AttributeValue - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input AttributeValueFilterInput { - ids: [ID!] - search: String - slugs: [String!] -} - -input AttributeValueInput { - """Represents the boolean value of the attribute value.""" - boolean: Boolean - - """File content type.""" - contentType: String - - """Represents the date value of the attribute value.""" - date: Date - - """Represents the date/time value of the attribute value.""" - dateTime: DateTime - - """ - Attribute value ID or external reference. - - Added in Saleor 3.9. - """ - dropdown: AttributeValueSelectableTypeInput - - """ - External ID of this attribute. - - Added in Saleor 3.14. - """ - externalReference: String - - """URL of the file attribute. Every time, a new value is created.""" - file: String - - """ID of the selected attribute.""" - id: ID - - """ - List of attribute value IDs or external references. - - Added in Saleor 3.9. - """ - multiselect: [AttributeValueSelectableTypeInput!] - - """ - Numeric value of an attribute. - - Added in Saleor 3.9. - """ - numeric: String - - """Plain text content.""" - plainText: String - - """List of entity IDs that will be used as references.""" - references: [ID!] - - """Text content in JSON format.""" - richText: JSONString - - """ - Attribute value ID or external reference. - - Added in Saleor 3.9. - """ - swatch: AttributeValueSelectableTypeInput - - """ - The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. This field will be removed in Saleor 4.0. - """ - values: [String!] -} - -""" -Represents attribute value. -1. If ID is provided, then attribute value will be resolved by ID. -2. If externalReference is provided, then attribute value will be resolved by external reference. -3. If value is provided, then attribute value will be resolved by value. If this attribute value doesn't exist, then it will be created. -4. If externalReference and value is provided then new attribute value will be created. - -Added in Saleor 3.9. -""" -input AttributeValueSelectableTypeInput { - """ - External reference of an attribute value. - - Added in Saleor 3.14. - """ - externalReference: String - - """ID of an attribute value.""" - id: ID - - """ - The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. - """ - value: String -} - -""" -Represents attribute value's original translatable fields and related translations. -""" -type AttributeValueTranslatableContent implements Node { - """ - Associated attribute that can be translated. - - Added in Saleor 3.9. - """ - attribute: AttributeTranslatableContent - - """Represents a value of an attribute.""" - attributeValue: AttributeValue @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the attribute value to translate. - - Added in Saleor 3.14. - """ - attributeValueId: ID! - - """The ID of the attribute value translatable content.""" - id: ID! - - """Name of the attribute value to translate.""" - name: String! - - """Attribute plain text value.""" - plainText: String - - """ - Attribute value. - - Rich text format. For reference see https://editorjs.io/ - """ - richText: JSONString - - """Returns translated attribute value fields for the given language code.""" - translation( - """A language code to return the translation for attribute value.""" - languageCode: LanguageCodeEnum! - ): AttributeValueTranslation -} - -""" -Creates/updates translations for an attribute value. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type AttributeValueTranslate { - attributeValue: AttributeValue - errors: [TranslationError!]! - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""An enumeration.""" -enum AttributeValueTranslateErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED -} - -"""Represents attribute value translations.""" -type AttributeValueTranslation implements Node { - """The ID of the attribute value translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated attribute value name.""" - name: String! - - """Translated plain text attribute value .""" - plainText: String - - """ - Translated rich-text attribute value. - - Rich text format. For reference see https://editorjs.io/ - """ - richText: JSONString - - """ - Represents the attribute value fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: AttributeValueTranslatableContent -} - -input AttributeValueTranslationInput { - name: String - - """Translated text.""" - plainText: String - - """ - Translated text. - - Rich text format. For reference see https://editorjs.io/ - """ - richText: JSONString -} - -""" -Updates value of an attribute. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - -Triggers the following webhook events: -- ATTRIBUTE_VALUE_UPDATED (async): An attribute value was updated. -- ATTRIBUTE_UPDATED (async): An attribute was updated. -""" -type AttributeValueUpdate { - """The updated attribute.""" - attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - attributeValue: AttributeValue - errors: [AttributeError!]! -} - -input AttributeValueUpdateInput { - """File content type.""" - contentType: String - - """ - External ID of this attribute value. - - Added in Saleor 3.10. - """ - externalReference: String - - """URL of the file attribute. Every time, a new value is created.""" - fileUrl: String - - """Name of a value displayed in the interface.""" - name: String - - """ - Represents the text of the attribute value, plain text without formatting. - - DEPRECATED: this field will be removed in Saleor 4.0.The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. - """ - plainText: String - - """ - Represents the text of the attribute value, includes formatting. - - Rich text format. For reference see https://editorjs.io/ - - DEPRECATED: this field will be removed in Saleor 4.0.The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. - """ - richText: JSONString - - """ - Represent value of the attribute value (e.g. color values for swatch attributes). - """ - value: String -} - -""" -Event sent when attribute value is updated. - -Added in Saleor 3.5. -""" -type AttributeValueUpdated implements Event { - """The attribute value the event relates to.""" - attributeValue: AttributeValue - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Where filtering options. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -input AttributeWhereInput { - """List of conditions that must be met.""" - AND: [AttributeWhereInput!] - - """A list of conditions of which at least one must be met.""" - OR: [AttributeWhereInput!] - entityType: AttributeEntityTypeEnumFilterInput - filterableInDashboard: Boolean - ids: [ID!] - inCategory: ID - inCollection: ID - inputType: AttributeInputTypeEnumFilterInput - metadata: [MetadataFilter!] - name: StringFilterInput - slug: StringFilterInput - type: AttributeTypeEnumFilterInput - unit: MeasurementUnitsEnumFilterInput - valueRequired: Boolean - visibleInStorefront: Boolean - withChoices: Boolean -} - -input BulkAttributeValueInput { - """ - The boolean value of an attribute to resolve. If the passed value is non-existent, it will be created. - """ - boolean: Boolean - - """ - File content type. - - Added in Saleor 3.12. - """ - contentType: String - - """ - Represents the date value of the attribute value. - - Added in Saleor 3.12. - """ - date: Date - - """ - Represents the date/time value of the attribute value. - - Added in Saleor 3.12. - """ - dateTime: DateTime - - """ - Attribute value ID. - - Added in Saleor 3.12. - """ - dropdown: AttributeValueSelectableTypeInput - - """ - External ID of this attribute. - - Added in Saleor 3.14. - """ - externalReference: String - - """ - URL of the file attribute. Every time, a new value is created. - - Added in Saleor 3.12. - """ - file: String - - """ID of the selected attribute.""" - id: ID - - """ - List of attribute value IDs. - - Added in Saleor 3.12. - """ - multiselect: [AttributeValueSelectableTypeInput!] - - """ - Numeric value of an attribute. - - Added in Saleor 3.12. - """ - numeric: String - - """ - Plain text content. - - Added in Saleor 3.12. - """ - plainText: String - - """ - List of entity IDs that will be used as references. - - Added in Saleor 3.12. - """ - references: [ID!] - - """ - Text content in JSON format. - - Added in Saleor 3.12. - """ - richText: JSONString - - """ - Attribute value ID. - - Added in Saleor 3.12. - """ - swatch: AttributeValueSelectableTypeInput - - """ - The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created.This field will be removed in Saleor 4.0. - """ - values: [String!] -} - -type BulkProductError { - """List of attributes IDs which causes the error.""" - attributes: [ID!] - - """List of channel IDs which causes the error.""" - channels: [ID!] - - """The error code.""" - code: ProductErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """Index of an input list item that caused the error.""" - index: Int - - """The error message.""" - message: String - - """List of attribute values IDs which causes the error.""" - values: [ID!] - - """List of warehouse IDs which causes the error.""" - warehouses: [ID!] -} - -type BulkStockError { - """List of attributes IDs which causes the error.""" - attributes: [ID!] - - """The error code.""" - code: ProductErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """Index of an input list item that caused the error.""" - index: Int - - """The error message.""" - message: String - - """List of attribute values IDs which causes the error.""" - values: [ID!] -} - -""" -Synchronous webhook for calculating checkout/order taxes. - -Added in Saleor 3.7. -""" -type CalculateTaxes implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - taxBase: TaxableObject! - - """Saleor version that triggered the event.""" - version: String -} - -input CardInput { - """ - Payment method nonce, a token returned by the appropriate provider's SDK. - """ - code: String! - - """Card security code.""" - cvc: String - - """Information about currency and amount.""" - money: MoneyInput! -} - -input CatalogueInput { - """Categories related to the discount.""" - categories: [ID!] - - """Collections related to the discount.""" - collections: [ID!] - - """Products related to the discount.""" - products: [ID!] - - """ - Product variant related to the discount. - - Added in Saleor 3.1. - """ - variants: [ID!] -} - -input CataloguePredicateInput { - """List of conditions that must be met.""" - AND: [CataloguePredicateInput!] - - """A list of conditions of which at least one must be met.""" - OR: [CataloguePredicateInput!] - - """Defines the category conditions to be met.""" - categoryPredicate: CategoryWhereInput - - """Defines the collection conditions to be met.""" - collectionPredicate: CollectionWhereInput - - """Defines the product conditions to be met.""" - productPredicate: ProductWhereInput - - """Defines the product variant conditions to be met.""" - variantPredicate: ProductVariantWhereInput -} - -""" -Represents a single category of products. Categories allow to organize products in a tree-hierarchies which can be used for navigation in the storefront. -""" -type Category implements Node & ObjectWithMetadata { - """List of ancestors of the category.""" - ancestors( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): CategoryCountableConnection - - """Background image of the category.""" - backgroundImage( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. - """ - format: ThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): Image - - """List of children of the category.""" - children( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): CategoryCountableConnection - - """ - Description of the category. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Description of the category. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """The ID of the category.""" - id: ID! - - """Level of the category.""" - level: Int! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Name of category""" - name: String! - - """Parent category.""" - parent: Category - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - List of products in the category. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - products( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """ - Filtering options for products. - - Added in Saleor 3.10. - """ - filter: ProductFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """ - Sort products. - - Added in Saleor 3.10. - """ - sortBy: ProductOrder - - """ - Filtering options for products. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - where: ProductWhereInput - ): ProductCountableConnection - - """SEO description of category.""" - seoDescription: String - - """SEO title of category.""" - seoTitle: String - - """Slug of the category.""" - slug: String! - - """Returns translated category fields for the given language code.""" - translation( - """A language code to return the translation for category.""" - languageCode: LanguageCodeEnum! - ): CategoryTranslation - - """ - The date and time when the category was last updated. - - Added in Saleor 3.17. - """ - updatedAt: DateTime! -} - -""" -Deletes categories. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CategoryBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type CategoryCountableConnection { - edges: [CategoryCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type CategoryCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Category! -} - -""" -Creates a new category. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CategoryCreate { - category: Category - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when new category is created. - -Added in Saleor 3.2. -""" -type CategoryCreated implements Event { - """The category the event relates to.""" - category: Category - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a category. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CategoryDelete { - category: Category - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when category is deleted. - -Added in Saleor 3.2. -""" -type CategoryDeleted implements Event { - """The category the event relates to.""" - category: Category - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input CategoryFilterInput { - ids: [ID!] - metadata: [MetadataFilter!] - search: String - slugs: [String!] - - """ - Filter by when was the most recent update. - - Added in Saleor 3.17. - """ - updatedAt: DateTimeRangeInput -} - -input CategoryInput { - """Background image file.""" - backgroundImage: Upload - - """Alt text for a product media.""" - backgroundImageAlt: String - - """ - Category description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Fields required to update the category metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Category name.""" - name: String - - """ - Fields required to update the category private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """Search engine optimization fields.""" - seo: SeoInput - - """Category slug.""" - slug: String -} - -enum CategorySortField { - """Sort categories by name.""" - NAME - - """Sort categories by product count.""" - PRODUCT_COUNT - - """Sort categories by subcategory count.""" - SUBCATEGORY_COUNT -} - -input CategorySortingInput { - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String - - """Specifies the direction in which to sort categories.""" - direction: OrderDirection! - - """Sort categories by the selected field.""" - field: CategorySortField! -} - -""" -Represents category original translatable fields and related translations. -""" -type CategoryTranslatableContent implements Node { - """Represents a single category of products.""" - category: Category @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the category to translate. - - Added in Saleor 3.14. - """ - categoryId: ID! - - """ - Category description to translate. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Description of the category. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """The ID of the category translatable content.""" - id: ID! - - """Name of the category translatable content.""" - name: String! - - """SEO description to translate.""" - seoDescription: String - - """SEO title to translate.""" - seoTitle: String - - """Returns translated category fields for the given language code.""" - translation( - """A language code to return the translation for category.""" - languageCode: LanguageCodeEnum! - ): CategoryTranslation -} - -""" -Creates/updates translations for a category. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type CategoryTranslate { - category: Category - errors: [TranslationError!]! - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""Represents category translations.""" -type CategoryTranslation implements Node { - """ - Translated description of the category. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Translated description of the category. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """The ID of the category translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated category name.""" - name: String - - """Translated SEO description.""" - seoDescription: String - - """Translated SEO title.""" - seoTitle: String - - """ - Represents the category fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: CategoryTranslatableContent -} - -""" -Updates a category. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CategoryUpdate { - category: Category - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when category is updated. - -Added in Saleor 3.2. -""" -type CategoryUpdated implements Event { - """The category the event relates to.""" - category: Category - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input CategoryWhereInput { - """List of conditions that must be met.""" - AND: [CategoryWhereInput!] - - """A list of conditions of which at least one must be met.""" - OR: [CategoryWhereInput!] - ids: [ID!] - metadata: [MetadataFilter!] -} - -"""Represents channel.""" -type Channel implements Node & ObjectWithMetadata { - """ - Shipping methods that are available for the channel. - - Added in Saleor 3.6. - """ - availableShippingMethodsPerCountry(countries: [CountryCode!]): [ShippingMethodsPerCountry!] - - """ - Channel-specific checkout settings. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_CHANNELS, MANAGE_CHECKOUTS. - """ - checkoutSettings: CheckoutSettings! - - """ - List of shippable countries for the channel. - - Added in Saleor 3.6. - """ - countries: [CountryDisplay!] - - """ - A currency that is assigned to the channel. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - currencyCode: String! - - """ - Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. - - Added in Saleor 3.1. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - defaultCountry: CountryDisplay! - - """ - Whether a channel has associated orders. - - Requires one of the following permissions: MANAGE_CHANNELS. - """ - hasOrders: Boolean! - - """The ID of the channel.""" - id: ID! - - """ - Whether the channel is active. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - isActive: Boolean! - - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.15. - """ - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.15. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.15. - """ - metafields(keys: [String!]): Metadata - - """ - Name of the channel. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - name: String! - - """ - Channel-specific order settings. - - Added in Saleor 3.12. - - Requires one of the following permissions: MANAGE_CHANNELS, MANAGE_ORDERS. - """ - orderSettings: OrderSettings! - - """ - Channel-specific payment settings. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_CHANNELS, HANDLE_PAYMENTS. - """ - paymentSettings: PaymentSettings! - - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.15. - """ - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.15. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.15. - """ - privateMetafields(keys: [String!]): Metadata - - """Slug of the channel.""" - slug: String! - - """ - Define the stock setting for this channel. - - Added in Saleor 3.7. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - stockSettings: StockSettings! - - """ - Channel specific tax configuration. - - Added in Saleor 3.20. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxConfiguration: TaxConfiguration! - - """ - List of warehouses assigned to this channel. - - Added in Saleor 3.5. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - warehouses: [Warehouse!]! -} - -""" -Activate a channel. - -Requires one of the following permissions: MANAGE_CHANNELS. - -Triggers the following webhook events: -- CHANNEL_STATUS_CHANGED (async): A channel was activated. -""" -type ChannelActivate { - """Activated channel.""" - channel: Channel - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [ChannelError!]! -} - -""" -Creates new channel. - -Requires one of the following permissions: MANAGE_CHANNELS. - -Triggers the following webhook events: -- CHANNEL_CREATED (async): A channel was created. -""" -type ChannelCreate { - channel: Channel - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [ChannelError!]! -} - -input ChannelCreateInput { - """List of shipping zones to assign to the channel.""" - addShippingZones: [ID!] - - """ - List of warehouses to assign to the channel. - - Added in Saleor 3.5. - """ - addWarehouses: [ID!] - - """ - The channel checkout settings - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - checkoutSettings: CheckoutSettingsInput - - """Currency of the channel.""" - currencyCode: String! - - """ - Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. - - Added in Saleor 3.1. - """ - defaultCountry: CountryCode! - - """Determine if channel will be set active or not.""" - isActive: Boolean - - """ - Channel public metadata. - - Added in Saleor 3.15. - """ - metadata: [MetadataInput!] - - """Name of the channel.""" - name: String! - - """ - The channel order settings - - Added in Saleor 3.12. - """ - orderSettings: OrderSettingsInput - - """ - The channel payment settings - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - paymentSettings: PaymentSettingsInput - - """ - Channel private metadata. - - Added in Saleor 3.15. - """ - privateMetadata: [MetadataInput!] - - """Slug of the channel.""" - slug: String! - - """ - The channel stock settings. - - Added in Saleor 3.7. - """ - stockSettings: StockSettingsInput -} - -""" -Event sent when new channel is created. - -Added in Saleor 3.2. -""" -type ChannelCreated implements Event { - """The channel the event relates to.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deactivate a channel. - -Requires one of the following permissions: MANAGE_CHANNELS. - -Triggers the following webhook events: -- CHANNEL_STATUS_CHANGED (async): A channel was deactivated. -""" -type ChannelDeactivate { - """Deactivated channel.""" - channel: Channel - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [ChannelError!]! -} - -""" -Delete a channel. Orders associated with the deleted channel will be moved to the target channel. Checkouts, product availability, and pricing will be removed. - -Requires one of the following permissions: MANAGE_CHANNELS. - -Triggers the following webhook events: -- CHANNEL_DELETED (async): A channel was deleted. -""" -type ChannelDelete { - channel: Channel - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [ChannelError!]! -} - -input ChannelDeleteInput { - """ID of channel to migrate orders from origin channel.""" - channelId: ID! -} - -""" -Event sent when channel is deleted. - -Added in Saleor 3.2. -""" -type ChannelDeleted implements Event { - """The channel the event relates to.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type ChannelError { - """The error code.""" - code: ChannelErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of shipping zone IDs which causes the error.""" - shippingZones: [ID!] - - """List of warehouses IDs which causes the error.""" - warehouses: [ID!] -} - -"""An enumeration.""" -enum ChannelErrorCode { - ALREADY_EXISTS - CHANNELS_CURRENCY_MUST_BE_THE_SAME - CHANNEL_WITH_ORDERS - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE -} - -input ChannelListingUpdateInput { - """ID of a channel listing.""" - channelListing: ID! - - """Cost price of the variant in channel.""" - costPrice: PositiveDecimal - - """The threshold for preorder variant in channel.""" - preorderThreshold: Int - - """Price of the particular variant in channel.""" - price: PositiveDecimal -} - -""" -Event sent when channel metadata is updated. - -Added in Saleor 3.15. -""" -type ChannelMetadataUpdated implements Event { - """The channel the event relates to.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Reorder the warehouses of a channel. - -Added in Saleor 3.7. - -Requires one of the following permissions: MANAGE_CHANNELS. -""" -type ChannelReorderWarehouses { - """Channel within the warehouses are reordered.""" - channel: Channel - errors: [ChannelError!]! -} - -""" -Event sent when channel status has changed. - -Added in Saleor 3.2. -""" -type ChannelStatusChanged implements Event { - """The channel the event relates to.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Update a channel. - -Requires one of the following permissions: MANAGE_CHANNELS. -Requires one of the following permissions when updating only `orderSettings` field: `MANAGE_CHANNELS`, `MANAGE_ORDERS`. -Requires one of the following permissions when updating only `checkoutSettings` field: `MANAGE_CHANNELS`, `MANAGE_CHECKOUTS`. -Requires one of the following permissions when updating only `paymentSettings` field: `MANAGE_CHANNELS`, `HANDLE_PAYMENTS`. - -Triggers the following webhook events: -- CHANNEL_UPDATED (async): A channel was updated. -- CHANNEL_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. -""" -type ChannelUpdate { - channel: Channel - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [ChannelError!]! -} - -input ChannelUpdateInput { - """List of shipping zones to assign to the channel.""" - addShippingZones: [ID!] - - """ - List of warehouses to assign to the channel. - - Added in Saleor 3.5. - """ - addWarehouses: [ID!] - - """ - The channel checkout settings - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - checkoutSettings: CheckoutSettingsInput - - """ - Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. - - Added in Saleor 3.1. - """ - defaultCountry: CountryCode - - """Determine if channel will be set active or not.""" - isActive: Boolean - - """ - Channel public metadata. - - Added in Saleor 3.15. - """ - metadata: [MetadataInput!] - - """Name of the channel.""" - name: String - - """ - The channel order settings - - Added in Saleor 3.12. - """ - orderSettings: OrderSettingsInput - - """ - The channel payment settings - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - paymentSettings: PaymentSettingsInput - - """ - Channel private metadata. - - Added in Saleor 3.15. - """ - privateMetadata: [MetadataInput!] - - """List of shipping zones to unassign from the channel.""" - removeShippingZones: [ID!] - - """ - List of warehouses to unassign from the channel. - - Added in Saleor 3.5. - """ - removeWarehouses: [ID!] - - """Slug of the channel.""" - slug: String - - """ - The channel stock settings. - - Added in Saleor 3.7. - """ - stockSettings: StockSettingsInput -} - -""" -Event sent when channel is updated. - -Added in Saleor 3.2. -""" -type ChannelUpdated implements Event { - """The channel the event relates to.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Checkout object.""" -type Checkout implements Node & ObjectWithMetadata { - """ - The authorize status of the checkout. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Triggers the following webhook events: - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - """ - authorizeStatus: CheckoutAuthorizeStatusEnum! - - """ - Collection points that can be used for this order. - - Added in Saleor 3.1. - """ - availableCollectionPoints: [Warehouse!]! - - """ - List of available payment gateways. - - Triggers the following webhook events: - - PAYMENT_LIST_GATEWAYS (sync): Fetch payment gateways available for checkout. - """ - availablePaymentGateways: [PaymentGateway!]! - - """ - Shipping methods that can be used with this checkout. - - Triggers the following webhook events: - - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. - """ - availableShippingMethods: [ShippingMethod!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `shippingMethods` instead.") - - """The billing address of the checkout.""" - billingAddress: Address - - """The channel for which checkout was created.""" - channel: Channel! - - """ - The charge status of the checkout. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Triggers the following webhook events: - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - """ - chargeStatus: CheckoutChargeStatusEnum! - - """The date and time when the checkout was created.""" - created: DateTime! - - """ - The delivery method selected for this checkout. - - Added in Saleor 3.1. - - Triggers the following webhook events: - - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. - """ - deliveryMethod: DeliveryMethod - - """ - The total discount applied to the checkout. Note: Only discount created via voucher are included in this field. - """ - discount: Money - - """The name of voucher assigned to the checkout.""" - discountName: String - - """ - Determines whether displayed prices should include taxes. - - Added in Saleor 3.9. - """ - displayGrossPrices: Boolean! - - """Email of a customer.""" - email: String - - """List of gift cards associated with this checkout.""" - giftCards: [GiftCard!]! - - """The ID of the checkout.""" - id: ID! - - """Returns True, if checkout requires shipping.""" - isShippingRequired: Boolean! - - """Checkout language code.""" - languageCode: LanguageCodeEnum! - lastChange: DateTime! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `updatedAt` instead.") - - """ - A list of checkout lines, each containing information about an item in the checkout. - """ - lines: [CheckoutLine!]! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """The note for the checkout.""" - note: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - List of problems with the checkout. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - problems: [CheckoutProblem!] - - """The number of items purchased.""" - quantity: Int! - - """The shipping address of the checkout.""" - shippingAddress: Address - - """ - The shipping method related with checkout. - - Triggers the following webhook events: - - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. - """ - shippingMethod: ShippingMethod @deprecated(reason: "This field will be removed in Saleor 4.0. Use `deliveryMethod` instead.") - - """ - Shipping methods that can be used with this checkout. - - Triggers the following webhook events: - - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. - """ - shippingMethods: [ShippingMethod!]! - - """ - The price of the shipping, with all the taxes included. Set to 0 when no delivery method is selected. - - Triggers the following webhook events: - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - """ - shippingPrice: TaxedMoney! - - """ - Date when oldest stock reservation for this checkout expires or null if no stock is reserved. - - Added in Saleor 3.1. - """ - stockReservationExpires: DateTime - - """ - List of user's stored payment methods that can be used in this checkout session. It uses the channel that the checkout was created in. When `amount` is not provided, `checkout.total` will be used as a default value. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - storedPaymentMethods( - """Amount that will be used to fetch stored payment methods.""" - amount: PositiveDecimal - ): [StoredPaymentMethod!] - - """ - The price of the checkout before shipping, with taxes included. - - Triggers the following webhook events: - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - """ - subtotalPrice: TaxedMoney! - - """ - Returns True if checkout has to be exempt from taxes. - - Added in Saleor 3.8. - """ - taxExemption: Boolean! - - """The checkout's token.""" - token: UUID! - - """ - The difference between the paid and the checkout total amount. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Triggers the following webhook events: - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - """ - totalBalance: Money! - - """ - The sum of the checkout line prices, with all the taxes,shipping costs, and discounts included. - - Triggers the following webhook events: - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - """ - totalPrice: TaxedMoney! - - """ - List of transactions for the checkout. Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS. - - Added in Saleor 3.4. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - transactions: [TransactionItem!] - - """ - Translation of the discountName field in the language set in Checkout.languageCode field.Note: this field is set automatically when Checkout.languageCode is defined; otherwise it's null - """ - translatedDiscountName: String - - """ - Time of last modification of the given checkout. - - Added in Saleor 3.13. - """ - updatedAt: DateTime! - - """ - The user assigned to the checkout. Requires one of the following permissions: MANAGE_USERS, HANDLE_PAYMENTS, OWNER. - """ - user: User - - """ - The voucher assigned to the checkout. - - Added in Saleor 3.18. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - voucher: Voucher - - """The code of voucher assigned to the checkout.""" - voucherCode: String -} - -""" -Adds a gift card or a voucher to a checkout. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutAddPromoCode { - """The checkout with the added gift card or voucher.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -input CheckoutAddressValidationRules { - """ - Determines if an error should be raised when the provided address doesn't match the expected format. Example: using letters for postal code when the numbers are expected. - """ - checkFieldsFormat: Boolean = true - - """ - Determines if an error should be raised when the provided address doesn't have all the required fields. The list of required fields is dynamic and depends on the country code (use the `addressValidationRules` query to fetch them). Note: country code is mandatory for all addresses regardless of the rules provided in this input. - """ - checkRequiredFields: Boolean = true - - """ - Determines if Saleor should apply normalization on address fields. Example: converting city field to uppercase letters. - """ - enableFieldsNormalization: Boolean = true -} - -""" -Determine a current authorize status for checkout. - - We treat the checkout as fully authorized when the sum of authorized and charged - funds cover the checkout.total. - We treat the checkout as partially authorized when the sum of authorized and charged - funds covers only part of the checkout.total - We treat the checkout as not authorized when the sum of authorized and charged funds - is 0. - - NONE - the funds are not authorized - PARTIAL - the cover funds don't cover fully the checkout's total - FULL - the cover funds covers the checkout's total -""" -enum CheckoutAuthorizeStatusEnum { - FULL - NONE - PARTIAL -} - -""" -Update billing address in the existing checkout. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutBillingAddressUpdate { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -""" -Determine the current charge status for the checkout. - - The checkout is considered overcharged when the sum of the transactionItem's charge - amounts exceeds the value of `checkout.total`. - If the sum of the transactionItem's charge amounts equals - `checkout.total`, we consider the checkout to be fully charged. - If the sum of the transactionItem's charge amounts covers a part of the - `checkout.total`, we treat the checkout as partially charged. - - - NONE - the funds are not charged. - PARTIAL - the funds that are charged don't cover the checkout's total - FULL - the funds that are charged fully cover the checkout's total - OVERCHARGED - the charged funds are bigger than checkout's total -""" -enum CheckoutChargeStatusEnum { - FULL - NONE - OVERCHARGED - PARTIAL -} - -""" -Completes the checkout. As a result a new order is created. The mutation allows to create the unpaid order when setting `orderSettings.allowUnpaidOrders` for given `Channel` is set to `true`. When `orderSettings.allowUnpaidOrders` is set to `false`, checkout can be completed only when attached `Payment`/`TransactionItem`s fully cover the checkout's total. When processing the checkout with `Payment`, in case of required additional confirmation step like 3D secure, the `confirmationNeeded` flag will be set to True and no order will be created until payment is confirmed with second call of this mutation. - -Triggers the following webhook events: -- SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. -- CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. -- CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. -- ORDER_CREATED (async): Triggered when order is created. -- NOTIFY_USER (async): A notification for order placement. -- NOTIFY_USER (async): A staff notification for order placement. -- ORDER_UPDATED (async): Triggered when order received the update after placement. -- ORDER_PAID (async): Triggered when newly created order is paid. -- ORDER_FULLY_PAID (async): Triggered when newly created order is fully paid. -- ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. -""" -type CheckoutComplete { - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Confirmation data used to process additional authorization steps.""" - confirmationData: JSONString - - """ - Set to true if payment needs to be confirmed before checkout is complete. - """ - confirmationNeeded: Boolean! - errors: [CheckoutError!]! - - """Placed order.""" - order: Order -} - -type CheckoutCountableConnection { - edges: [CheckoutCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type CheckoutCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Checkout! -} - -""" -Create a new checkout. - -`skipValidation` field requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. - -Triggers the following webhook events: -- CHECKOUT_CREATED (async): A checkout was created. -""" -type CheckoutCreate { - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """ - Whether the checkout was created or the current active one was returned. Refer to checkoutLinesAdd and checkoutLinesUpdate to merge a cart with an active checkout. - """ - created: Boolean @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `true`.") - errors: [CheckoutError!]! -} - -""" -Create new checkout from existing order. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type CheckoutCreateFromOrder { - """Created checkout.""" - checkout: Checkout - errors: [CheckoutCreateFromOrderError!]! - - """Variants that were not attached to the checkout.""" - unavailableVariants: [CheckoutCreateFromOrderUnavailableVariant!] -} - -type CheckoutCreateFromOrderError { - """The error code.""" - code: CheckoutCreateFromOrderErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum CheckoutCreateFromOrderErrorCode { - CHANNEL_INACTIVE - GRAPHQL_ERROR - INVALID - ORDER_NOT_FOUND - TAX_ERROR -} - -type CheckoutCreateFromOrderUnavailableVariant { - """The error code.""" - code: CheckoutCreateFromOrderUnavailableVariantErrorCode! - - """Order line ID that is unavailable.""" - lineId: ID! - - """The error message.""" - message: String! - - """Variant ID that is unavailable.""" - variantId: ID! -} - -"""An enumeration.""" -enum CheckoutCreateFromOrderUnavailableVariantErrorCode { - INSUFFICIENT_STOCK - NOT_FOUND - PRODUCT_NOT_PUBLISHED - PRODUCT_UNAVAILABLE_FOR_PURCHASE - QUANTITY_GREATER_THAN_LIMIT - UNAVAILABLE_VARIANT_IN_CHANNEL -} - -input CheckoutCreateInput { - """ - Billing address of the customer. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. - """ - billingAddress: AddressInput - - """Slug of a channel in which to create a checkout.""" - channel: String - - """The customer's email address.""" - email: String - - """Checkout language code.""" - languageCode: LanguageCodeEnum - - """ - A list of checkout lines, each containing information about an item in the checkout. - """ - lines: [CheckoutLineInput!]! - - """ - The mailing address to where the checkout will be shipped. Note: the address will be ignored if the checkout doesn't contain shippable items. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. - """ - shippingAddress: AddressInput - - """ - The checkout validation rules that can be changed. - - Added in Saleor 3.5. - """ - validationRules: CheckoutValidationRules -} - -""" -Event sent when new checkout is created. - -Added in Saleor 3.2. -""" -type CheckoutCreated implements Event { - """The checkout the event relates to.""" - checkout: Checkout - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Sets the customer as the owner of the checkout. - -Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_USER. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutCustomerAttach { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -""" -Removes the user assigned as the owner of the checkout. - -Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_USER. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutCustomerDetach { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -""" -Updates the delivery method (shipping method or pick up point) of the checkout. Updates the checkout shipping_address for click and collect delivery for a warehouse address. - -Added in Saleor 3.1. - -Triggers the following webhook events: -- SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout delivery method with the external one. -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutDeliveryMethodUpdate { - """An updated checkout.""" - checkout: Checkout - errors: [CheckoutError!]! -} - -""" -Updates email address in the existing checkout object. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutEmailUpdate { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -type CheckoutError { - """A type of address that causes the error.""" - addressType: AddressTypeEnum - - """The error code.""" - code: CheckoutErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """List of line Ids which cause the error.""" - lines: [ID!] - - """The error message.""" - message: String - - """List of variant IDs which causes the error.""" - variants: [ID!] -} - -"""An enumeration.""" -enum CheckoutErrorCode { - BILLING_ADDRESS_NOT_SET - CHANNEL_INACTIVE - CHECKOUT_NOT_FULLY_PAID - DELIVERY_METHOD_NOT_APPLICABLE - EMAIL_NOT_SET - GIFT_CARD_NOT_APPLICABLE - GRAPHQL_ERROR - INACTIVE_PAYMENT - INSUFFICIENT_STOCK - INVALID - INVALID_SHIPPING_METHOD - MISSING_CHANNEL_SLUG - NON_EDITABLE_GIFT_LINE - NON_REMOVABLE_GIFT_LINE - NOT_FOUND - NO_LINES - PAYMENT_ERROR - PRODUCT_NOT_PUBLISHED - PRODUCT_UNAVAILABLE_FOR_PURCHASE - QUANTITY_GREATER_THAN_LIMIT - REQUIRED - SHIPPING_ADDRESS_NOT_SET - SHIPPING_CHANGE_FORBIDDEN - SHIPPING_METHOD_NOT_APPLICABLE - SHIPPING_METHOD_NOT_SET - SHIPPING_NOT_REQUIRED - TAX_ERROR - UNAVAILABLE_VARIANT_IN_CHANNEL - UNIQUE - VOUCHER_NOT_APPLICABLE - ZERO_QUANTITY -} - -input CheckoutFilterInput { - authorizeStatus: [CheckoutAuthorizeStatusEnum!] - channels: [ID!] - chargeStatus: [CheckoutChargeStatusEnum!] - created: DateRangeInput - customer: String - metadata: [MetadataFilter!] - search: String - updatedAt: DateRangeInput -} - -""" -Filter shipping methods for checkout. - -Added in Saleor 3.6. -""" -type CheckoutFilterShippingMethods implements Event { - """The checkout the event relates to.""" - checkout: Checkout - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """ - Shipping methods that can be used with this checkout. - - Added in Saleor 3.6. - """ - shippingMethods: [ShippingMethod!] - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when checkout is fully paid with transactions. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type CheckoutFullyPaid implements Event { - """The checkout the event relates to.""" - checkout: Checkout - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Update language code in the existing checkout. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutLanguageCodeUpdate { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -"""Represents an item in the checkout.""" -type CheckoutLine implements Node & ObjectWithMetadata { - """The ID of the checkout line.""" - id: ID! - - """ - Determine if the line is a gift. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - isGift: Boolean - - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.5. - """ - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.5. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.5. - """ - metafields(keys: [String!]): Metadata - - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.5. - """ - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.5. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.5. - """ - privateMetafields(keys: [String!]): Metadata - - """ - List of problems with the checkout line. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - problems: [CheckoutLineProblem!] - - """The quantity of product variant assigned to the checkout line.""" - quantity: Int! - - """Indicates whether the item need to be delivered.""" - requiresShipping: Boolean! - - """ - The sum of the checkout line price, taxes and discounts. - - Triggers the following webhook events: - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - """ - totalPrice: TaxedMoney! - - """The sum of the checkout line price, without discounts.""" - undiscountedTotalPrice: Money! - - """The unit price of the checkout line, without discounts.""" - undiscountedUnitPrice: Money! - - """ - The unit price of the checkout line, with taxes and discounts. - - Triggers the following webhook events: - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - """ - unitPrice: TaxedMoney! - - """The product variant from which the checkout line was created.""" - variant: ProductVariant! -} - -type CheckoutLineCountableConnection { - edges: [CheckoutLineCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type CheckoutLineCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: CheckoutLine! -} - -""" -Deletes a CheckoutLine. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutLineDelete { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -input CheckoutLineInput { - """ - Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. - - Added in Saleor 3.6. - """ - forceNewLine: Boolean = false - - """ - Fields required to update the object's metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """ - Custom price of the item. Can be set only by apps with `HANDLE_CHECKOUTS` permission. When the line with the same variant will be provided multiple times, the last price will be used. - - Added in Saleor 3.1. - """ - price: PositiveDecimal - - """The number of items purchased.""" - quantity: Int! - - """ID of the product variant.""" - variantId: ID! -} - -""" -Represents an problem in the checkout line. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -union CheckoutLineProblem = CheckoutLineProblemInsufficientStock | CheckoutLineProblemVariantNotAvailable - -""" -Indicates insufficient stock for a given checkout line.Placing the order will not be possible until solving this problem. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type CheckoutLineProblemInsufficientStock { - """Available quantity of a variant.""" - availableQuantity: Int - - """The line that has variant with insufficient stock.""" - line: CheckoutLine! - - """The variant with insufficient stock.""" - variant: ProductVariant! -} - -""" -The variant assigned to the checkout line is not available.Placing the order will not be possible until solving this problem. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type CheckoutLineProblemVariantNotAvailable { - """The line that has variant that is not available.""" - line: CheckoutLine! -} - -input CheckoutLineUpdateInput { - """ - ID of the line. - - Added in Saleor 3.6. - """ - lineId: ID - - """ - Custom price of the item. Can be set only by apps with `HANDLE_CHECKOUTS` permission. When the line with the same variant will be provided multiple times, the last price will be used. - - Added in Saleor 3.1. - """ - price: PositiveDecimal - - """ - The number of items purchased. Optional for apps, required for any other users. - """ - quantity: Int - - """ - ID of the product variant. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `lineId` instead. - """ - variantId: ID -} - -""" -Adds a checkout line to the existing checkout.If line was already in checkout, its quantity will be increased. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutLinesAdd { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -""" -Deletes checkout lines. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutLinesDelete { - """An updated checkout.""" - checkout: Checkout - errors: [CheckoutError!]! -} - -""" -Updates checkout line in the existing checkout. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutLinesUpdate { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -""" -Event sent when checkout metadata is updated. - -Added in Saleor 3.8. -""" -type CheckoutMetadataUpdated implements Event { - """The checkout the event relates to.""" - checkout: Checkout - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Create a new payment for given checkout.""" -type CheckoutPaymentCreate { - """Related checkout object.""" - checkout: Checkout - errors: [PaymentError!]! - - """A newly created payment.""" - payment: Payment - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Represents an problem in the checkout. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -union CheckoutProblem = CheckoutLineProblemInsufficientStock | CheckoutLineProblemVariantNotAvailable - -""" -Remove a gift card or a voucher from a checkout. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutRemovePromoCode { - """The checkout with the removed gift card or voucher.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -""" -Represents the channel-specific checkout settings. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type CheckoutSettings { - """ - Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. - - Added in Saleor 3.15.This field will be removed in Saleor 4.0. - """ - useLegacyErrorFlow: Boolean! -} - -input CheckoutSettingsInput { - """ - Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. - - Added in Saleor 3.15. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - useLegacyErrorFlow: Boolean -} - -""" -Update shipping address in the existing checkout. - -Triggers the following webhook events: -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutShippingAddressUpdate { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -""" -Updates the shipping method of the checkout. - -Triggers the following webhook events: -- SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout shipping method with the external one. -- CHECKOUT_UPDATED (async): A checkout was updated. -""" -type CheckoutShippingMethodUpdate { - """An updated checkout.""" - checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CheckoutError!]! -} - -enum CheckoutSortField { - """Sort checkouts by creation date.""" - CREATION_DATE - - """Sort checkouts by customer.""" - CUSTOMER - - """Sort checkouts by payment.""" - PAYMENT -} - -input CheckoutSortingInput { - """Specifies the direction in which to sort checkouts.""" - direction: OrderDirection! - - """Sort checkouts by the selected field.""" - field: CheckoutSortField! -} - -""" -Event sent when checkout is updated. - -Added in Saleor 3.2. -""" -type CheckoutUpdated implements Event { - """The checkout the event relates to.""" - checkout: Checkout - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input CheckoutValidationRules { - """ - The validation rules that can be applied to provided billing address data. - """ - billingAddress: CheckoutAddressValidationRules - - """ - The validation rules that can be applied to provided shipping address data. - """ - shippingAddress: CheckoutAddressValidationRules -} - -type ChoiceValue { - """The raw name of the choice.""" - raw: String - - """The verbose name of the choice.""" - verbose: String -} - -"""Represents a collection of products.""" -type Collection implements Node & ObjectWithMetadata { - """Background image of the collection.""" - backgroundImage( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. - """ - format: ThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): Image - - """ - Channel given to retrieve this collection. Also used by federation gateway to resolve this object in a federated query. - """ - channel: String - - """ - List of channels in which the collection is available. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - channelListings: [CollectionChannelListing!] - - """ - Description of the collection. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Description of the collection. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """The ID of the collection.""" - id: ID! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Name of the collection.""" - name: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """List of products in this collection.""" - products( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for products.""" - filter: ProductFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort products.""" - sortBy: ProductOrder - - """ - Filtering options for products. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - where: ProductWhereInput - ): ProductCountableConnection - - """SEO description of the collection.""" - seoDescription: String - - """SEO title of the collection.""" - seoTitle: String - - """Slug of the collection.""" - slug: String! - - """Returns translated collection fields for the given language code.""" - translation( - """A language code to return the translation for collection.""" - languageCode: LanguageCodeEnum! - ): CollectionTranslation -} - -""" -Adds products to a collection. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CollectionAddProducts { - """Collection to which products will be added.""" - collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CollectionError!]! -} - -""" -Deletes collections. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CollectionBulkDelete { - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Returns how many objects were affected.""" - count: Int! - errors: [CollectionError!]! -} - -"""Represents collection channel listing.""" -type CollectionChannelListing implements Node { - """The channel to which the collection belongs.""" - channel: Channel! - - """The ID of the collection channel listing.""" - id: ID! - - """Indicates if the collection is published in the channel.""" - isPublished: Boolean! - publicationDate: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date.") - - """ - The collection publication date. - - Added in Saleor 3.3. - """ - publishedAt: DateTime -} - -type CollectionChannelListingError { - """List of attributes IDs which causes the error.""" - attributes: [ID!] - - """List of channels IDs which causes the error.""" - channels: [ID!] - - """The error code.""" - code: ProductErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of attribute values IDs which causes the error.""" - values: [ID!] -} - -""" -Manage collection's availability in channels. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CollectionChannelListingUpdate { - """An updated collection instance.""" - collection: Collection - collectionChannelListingErrors: [CollectionChannelListingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CollectionChannelListingError!]! -} - -input CollectionChannelListingUpdateInput { - """List of channels to which the collection should be assigned.""" - addChannels: [PublishableChannelListingInput!] - - """List of channels from which the collection should be unassigned.""" - removeChannels: [ID!] -} - -"""Represents a connection to a list of collections.""" -type CollectionCountableConnection { - edges: [CollectionCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type CollectionCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Collection! -} - -""" -Creates a new collection. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CollectionCreate { - collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CollectionError!]! -} - -input CollectionCreateInput { - """Background image file.""" - backgroundImage: Upload - - """Alt text for an image.""" - backgroundImageAlt: String - - """ - Description of the collection. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """Informs whether a collection is published.""" - isPublished: Boolean - - """ - Fields required to update the collection metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Name of the collection.""" - name: String - - """ - Fields required to update the collection private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """List of products to be added to the collection.""" - products: [ID!] - - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - publicationDate: Date - - """Search engine optimization fields.""" - seo: SeoInput - - """Slug of the collection.""" - slug: String -} - -""" -Event sent when new collection is created. - -Added in Saleor 3.2. -""" -type CollectionCreated implements Event { - """The collection the event relates to.""" - collection( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Collection - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a collection. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CollectionDelete { - collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CollectionError!]! -} - -""" -Event sent when collection is deleted. - -Added in Saleor 3.2. -""" -type CollectionDeleted implements Event { - """The collection the event relates to.""" - collection( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Collection - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type CollectionError { - """The error code.""" - code: CollectionErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of products IDs which causes the error.""" - products: [ID!] -} - -"""An enumeration.""" -enum CollectionErrorCode { - CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE -} - -input CollectionFilterInput { - """ - Specifies the channel by which the data should be filtered. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String - ids: [ID!] - metadata: [MetadataFilter!] - published: CollectionPublished - search: String - slugs: [String!] -} - -input CollectionInput { - """Background image file.""" - backgroundImage: Upload - - """Alt text for an image.""" - backgroundImageAlt: String - - """ - Description of the collection. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """Informs whether a collection is published.""" - isPublished: Boolean - - """ - Fields required to update the collection metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Name of the collection.""" - name: String - - """ - Fields required to update the collection private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - publicationDate: Date - - """Search engine optimization fields.""" - seo: SeoInput - - """Slug of the collection.""" - slug: String -} - -""" -Event sent when collection metadata is updated. - -Added in Saleor 3.8. -""" -type CollectionMetadataUpdated implements Event { - """The collection the event relates to.""" - collection( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Collection - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -enum CollectionPublished { - HIDDEN - PUBLISHED -} - -""" -Remove products from a collection. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CollectionRemoveProducts { - """Collection from which products will be removed.""" - collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CollectionError!]! -} - -""" -Reorder the products of a collection. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CollectionReorderProducts { - """Collection from which products are reordered.""" - collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CollectionError!]! -} - -enum CollectionSortField { - """ - Sort collections by availability. - - This option requires a channel filter to work as the values can vary between channels. - """ - AVAILABILITY - - """Sort collections by name.""" - NAME - - """Sort collections by product count.""" - PRODUCT_COUNT - - """ - Sort collections by publication date. - - This option requires a channel filter to work as the values can vary between channels. - """ - PUBLICATION_DATE - - """ - Sort collections by publication date. - - This option requires a channel filter to work as the values can vary between channels. - """ - PUBLISHED_AT -} - -input CollectionSortingInput { - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String - - """Specifies the direction in which to sort collections.""" - direction: OrderDirection! - - """Sort collections by the selected field.""" - field: CollectionSortField! -} - -""" -Represents collection's original translatable fields and related translations. -""" -type CollectionTranslatableContent implements Node { - """Represents a collection of products.""" - collection: Collection @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the collection to translate. - - Added in Saleor 3.14. - """ - collectionId: ID! - - """ - Collection's description to translate. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Description of the collection. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """The ID of the collection translatable content.""" - id: ID! - - """Collection's name to translate.""" - name: String! - - """SEO description to translate.""" - seoDescription: String - - """SEO title to translate.""" - seoTitle: String - - """Returns translated collection fields for the given language code.""" - translation( - """A language code to return the translation for collection.""" - languageCode: LanguageCodeEnum! - ): CollectionTranslation -} - -""" -Creates/updates translations for a collection. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type CollectionTranslate { - collection: Collection - errors: [TranslationError!]! - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""Represents collection translations.""" -type CollectionTranslation implements Node { - """ - Translated description of the collection. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Translated description of the collection. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """The ID of the collection translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated collection name.""" - name: String - - """Translated SEO description.""" - seoDescription: String - - """Translated SEO title.""" - seoTitle: String - - """ - Represents the collection fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: CollectionTranslatableContent -} - -""" -Updates a collection. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type CollectionUpdate { - collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [CollectionError!]! -} - -""" -Event sent when collection is updated. - -Added in Saleor 3.2. -""" -type CollectionUpdated implements Event { - """The collection the event relates to.""" - collection( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Collection - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input CollectionWhereInput { - """List of conditions that must be met.""" - AND: [CollectionWhereInput!] - - """A list of conditions of which at least one must be met.""" - OR: [CollectionWhereInput!] - ids: [ID!] - metadata: [MetadataFilter!] -} - -"""Stores information about a single configuration field.""" -type ConfigurationItem { - """Help text for the field.""" - helpText: String - - """Label for the field.""" - label: String - - """Name of the field.""" - name: String! - - """Type of the field.""" - type: ConfigurationTypeFieldEnum - - """Current value of the field.""" - value: String -} - -input ConfigurationItemInput { - """Name of the field to update.""" - name: String! - - """Value of the given field to update.""" - value: String -} - -"""An enumeration.""" -enum ConfigurationTypeFieldEnum { - BOOLEAN - MULTILINE - OUTPUT - PASSWORD - SECRET - SECRETMULTILINE - STRING -} - -""" -Confirm user account with token sent by email during registration. - -Triggers the following webhook events: -- ACCOUNT_CONFIRMED (async): Account was confirmed. -""" -type ConfirmAccount { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """An activated user account.""" - user: User -} - -""" -Confirm the email change of the logged-in user. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- CUSTOMER_UPDATED (async): A customer account was updated. -- NOTIFY_USER (async): A notification that account email change was confirmed. -- ACCOUNT_EMAIL_CHANGED (async): An account email was changed. -""" -type ConfirmEmailChange { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """A user instance with a new email.""" - user: User -} - -""" -Represents country codes defined by the ISO 3166-1 alpha-2 standard. - -The `EU` value is DEPRECATED and will be removed in Saleor 3.21. -""" -enum CountryCode { - AD - AE - AF - AG - AI - AL - AM - AO - AQ - AR - AS - AT - AU - AW - AX - AZ - BA - BB - BD - BE - BF - BG - BH - BI - BJ - BL - BM - BN - BO - BQ - BR - BS - BT - BV - BW - BY - BZ - CA - CC - CD - CF - CG - CH - CI - CK - CL - CM - CN - CO - CR - CU - CV - CW - CX - CY - CZ - DE - DJ - DK - DM - DO - DZ - EC - EE - EG - EH - ER - ES - ET - EU - FI - FJ - FK - FM - FO - FR - GA - GB - GD - GE - GF - GG - GH - GI - GL - GM - GN - GP - GQ - GR - GS - GT - GU - GW - GY - HK - HM - HN - HR - HT - HU - ID - IE - IL - IM - IN - IO - IQ - IR - IS - IT - JE - JM - JO - JP - KE - KG - KH - KI - KM - KN - KP - KR - KW - KY - KZ - LA - LB - LC - LI - LK - LR - LS - LT - LU - LV - LY - MA - MC - MD - ME - MF - MG - MH - MK - ML - MM - MN - MO - MP - MQ - MR - MS - MT - MU - MV - MW - MX - MY - MZ - NA - NC - NE - NF - NG - NI - NL - NO - NP - NR - NU - NZ - OM - PA - PE - PF - PG - PH - PK - PL - PM - PN - PR - PS - PT - PW - PY - QA - RE - RO - RS - RU - RW - SA - SB - SC - SD - SE - SG - SH - SI - SJ - SK - SL - SM - SN - SO - SR - SS - ST - SV - SX - SY - SZ - TC - TD - TF - TG - TH - TJ - TK - TL - TM - TN - TO - TR - TT - TV - TW - TZ - UA - UG - UM - US - UY - UZ - VA - VC - VE - VG - VI - VN - VU - WF - WS - YE - YT - ZA - ZM - ZW -} - -type CountryDisplay { - """Country code.""" - code: String! - - """Country name.""" - country: String! - - """Country tax.""" - vat: VAT @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`. Use `TaxClassCountryRate` type to manage tax rates per country.") -} - -input CountryFilterInput { - """ - Boolean for filtering countries by having shipping zone assigned.If 'true', return countries with shipping zone assigned.If 'false', return countries without any shipping zone assigned.If the argument is not provided (null), return all countries. - """ - attachedToShippingZones: Boolean -} - -input CountryRateInput { - """Country in which this rate applies.""" - countryCode: CountryCode! - - """ - Tax rate value provided as percentage. Example: provide `23` to represent `23%` tax rate. - """ - rate: Float! -} - -input CountryRateUpdateInput { - """Country in which this rate applies.""" - countryCode: CountryCode! - - """ - Tax rate value provided as percentage. Example: provide `23` to represent `23%` tax rate. Provide `null` to remove the particular rate. - """ - rate: Float -} - -"""Create JWT token.""" -type CreateToken { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """CSRF token required to re-generate access token.""" - csrfToken: String - errors: [AccountError!]! - - """JWT refresh token, required to re-generate access token.""" - refreshToken: String - - """JWT token, required to authenticate.""" - token: String - - """A user instance.""" - user: User -} - -type CreditCard { - """Card brand.""" - brand: String! - - """Two-digit number representing the card’s expiration month.""" - expMonth: Int - - """Four-digit number representing the card’s expiration year.""" - expYear: Int - - """First 4 digits of the card number.""" - firstDigits: String - - """Last 4 digits of the card number.""" - lastDigits: String! -} - -""" -Deletes customers. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- CUSTOMER_DELETED (async): A customer account was deleted. -""" -type CustomerBulkDelete { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Returns how many objects were affected.""" - count: Int! - errors: [AccountError!]! -} - -type CustomerBulkResult { - """Customer data.""" - customer: User - - """List of errors that occurred during the update attempt.""" - errors: [CustomerBulkUpdateError!] -} - -""" -Updates customers. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- CUSTOMER_UPDATED (async): A customer account was updated. -- CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. -""" -type CustomerBulkUpdate { - """Returns how many objects were created.""" - count: Int! - errors: [CustomerBulkUpdateError!]! - - """List of the updated customers.""" - results: [CustomerBulkResult!]! -} - -type CustomerBulkUpdateError { - """The error code.""" - code: CustomerBulkUpdateErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String -} - -"""An enumeration.""" -enum CustomerBulkUpdateErrorCode { - BLANK - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - MAX_LENGTH - NOT_FOUND - REQUIRED - UNIQUE -} - -input CustomerBulkUpdateInput { - """External ID of a customer to update.""" - externalReference: String - - """ID of a customer to update.""" - id: ID - - """Fields required to update a customer.""" - input: CustomerInput! -} - -""" -Creates a new customer. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- CUSTOMER_CREATED (async): A new customer account was created. -- CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. -- NOTIFY_USER (async): A notification for setting the password. -- ACCOUNT_SET_PASSWORD_REQUESTED (async): Setting a new password for the account is requested. -""" -type CustomerCreate { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - user: User -} - -""" -Event sent when new customer user is created. - -Added in Saleor 3.2. -""" -type CustomerCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a customer. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- CUSTOMER_DELETED (async): A customer account was deleted. -""" -type CustomerDelete { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - user: User -} - -"""History log of the customer.""" -type CustomerEvent implements Node { - """App that performed the action.""" - app: App - - """Number of objects concerned by the event.""" - count: Int - - """Date when event happened at in ISO 8601 format.""" - date: DateTime - - """The ID of the customer event.""" - id: ID! - - """Content of the event.""" - message: String - - """The concerned order.""" - order: Order - - """The concerned order line.""" - orderLine: OrderLine - - """Customer event type.""" - type: CustomerEventsEnum - - """User who performed the action.""" - user: User -} - -"""An enumeration.""" -enum CustomerEventsEnum { - ACCOUNT_ACTIVATED - ACCOUNT_CREATED - ACCOUNT_DEACTIVATED - CUSTOMER_DELETED - DIGITAL_LINK_DOWNLOADED - EMAIL_ASSIGNED - EMAIL_CHANGED - EMAIL_CHANGED_REQUEST - NAME_ASSIGNED - NOTE_ADDED - NOTE_ADDED_TO_ORDER - PASSWORD_CHANGED - PASSWORD_RESET - PASSWORD_RESET_LINK_SENT - PLACED_ORDER -} - -input CustomerFilterInput { - dateJoined: DateRangeInput - - """ - Filter by ids. - - Added in Saleor 3.8. - """ - ids: [ID!] - metadata: [MetadataFilter!] - numberOfOrders: IntRangeInput - placedOrders: DateRangeInput - search: String - updatedAt: DateTimeRangeInput -} - -input CustomerInput { - """Billing address of the customer.""" - defaultBillingAddress: AddressInput - - """Shipping address of the customer.""" - defaultShippingAddress: AddressInput - - """The unique email address of the user.""" - email: String - - """ - External ID of the customer. - - Added in Saleor 3.10. - """ - externalReference: String - - """Given name.""" - firstName: String - - """User account is active.""" - isActive: Boolean - - """ - User account is confirmed. - - Added in Saleor 3.15. - """ - isConfirmed: Boolean - - """User language code.""" - languageCode: LanguageCodeEnum - - """Family name.""" - lastName: String - - """ - Fields required to update the user metadata. - - Added in Saleor 3.14. - """ - metadata: [MetadataInput!] - - """A note about the user.""" - note: String - - """ - Fields required to update the user private metadata. - - Added in Saleor 3.14. - """ - privateMetadata: [MetadataInput!] -} - -""" -Event sent when customer user metadata is updated. - -Added in Saleor 3.8. -""" -type CustomerMetadataUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Updates an existing customer. - -Requires one of the following permissions: MANAGE_USERS. - -Triggers the following webhook events: -- CUSTOMER_UPDATED (async): A new customer account was updated. -- CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. -""" -type CustomerUpdate { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - user: User -} - -""" -Event sent when customer user is updated. - -Added in Saleor 3.2. -""" -type CustomerUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -The `Date` scalar type represents a Date -value as specified by -[iso8601](https://en.wikipedia.org/wiki/ISO_8601). -""" -scalar Date - -input DateRangeInput { - """Start date.""" - gte: Date - - """End date.""" - lte: Date -} - -""" -The `DateTime` scalar type represents a DateTime -value as specified by -[iso8601](https://en.wikipedia.org/wiki/ISO_8601). -""" -scalar DateTime - -""" -Define the filtering options for date time fields. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -input DateTimeFilterInput { - """The value equal to.""" - eq: DateTime - - """The value included in.""" - oneOf: [DateTime!] - - """The value in range.""" - range: DateTimeRangeInput -} - -input DateTimeRangeInput { - """Start date.""" - gte: DateTime - - """End date.""" - lte: DateTime -} - -"""The `Day` scalar type represents number of days by integer value.""" -scalar Day - -""" -Deactivate all JWT tokens of the currently authenticated user. - -Requires one of the following permissions: AUTHENTICATED_USER. -""" -type DeactivateAllUserTokens { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! -} - -""" -Custom Decimal implementation. - -Returns Decimal as a float in the API, -parses float to the Decimal on the way back. -""" -scalar Decimal - -""" -Define the filtering options for decimal fields. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -input DecimalFilterInput { - """The value equal to.""" - eq: Decimal - - """The value included in.""" - oneOf: [Decimal!] - - """The value in range.""" - range: DecimalRangeInput -} - -input DecimalRangeInput { - """Decimal value greater than or equal to.""" - gte: Decimal - - """Decimal value less than or equal to.""" - lte: Decimal -} - -""" -Delete metadata of an object. To use it, you need to have access to the modified object. -""" -type DeleteMetadata { - errors: [MetadataError!]! - item: ObjectWithMetadata - metadataErrors: [MetadataError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Delete object's private metadata. To use it, you need to be an authenticated staff user or an app and have access to the modified object. -""" -type DeletePrivateMetadata { - errors: [MetadataError!]! - item: ObjectWithMetadata - metadataErrors: [MetadataError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Represents a delivery method chosen for the checkout. `Warehouse` type is used when checkout is marked as "click and collect" and `ShippingMethod` otherwise. - -Added in Saleor 3.1. -""" -union DeliveryMethod = ShippingMethod | Warehouse - -"""Represents digital content associated with a product variant.""" -type DigitalContent implements Node & ObjectWithMetadata { - """Indicator for automatic fulfillment of digital content.""" - automaticFulfillment: Boolean! - - """File associated with digital content.""" - contentFile: String! - - """The ID of the digital content.""" - id: ID! - - """Maximum number of allowed downloads for the digital content.""" - maxDownloads: Int - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Product variant assigned to digital content.""" - productVariant: ProductVariant! - - """Number of days the URL for the digital content remains valid.""" - urlValidDays: Int - - """List of URLs for the digital variant.""" - urls: [DigitalContentUrl!] - - """Default settings indicator for digital content.""" - useDefaultSettings: Boolean! -} - -"""A connection to a list of digital content items.""" -type DigitalContentCountableConnection { - edges: [DigitalContentCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type DigitalContentCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: DigitalContent! -} - -""" -Create new digital content. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type DigitalContentCreate { - content: DigitalContent - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - variant: ProductVariant -} - -""" -Remove digital content assigned to given variant. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type DigitalContentDelete { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - variant: ProductVariant -} - -input DigitalContentInput { - """Overwrite default automatic_fulfillment setting for variant.""" - automaticFulfillment: Boolean - - """ - Determines how many times a download link can be accessed by a customer. - """ - maxDownloads: Int - - """ - Fields required to update the digital content metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """ - Fields required to update the digital content private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """ - Determines for how many days a download link is active since it was generated. - """ - urlValidDays: Int - - """Use default digital content settings for this product.""" - useDefaultSettings: Boolean! -} - -""" -Update digital content. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type DigitalContentUpdate { - content: DigitalContent - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - variant: ProductVariant -} - -input DigitalContentUploadInput { - """Overwrite default automatic_fulfillment setting for variant.""" - automaticFulfillment: Boolean - - """Represents an file in a multipart request.""" - contentFile: Upload! - - """ - Determines how many times a download link can be accessed by a customer. - """ - maxDownloads: Int - - """ - Fields required to update the digital content metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """ - Fields required to update the digital content private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """ - Determines for how many days a download link is active since it was generated. - """ - urlValidDays: Int - - """Use default digital content settings for this product.""" - useDefaultSettings: Boolean! -} - -"""Represents a URL for digital content.""" -type DigitalContentUrl implements Node { - """Digital content associated with the URL.""" - content: DigitalContent! - - """Date and time when the digital content URL was created.""" - created: DateTime! - - """Number of times digital content has been downloaded.""" - downloadNum: Int! - - """The ID of the digital content URL.""" - id: ID! - - """UUID of digital content.""" - token: UUID! - - """URL for digital content.""" - url: String -} - -""" -Generate new URL to digital content. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type DigitalContentUrlCreate { - digitalContentUrl: DigitalContentUrl - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input DigitalContentUrlCreateInput { - """Digital content ID which URL will belong to.""" - content: ID! -} - -type DiscountError { - """List of channels IDs which causes the error.""" - channels: [ID!] - - """The error code.""" - code: DiscountErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of products IDs which causes the error.""" - products: [ID!] - - """ - List of voucher codes which causes the error. - - Added in Saleor 3.18. - """ - voucherCodes: [String!] -} - -"""An enumeration.""" -enum DiscountErrorCode { - ALREADY_EXISTS - CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE - VOUCHER_ALREADY_USED -} - -enum DiscountStatusEnum { - ACTIVE - EXPIRED - SCHEDULED -} - -enum DiscountValueTypeEnum { - FIXED - PERCENTAGE -} - -input DiscountedObjectWhereInput { - """List of conditions that must be met.""" - AND: [DiscountedObjectWhereInput!] - - """A list of conditions of which at least one must be met.""" - OR: [DiscountedObjectWhereInput!] - - """Filter by the base subtotal price.""" - baseSubtotalPrice: DecimalFilterInput - - """Filter by the base total price.""" - baseTotalPrice: DecimalFilterInput -} - -"""An enumeration.""" -enum DistanceUnitsEnum { - CM - DM - FT - INCH - KM - M - MM - YD -} - -"""Represents API domain.""" -type Domain { - """The host name of the domain.""" - host: String! - - """Inform if SSL is enabled.""" - sslEnabled: Boolean! - - """The absolute URL of the API.""" - url: String! -} - -""" -Deletes draft orders. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type DraftOrderBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [OrderError!]! - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Completes creating an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type DraftOrderComplete { - errors: [OrderError!]! - - """Completed order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Creates a new draft order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type DraftOrderCreate { - errors: [OrderError!]! - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input DraftOrderCreateInput { - """Billing address of the customer.""" - billingAddress: AddressInput - - """ID of the channel associated with the order.""" - channelId: ID - - """A note from a customer. Visible by customers in the order summary.""" - customerNote: String - - """Discount amount for the order.""" - discount: PositiveDecimal - - """ - External ID of this order. - - Added in Saleor 3.10. - """ - externalReference: String - - """Variant line input consisting of variant ID and quantity of products.""" - lines: [OrderLineCreateInput!] - - """ - URL of a view where users should be redirected to see the order details. URL in RFC 1808 format. - """ - redirectUrl: String - - """Shipping address of the customer.""" - shippingAddress: AddressInput - - """ID of a selected shipping method.""" - shippingMethod: ID - - """Customer associated with the draft order.""" - user: ID - - """Email address of the customer.""" - userEmail: String - - """ID of the voucher associated with the order.""" - voucher: ID - - """ - A code of the voucher associated with the order. - - Added in Saleor 3.18. - """ - voucherCode: String -} - -""" -Event sent when new draft order is created. - -Added in Saleor 3.2. -""" -type DraftOrderCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a draft order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type DraftOrderDelete { - errors: [OrderError!]! - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when draft order is deleted. - -Added in Saleor 3.2. -""" -type DraftOrderDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input DraftOrderInput { - """Billing address of the customer.""" - billingAddress: AddressInput - - """ID of the channel associated with the order.""" - channelId: ID - - """A note from a customer. Visible by customers in the order summary.""" - customerNote: String - - """Discount amount for the order.""" - discount: PositiveDecimal - - """ - External ID of this order. - - Added in Saleor 3.10. - """ - externalReference: String - - """ - URL of a view where users should be redirected to see the order details. URL in RFC 1808 format. - """ - redirectUrl: String - - """Shipping address of the customer.""" - shippingAddress: AddressInput - - """ID of a selected shipping method.""" - shippingMethod: ID - - """Customer associated with the draft order.""" - user: ID - - """Email address of the customer.""" - userEmail: String - - """ID of the voucher associated with the order.""" - voucher: ID - - """ - A code of the voucher associated with the order. - - Added in Saleor 3.18. - """ - voucherCode: String -} - -""" -Deletes order lines. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type DraftOrderLinesBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [OrderError!]! - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Updates a draft order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type DraftOrderUpdate { - errors: [OrderError!]! - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when draft order is updated. - -Added in Saleor 3.2. -""" -type DraftOrderUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -enum ErrorPolicyEnum { - """ - Save what is possible within a single row. If there are errors in an input data row, try to save it partially and skip the invalid part. - """ - IGNORE_FAILED - - """Reject all rows if there is at least one error in any of them.""" - REJECT_EVERYTHING - - """Reject rows with errors.""" - REJECT_FAILED_ROWS -} - -interface Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Event delivery.""" -type EventDelivery implements Node { - """Event delivery attempts.""" - attempts( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Event delivery sorter""" - sortBy: EventDeliveryAttemptSortingInput - ): EventDeliveryAttemptCountableConnection - - """Creation time of an event delivery.""" - createdAt: DateTime! - - """Webhook event type.""" - eventType: WebhookEventTypeEnum! - - """The ID of an event delivery.""" - id: ID! - - """Event payload.""" - payload: String - - """Event delivery status.""" - status: EventDeliveryStatusEnum! -} - -"""Event delivery attempts.""" -type EventDeliveryAttempt implements Node { - """Event delivery creation date and time.""" - createdAt: DateTime! - - """Delivery attempt duration.""" - duration: Float - - """The ID of Event Delivery Attempt.""" - id: ID! - - """Request headers for delivery attempt.""" - requestHeaders: String - - """Delivery attempt response content.""" - response: String - - """Response headers for delivery attempt.""" - responseHeaders: String - - """Delivery attempt response status code.""" - responseStatusCode: Int - - """Event delivery status.""" - status: EventDeliveryStatusEnum! - - """Task id for delivery attempt.""" - taskId: String -} - -type EventDeliveryAttemptCountableConnection { - edges: [EventDeliveryAttemptCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type EventDeliveryAttemptCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: EventDeliveryAttempt! -} - -enum EventDeliveryAttemptSortField { - """Sort event delivery attempts by created at.""" - CREATED_AT -} - -input EventDeliveryAttemptSortingInput { - """Specifies the direction in which to sort attempts.""" - direction: OrderDirection! - - """Sort attempts by the selected field.""" - field: EventDeliveryAttemptSortField! -} - -type EventDeliveryCountableConnection { - edges: [EventDeliveryCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type EventDeliveryCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: EventDelivery! -} - -input EventDeliveryFilterInput { - eventType: WebhookEventTypeEnum - status: EventDeliveryStatusEnum -} - -""" -Retries event delivery. - -Requires one of the following permissions: MANAGE_APPS. -""" -type EventDeliveryRetry { - """Event delivery.""" - delivery: EventDelivery - errors: [WebhookError!]! -} - -enum EventDeliverySortField { - """Sort event deliveries by created at.""" - CREATED_AT -} - -input EventDeliverySortingInput { - """Specifies the direction in which to sort deliveries.""" - direction: OrderDirection! - - """Sort deliveries by the selected field.""" - field: EventDeliverySortField! -} - -enum EventDeliveryStatusEnum { - FAILED - PENDING - SUCCESS -} - -type ExportError { - """The error code.""" - code: ExportErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum ExportErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED -} - -"""History log of export file.""" -type ExportEvent implements Node { - """ - App which performed the action. Requires one of the following permissions: OWNER, MANAGE_APPS. - """ - app: App - - """Date when event happened at in ISO 8601 format.""" - date: DateTime! - - """The ID of the object.""" - id: ID! - - """Content of the event.""" - message: String! - - """Export event type.""" - type: ExportEventsEnum! - - """ - User who performed the action. Requires one of the following permissions: OWNER, MANAGE_STAFF. - """ - user: User -} - -"""An enumeration.""" -enum ExportEventsEnum { - EXPORTED_FILE_SENT - EXPORT_DELETED - EXPORT_FAILED - EXPORT_FAILED_INFO_SENT - EXPORT_PENDING - EXPORT_SUCCESS -} - -"""Represents a job data of exported file.""" -type ExportFile implements Job & Node { - """The app which requests file export.""" - app: App - - """Created date time of job in ISO 8601 format.""" - createdAt: DateTime! - - """List of events associated with the export.""" - events: [ExportEvent!] - - """The ID of the export file.""" - id: ID! - - """Job message.""" - message: String - - """Job status.""" - status: JobStatusEnum! - - """Date time of job last update in ISO 8601 format.""" - updatedAt: DateTime! - - """The URL of field to download.""" - url: String - - """The user who requests file export.""" - user: User -} - -type ExportFileCountableConnection { - edges: [ExportFileCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type ExportFileCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: ExportFile! -} - -input ExportFileFilterInput { - app: String - createdAt: DateTimeRangeInput - status: JobStatusEnum - updatedAt: DateTimeRangeInput - user: String -} - -enum ExportFileSortField { - CREATED_AT - LAST_MODIFIED_AT - STATUS - UPDATED_AT -} - -input ExportFileSortingInput { - """Specifies the direction in which to sort export file.""" - direction: OrderDirection! - - """Sort export file by the selected field.""" - field: ExportFileSortField! -} - -""" -Export gift cards to csv file. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- NOTIFY_USER (async): A notification for the exported file. -- GIFT_CARD_EXPORT_COMPLETED (async): A notification for the exported file. -""" -type ExportGiftCards { - errors: [ExportError!]! - - """ - The newly created export file job which is responsible for export data. - """ - exportFile: ExportFile -} - -input ExportGiftCardsInput { - """Type of exported file.""" - fileType: FileTypesEnum! - - """Filtering options for gift cards.""" - filter: GiftCardFilterInput - - """List of gift cards IDs to export.""" - ids: [ID!] - - """Determine which gift cards should be exported.""" - scope: ExportScope! -} - -input ExportInfoInput { - """List of attribute ids witch should be exported.""" - attributes: [ID!] - - """List of channels ids which should be exported.""" - channels: [ID!] - - """List of product fields witch should be exported.""" - fields: [ProductFieldEnum!] - - """List of warehouse ids witch should be exported.""" - warehouses: [ID!] -} - -""" -Export products to csv file. - -Requires one of the following permissions: MANAGE_PRODUCTS. - -Triggers the following webhook events: -- NOTIFY_USER (async): A notification for the exported file. -- PRODUCT_EXPORT_COMPLETED (async): A notification for the exported file. -""" -type ExportProducts { - errors: [ExportError!]! - exportErrors: [ExportError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """ - The newly created export file job which is responsible for export data. - """ - exportFile: ExportFile -} - -input ExportProductsInput { - """Input with info about fields which should be exported.""" - exportInfo: ExportInfoInput - - """Type of exported file.""" - fileType: FileTypesEnum! - - """Filtering options for products.""" - filter: ProductFilterInput - - """List of products IDs to export.""" - ids: [ID!] - - """Determine which products should be exported.""" - scope: ExportScope! -} - -enum ExportScope { - """Export all products.""" - ALL - - """Export the filtered products.""" - FILTER - - """Export products with given ids.""" - IDS -} - -""" -Export voucher codes to csv/xlsx file. - -Added in Saleor 3.18. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_CODE_EXPORT_COMPLETED (async): A notification for the exported file. -""" -type ExportVoucherCodes { - errors: [ExportError!]! - - """ - The newly created export file job which is responsible for export data. - """ - exportFile: ExportFile -} - -input ExportVoucherCodesInput { - """Type of exported file.""" - fileType: FileTypesEnum! - - """List of voucher code IDs to export.""" - ids: [ID!] - - """ - The ID of the voucher. If provided, exports all codes belonging to the voucher. - """ - voucherId: ID -} - -"""External authentication plugin.""" -type ExternalAuthentication { - """ID of external authentication plugin.""" - id: String! - - """Name of external authentication plugin.""" - name: String -} - -"""Prepare external authentication URL for user by custom plugin.""" -type ExternalAuthenticationUrl { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """The data returned by authentication plugin.""" - authenticationData: JSONString - errors: [AccountError!]! -} - -"""Logout user by custom plugin.""" -type ExternalLogout { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """The data returned by authentication plugin.""" - logoutData: JSONString -} - -type ExternalNotificationError { - """The error code.""" - code: ExternalNotificationErrorCodes! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum ExternalNotificationErrorCodes { - CHANNEL_INACTIVE - INVALID_MODEL_TYPE - NOT_FOUND - REQUIRED -} - -""" -Trigger sending a notification with the notify plugin method. Serializes nodes provided as ids parameter and includes this data in the notification payload. - -Added in Saleor 3.1. -""" -type ExternalNotificationTrigger { - errors: [ExternalNotificationError!]! -} - -input ExternalNotificationTriggerInput { - """ - External event type. This field is passed to a plugin as an event type. - """ - externalEventType: String! - - """ - Additional payload that will be merged with the one based on the business object ID. - """ - extraPayload: JSONString - - """ - The list of customers or orders node IDs that will be serialized and included in the notification payload. - """ - ids: [ID!]! -} - -"""Obtain external access tokens for user by custom plugin.""" -type ExternalObtainAccessTokens { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """CSRF token required to re-generate external access token.""" - csrfToken: String - errors: [AccountError!]! - - """The refresh token, required to re-generate external access token.""" - refreshToken: String - - """The token, required to authenticate.""" - token: String - - """A user instance.""" - user: User -} - -"""Refresh user's access by custom plugin.""" -type ExternalRefresh { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """CSRF token required to re-generate external access token.""" - csrfToken: String - errors: [AccountError!]! - - """The refresh token, required to re-generate external access token.""" - refreshToken: String - - """The token, required to authenticate.""" - token: String - - """A user instance.""" - user: User -} - -"""Verify external authentication data by plugin.""" -type ExternalVerify { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """Determine if authentication data is valid or not.""" - isValid: Boolean! - - """User assigned to data.""" - user: User - - """External data.""" - verifyData: JSONString -} - -type File { - """Content type of the file.""" - contentType: String - - """The URL of the file.""" - url: String! -} - -"""An enumeration.""" -enum FileTypesEnum { - CSV - XLSX -} - -""" -Upload a file. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec - -Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. -""" -type FileUpload { - errors: [UploadError!]! - uploadErrors: [UploadError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - uploadedFile: File -} - -"""Represents order fulfillment.""" -type Fulfillment implements Node & ObjectWithMetadata { - """Date and time when fulfillment was created.""" - created: DateTime! - - """Sequence in which the fulfillments were created for an order.""" - fulfillmentOrder: Int! - - """ID of the fulfillment.""" - id: ID! - - """List of lines for the fulfillment.""" - lines: [FulfillmentLine!] - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - Amount of refunded shipping price. - - Added in Saleor 3.14. - """ - shippingRefundedAmount: Money - - """Status of fulfillment.""" - status: FulfillmentStatus! - - """User-friendly fulfillment status.""" - statusDisplay: String - - """ - Total refunded amount assigned to this fulfillment. - - Added in Saleor 3.14. - """ - totalRefundedAmount: Money - - """Fulfillment tracking number.""" - trackingNumber: String! - - """Warehouse from fulfillment was fulfilled.""" - warehouse: Warehouse -} - -""" -Approve existing fulfillment. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_ORDERS. - -Triggers the following webhook events: -- FULFILLMENT_APPROVED (async): Fulfillment is approved. -""" -type FulfillmentApprove { - errors: [OrderError!]! - - """An approved fulfillment.""" - fulfillment: Fulfillment - - """Order which fulfillment was approved.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when fulfillment is approved. - -Added in Saleor 3.7. -""" -type FulfillmentApproved implements Event { - """The fulfillment the event relates to.""" - fulfillment: Fulfillment - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """ - If true, send a notification to the customer. - - Added in Saleor 3.16. - """ - notifyCustomer: Boolean! - - """The order the fulfillment belongs to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Cancels existing fulfillment and optionally restocks items. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type FulfillmentCancel { - errors: [OrderError!]! - - """A canceled fulfillment.""" - fulfillment: Fulfillment - - """Order which fulfillment was cancelled.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input FulfillmentCancelInput { - """ - ID of a warehouse where items will be restocked. Optional when fulfillment is in WAITING_FOR_APPROVAL state. - """ - warehouseId: ID -} - -""" -Event sent when fulfillment is canceled. - -Added in Saleor 3.4. -""" -type FulfillmentCanceled implements Event { - """The fulfillment the event relates to.""" - fulfillment: Fulfillment - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the fulfillment belongs to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when new fulfillment is created. - -Added in Saleor 3.4. -""" -type FulfillmentCreated implements Event { - """The fulfillment the event relates to.""" - fulfillment: Fulfillment - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """ - If true, the app should send a notification to the customer. - - Added in Saleor 3.16. - """ - notifyCustomer: Boolean! - - """The order the fulfillment belongs to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents line of the fulfillment.""" -type FulfillmentLine implements Node { - """ID of the fulfillment line.""" - id: ID! - - """The order line to which the fulfillment line is related.""" - orderLine: OrderLine - - """The number of items included in the fulfillment line.""" - quantity: Int! -} - -""" -Event sent when fulfillment metadata is updated. - -Added in Saleor 3.8. -""" -type FulfillmentMetadataUpdated implements Event { - """The fulfillment the event relates to.""" - fulfillment: Fulfillment - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the fulfillment belongs to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Refund products. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type FulfillmentRefundProducts { - errors: [OrderError!]! - - """A refunded fulfillment.""" - fulfillment: Fulfillment - - """Order which fulfillment was refunded.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Return products. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type FulfillmentReturnProducts { - errors: [OrderError!]! - - """Order which fulfillment was returned.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """A replace fulfillment.""" - replaceFulfillment: Fulfillment - - """A draft order which was created for products with replace flag.""" - replaceOrder: Order - - """A return fulfillment.""" - returnFulfillment: Fulfillment -} - -"""An enumeration.""" -enum FulfillmentStatus { - CANCELED - FULFILLED - REFUNDED - REFUNDED_AND_RETURNED - REPLACED - RETURNED - WAITING_FOR_APPROVAL -} - -""" -Event sent when the tracking number is updated. - -Added in Saleor 3.16. -""" -type FulfillmentTrackingNumberUpdated implements Event { - """The fulfillment the event relates to.""" - fulfillment: Fulfillment - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the fulfillment belongs to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Updates a fulfillment for an order. - -Requires one of the following permissions: MANAGE_ORDERS. - -Triggers the following webhook events: -- FULFILLMENT_TRACKING_NUMBER_UPDATED (async): Fulfillment tracking number is updated. -""" -type FulfillmentUpdateTracking { - errors: [OrderError!]! - - """A fulfillment with updated tracking.""" - fulfillment: Fulfillment - - """Order for which fulfillment was updated.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input FulfillmentUpdateTrackingInput { - """If true, send an email notification to the customer.""" - notifyCustomer: Boolean = false - - """Fulfillment tracking number.""" - trackingNumber: String -} - -"""Payment gateway client configuration key and value pair.""" -type GatewayConfigLine { - """Gateway config key.""" - field: String! - - """Gateway config value for key.""" - value: String -} - -""" -The `GenericScalar` scalar type represents a generic -GraphQL scalar value that could be: -String, Boolean, Int, Float, List or Object. -""" -scalar GenericScalar - -""" -A gift card is a prepaid electronic payment card accepted in stores. They can be used during checkout by providing a valid gift card codes. -""" -type GiftCard implements Node & ObjectWithMetadata { - """ - App which created the gift card. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_APPS, OWNER. - """ - app: App - - """ - Slug of the channel where the gift card was bought. - - Added in Saleor 3.1. - """ - boughtInChannel: String - - """ - Gift card code. It can be fetched both by a staff member with 'MANAGE_GIFT_CARD' when gift card hasn't been used yet or a user who bought or issued the gift card. - - Requires one of the following permissions: MANAGE_GIFT_CARD, OWNER. - """ - code: String! - - """Date and time when gift card was created.""" - created: DateTime! - - """ - The user who bought or issued a gift card. - - Added in Saleor 3.1. - """ - createdBy: User - - """ - Email address of the user who bought or issued gift card. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_USERS, OWNER. - """ - createdByEmail: String - currentBalance: Money! - - """Code in format which allows displaying in a user interface.""" - displayCode: String! - - """End date of gift card.""" - endDate: DateTime @deprecated(reason: "This field will be removed in Saleor 4.0. Use `expiryDate` field instead.") - - """ - List of events associated with the gift card. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - """ - events( - """Filtering options for gift card events.""" - filter: GiftCardEventFilterInput - ): [GiftCardEvent!]! - - """Expiry date of the gift card.""" - expiryDate: Date - - """ID of the gift card.""" - id: ID! - initialBalance: Money! - isActive: Boolean! - - """Last 4 characters of gift card code.""" - last4CodeChars: String! - - """Date and time when gift card was last used.""" - lastUsedOn: DateTime - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - Related gift card product. - - Added in Saleor 3.1. - """ - product: Product - - """Start date of gift card.""" - startDate: DateTime @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """ - The gift card tag. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - """ - tags: [GiftCardTag!]! - - """ - The customer who used a gift card. - - Added in Saleor 3.1. - """ - usedBy: User @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """ - Email address of the customer who used a gift card. - - Added in Saleor 3.1. - """ - usedByEmail: String @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """The customer who bought a gift card.""" - user: User @deprecated(reason: "This field will be removed in Saleor 4.0. Use `createdBy` field instead.") -} - -""" -Activate a gift card. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_STATUS_CHANGED (async): A gift card was activated. -""" -type GiftCardActivate { - errors: [GiftCardError!]! - - """Activated gift card.""" - giftCard: GiftCard - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Adds note to the gift card. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_UPDATED (async): A gift card was updated. -""" -type GiftCardAddNote { - errors: [GiftCardError!]! - - """Gift card note created.""" - event: GiftCardEvent - - """Gift card with the note added.""" - giftCard: GiftCard -} - -input GiftCardAddNoteInput { - """Note message.""" - message: String! -} - -""" -Activate gift cards. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_STATUS_CHANGED (async): A gift card was activated. -""" -type GiftCardBulkActivate { - """Returns how many objects were affected.""" - count: Int! - errors: [GiftCardError!]! -} - -""" -Create gift cards. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_CREATED (async): A gift card was created. -- NOTIFY_USER (async): A notification for created gift card. -""" -type GiftCardBulkCreate { - """Returns how many objects were created.""" - count: Int! - errors: [GiftCardError!]! - - """List of created gift cards.""" - giftCards: [GiftCard!]! -} - -input GiftCardBulkCreateInput { - """Balance of the gift card.""" - balance: PriceInput! - - """The number of cards to issue.""" - count: Int! - - """The gift card expiry date.""" - expiryDate: Date - - """Determine if gift card is active.""" - isActive: Boolean! - - """The gift card tags.""" - tags: [String!] -} - -""" -Deactivate gift cards. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_STATUS_CHANGED (async): A gift card was deactivated. -""" -type GiftCardBulkDeactivate { - """Returns how many objects were affected.""" - count: Int! - errors: [GiftCardError!]! -} - -""" -Delete gift cards. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_DELETED (async): A gift card was deleted. -""" -type GiftCardBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [GiftCardError!]! -} - -type GiftCardCountableConnection { - edges: [GiftCardCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type GiftCardCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: GiftCard! -} - -""" -Creates a new gift card. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_CREATED (async): A gift card was created. -- NOTIFY_USER (async): A notification for created gift card. -""" -type GiftCardCreate { - errors: [GiftCardError!]! - giftCard: GiftCard - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input GiftCardCreateInput { - """ - The gift card tags to add. - - Added in Saleor 3.1. - """ - addTags: [String!] - - """Balance of the gift card.""" - balance: PriceInput! - - """ - Slug of a channel from which the email should be sent. - - Added in Saleor 3.1. - """ - channel: String - - """ - Code to use the gift card. - - DEPRECATED: this field will be removed in Saleor 4.0. The code is now auto generated. - """ - code: String - - """ - End date of the gift card in ISO 8601 format. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `expiryDate` from `expirySettings` instead. - """ - endDate: Date - - """ - The gift card expiry date. - - Added in Saleor 3.1. - """ - expiryDate: Date - - """ - Determine if gift card is active. - - Added in Saleor 3.1. - """ - isActive: Boolean! - - """ - The gift card note from the staff member. - - Added in Saleor 3.1. - """ - note: String - - """ - Start date of the gift card in ISO 8601 format. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - startDate: Date - - """Email of the customer to whom gift card will be sent.""" - userEmail: String -} - -""" -Event sent when new gift card is created. - -Added in Saleor 3.2. -""" -type GiftCardCreated implements Event { - """The gift card the event relates to.""" - giftCard: GiftCard - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deactivate a gift card. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_STATUS_CHANGED (async): A gift card was deactivated. -""" -type GiftCardDeactivate { - errors: [GiftCardError!]! - - """Deactivated gift card.""" - giftCard: GiftCard - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Delete gift card. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_DELETED (async): A gift card was deleted. -""" -type GiftCardDelete { - errors: [GiftCardError!]! - giftCard: GiftCard - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when gift card is deleted. - -Added in Saleor 3.2. -""" -type GiftCardDeleted implements Event { - """The gift card the event relates to.""" - giftCard: GiftCard - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type GiftCardError { - """The error code.""" - code: GiftCardErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of tag values that cause the error.""" - tags: [String!] -} - -"""An enumeration.""" -enum GiftCardErrorCode { - ALREADY_EXISTS - DUPLICATED_INPUT_ITEM - EXPIRED_GIFT_CARD - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE -} - -""" -History log of the gift card. - -Added in Saleor 3.1. -""" -type GiftCardEvent implements Node { - """ - App that performed the action. Requires one of the following permissions: MANAGE_APPS, OWNER. - """ - app: App - - """The gift card balance.""" - balance: GiftCardEventBalance - - """Date when event happened at in ISO 8601 format.""" - date: DateTime - - """Email of the customer.""" - email: String - - """The gift card expiry date.""" - expiryDate: Date - - """ID of the event associated with a gift card.""" - id: ID! - - """Content of the event.""" - message: String - - """Previous gift card expiry date.""" - oldExpiryDate: Date - - """The list of old gift card tags.""" - oldTags: [String!] - - """The order ID where gift card was used or bought.""" - orderId: ID - - """User-friendly number of an order where gift card was used or bought.""" - orderNumber: String - - """The list of gift card tags.""" - tags: [String!] - - """Gift card event type.""" - type: GiftCardEventsEnum - - """ - User who performed the action. Requires one of the following permissions: MANAGE_USERS, MANAGE_STAFF, OWNER. - """ - user: User -} - -type GiftCardEventBalance { - """Current balance of the gift card.""" - currentBalance: Money! - - """Initial balance of the gift card.""" - initialBalance: Money - - """Previous current balance of the gift card.""" - oldCurrentBalance: Money - - """Previous initial balance of the gift card.""" - oldInitialBalance: Money -} - -input GiftCardEventFilterInput { - orders: [ID!] - type: GiftCardEventsEnum -} - -"""An enumeration.""" -enum GiftCardEventsEnum { - ACTIVATED - BALANCE_RESET - BOUGHT - DEACTIVATED - EXPIRY_DATE_UPDATED - ISSUED - NOTE_ADDED - RESENT - SENT_TO_CUSTOMER - TAGS_UPDATED - UPDATED - USED_IN_ORDER -} - -""" -Event sent when gift card export is completed. - -Added in Saleor 3.16. -""" -type GiftCardExportCompleted implements Event { - """The export file for gift cards.""" - export: ExportFile - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input GiftCardFilterInput { - code: String - createdByEmail: String - currency: String - currentBalance: PriceRangeInput - initialBalance: PriceRangeInput - isActive: Boolean - metadata: [MetadataFilter!] - products: [ID!] - tags: [String!] - used: Boolean - usedBy: [ID!] -} - -""" -Event sent when gift card metadata is updated. - -Added in Saleor 3.8. -""" -type GiftCardMetadataUpdated implements Event { - """The gift card the event relates to.""" - giftCard: GiftCard - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Resend a gift card. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- NOTIFY_USER (async): A notification for gift card resend. -""" -type GiftCardResend { - errors: [GiftCardError!]! - - """Gift card which has been sent.""" - giftCard: GiftCard -} - -input GiftCardResendInput { - """Slug of a channel from which the email should be sent.""" - channel: String! - - """Email to which gift card should be send.""" - email: String - - """ID of a gift card to resend.""" - id: ID! -} - -""" -Event sent when gift card is e-mailed. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type GiftCardSent implements Event { - """Slug of a channel for which this gift card email was sent.""" - channel: String - - """The gift card the event relates to.""" - giftCard: GiftCard - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """E-mail address to which gift card was sent.""" - sentToEmail: String - - """Saleor version that triggered the event.""" - version: String -} - -"""Gift card related settings from site settings.""" -type GiftCardSettings { - """The gift card expiry period settings.""" - expiryPeriod: TimePeriod - - """The gift card expiry type settings.""" - expiryType: GiftCardSettingsExpiryTypeEnum! -} - -type GiftCardSettingsError { - """The error code.""" - code: GiftCardSettingsErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum GiftCardSettingsErrorCode { - GRAPHQL_ERROR - INVALID - REQUIRED -} - -"""An enumeration.""" -enum GiftCardSettingsExpiryTypeEnum { - EXPIRY_PERIOD - NEVER_EXPIRE -} - -""" -Update gift card settings. - -Requires one of the following permissions: MANAGE_GIFT_CARD. -""" -type GiftCardSettingsUpdate { - errors: [GiftCardSettingsError!]! - - """Gift card settings.""" - giftCardSettings: GiftCardSettings -} - -input GiftCardSettingsUpdateInput { - """Defines gift card expiry period.""" - expiryPeriod: TimePeriodInputType - - """Defines gift card default expiry settings.""" - expiryType: GiftCardSettingsExpiryTypeEnum -} - -enum GiftCardSortField { - """ - Sort gift cards by created at. - - Added in Saleor 3.8. - """ - CREATED_AT - - """Sort gift cards by current balance.""" - CURRENT_BALANCE - - """Sort gift cards by product.""" - PRODUCT - - """Sort gift cards by used by.""" - USED_BY -} - -input GiftCardSortingInput { - """Specifies the direction in which to sort gift cards.""" - direction: OrderDirection! - - """Sort gift cards by the selected field.""" - field: GiftCardSortField! -} - -""" -Event sent when gift card status has changed. - -Added in Saleor 3.2. -""" -type GiftCardStatusChanged implements Event { - """The gift card the event relates to.""" - giftCard: GiftCard - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -The gift card tag. - -Added in Saleor 3.1. -""" -type GiftCardTag implements Node { - """ID of the tag associated with a gift card.""" - id: ID! - - """Name of the tag associated with a gift card.""" - name: String! -} - -type GiftCardTagCountableConnection { - edges: [GiftCardTagCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type GiftCardTagCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: GiftCardTag! -} - -input GiftCardTagFilterInput { - search: String -} - -""" -Update a gift card. - -Requires one of the following permissions: MANAGE_GIFT_CARD. - -Triggers the following webhook events: -- GIFT_CARD_UPDATED (async): A gift card was updated. -""" -type GiftCardUpdate { - errors: [GiftCardError!]! - giftCard: GiftCard - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input GiftCardUpdateInput { - """ - The gift card tags to add. - - Added in Saleor 3.1. - """ - addTags: [String!] - - """ - The gift card balance amount. - - Added in Saleor 3.1. - """ - balanceAmount: PositiveDecimal - - """ - End date of the gift card in ISO 8601 format. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `expiryDate` from `expirySettings` instead. - """ - endDate: Date - - """ - The gift card expiry date. - - Added in Saleor 3.1. - """ - expiryDate: Date - - """ - The gift card tags to remove. - - Added in Saleor 3.1. - """ - removeTags: [String!] - - """ - Start date of the gift card in ISO 8601 format. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - startDate: Date -} - -""" -Event sent when gift card is updated. - -Added in Saleor 3.2. -""" -type GiftCardUpdated implements Event { - """The gift card the event relates to.""" - giftCard: GiftCard - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Define the filtering options for foreign key fields. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -input GlobalIDFilterInput { - """The value equal to.""" - eq: ID - - """The value included in.""" - oneOf: [ID!] -} - -"""Represents permission group data.""" -type Group implements Node { - """ - List of channels the group has access to. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - accessibleChannels: [Channel!] - - """The ID of the group.""" - id: ID! - - """The name of the group.""" - name: String! - - """List of group permissions""" - permissions: [Permission!] - - """ - Determine if the group have restricted access to channels. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - restrictedAccessToChannels: Boolean! - - """ - True, if the currently authenticated user has rights to manage a group. - """ - userCanManage: Boolean! - - """ - List of group users - - Requires one of the following permissions: MANAGE_STAFF. - """ - users: [User!] -} - -type GroupCountableConnection { - edges: [GroupCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type GroupCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Group! -} - -"""Thumbnail formats for icon images.""" -enum IconThumbnailFormatEnum { - ORIGINAL - WEBP -} - -"""Represents an image.""" -type Image { - """Alt text for an image.""" - alt: String - - """The URL of the image.""" - url: String! -} - -input IntRangeInput { - """Value greater than or equal to.""" - gte: Int - - """Value less than or equal to.""" - lte: Int -} - -"""Represents an Invoice.""" -type Invoice implements Job & Node & ObjectWithMetadata { - """Date and time at which invoice was created.""" - createdAt: DateTime! - - """URL to view an invoice.""" - externalUrl: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `url` field.This field will be removed in 4.0") - - """The ID of the object.""" - id: ID! - - """Message associated with an invoice.""" - message: String - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Invoice number.""" - number: String - - """ - Order related to the invoice. - - Added in Saleor 3.10. - """ - order: Order - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Job status.""" - status: JobStatusEnum! - - """Date and time at which invoice was updated.""" - updatedAt: DateTime! - - """ - URL to view/download an invoice. This can be an internal URL if the Invoicing Plugin was used or an external URL if it has been provided. - """ - url: String -} - -""" -Creates a ready to send invoice. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type InvoiceCreate { - errors: [InvoiceError!]! - invoice: Invoice - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input InvoiceCreateInput { - """ - Fields required to update the invoice metadata. - - Added in Saleor 3.14. - """ - metadata: [MetadataInput!] - - """Invoice number.""" - number: String! - - """ - Fields required to update the invoice private metadata. - - Added in Saleor 3.14. - """ - privateMetadata: [MetadataInput!] - - """URL of an invoice to download.""" - url: String! -} - -""" -Deletes an invoice. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type InvoiceDelete { - errors: [InvoiceError!]! - invoice: Invoice - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when invoice is deleted. - -Added in Saleor 3.2. -""" -type InvoiceDeleted implements Event { - """The invoice the event relates to.""" - invoice: Invoice - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """ - Order related to the invoice. - - Added in Saleor 3.10. - """ - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type InvoiceError { - """The error code.""" - code: InvoiceErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum InvoiceErrorCode { - EMAIL_NOT_SET - INVALID_STATUS - NOT_FOUND - NOT_READY - NO_INVOICE_PLUGIN - NUMBER_NOT_SET - REQUIRED - URL_NOT_SET -} - -""" -Request an invoice for the order using plugin. - -Requires one of the following permissions: MANAGE_ORDERS. - -Triggers the following webhook events: -- INVOICE_REQUESTED (async): An invoice was requested. -""" -type InvoiceRequest { - errors: [InvoiceError!]! - invoice: Invoice - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Order related to an invoice.""" - order: Order -} - -""" -Requests deletion of an invoice. - -Requires one of the following permissions: MANAGE_ORDERS. - -Triggers the following webhook events: -- INVOICE_DELETED (async): An invoice was requested to delete. -""" -type InvoiceRequestDelete { - errors: [InvoiceError!]! - invoice: Invoice - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when invoice is requested. - -Added in Saleor 3.2. -""" -type InvoiceRequested implements Event { - """The invoice the event relates to.""" - invoice: Invoice - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """ - Order related to the invoice. - - Added in Saleor 3.10. - """ - order: Order! - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Send an invoice notification to the customer. - -Requires one of the following permissions: MANAGE_ORDERS. - -Triggers the following webhook events: -- INVOICE_SENT (async): A notification for invoice send -- NOTIFY_USER (async): A notification for invoice send -""" -type InvoiceSendNotification { - errors: [InvoiceError!]! - invoice: Invoice - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when invoice is sent. - -Added in Saleor 3.2. -""" -type InvoiceSent implements Event { - """The invoice the event relates to.""" - invoice: Invoice - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """ - Order related to the invoice. - - Added in Saleor 3.10. - """ - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Updates an invoice. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type InvoiceUpdate { - errors: [InvoiceError!]! - invoice: Invoice - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -union IssuingPrincipal = App | User - -scalar JSON - -scalar JSONString - -interface Job { - """Created date time of job in ISO 8601 format.""" - createdAt: DateTime! - - """Job message.""" - message: String - - """Job status.""" - status: JobStatusEnum! - - """Date time of job last update in ISO 8601 format.""" - updatedAt: DateTime! -} - -"""An enumeration.""" -enum JobStatusEnum { - DELETED - FAILED - PENDING - SUCCESS -} - -"""An enumeration.""" -enum LanguageCodeEnum { - AF - AF_NA - AF_ZA - AGQ - AGQ_CM - AK - AK_GH - AM - AM_ET - AR - AR_AE - AR_BH - AR_DJ - AR_DZ - AR_EG - AR_EH - AR_ER - AR_IL - AR_IQ - AR_JO - AR_KM - AR_KW - AR_LB - AR_LY - AR_MA - AR_MR - AR_OM - AR_PS - AR_QA - AR_SA - AR_SD - AR_SO - AR_SS - AR_SY - AR_TD - AR_TN - AR_YE - AS - ASA - ASA_TZ - AST - AST_ES - AS_IN - AZ - AZ_CYRL - AZ_CYRL_AZ - AZ_LATN - AZ_LATN_AZ - BAS - BAS_CM - BE - BEM - BEM_ZM - BEZ - BEZ_TZ - BE_BY - BG - BG_BG - BM - BM_ML - BN - BN_BD - BN_IN - BO - BO_CN - BO_IN - BR - BRX - BRX_IN - BR_FR - BS - BS_CYRL - BS_CYRL_BA - BS_LATN - BS_LATN_BA - CA - CA_AD - CA_ES - CA_ES_VALENCIA - CA_FR - CA_IT - CCP - CCP_BD - CCP_IN - CE - CEB - CEB_PH - CE_RU - CGG - CGG_UG - CHR - CHR_US - CKB - CKB_IQ - CKB_IR - CS - CS_CZ - CU - CU_RU - CY - CY_GB - DA - DAV - DAV_KE - DA_DK - DA_GL - DE - DE_AT - DE_BE - DE_CH - DE_DE - DE_IT - DE_LI - DE_LU - DJE - DJE_NE - DSB - DSB_DE - DUA - DUA_CM - DYO - DYO_SN - DZ - DZ_BT - EBU - EBU_KE - EE - EE_GH - EE_TG - EL - EL_CY - EL_GR - EN - EN_AE - EN_AG - EN_AI - EN_AS - EN_AT - EN_AU - EN_BB - EN_BE - EN_BI - EN_BM - EN_BS - EN_BW - EN_BZ - EN_CA - EN_CC - EN_CH - EN_CK - EN_CM - EN_CX - EN_CY - EN_DE - EN_DG - EN_DK - EN_DM - EN_ER - EN_FI - EN_FJ - EN_FK - EN_FM - EN_GB - EN_GD - EN_GG - EN_GH - EN_GI - EN_GM - EN_GU - EN_GY - EN_HK - EN_IE - EN_IL - EN_IM - EN_IN - EN_IO - EN_JE - EN_JM - EN_KE - EN_KI - EN_KN - EN_KY - EN_LC - EN_LR - EN_LS - EN_MG - EN_MH - EN_MO - EN_MP - EN_MS - EN_MT - EN_MU - EN_MW - EN_MY - EN_NA - EN_NF - EN_NG - EN_NL - EN_NR - EN_NU - EN_NZ - EN_PG - EN_PH - EN_PK - EN_PN - EN_PR - EN_PW - EN_RW - EN_SB - EN_SC - EN_SD - EN_SE - EN_SG - EN_SH - EN_SI - EN_SL - EN_SS - EN_SX - EN_SZ - EN_TC - EN_TK - EN_TO - EN_TT - EN_TV - EN_TZ - EN_UG - EN_UM - EN_US - EN_VC - EN_VG - EN_VI - EN_VU - EN_WS - EN_ZA - EN_ZM - EN_ZW - EO - ES - ES_AR - ES_BO - ES_BR - ES_BZ - ES_CL - ES_CO - ES_CR - ES_CU - ES_DO - ES_EA - ES_EC - ES_ES - ES_GQ - ES_GT - ES_HN - ES_IC - ES_MX - ES_NI - ES_PA - ES_PE - ES_PH - ES_PR - ES_PY - ES_SV - ES_US - ES_UY - ES_VE - ET - ET_EE - EU - EU_ES - EWO - EWO_CM - FA - FA_AF - FA_IR - FF - FF_ADLM - FF_ADLM_BF - FF_ADLM_CM - FF_ADLM_GH - FF_ADLM_GM - FF_ADLM_GN - FF_ADLM_GW - FF_ADLM_LR - FF_ADLM_MR - FF_ADLM_NE - FF_ADLM_NG - FF_ADLM_SL - FF_ADLM_SN - FF_LATN - FF_LATN_BF - FF_LATN_CM - FF_LATN_GH - FF_LATN_GM - FF_LATN_GN - FF_LATN_GW - FF_LATN_LR - FF_LATN_MR - FF_LATN_NE - FF_LATN_NG - FF_LATN_SL - FF_LATN_SN - FI - FIL - FIL_PH - FI_FI - FO - FO_DK - FO_FO - FR - FR_BE - FR_BF - FR_BI - FR_BJ - FR_BL - FR_CA - FR_CD - FR_CF - FR_CG - FR_CH - FR_CI - FR_CM - FR_DJ - FR_DZ - FR_FR - FR_GA - FR_GF - FR_GN - FR_GP - FR_GQ - FR_HT - FR_KM - FR_LU - FR_MA - FR_MC - FR_MF - FR_MG - FR_ML - FR_MQ - FR_MR - FR_MU - FR_NC - FR_NE - FR_PF - FR_PM - FR_RE - FR_RW - FR_SC - FR_SN - FR_SY - FR_TD - FR_TG - FR_TN - FR_VU - FR_WF - FR_YT - FUR - FUR_IT - FY - FY_NL - GA - GA_GB - GA_IE - GD - GD_GB - GL - GL_ES - GSW - GSW_CH - GSW_FR - GSW_LI - GU - GUZ - GUZ_KE - GU_IN - GV - GV_IM - HA - HAW - HAW_US - HA_GH - HA_NE - HA_NG - HE - HE_IL - HI - HI_IN - HR - HR_BA - HR_HR - HSB - HSB_DE - HU - HU_HU - HY - HY_AM - IA - ID - ID_ID - IG - IG_NG - II - II_CN - IS - IS_IS - IT - IT_CH - IT_IT - IT_SM - IT_VA - JA - JA_JP - JGO - JGO_CM - JMC - JMC_TZ - JV - JV_ID - KA - KAB - KAB_DZ - KAM - KAM_KE - KA_GE - KDE - KDE_TZ - KEA - KEA_CV - KHQ - KHQ_ML - KI - KI_KE - KK - KKJ - KKJ_CM - KK_KZ - KL - KLN - KLN_KE - KL_GL - KM - KM_KH - KN - KN_IN - KO - KOK - KOK_IN - KO_KP - KO_KR - KS - KSB - KSB_TZ - KSF - KSF_CM - KSH - KSH_DE - KS_ARAB - KS_ARAB_IN - KU - KU_TR - KW - KW_GB - KY - KY_KG - LAG - LAG_TZ - LB - LB_LU - LG - LG_UG - LKT - LKT_US - LN - LN_AO - LN_CD - LN_CF - LN_CG - LO - LO_LA - LRC - LRC_IQ - LRC_IR - LT - LT_LT - LU - LUO - LUO_KE - LUY - LUY_KE - LU_CD - LV - LV_LV - MAI - MAI_IN - MAS - MAS_KE - MAS_TZ - MER - MER_KE - MFE - MFE_MU - MG - MGH - MGH_MZ - MGO - MGO_CM - MG_MG - MI - MI_NZ - MK - MK_MK - ML - ML_IN - MN - MNI - MNI_BENG - MNI_BENG_IN - MN_MN - MR - MR_IN - MS - MS_BN - MS_ID - MS_MY - MS_SG - MT - MT_MT - MUA - MUA_CM - MY - MY_MM - MZN - MZN_IR - NAQ - NAQ_NA - NB - NB_NO - NB_SJ - ND - NDS - NDS_DE - NDS_NL - ND_ZW - NE - NE_IN - NE_NP - NL - NL_AW - NL_BE - NL_BQ - NL_CW - NL_NL - NL_SR - NL_SX - NMG - NMG_CM - NN - NNH - NNH_CM - NN_NO - NUS - NUS_SS - NYN - NYN_UG - OM - OM_ET - OM_KE - OR - OR_IN - OS - OS_GE - OS_RU - PA - PA_ARAB - PA_ARAB_PK - PA_GURU - PA_GURU_IN - PCM - PCM_NG - PL - PL_PL - PRG - PS - PS_AF - PS_PK - PT - PT_AO - PT_BR - PT_CH - PT_CV - PT_GQ - PT_GW - PT_LU - PT_MO - PT_MZ - PT_PT - PT_ST - PT_TL - QU - QU_BO - QU_EC - QU_PE - RM - RM_CH - RN - RN_BI - RO - ROF - ROF_TZ - RO_MD - RO_RO - RU - RU_BY - RU_KG - RU_KZ - RU_MD - RU_RU - RU_UA - RW - RWK - RWK_TZ - RW_RW - SAH - SAH_RU - SAQ - SAQ_KE - SAT - SAT_OLCK - SAT_OLCK_IN - SBP - SBP_TZ - SD - SD_ARAB - SD_ARAB_PK - SD_DEVA - SD_DEVA_IN - SE - SEH - SEH_MZ - SES - SES_ML - SE_FI - SE_NO - SE_SE - SG - SG_CF - SHI - SHI_LATN - SHI_LATN_MA - SHI_TFNG - SHI_TFNG_MA - SI - SI_LK - SK - SK_SK - SL - SL_SI - SMN - SMN_FI - SN - SN_ZW - SO - SO_DJ - SO_ET - SO_KE - SO_SO - SQ - SQ_AL - SQ_MK - SQ_XK - SR - SR_CYRL - SR_CYRL_BA - SR_CYRL_ME - SR_CYRL_RS - SR_CYRL_XK - SR_LATN - SR_LATN_BA - SR_LATN_ME - SR_LATN_RS - SR_LATN_XK - SU - SU_LATN - SU_LATN_ID - SV - SV_AX - SV_FI - SV_SE - SW - SW_CD - SW_KE - SW_TZ - SW_UG - TA - TA_IN - TA_LK - TA_MY - TA_SG - TE - TEO - TEO_KE - TEO_UG - TE_IN - TG - TG_TJ - TH - TH_TH - TI - TI_ER - TI_ET - TK - TK_TM - TO - TO_TO - TR - TR_CY - TR_TR - TT - TT_RU - TWQ - TWQ_NE - TZM - TZM_MA - UG - UG_CN - UK - UK_UA - UR - UR_IN - UR_PK - UZ - UZ_ARAB - UZ_ARAB_AF - UZ_CYRL - UZ_CYRL_UZ - UZ_LATN - UZ_LATN_UZ - VAI - VAI_LATN - VAI_LATN_LR - VAI_VAII - VAI_VAII_LR - VI - VI_VN - VO - VUN - VUN_TZ - WAE - WAE_CH - WO - WO_SN - XH - XH_ZA - XOG - XOG_UG - YAV - YAV_CM - YI - YO - YO_BJ - YO_NG - YUE - YUE_HANS - YUE_HANS_CN - YUE_HANT - YUE_HANT_HK - ZGH - ZGH_MA - ZH - ZH_HANS - ZH_HANS_CN - ZH_HANS_HK - ZH_HANS_MO - ZH_HANS_SG - ZH_HANT - ZH_HANT_HK - ZH_HANT_MO - ZH_HANT_TW - ZU - ZU_ZA -} - -type LanguageDisplay { - """ISO 639 representation of the language name.""" - code: LanguageCodeEnum! - - """Full name of the language.""" - language: String! -} - -"""Store the current and allowed usage.""" -type LimitInfo { - """Defines the allowed maximum resource usage, null means unlimited.""" - allowedUsage: Limits! - - """Defines the current resource usage.""" - currentUsage: Limits! -} - -type Limits { - """Defines the number of channels.""" - channels: Int - - """Defines the number of order.""" - orders: Int - - """Defines the number of product variants.""" - productVariants: Int - - """Defines the number of staff users.""" - staffUsers: Int - - """Defines the number of warehouses.""" - warehouses: Int -} - -""" -List payment methods stored for the user by payment gateway. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type ListStoredPaymentMethods implements Event { - """ - Channel in context which was used to fetch the list of payment methods. - """ - channel: Channel! - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user for which the app should return a list of payment methods.""" - user: User! - - """Saleor version that triggered the event.""" - version: String -} - -"""The manifest definition.""" -type Manifest { - """Description of the app displayed in the dashboard.""" - about: String - - """App website rendered in the dashboard.""" - appUrl: String - - """ - The audience that will be included in all JWT tokens for the app. - - Added in Saleor 3.8. - """ - audience: String - - """ - The App's author name. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - author: String - - """ - App's brand data. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - brand: AppManifestBrand - - """URL to iframe with the configuration for the app.""" - configurationUrl: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `appUrl` instead.") - - """Description of the data privacy defined for this app.""" - dataPrivacy: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `dataPrivacyUrl` instead.") - - """URL to the full privacy policy.""" - dataPrivacyUrl: String - - """ - List of extensions that will be mounted in Saleor's dashboard. For details, please [see the extension section.](https://docs.saleor.io/docs/3.x/developer/extending/apps/extending-dashboard-with-apps#key-concepts) - """ - extensions: [AppManifestExtension!]! - - """External URL to the app homepage.""" - homepageUrl: String - - """The identifier of the manifest for the app.""" - identifier: String! - - """The name of the manifest for the app .""" - name: String! - - """The array permissions required for the app.""" - permissions: [Permission!] - - """ - Determines the app's required Saleor version as semver range. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - requiredSaleorVersion: AppManifestRequiredSaleorVersion - - """External URL to the page where app users can find support.""" - supportUrl: String - - """ - Endpoint used during process of app installation, [see installing an app.](https://docs.saleor.io/docs/3.x/developer/extending/apps/installing-apps#installing-an-app) - """ - tokenTargetUrl: String - - """The version of the manifest for the app.""" - version: String! - - """ - List of the app's webhooks. - - Added in Saleor 3.5. - """ - webhooks: [AppManifestWebhook!]! -} - -"""Metadata for the Margin class.""" -type Margin { - """The starting value of the margin.""" - start: Int - - """The ending value of the margin.""" - stop: Int -} - -""" -Determine the mark as paid strategy for the channel. - - TRANSACTION_FLOW - new orders marked as paid will receive a - `TransactionItem` object, that will cover the `order.total`. - - PAYMENT_FLOW - new orders marked as paid will receive a - `Payment` object, that will cover the `order.total`. -""" -enum MarkAsPaidStrategyEnum { - PAYMENT_FLOW - TRANSACTION_FLOW -} - -"""An enumeration.""" -enum MeasurementUnitsEnum { - ACRE_FT - ACRE_IN - CM - CUBIC_CENTIMETER - CUBIC_DECIMETER - CUBIC_FOOT - CUBIC_INCH - CUBIC_METER - CUBIC_MILLIMETER - CUBIC_YARD - DM - FL_OZ - FT - G - INCH - KG - KM - LB - LITER - M - MM - OZ - PINT - QT - SQ_CM - SQ_DM - SQ_FT - SQ_INCH - SQ_KM - SQ_M - SQ_MM - SQ_YD - TONNE - YD -} - -input MeasurementUnitsEnumFilterInput { - """The value equal to.""" - eq: MeasurementUnitsEnum - - """The value included in.""" - oneOf: [MeasurementUnitsEnum!] -} - -enum MediaChoicesSortField { - """Sort media by ID.""" - ID -} - -input MediaInput { - """Alt text for a product media.""" - alt: String - - """Represents an image file in a multipart request.""" - image: Upload - - """Represents an URL to an external media.""" - mediaUrl: String -} - -input MediaSortingInput { - """Specifies the direction in which to sort media.""" - direction: OrderDirection! - - """Sort media by the selected field.""" - field: MediaChoicesSortField! -} - -""" -Represents a single menu - an object that is used to help navigate through the store. -""" -type Menu implements Node & ObjectWithMetadata { - """The ID of the menu.""" - id: ID! - - """Menu items associated with this menu.""" - items: [MenuItem!] - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """The name of the menu.""" - name: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Slug of the menu.""" - slug: String! -} - -""" -Deletes menus. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_DELETED (async): A menu was deleted. -""" -type MenuBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [MenuError!]! - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type MenuCountableConnection { - edges: [MenuCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type MenuCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Menu! -} - -""" -Creates a new Menu. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_CREATED (async): A menu was created. -""" -type MenuCreate { - errors: [MenuError!]! - menu: Menu - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input MenuCreateInput { - """List of menu items.""" - items: [MenuItemInput!] - - """Name of the menu.""" - name: String! - - """Slug of the menu. Will be generated if not provided.""" - slug: String -} - -""" -Event sent when new menu is created. - -Added in Saleor 3.4. -""" -type MenuCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The menu the event relates to.""" - menu( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Menu - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a menu. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_DELETED (async): A menu was deleted. -""" -type MenuDelete { - errors: [MenuError!]! - menu: Menu - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when menu is deleted. - -Added in Saleor 3.4. -""" -type MenuDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The menu the event relates to.""" - menu( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Menu - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type MenuError { - """The error code.""" - code: MenuErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum MenuErrorCode { - CANNOT_ASSIGN_NODE - GRAPHQL_ERROR - INVALID - INVALID_MENU_ITEM - NOT_FOUND - NO_MENU_ITEM_PROVIDED - REQUIRED - TOO_MANY_MENU_ITEMS - UNIQUE -} - -input MenuFilterInput { - metadata: [MetadataFilter!] - search: String - slug: [String!] - slugs: [String!] -} - -input MenuInput { - """Name of the menu.""" - name: String - - """Slug of the menu.""" - slug: String -} - -""" -Represents a single item of the related menu. Can store categories, collection or pages. -""" -type MenuItem implements Node & ObjectWithMetadata { - """Category associated with the menu item.""" - category: Category - - """Represents the child items of the current menu item.""" - children: [MenuItem!] - - """ - A collection associated with this menu item. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - collection: Collection - - """The ID of the menu item.""" - id: ID! - - """Indicates the position of the menu item within the menu structure.""" - level: Int! - - """Represents the menu to which the menu item belongs.""" - menu: Menu! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """The name of the menu item.""" - name: String! - - """ - A page associated with this menu item. Requires one of the following permissions to include unpublished items: MANAGE_PAGES. - """ - page: Page - - """ID of parent menu item. If empty, menu will be top level menu.""" - parent: MenuItem - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Returns translated menu item fields for the given language code.""" - translation( - """A language code to return the translation for menu item.""" - languageCode: LanguageCodeEnum! - ): MenuItemTranslation - - """URL to the menu item.""" - url: String -} - -""" -Deletes menu items. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_ITEM_DELETED (async): A menu item was deleted. -""" -type MenuItemBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [MenuError!]! - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type MenuItemCountableConnection { - edges: [MenuItemCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type MenuItemCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: MenuItem! -} - -""" -Creates a new menu item. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_ITEM_CREATED (async): A menu item was created. -""" -type MenuItemCreate { - errors: [MenuError!]! - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - menuItem: MenuItem -} - -input MenuItemCreateInput { - """Category to which item points.""" - category: ID - - """Collection to which item points.""" - collection: ID - - """Menu to which item belongs.""" - menu: ID! - - """Name of the menu item.""" - name: String! - - """Page to which item points.""" - page: ID - - """ID of the parent menu. If empty, menu will be top level menu.""" - parent: ID - - """URL of the pointed item.""" - url: String -} - -""" -Event sent when new menu item is created. - -Added in Saleor 3.4. -""" -type MenuItemCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The menu item the event relates to.""" - menuItem( - """Slug of a channel for which the data should be returned.""" - channel: String - ): MenuItem - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a menu item. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_ITEM_DELETED (async): A menu item was deleted. -""" -type MenuItemDelete { - errors: [MenuError!]! - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - menuItem: MenuItem -} - -""" -Event sent when menu item is deleted. - -Added in Saleor 3.4. -""" -type MenuItemDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The menu item the event relates to.""" - menuItem( - """Slug of a channel for which the data should be returned.""" - channel: String - ): MenuItem - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input MenuItemFilterInput { - metadata: [MetadataFilter!] - search: String -} - -input MenuItemInput { - """Category to which item points.""" - category: ID - - """Collection to which item points.""" - collection: ID - - """Name of the menu item.""" - name: String - - """Page to which item points.""" - page: ID - - """URL of the pointed item.""" - url: String -} - -""" -Moves items of menus. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_ITEM_UPDATED (async): Optionally triggered when sort order or parent changed for menu item. -""" -type MenuItemMove { - errors: [MenuError!]! - - """Assigned menu to move within.""" - menu: Menu - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input MenuItemMoveInput { - """The menu item ID to move.""" - itemId: ID! - - """ID of the parent menu. If empty, menu will be top level menu.""" - parentId: ID - - """ - The new relative sorting position of the item (from -inf to +inf). 1 moves the item one position forward, -1 moves the item one position backward, 0 leaves the item unchanged. - """ - sortOrder: Int -} - -input MenuItemSortingInput { - """Specifies the direction in which to sort menu items.""" - direction: OrderDirection! - - """Sort menu items by the selected field.""" - field: MenuItemsSortField! -} - -""" -Represents menu item's original translatable fields and related translations. -""" -type MenuItemTranslatableContent implements Node { - """The ID of the menu item translatable content.""" - id: ID! - - """ - Represents a single item of the related menu. Can store categories, collection or pages. - """ - menuItem: MenuItem @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the menu item to translate. - - Added in Saleor 3.14. - """ - menuItemId: ID! - - """Name of the menu item to translate.""" - name: String! - - """Returns translated menu item fields for the given language code.""" - translation( - """A language code to return the translation for menu item.""" - languageCode: LanguageCodeEnum! - ): MenuItemTranslation -} - -""" -Creates/updates translations for a menu item. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type MenuItemTranslate { - errors: [TranslationError!]! - menuItem: MenuItem - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""Represents menu item translations.""" -type MenuItemTranslation implements Node { - """The ID of the menu item translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated menu item name.""" - name: String! - - """ - Represents the menu item fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: MenuItemTranslatableContent -} - -""" -Updates a menu item. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_ITEM_UPDATED (async): A menu item was updated. -""" -type MenuItemUpdate { - errors: [MenuError!]! - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - menuItem: MenuItem -} - -""" -Event sent when menu item is updated. - -Added in Saleor 3.4. -""" -type MenuItemUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The menu item the event relates to.""" - menuItem( - """Slug of a channel for which the data should be returned.""" - channel: String - ): MenuItem - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -enum MenuItemsSortField { - """Sort menu items by name.""" - NAME -} - -enum MenuSortField { - """Sort menus by items count.""" - ITEMS_COUNT - - """Sort menus by name.""" - NAME -} - -input MenuSortingInput { - """Specifies the direction in which to sort menus.""" - direction: OrderDirection! - - """Sort menus by the selected field.""" - field: MenuSortField! -} - -""" -Updates a menu. - -Requires one of the following permissions: MANAGE_MENUS. - -Triggers the following webhook events: -- MENU_UPDATED (async): A menu was updated. -""" -type MenuUpdate { - errors: [MenuError!]! - menu: Menu - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when menu is updated. - -Added in Saleor 3.4. -""" -type MenuUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The menu the event relates to.""" - menu( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Menu - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Metadata is a map of key-value pairs, both keys and values are `String`. - -Example: -``` -{ - "key1": "value1", - "key2": "value2" -} -``` -""" -scalar Metadata - -type MetadataError { - """The error code.""" - code: MetadataErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum MetadataErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - NOT_UPDATED - REQUIRED -} - -input MetadataFilter { - """Key of a metadata item.""" - key: String! - - """Value of a metadata item.""" - value: String -} - -input MetadataInput { - """Key of a metadata item.""" - key: String! - - """Value of a metadata item.""" - value: String! -} - -type MetadataItem { - """Key of a metadata item.""" - key: String! - - """Value of a metadata item.""" - value: String! -} - -""" -The `Minute` scalar type represents number of minutes by integer value. -""" -scalar Minute - -"""Represents amount of money in specific currency.""" -type Money { - """Amount of money.""" - amount: Float! - - """Currency code.""" - currency: String! -} - -input MoneyInput { - """Amount of money.""" - amount: PositiveDecimal! - - """Currency code.""" - currency: String! -} - -"""Represents a range of amounts of money.""" -type MoneyRange { - """Lower bound of a price range.""" - start: Money - - """Upper bound of a price range.""" - stop: Money -} - -input MoveProductInput { - """The ID of the product to move.""" - productId: ID! - - """ - The relative sorting position of the product (from -inf to +inf) starting from the first given product's actual position.1 moves the item one position forward, -1 moves the item one position backward, 0 leaves the item unchanged. - """ - sortOrder: Int -} - -type Mutation { - """ - Create a new address for the customer. - - Requires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER. - - Triggers the following webhook events: - - CUSTOMER_UPDATED (async): A customer account was updated. - - ADDRESS_CREATED (async): An address was created. - """ - accountAddressCreate( - """ - ID of customer the application is impersonating. The field can be used and is required by apps only. Requires IMPERSONATE_USER and AUTHENTICATED_APP permission. - - Added in Saleor 3.19. - """ - customerId: ID - - """Fields required to create address.""" - input: AddressInput! - - """ - A type of address. If provided, the new address will be automatically assigned as the customer's default address of that type. - """ - type: AddressTypeEnum - ): AccountAddressCreate - - """ - Delete an address of the logged-in user. Requires one of the following permissions: MANAGE_USERS, IS_OWNER. - - Triggers the following webhook events: - - ADDRESS_DELETED (async): An address was deleted. - """ - accountAddressDelete( - """ID of the address to delete.""" - id: ID! - ): AccountAddressDelete - - """ - Updates an address of the logged-in user. Requires one of the following permissions: MANAGE_USERS, IS_OWNER. - - Triggers the following webhook events: - - ADDRESS_UPDATED (async): An address was updated. - """ - accountAddressUpdate( - """ID of the address to update.""" - id: ID! - - """Fields required to update the address.""" - input: AddressInput! - ): AccountAddressUpdate - - """ - Remove user account. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - ACCOUNT_DELETED (async): Account was deleted. - """ - accountDelete( - """ - A one-time token required to remove account. Sent by email using AccountRequestDeletion mutation. - """ - token: String! - ): AccountDelete - - """ - Register a new user. - - Triggers the following webhook events: - - CUSTOMER_CREATED (async): A new customer account was created. - - NOTIFY_USER (async): A notification for account confirmation. - - ACCOUNT_CONFIRMATION_REQUESTED (async): An user confirmation was requested. This event is always sent regardless of settings. - """ - accountRegister( - """Fields required to create a user.""" - input: AccountRegisterInput! - ): AccountRegister - - """ - Sends an email with the account removal link for the logged-in user. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - NOTIFY_USER (async): A notification for account delete request. - - ACCOUNT_DELETE_REQUESTED (async): An account delete requested. - """ - accountRequestDeletion( - """ - Slug of a channel which will be used to notify users. Optional when only one channel exists. - """ - channel: String - - """ - URL of a view where users should be redirected to delete their account. URL in RFC 1808 format. - """ - redirectUrl: String! - ): AccountRequestDeletion - - """ - Sets a default address for the authenticated user. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - CUSTOMER_UPDATED (async): A customer's address was updated. - """ - accountSetDefaultAddress( - """ID of the address to set as default.""" - id: ID! - - """The type of address.""" - type: AddressTypeEnum! - ): AccountSetDefaultAddress - - """ - Updates the account of the logged-in user. - - Requires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER. - - Triggers the following webhook events: - - CUSTOMER_UPDATED (async): A customer account was updated. - - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. - """ - accountUpdate( - """ - ID of customer the application is impersonating. The field can be used and is required by apps only. Requires IMPERSONATE_USER and AUTHENTICATED_APP permission. - - Added in Saleor 3.19. - """ - customerId: ID - - """Fields required to update the account of the logged-in user.""" - input: AccountInput! - ): AccountUpdate - - """ - Creates user address. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - ADDRESS_CREATED (async): A new address was created. - """ - addressCreate( - """Fields required to create address.""" - input: AddressInput! - - """ID of a user to create address for.""" - userId: ID! - ): AddressCreate - - """ - Deletes an address. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - ADDRESS_DELETED (async): An address was deleted. - """ - addressDelete( - """ID of the address to delete.""" - id: ID! - ): AddressDelete - - """ - Sets a default address for the given user. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - CUSTOMER_UPDATED (async): A customer was updated. - """ - addressSetDefault( - """ID of the address.""" - addressId: ID! - - """The type of address.""" - type: AddressTypeEnum! - - """ID of the user to change the address for.""" - userId: ID! - ): AddressSetDefault - - """ - Updates an address. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - ADDRESS_UPDATED (async): An address was updated. - """ - addressUpdate( - """ID of the address to update.""" - id: ID! - - """Fields required to update the address.""" - input: AddressInput! - ): AddressUpdate - - """ - Activate the app. - - Requires one of the following permissions: MANAGE_APPS. - - Triggers the following webhook events: - - APP_STATUS_CHANGED (async): An app was activated. - """ - appActivate( - """ID of app to activate.""" - id: ID! - ): AppActivate - - """ - Creates a new app. Requires the following permissions: AUTHENTICATED_STAFF_USER and MANAGE_APPS. - - Triggers the following webhook events: - - APP_INSTALLED (async): An app was installed. - """ - appCreate( - """Fields required to create a new app.""" - input: AppInput! - ): AppCreate - - """ - Deactivate the app. - - Requires one of the following permissions: MANAGE_APPS. - - Triggers the following webhook events: - - APP_STATUS_CHANGED (async): An app was deactivated. - """ - appDeactivate( - """ID of app to deactivate.""" - id: ID! - ): AppDeactivate - - """ - Deletes an app. - - Requires one of the following permissions: MANAGE_APPS. - - Triggers the following webhook events: - - APP_DELETED (async): An app was deleted. - """ - appDelete( - """ID of an app to delete.""" - id: ID! - ): AppDelete - - """ - Delete failed installation. - - Requires one of the following permissions: MANAGE_APPS. - """ - appDeleteFailedInstallation( - """ID of failed installation to delete.""" - id: ID! - ): AppDeleteFailedInstallation - - """ - Fetch and validate manifest. - - Requires one of the following permissions: MANAGE_APPS. - """ - appFetchManifest( - """URL to app's manifest in JSON format.""" - manifestUrl: String! - ): AppFetchManifest - - """ - Install new app by using app manifest. Requires the following permissions: AUTHENTICATED_STAFF_USER and MANAGE_APPS. - """ - appInstall( - """Fields required to install a new app.""" - input: AppInstallInput! - ): AppInstall - - """ - Retry failed installation of new app. - - Requires one of the following permissions: MANAGE_APPS. - - Triggers the following webhook events: - - APP_INSTALLED (async): An app was installed. - """ - appRetryInstall( - """Determine if app will be set active or not.""" - activateAfterInstallation: Boolean = true - - """ID of failed installation.""" - id: ID! - ): AppRetryInstall - - """ - Creates a new token. - - Requires one of the following permissions: MANAGE_APPS. - """ - appTokenCreate( - """Fields required to create a new auth token.""" - input: AppTokenInput! - ): AppTokenCreate - - """ - Deletes an authentication token assigned to app. - - Requires one of the following permissions: MANAGE_APPS. - """ - appTokenDelete( - """ID of an auth token to delete.""" - id: ID! - ): AppTokenDelete - - """Verify provided app token.""" - appTokenVerify( - """App token to verify.""" - token: String! - ): AppTokenVerify - - """ - Updates an existing app. - - Requires one of the following permissions: MANAGE_APPS. - - Triggers the following webhook events: - - APP_UPDATED (async): An app was updated. - """ - appUpdate( - """ID of an app to update.""" - id: ID! - - """Fields required to update an existing app.""" - input: AppInput! - ): AppUpdate - - """ - Assigns storefront's navigation menus. - - Requires one of the following permissions: MANAGE_MENUS, MANAGE_SETTINGS. - """ - assignNavigation( - """ID of the menu.""" - menu: ID - - """Type of the navigation bar to assign the menu to.""" - navigationType: NavigationType! - ): AssignNavigation - - """ - Add shipping zone to given warehouse. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - assignWarehouseShippingZone( - """ID of a warehouse to update.""" - id: ID! - - """List of shipping zone IDs.""" - shippingZoneIds: [ID!]! - ): WarehouseShippingZoneAssign - - """ - Creates attributes. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Triggers the following webhook events: - - ATTRIBUTE_CREATED (async): An attribute was created. - """ - attributeBulkCreate( - """Input list of attributes to create.""" - attributes: [AttributeCreateInput!]! - - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - ): AttributeBulkCreate - - """ - Deletes attributes. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - - Triggers the following webhook events: - - ATTRIBUTE_DELETED (async): An attribute was deleted. - """ - attributeBulkDelete( - """List of attribute IDs to delete.""" - ids: [ID!]! - ): AttributeBulkDelete - - """ - Creates/updates translations for attributes. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - attributeBulkTranslate( - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - - """List of attributes translations.""" - translations: [AttributeBulkTranslateInput!]! - ): AttributeBulkTranslate - - """ - Updates attributes. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Triggers the following webhook events: - - ATTRIBUTE_UPDATED (async): An attribute was updated. Optionally called when new attribute value was created or deleted. - - ATTRIBUTE_VALUE_CREATED (async): Called optionally when an attribute value was created. - - ATTRIBUTE_VALUE_DELETED (async): Called optionally when an attribute value was deleted. - """ - attributeBulkUpdate( - """Input list of attributes to update.""" - attributes: [AttributeBulkUpdateInput!]! - - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - ): AttributeBulkUpdate - - """ - Creates an attribute. - - Triggers the following webhook events: - - ATTRIBUTE_CREATED (async): An attribute was created. - """ - attributeCreate( - """Fields required to create an attribute.""" - input: AttributeCreateInput! - ): AttributeCreate - - """ - Deletes an attribute. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - - Triggers the following webhook events: - - ATTRIBUTE_DELETED (async): An attribute was deleted. - """ - attributeDelete( - """ - External ID of an attribute to delete. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of an attribute to delete.""" - id: ID - ): AttributeDelete - - """ - Reorder the values of an attribute. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - - Triggers the following webhook events: - - ATTRIBUTE_VALUE_UPDATED (async): An attribute value was updated. - - ATTRIBUTE_UPDATED (async): An attribute was updated. - """ - attributeReorderValues( - """ID of an attribute.""" - attributeId: ID! - - """The list of reordering operations for given attribute values.""" - moves: [ReorderInput!]! - ): AttributeReorderValues - - """ - Creates/updates translations for an attribute. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - attributeTranslate( - """Attribute ID or AttributeTranslatableContent ID.""" - id: ID! - - """Fields required to update attribute translations.""" - input: NameTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): AttributeTranslate - - """ - Updates attribute. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - - Triggers the following webhook events: - - ATTRIBUTE_UPDATED (async): An attribute was updated. - """ - attributeUpdate( - """ - External ID of an attribute to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of an attribute to update.""" - id: ID - - """Fields required to update an attribute.""" - input: AttributeUpdateInput! - ): AttributeUpdate - - """ - Deletes values of attributes. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - - Triggers the following webhook events: - - ATTRIBUTE_VALUE_DELETED (async): An attribute value was deleted. - - ATTRIBUTE_UPDATED (async): An attribute was updated. - """ - attributeValueBulkDelete( - """List of attribute value IDs to delete.""" - ids: [ID!]! - ): AttributeValueBulkDelete - - """ - Creates/updates translations for attributes values. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - attributeValueBulkTranslate( - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - - """List of attribute values translations.""" - translations: [AttributeValueBulkTranslateInput!]! - ): AttributeValueBulkTranslate - - """ - Creates a value for an attribute. - - Requires one of the following permissions: MANAGE_PRODUCTS. - - Triggers the following webhook events: - - ATTRIBUTE_VALUE_CREATED (async): An attribute value was created. - - ATTRIBUTE_UPDATED (async): An attribute was updated. - """ - attributeValueCreate( - """Attribute to which value will be assigned.""" - attribute: ID! - - """Fields required to create an AttributeValue.""" - input: AttributeValueCreateInput! - ): AttributeValueCreate - - """ - Deletes a value of an attribute. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - - Triggers the following webhook events: - - ATTRIBUTE_VALUE_DELETED (async): An attribute value was deleted. - - ATTRIBUTE_UPDATED (async): An attribute was updated. - """ - attributeValueDelete( - """ - External ID of a value to delete. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a value to delete.""" - id: ID - ): AttributeValueDelete - - """ - Creates/updates translations for an attribute value. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - attributeValueTranslate( - """AttributeValue ID or AttributeValueTranslatableContent ID.""" - id: ID! - - """Fields required to update attribute value translations.""" - input: AttributeValueTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): AttributeValueTranslate - - """ - Updates value of an attribute. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - - Triggers the following webhook events: - - ATTRIBUTE_VALUE_UPDATED (async): An attribute value was updated. - - ATTRIBUTE_UPDATED (async): An attribute was updated. - """ - attributeValueUpdate( - """ - External ID of an AttributeValue to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of an AttributeValue to update.""" - id: ID - - """Fields required to update an AttributeValue.""" - input: AttributeValueUpdateInput! - ): AttributeValueUpdate - - """ - Deletes categories. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - categoryBulkDelete( - """List of category IDs to delete.""" - ids: [ID!]! - ): CategoryBulkDelete - - """ - Creates a new category. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - categoryCreate( - """Fields required to create a category.""" - input: CategoryInput! - - """ - ID of the parent category. If empty, category will be top level category. - """ - parent: ID - ): CategoryCreate - - """ - Deletes a category. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - categoryDelete( - """ID of a category to delete.""" - id: ID! - ): CategoryDelete - - """ - Creates/updates translations for a category. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - categoryTranslate( - """Category ID or CategoryTranslatableContent ID.""" - id: ID! - - """Fields required to update category translations.""" - input: TranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): CategoryTranslate - - """ - Updates a category. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - categoryUpdate( - """ID of a category to update.""" - id: ID! - - """Fields required to update a category.""" - input: CategoryInput! - ): CategoryUpdate - - """ - Activate a channel. - - Requires one of the following permissions: MANAGE_CHANNELS. - - Triggers the following webhook events: - - CHANNEL_STATUS_CHANGED (async): A channel was activated. - """ - channelActivate( - """ID of the channel to activate.""" - id: ID! - ): ChannelActivate - - """ - Creates new channel. - - Requires one of the following permissions: MANAGE_CHANNELS. - - Triggers the following webhook events: - - CHANNEL_CREATED (async): A channel was created. - """ - channelCreate( - """Fields required to create channel.""" - input: ChannelCreateInput! - ): ChannelCreate - - """ - Deactivate a channel. - - Requires one of the following permissions: MANAGE_CHANNELS. - - Triggers the following webhook events: - - CHANNEL_STATUS_CHANGED (async): A channel was deactivated. - """ - channelDeactivate( - """ID of the channel to deactivate.""" - id: ID! - ): ChannelDeactivate - - """ - Delete a channel. Orders associated with the deleted channel will be moved to the target channel. Checkouts, product availability, and pricing will be removed. - - Requires one of the following permissions: MANAGE_CHANNELS. - - Triggers the following webhook events: - - CHANNEL_DELETED (async): A channel was deleted. - """ - channelDelete( - """ID of a channel to delete.""" - id: ID! - - """Fields required to delete a channel.""" - input: ChannelDeleteInput - ): ChannelDelete - - """ - Reorder the warehouses of a channel. - - Added in Saleor 3.7. - - Requires one of the following permissions: MANAGE_CHANNELS. - """ - channelReorderWarehouses( - """ID of a channel.""" - channelId: ID! - - """The list of reordering operations for the given channel warehouses.""" - moves: [ReorderInput!]! - ): ChannelReorderWarehouses - - """ - Update a channel. - - Requires one of the following permissions: MANAGE_CHANNELS. - Requires one of the following permissions when updating only `orderSettings` field: `MANAGE_CHANNELS`, `MANAGE_ORDERS`. - Requires one of the following permissions when updating only `checkoutSettings` field: `MANAGE_CHANNELS`, `MANAGE_CHECKOUTS`. - Requires one of the following permissions when updating only `paymentSettings` field: `MANAGE_CHANNELS`, `HANDLE_PAYMENTS`. - - Triggers the following webhook events: - - CHANNEL_UPDATED (async): A channel was updated. - - CHANNEL_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. - """ - channelUpdate( - """ID of a channel to update.""" - id: ID! - - """Fields required to update a channel.""" - input: ChannelUpdateInput! - ): ChannelUpdate - - """ - Adds a gift card or a voucher to a checkout. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutAddPromoCode( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """Gift card code or voucher code.""" - promoCode: String! - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutAddPromoCode - - """ - Update billing address in the existing checkout. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutBillingAddressUpdate( - """The billing address of the checkout.""" - billingAddress: AddressInput! - - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - - """ - The rules for changing validation for received billing address data. - - Added in Saleor 3.5. - """ - validationRules: CheckoutAddressValidationRules - ): CheckoutBillingAddressUpdate - - """ - Completes the checkout. As a result a new order is created. The mutation allows to create the unpaid order when setting `orderSettings.allowUnpaidOrders` for given `Channel` is set to `true`. When `orderSettings.allowUnpaidOrders` is set to `false`, checkout can be completed only when attached `Payment`/`TransactionItem`s fully cover the checkout's total. When processing the checkout with `Payment`, in case of required additional confirmation step like 3D secure, the `confirmationNeeded` flag will be set to True and no order will be created until payment is confirmed with second call of this mutation. - - Triggers the following webhook events: - - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - - ORDER_CREATED (async): Triggered when order is created. - - NOTIFY_USER (async): A notification for order placement. - - NOTIFY_USER (async): A staff notification for order placement. - - ORDER_UPDATED (async): Triggered when order received the update after placement. - - ORDER_PAID (async): Triggered when newly created order is paid. - - ORDER_FULLY_PAID (async): Triggered when newly created order is fully paid. - - ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. - """ - checkoutComplete( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - Fields required to update the checkout metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Client-side generated data required to finalize the payment.""" - paymentData: JSONString - - """ - URL of a view where users should be redirected to see the order details. URL in RFC 1808 format. - """ - redirectUrl: String - - """ - Determines whether to store the payment source for future usage. - - DEPRECATED: this field will be removed in Saleor 4.0. Use checkoutPaymentCreate for this action. - """ - storeSource: Boolean = false - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutComplete - - """ - Create a new checkout. - - `skipValidation` field requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. - - Triggers the following webhook events: - - CHECKOUT_CREATED (async): A checkout was created. - """ - checkoutCreate( - """Fields required to create checkout.""" - input: CheckoutCreateInput! - ): CheckoutCreate - - """ - Create new checkout from existing order. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - checkoutCreateFromOrder( - """ID of a order that will be used to create the checkout.""" - id: ID! - ): CheckoutCreateFromOrder - - """ - Sets the customer as the owner of the checkout. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_USER. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutCustomerAttach( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - ID of customer to attach to checkout. Requires IMPERSONATE_USER permission when customerId is different than the logged-in user. - """ - customerId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutCustomerAttach - - """ - Removes the user assigned as the owner of the checkout. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_USER. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutCustomerDetach( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutCustomerDetach - - """ - Updates the delivery method (shipping method or pick up point) of the checkout. Updates the checkout shipping_address for click and collect delivery for a warehouse address. - - Added in Saleor 3.1. - - Triggers the following webhook events: - - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout delivery method with the external one. - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutDeliveryMethodUpdate( - """Delivery Method ID (`Warehouse` ID or `ShippingMethod` ID).""" - deliveryMethodId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutDeliveryMethodUpdate - - """ - Updates email address in the existing checkout object. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutEmailUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """email.""" - email: String! - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutEmailUpdate - - """ - Update language code in the existing checkout. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutLanguageCodeUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """New language code.""" - languageCode: LanguageCodeEnum! - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutLanguageCodeUpdate - - """ - Deletes a CheckoutLine. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutLineDelete( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ID of the checkout line to delete.""" - lineId: ID - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutLineDelete @deprecated(reason: "This field will be removed in Saleor 4.0. Use `checkoutLinesDelete` instead.") - - """ - Adds a checkout line to the existing checkout.If line was already in checkout, its quantity will be increased. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutLinesAdd( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - A list of checkout lines, each containing information about an item in the checkout. - """ - lines: [CheckoutLineInput!]! - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutLinesAdd - - """ - Deletes checkout lines. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutLinesDelete( - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """A list of checkout lines.""" - linesIds: [ID!]! - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutLinesDelete - - """ - Updates checkout line in the existing checkout. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutLinesUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - A list of checkout lines, each containing information about an item in the checkout. - """ - lines: [CheckoutLineUpdateInput!]! - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutLinesUpdate - - """Create a new payment for given checkout.""" - checkoutPaymentCreate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """Data required to create a new payment.""" - input: PaymentInput! - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutPaymentCreate - - """ - Remove a gift card or a voucher from a checkout. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutRemovePromoCode( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """Gift card code or voucher code.""" - promoCode: String - - """Gift card or voucher ID.""" - promoCodeId: ID - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutRemovePromoCode - - """ - Update shipping address in the existing checkout. - - Triggers the following webhook events: - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutShippingAddressUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """The mailing address to where the checkout will be shipped.""" - shippingAddress: AddressInput! - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - - """ - The rules for changing validation for received shipping address data. - - Added in Saleor 3.5. - """ - validationRules: CheckoutAddressValidationRules - ): CheckoutShippingAddressUpdate - - """ - Updates the shipping method of the checkout. - - Triggers the following webhook events: - - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout shipping method with the external one. - - CHECKOUT_UPDATED (async): A checkout was updated. - """ - checkoutShippingMethodUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID - - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """Shipping method.""" - shippingMethodId: ID - - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutShippingMethodUpdate @deprecated(reason: "This field will be removed in Saleor 4.0. Use `checkoutDeliveryMethodUpdate` instead.") - - """ - Adds products to a collection. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - collectionAddProducts( - """ID of a collection.""" - collectionId: ID! - - """List of product IDs.""" - products: [ID!]! - ): CollectionAddProducts - - """ - Deletes collections. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - collectionBulkDelete( - """List of collection IDs to delete.""" - ids: [ID!]! - ): CollectionBulkDelete - - """ - Manage collection's availability in channels. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - collectionChannelListingUpdate( - """ID of a collection to update.""" - id: ID! - - """Fields required to create or update collection channel listings.""" - input: CollectionChannelListingUpdateInput! - ): CollectionChannelListingUpdate - - """ - Creates a new collection. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - collectionCreate( - """Fields required to create a collection.""" - input: CollectionCreateInput! - ): CollectionCreate - - """ - Deletes a collection. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - collectionDelete( - """ID of a collection to delete.""" - id: ID! - ): CollectionDelete - - """ - Remove products from a collection. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - collectionRemoveProducts( - """ID of a collection.""" - collectionId: ID! - - """List of product IDs.""" - products: [ID!]! - ): CollectionRemoveProducts - - """ - Reorder the products of a collection. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - collectionReorderProducts( - """ID of a collection.""" - collectionId: ID! - - """The collection products position operations.""" - moves: [MoveProductInput!]! - ): CollectionReorderProducts - - """ - Creates/updates translations for a collection. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - collectionTranslate( - """Collection ID or CollectionTranslatableContent ID.""" - id: ID! - - """Fields required to update collection translations.""" - input: TranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): CollectionTranslate - - """ - Updates a collection. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - collectionUpdate( - """ID of a collection to update.""" - id: ID! - - """Fields required to update a collection.""" - input: CollectionInput! - ): CollectionUpdate - - """ - Confirm user account with token sent by email during registration. - - Triggers the following webhook events: - - ACCOUNT_CONFIRMED (async): Account was confirmed. - """ - confirmAccount( - """E-mail of the user performing account confirmation.""" - email: String! - - """A one-time token required to confirm the account.""" - token: String! - ): ConfirmAccount - - """ - Confirm the email change of the logged-in user. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - CUSTOMER_UPDATED (async): A customer account was updated. - - NOTIFY_USER (async): A notification that account email change was confirmed. - - ACCOUNT_EMAIL_CHANGED (async): An account email was changed. - """ - confirmEmailChange( - """ - Slug of a channel which will be used to notify users. Optional when only one channel exists. - """ - channel: String - - """A one-time token required to change the email.""" - token: String! - ): ConfirmEmailChange - - """ - Creates new warehouse. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - createWarehouse( - """Fields required to create warehouse.""" - input: WarehouseCreateInput! - ): WarehouseCreate - - """ - Deletes customers. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - CUSTOMER_DELETED (async): A customer account was deleted. - """ - customerBulkDelete( - """List of user IDs to delete.""" - ids: [ID!]! - ): CustomerBulkDelete - - """ - Updates customers. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - CUSTOMER_UPDATED (async): A customer account was updated. - - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. - """ - customerBulkUpdate( - """Input list of customers to update.""" - customers: [CustomerBulkUpdateInput!]! - - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - ): CustomerBulkUpdate - - """ - Creates a new customer. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - CUSTOMER_CREATED (async): A new customer account was created. - - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. - - NOTIFY_USER (async): A notification for setting the password. - - ACCOUNT_SET_PASSWORD_REQUESTED (async): Setting a new password for the account is requested. - """ - customerCreate( - """Fields required to create a customer.""" - input: UserCreateInput! - ): CustomerCreate - - """ - Deletes a customer. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - CUSTOMER_DELETED (async): A customer account was deleted. - """ - customerDelete( - """ - External ID of a customer to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a customer to delete.""" - id: ID - ): CustomerDelete - - """ - Updates an existing customer. - - Requires one of the following permissions: MANAGE_USERS. - - Triggers the following webhook events: - - CUSTOMER_UPDATED (async): A new customer account was updated. - - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. - """ - customerUpdate( - """ - External ID of a customer to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a customer to update.""" - id: ID - - """Fields required to update a customer.""" - input: CustomerInput! - ): CustomerUpdate - - """ - Delete metadata of an object. To use it, you need to have access to the modified object. - """ - deleteMetadata( - """ID or token (for Order and Checkout) of an object to update.""" - id: ID! - - """Metadata keys to delete.""" - keys: [String!]! - ): DeleteMetadata - - """ - Delete object's private metadata. To use it, you need to be an authenticated staff user or an app and have access to the modified object. - """ - deletePrivateMetadata( - """ID or token (for Order and Checkout) of an object to update.""" - id: ID! - - """Metadata keys to delete.""" - keys: [String!]! - ): DeletePrivateMetadata - - """ - Deletes selected warehouse. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - deleteWarehouse( - """ID of a warehouse to delete.""" - id: ID! - ): WarehouseDelete - - """ - Create new digital content. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - digitalContentCreate( - """Fields required to create a digital content.""" - input: DigitalContentUploadInput! - - """ID of a product variant to upload digital content.""" - variantId: ID! - ): DigitalContentCreate - - """ - Remove digital content assigned to given variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - digitalContentDelete( - """ID of a product variant with digital content to remove.""" - variantId: ID! - ): DigitalContentDelete - - """ - Update digital content. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - digitalContentUpdate( - """Fields required to update a digital content.""" - input: DigitalContentInput! - - """ID of a product variant with digital content to update.""" - variantId: ID! - ): DigitalContentUpdate - - """ - Generate new URL to digital content. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - digitalContentUrlCreate( - """Fields required to create a new url.""" - input: DigitalContentUrlCreateInput! - ): DigitalContentUrlCreate - - """ - Deletes draft orders. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - draftOrderBulkDelete( - """List of draft order IDs to delete.""" - ids: [ID!]! - ): DraftOrderBulkDelete - - """ - Completes creating an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - draftOrderComplete( - """ID of the order that will be completed.""" - id: ID! - ): DraftOrderComplete - - """ - Creates a new draft order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - draftOrderCreate( - """Fields required to create an order.""" - input: DraftOrderCreateInput! - ): DraftOrderCreate - - """ - Deletes a draft order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - draftOrderDelete( - """ - External ID of a product to delete. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a product to delete.""" - id: ID - ): DraftOrderDelete - - """ - Deletes order lines. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - draftOrderLinesBulkDelete( - """List of order lines IDs to delete.""" - ids: [ID!]! - ): DraftOrderLinesBulkDelete @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """ - Updates a draft order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - draftOrderUpdate( - """ - External ID of a draft order to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a draft order to update.""" - id: ID - - """Fields required to update an order.""" - input: DraftOrderInput! - ): DraftOrderUpdate - - """ - Retries event delivery. - - Requires one of the following permissions: MANAGE_APPS. - """ - eventDeliveryRetry( - """ID of the event delivery to retry.""" - id: ID! - ): EventDeliveryRetry - - """ - Export gift cards to csv file. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - NOTIFY_USER (async): A notification for the exported file. - - GIFT_CARD_EXPORT_COMPLETED (async): A notification for the exported file. - """ - exportGiftCards( - """Fields required to export gift cards data.""" - input: ExportGiftCardsInput! - ): ExportGiftCards - - """ - Export products to csv file. - - Requires one of the following permissions: MANAGE_PRODUCTS. - - Triggers the following webhook events: - - NOTIFY_USER (async): A notification for the exported file. - - PRODUCT_EXPORT_COMPLETED (async): A notification for the exported file. - """ - exportProducts( - """Fields required to export product data.""" - input: ExportProductsInput! - ): ExportProducts - - """ - Export voucher codes to csv/xlsx file. - - Added in Saleor 3.18. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_CODE_EXPORT_COMPLETED (async): A notification for the exported file. - """ - exportVoucherCodes( - """Fields required to export voucher codes.""" - input: ExportVoucherCodesInput! - ): ExportVoucherCodes - - """Prepare external authentication URL for user by custom plugin.""" - externalAuthenticationUrl( - """The data required by plugin to create external authentication url.""" - input: JSONString! - - """The ID of the authentication plugin.""" - pluginId: String! - ): ExternalAuthenticationUrl - - """Logout user by custom plugin.""" - externalLogout( - """The data required by plugin to proceed the logout process.""" - input: JSONString! - - """The ID of the authentication plugin.""" - pluginId: String! - ): ExternalLogout - - """ - Trigger sending a notification with the notify plugin method. Serializes nodes provided as ids parameter and includes this data in the notification payload. - - Added in Saleor 3.1. - """ - externalNotificationTrigger( - """ - Channel slug. Saleor will send a notification within a provided channel. Please, make sure that necessary plugins are active. - """ - channel: String! - - """Input for External Notification Trigger.""" - input: ExternalNotificationTriggerInput! - - """The ID of notification plugin.""" - pluginId: String - ): ExternalNotificationTrigger @deprecated(reason: "\\n\\nDEPRECATED: this mutation will be removed in Saleor 4.0.") - - """Obtain external access tokens for user by custom plugin.""" - externalObtainAccessTokens( - """The data required by plugin to create authentication data.""" - input: JSONString! - - """The ID of the authentication plugin.""" - pluginId: String! - ): ExternalObtainAccessTokens - - """Refresh user's access by custom plugin.""" - externalRefresh( - """The data required by plugin to proceed the refresh process.""" - input: JSONString! - - """The ID of the authentication plugin.""" - pluginId: String! - ): ExternalRefresh - - """Verify external authentication data by plugin.""" - externalVerify( - """The data required by plugin to proceed the verification.""" - input: JSONString! - - """The ID of the authentication plugin.""" - pluginId: String! - ): ExternalVerify - - """ - Upload a file. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - fileUpload( - """Represents a file in a multipart request.""" - file: Upload! - ): FileUpload - - """ - Activate a gift card. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_STATUS_CHANGED (async): A gift card was activated. - """ - giftCardActivate( - """ID of a gift card to activate.""" - id: ID! - ): GiftCardActivate - - """ - Adds note to the gift card. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_UPDATED (async): A gift card was updated. - """ - giftCardAddNote( - """ID of the gift card to add a note for.""" - id: ID! - - """Fields required to create a note for the gift card.""" - input: GiftCardAddNoteInput! - ): GiftCardAddNote - - """ - Activate gift cards. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_STATUS_CHANGED (async): A gift card was activated. - """ - giftCardBulkActivate( - """List of gift card IDs to activate.""" - ids: [ID!]! - ): GiftCardBulkActivate - - """ - Create gift cards. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_CREATED (async): A gift card was created. - - NOTIFY_USER (async): A notification for created gift card. - """ - giftCardBulkCreate( - """Fields required to create gift cards.""" - input: GiftCardBulkCreateInput! - ): GiftCardBulkCreate - - """ - Deactivate gift cards. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_STATUS_CHANGED (async): A gift card was deactivated. - """ - giftCardBulkDeactivate( - """List of gift card IDs to deactivate.""" - ids: [ID!]! - ): GiftCardBulkDeactivate - - """ - Delete gift cards. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_DELETED (async): A gift card was deleted. - """ - giftCardBulkDelete( - """List of gift card IDs to delete.""" - ids: [ID!]! - ): GiftCardBulkDelete - - """ - Creates a new gift card. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_CREATED (async): A gift card was created. - - NOTIFY_USER (async): A notification for created gift card. - """ - giftCardCreate( - """Fields required to create a gift card.""" - input: GiftCardCreateInput! - ): GiftCardCreate - - """ - Deactivate a gift card. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_STATUS_CHANGED (async): A gift card was deactivated. - """ - giftCardDeactivate( - """ID of a gift card to deactivate.""" - id: ID! - ): GiftCardDeactivate - - """ - Delete gift card. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_DELETED (async): A gift card was deleted. - """ - giftCardDelete( - """ID of the gift card to delete.""" - id: ID! - ): GiftCardDelete - - """ - Resend a gift card. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - NOTIFY_USER (async): A notification for gift card resend. - """ - giftCardResend( - """Fields required to resend a gift card.""" - input: GiftCardResendInput! - ): GiftCardResend - - """ - Update gift card settings. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - """ - giftCardSettingsUpdate( - """Fields required to update gift card settings.""" - input: GiftCardSettingsUpdateInput! - ): GiftCardSettingsUpdate - - """ - Update a gift card. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - - Triggers the following webhook events: - - GIFT_CARD_UPDATED (async): A gift card was updated. - """ - giftCardUpdate( - """ID of a gift card to update.""" - id: ID! - - """Fields required to update a gift card.""" - input: GiftCardUpdateInput! - ): GiftCardUpdate - - """ - Creates a ready to send invoice. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - invoiceCreate( - """Fields required when creating an invoice.""" - input: InvoiceCreateInput! - - """ID of the order related to invoice.""" - orderId: ID! - ): InvoiceCreate - - """ - Deletes an invoice. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - invoiceDelete( - """ID of an invoice to delete.""" - id: ID! - ): InvoiceDelete - - """ - Request an invoice for the order using plugin. - - Requires one of the following permissions: MANAGE_ORDERS. - - Triggers the following webhook events: - - INVOICE_REQUESTED (async): An invoice was requested. - """ - invoiceRequest( - """Invoice number, if not provided it will be generated.""" - number: String - - """ID of the order related to invoice.""" - orderId: ID! - ): InvoiceRequest - - """ - Requests deletion of an invoice. - - Requires one of the following permissions: MANAGE_ORDERS. - - Triggers the following webhook events: - - INVOICE_DELETED (async): An invoice was requested to delete. - """ - invoiceRequestDelete( - """ID of an invoice to request the deletion.""" - id: ID! - ): InvoiceRequestDelete - - """ - Send an invoice notification to the customer. - - Requires one of the following permissions: MANAGE_ORDERS. - - Triggers the following webhook events: - - INVOICE_SENT (async): A notification for invoice send - - NOTIFY_USER (async): A notification for invoice send - """ - invoiceSendNotification( - """ID of an invoice to be sent.""" - id: ID! - ): InvoiceSendNotification - - """ - Updates an invoice. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - invoiceUpdate( - """ID of an invoice to update.""" - id: ID! - - """Fields to use when updating an invoice.""" - input: UpdateInvoiceInput! - ): InvoiceUpdate - - """ - Deletes menus. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_DELETED (async): A menu was deleted. - """ - menuBulkDelete( - """List of menu IDs to delete.""" - ids: [ID!]! - ): MenuBulkDelete - - """ - Creates a new Menu. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_CREATED (async): A menu was created. - """ - menuCreate( - """Fields required to create a menu.""" - input: MenuCreateInput! - ): MenuCreate - - """ - Deletes a menu. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_DELETED (async): A menu was deleted. - """ - menuDelete( - """ID of a menu to delete.""" - id: ID! - ): MenuDelete - - """ - Deletes menu items. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_ITEM_DELETED (async): A menu item was deleted. - """ - menuItemBulkDelete( - """List of menu item IDs to delete.""" - ids: [ID!]! - ): MenuItemBulkDelete - - """ - Creates a new menu item. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_ITEM_CREATED (async): A menu item was created. - """ - menuItemCreate( - """ - Fields required to update a menu item. Only one of `url`, `category`, `page`, `collection` is allowed per item. - """ - input: MenuItemCreateInput! - ): MenuItemCreate - - """ - Deletes a menu item. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_ITEM_DELETED (async): A menu item was deleted. - """ - menuItemDelete( - """ID of a menu item to delete.""" - id: ID! - ): MenuItemDelete - - """ - Moves items of menus. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_ITEM_UPDATED (async): Optionally triggered when sort order or parent changed for menu item. - """ - menuItemMove( - """ID of the menu.""" - menu: ID! - - """The menu position data.""" - moves: [MenuItemMoveInput!]! - ): MenuItemMove - - """ - Creates/updates translations for a menu item. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - menuItemTranslate( - """MenuItem ID or MenuItemTranslatableContent ID.""" - id: ID! - - """Fields required to update menu item translations.""" - input: NameTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): MenuItemTranslate - - """ - Updates a menu item. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_ITEM_UPDATED (async): A menu item was updated. - """ - menuItemUpdate( - """ID of a menu item to update.""" - id: ID! - - """ - Fields required to update a menu item. Only one of `url`, `category`, `page`, `collection` is allowed per item. - """ - input: MenuItemInput! - ): MenuItemUpdate - - """ - Updates a menu. - - Requires one of the following permissions: MANAGE_MENUS. - - Triggers the following webhook events: - - MENU_UPDATED (async): A menu was updated. - """ - menuUpdate( - """ID of a menu to update.""" - id: ID! - - """Fields required to update a menu.""" - input: MenuInput! - ): MenuUpdate - - """ - Adds note to the order. - - DEPRECATED: this mutation will be removed in Saleor 4.0. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderAddNote( - """Fields required to create a note for the order.""" - input: OrderAddNoteInput! - - """ID of the order to add a note for.""" - order: ID! - ): OrderAddNote @deprecated(reason: "This field will be removed in Saleor 4.0. Use `orderNoteAdd` instead.") - - """ - Cancels orders. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderBulkCancel( - """List of orders IDs to cancel.""" - ids: [ID!]! - ): OrderBulkCancel - - """ - Creates multiple orders. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS_IMPORT. - """ - orderBulkCreate( - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - - """Input list of orders to create. Orders limit: 50.""" - orders: [OrderBulkCreateInput!]! - - """ - Determine how stock should be updated, while processing the order. DEFAULT: UPDATE - Only do update, if there is enough stocks. - """ - stockUpdatePolicy: StockUpdatePolicyEnum - ): OrderBulkCreate - - """ - Cancel an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderCancel( - """ID of the order to cancel.""" - id: ID! - ): OrderCancel - - """ - Capture an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderCapture( - """Amount of money to capture.""" - amount: PositiveDecimal! - - """ID of the order to capture.""" - id: ID! - ): OrderCapture - - """ - Confirms an unconfirmed order by changing status to unfulfilled. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderConfirm( - """ID of an order to confirm.""" - id: ID! - ): OrderConfirm - - """ - Create new order from existing checkout. Requires the following permissions: AUTHENTICATED_APP and HANDLE_CHECKOUTS. - - Added in Saleor 3.2. - - Triggers the following webhook events: - - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. - - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. - - ORDER_CREATED (async): Triggered when order is created. - - NOTIFY_USER (async): A notification for order placement. - - NOTIFY_USER (async): A staff notification for order placement. - - ORDER_UPDATED (async): Triggered when order received the update after placement. - - ORDER_PAID (async): Triggered when newly created order is paid. - - ORDER_FULLY_PAID (async): Triggered when newly created order is fully paid. - - ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. - """ - orderCreateFromCheckout( - """ID of a checkout that will be converted to an order.""" - id: ID! - - """ - Fields required to update the checkout metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """ - Fields required to update the checkout private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """ - Determines if checkout should be removed after creating an order. Default true. - """ - removeCheckout: Boolean = true - ): OrderCreateFromCheckout - - """ - Adds discount to the order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderDiscountAdd( - """Fields required to create a discount for the order.""" - input: OrderDiscountCommonInput! - - """ID of an order to discount.""" - orderId: ID! - ): OrderDiscountAdd - - """ - Remove discount from the order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderDiscountDelete( - """ID of a discount to remove.""" - discountId: ID! - ): OrderDiscountDelete - - """ - Update discount for the order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderDiscountUpdate( - """ID of a discount to update.""" - discountId: ID! - - """Fields required to update a discount for the order.""" - input: OrderDiscountCommonInput! - ): OrderDiscountUpdate - - """ - Creates new fulfillments for an order. - - Requires one of the following permissions: MANAGE_ORDERS. - - Triggers the following webhook events: - - FULFILLMENT_CREATED (async): A new fulfillment is created. - - ORDER_FULFILLED (async): Order is fulfilled. - - FULFILLMENT_TRACKING_NUMBER_UPDATED (async): Sent when fulfillment tracking number is updated. - - FULFILLMENT_APPROVED (async): A fulfillment is approved. - """ - orderFulfill( - """Fields required to create a fulfillment.""" - input: OrderFulfillInput! - - """ID of the order to be fulfilled.""" - order: ID - ): OrderFulfill - - """ - Approve existing fulfillment. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_ORDERS. - - Triggers the following webhook events: - - FULFILLMENT_APPROVED (async): Fulfillment is approved. - """ - orderFulfillmentApprove( - """True if stock could be exceeded.""" - allowStockToBeExceeded: Boolean = false - - """ID of a fulfillment to approve.""" - id: ID! - - """True if confirmation email should be send.""" - notifyCustomer: Boolean! - ): FulfillmentApprove - - """ - Cancels existing fulfillment and optionally restocks items. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderFulfillmentCancel( - """ID of a fulfillment to cancel.""" - id: ID! - - """Fields required to cancel a fulfillment.""" - input: FulfillmentCancelInput - ): FulfillmentCancel - - """ - Refund products. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderFulfillmentRefundProducts( - """Fields required to create an refund fulfillment.""" - input: OrderRefundProductsInput! - - """ID of the order to be refunded.""" - order: ID! - ): FulfillmentRefundProducts - - """ - Return products. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderFulfillmentReturnProducts( - """Fields required to return products.""" - input: OrderReturnProductsInput! - - """ID of the order to be returned.""" - order: ID! - ): FulfillmentReturnProducts - - """ - Updates a fulfillment for an order. - - Requires one of the following permissions: MANAGE_ORDERS. - - Triggers the following webhook events: - - FULFILLMENT_TRACKING_NUMBER_UPDATED (async): Fulfillment tracking number is updated. - """ - orderFulfillmentUpdateTracking( - """ID of a fulfillment to update.""" - id: ID! - - """Fields required to update a fulfillment.""" - input: FulfillmentUpdateTrackingInput! - ): FulfillmentUpdateTracking - - """ - Adds granted refund to the order. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderGrantRefundCreate( - """ID of the order.""" - id: ID! - - """Fields required to create a granted refund for the order.""" - input: OrderGrantRefundCreateInput! - ): OrderGrantRefundCreate - - """ - Updates granted refund. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderGrantRefundUpdate( - """ID of the granted refund.""" - id: ID! - - """Fields required to update a granted refund.""" - input: OrderGrantRefundUpdateInput! - ): OrderGrantRefundUpdate - - """ - Deletes an order line from an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderLineDelete( - """ID of the order line to delete.""" - id: ID! - ): OrderLineDelete - - """ - Remove discount applied to the order line. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderLineDiscountRemove( - """ID of a order line to remove its discount""" - orderLineId: ID! - ): OrderLineDiscountRemove - - """ - Update discount for the order line. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderLineDiscountUpdate( - """Fields required to update price for the order line.""" - input: OrderDiscountCommonInput! - - """ID of a order line to update price""" - orderLineId: ID! - ): OrderLineDiscountUpdate - - """ - Updates an order line of an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderLineUpdate( - """ID of the order line to update.""" - id: ID! - - """Fields required to update an order line.""" - input: OrderLineInput! - ): OrderLineUpdate - - """ - Create order lines for an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderLinesCreate( - """ID of the order to add the lines to.""" - id: ID! - - """Fields required to add order lines.""" - input: [OrderLineCreateInput!]! - ): OrderLinesCreate - - """ - Mark order as manually paid. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderMarkAsPaid( - """ID of the order to mark paid.""" - id: ID! - - """The external transaction reference.""" - transactionReference: String - ): OrderMarkAsPaid - - """ - Adds note to the order. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderNoteAdd( - """Fields required to create a note for the order.""" - input: OrderNoteInput! - - """ID of the order to add a note for.""" - order: ID! - ): OrderNoteAdd - - """ - Updates note of an order. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderNoteUpdate( - """Fields required to create a note for the order.""" - input: OrderNoteInput! - - """ID of the note.""" - note: ID! - ): OrderNoteUpdate - - """ - Refund an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderRefund( - """Amount of money to refund.""" - amount: PositiveDecimal! - - """ID of the order to refund.""" - id: ID! - ): OrderRefund - - """ - Update shop order settings across all channels. Returns `orderSettings` for the first `channel` in alphabetical order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderSettingsUpdate( - """Fields required to update shop order settings.""" - input: OrderSettingsUpdateInput! - ): OrderSettingsUpdate @deprecated(reason: "\\n\\nDEPRECATED: this mutation will be removed in Saleor 4.0. Use `channelUpdate` mutation instead.") - - """ - Updates an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderUpdate( - """ - External ID of an order to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of an order to update.""" - id: ID - - """Fields required to update an order.""" - input: OrderUpdateInput! - ): OrderUpdate - - """ - Updates a shipping method of the order. Requires shipping method ID to update, when null is passed then currently assigned shipping method is removed. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderUpdateShipping( - """Fields required to change shipping method of the order.""" - input: OrderUpdateShippingInput! - - """ID of the order to update a shipping method.""" - order: ID! - ): OrderUpdateShipping - - """ - Void an order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderVoid( - """ID of the order to void.""" - id: ID! - ): OrderVoid - - """ - Assign attributes to a given page type. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - pageAttributeAssign( - """The IDs of the attributes to assign.""" - attributeIds: [ID!]! - - """ID of the page type to assign the attributes into.""" - pageTypeId: ID! - ): PageAttributeAssign - - """ - Unassign attributes from a given page type. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - pageAttributeUnassign( - """The IDs of the attributes to unassign.""" - attributeIds: [ID!]! - - """ID of the page type from which the attributes should be unassign.""" - pageTypeId: ID! - ): PageAttributeUnassign - - """ - Deletes pages. - - Requires one of the following permissions: MANAGE_PAGES. - """ - pageBulkDelete( - """List of page IDs to delete.""" - ids: [ID!]! - ): PageBulkDelete - - """ - Publish pages. - - Requires one of the following permissions: MANAGE_PAGES. - """ - pageBulkPublish( - """List of page IDs to (un)publish.""" - ids: [ID!]! - - """Determine if pages will be published or not.""" - isPublished: Boolean! - ): PageBulkPublish - - """ - Creates a new page. - - Requires one of the following permissions: MANAGE_PAGES. - """ - pageCreate( - """Fields required to create a page.""" - input: PageCreateInput! - ): PageCreate - - """ - Deletes a page. - - Requires one of the following permissions: MANAGE_PAGES. - """ - pageDelete( - """ID of a page to delete.""" - id: ID! - ): PageDelete - - """ - Reorder page attribute values. - - Requires one of the following permissions: MANAGE_PAGES. - """ - pageReorderAttributeValues( - """ID of an attribute.""" - attributeId: ID! - - """The list of reordering operations for given attribute values.""" - moves: [ReorderInput!]! - - """ID of a page.""" - pageId: ID! - ): PageReorderAttributeValues - - """ - Creates/updates translations for a page. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - pageTranslate( - """Page ID or PageTranslatableContent ID.""" - id: ID! - - """Fields required to update page translations.""" - input: PageTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): PageTranslate - - """ - Delete page types. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - pageTypeBulkDelete( - """List of page type IDs to delete""" - ids: [ID!]! - ): PageTypeBulkDelete - - """ - Create a new page type. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - pageTypeCreate( - """Fields required to create page type.""" - input: PageTypeCreateInput! - ): PageTypeCreate - - """ - Delete a page type. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - pageTypeDelete( - """ID of the page type to delete.""" - id: ID! - ): PageTypeDelete - - """ - Reorder the attributes of a page type. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - pageTypeReorderAttributes( - """The list of attribute reordering operations.""" - moves: [ReorderInput!]! - - """ID of a page type.""" - pageTypeId: ID! - ): PageTypeReorderAttributes - - """ - Update page type. - - Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - pageTypeUpdate( - """ID of the page type to update.""" - id: ID - - """Fields required to update page type.""" - input: PageTypeUpdateInput! - ): PageTypeUpdate - - """ - Updates an existing page. - - Requires one of the following permissions: MANAGE_PAGES. - """ - pageUpdate( - """ID of a page to update.""" - id: ID! - - """Fields required to update a page.""" - input: PageInput! - ): PageUpdate - - """ - Change the password of the logged in user. - - Requires one of the following permissions: AUTHENTICATED_USER. - """ - passwordChange( - """New user password.""" - newPassword: String! - - """Current user password.""" - oldPassword: String - ): PasswordChange - - """ - Captures the authorized payment amount. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - paymentCapture( - """Transaction amount.""" - amount: PositiveDecimal - - """Payment ID.""" - paymentId: ID! - ): PaymentCapture - - """Check payment balance.""" - paymentCheckBalance( - """Fields required to check payment balance.""" - input: PaymentCheckBalanceInput! - ): PaymentCheckBalance - - """ - Initializes a payment gateway session. It triggers the webhook `PAYMENT_GATEWAY_INITIALIZE_SESSION`, to the requested `paymentGateways`. If `paymentGateways` is not provided, the webhook will be send to all subscribed payment gateways. There is a limit of 100 transaction items per checkout / order. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - paymentGatewayInitialize( - """ - The amount requested for initializing the payment gateway. If not provided, the difference between checkout.total - transactions that are already processed will be send. - """ - amount: PositiveDecimal - - """The ID of the checkout or order.""" - id: ID! - - """List of payment gateways to initialize.""" - paymentGateways: [PaymentGatewayToInitialize!] - ): PaymentGatewayInitialize - - """ - Initializes payment gateway for tokenizing payment method session. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION (sync): The customer requested to initialize payment gateway for tokenization. - """ - paymentGatewayInitializeTokenization( - """Slug of a channel related to tokenization request.""" - channel: String! - - """The data that will be passed to the payment gateway.""" - data: JSON - - """The identifier of the payment gateway app to initialize tokenization.""" - id: String! - ): PaymentGatewayInitializeTokenization - - """Initializes payment process when it is required by gateway.""" - paymentInitialize( - """Slug of a channel for which the data should be returned.""" - channel: String - - """A gateway name used to initialize the payment.""" - gateway: String! - - """Client-side generated data required to initialize the payment.""" - paymentData: JSONString - ): PaymentInitialize - - """ - Tokenize payment method. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION (sync): The customer requested to tokenize payment method. - """ - paymentMethodInitializeTokenization( - """Slug of a channel related to tokenization request.""" - channel: String! - - """The data that will be passed to the payment gateway.""" - data: JSON - - """ - The identifier of the payment gateway app to initialize payment method tokenization. - """ - id: String! - - """The payment flow that the tokenized payment method should support.""" - paymentFlowToSupport: TokenizedPaymentFlowEnum! - ): PaymentMethodInitializeTokenization - - """ - Tokenize payment method. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION (sync): The customer continues payment method tokenization. - """ - paymentMethodProcessTokenization( - """Slug of a channel related to tokenization request.""" - channel: String! - - """The data that will be passed to the payment gateway.""" - data: JSON - - """ - The identifier of the payment gateway app to process payment method tokenization. - """ - id: String! - ): PaymentMethodProcessTokenization - - """ - Refunds the captured payment amount. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - paymentRefund( - """Transaction amount.""" - amount: PositiveDecimal - - """Payment ID.""" - paymentId: ID! - ): PaymentRefund - - """ - Voids the authorized payment. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - paymentVoid( - """Payment ID.""" - paymentId: ID! - ): PaymentVoid - - """ - Create new permission group. Apps are not allowed to perform this mutation. - - Requires one of the following permissions: MANAGE_STAFF. - - Triggers the following webhook events: - - PERMISSION_GROUP_CREATED (async) - """ - permissionGroupCreate( - """Input fields to create permission group.""" - input: PermissionGroupCreateInput! - ): PermissionGroupCreate - - """ - Delete permission group. Apps are not allowed to perform this mutation. - - Requires one of the following permissions: MANAGE_STAFF. - - Triggers the following webhook events: - - PERMISSION_GROUP_DELETED (async) - """ - permissionGroupDelete( - """ID of the group to delete.""" - id: ID! - ): PermissionGroupDelete - - """ - Update permission group. Apps are not allowed to perform this mutation. - - Requires one of the following permissions: MANAGE_STAFF. - - Triggers the following webhook events: - - PERMISSION_GROUP_UPDATED (async) - """ - permissionGroupUpdate( - """ID of the group to update.""" - id: ID! - - """Input fields to create permission group.""" - input: PermissionGroupUpdateInput! - ): PermissionGroupUpdate - - """ - Update plugin configuration. - - Requires one of the following permissions: MANAGE_PLUGINS. - """ - pluginUpdate( - """ID of a channel for which the data should be modified.""" - channelId: ID - - """ID of plugin to update.""" - id: ID! - - """Fields required to update a plugin configuration.""" - input: PluginUpdateInput! - ): PluginUpdate - - """ - Assign attributes to a given product type. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - productAttributeAssign( - """The operations to perform.""" - operations: [ProductAttributeAssignInput!]! - - """ID of the product type to assign the attributes into.""" - productTypeId: ID! - ): ProductAttributeAssign - - """ - Update attributes assigned to product variant for given product type. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - productAttributeAssignmentUpdate( - """The operations to perform.""" - operations: [ProductAttributeAssignmentUpdateInput!]! - - """ID of the product type to assign the attributes into.""" - productTypeId: ID! - ): ProductAttributeAssignmentUpdate - - """ - Un-assign attributes from a given product type. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - productAttributeUnassign( - """The IDs of the attributes to unassign.""" - attributeIds: [ID!]! - - """ID of the product type from which the attributes should be unassigned.""" - productTypeId: ID! - ): ProductAttributeUnassign - - """ - Creates products. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productBulkCreate( - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - - """Input list of products to create.""" - products: [ProductBulkCreateInput!]! - ): ProductBulkCreate - - """ - Deletes products. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productBulkDelete( - """List of product IDs to delete.""" - ids: [ID!]! - ): ProductBulkDelete - - """ - Creates/updates translations for products. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - - Triggers the following webhook events: - - TRANSLATION_CREATED (async): Called when a translation was created. - - TRANSLATION_UPDATED (async): Called when a translation was updated. - """ - productBulkTranslate( - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - - """List of product translations.""" - translations: [ProductBulkTranslateInput!]! - ): ProductBulkTranslate - - """ - Manage product's availability in channels. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productChannelListingUpdate( - """ID of a product to update.""" - id: ID! - - """Fields required to create or update product channel listings.""" - input: ProductChannelListingUpdateInput! - ): ProductChannelListingUpdate - - """ - Creates a new product. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productCreate( - """Fields required to create a product.""" - input: ProductCreateInput! - ): ProductCreate - - """ - Deletes a product. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productDelete( - """ - External ID of a product to delete. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a product to delete.""" - id: ID - ): ProductDelete - - """ - Deletes product media. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productMediaBulkDelete( - """List of product media IDs to delete.""" - ids: [ID!]! - ): ProductMediaBulkDelete - - """ - Create a media object (image or video URL) associated with product. For image, this mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productMediaCreate( - """Fields required to create a product media.""" - input: ProductMediaCreateInput! - ): ProductMediaCreate - - """ - Deletes a product media. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productMediaDelete( - """ID of a product media to delete.""" - id: ID! - ): ProductMediaDelete - - """ - Changes ordering of the product media. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productMediaReorder( - """IDs of a product media in the desired order.""" - mediaIds: [ID!]! - - """ID of product that media order will be altered.""" - productId: ID! - ): ProductMediaReorder - - """ - Updates a product media. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productMediaUpdate( - """ID of a product media to update.""" - id: ID! - - """Fields required to update a product media.""" - input: ProductMediaUpdateInput! - ): ProductMediaUpdate - - """ - Reorder product attribute values. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productReorderAttributeValues( - """ID of an attribute.""" - attributeId: ID! - - """The list of reordering operations for given attribute values.""" - moves: [ReorderInput!]! - - """ID of a product.""" - productId: ID! - ): ProductReorderAttributeValues - - """ - Creates/updates translations for a product. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - productTranslate( - """Product ID or ProductTranslatableContent ID.""" - id: ID! - - """Fields required to update product translations.""" - input: TranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): ProductTranslate - - """ - Deletes product types. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - productTypeBulkDelete( - """List of product type IDs to delete.""" - ids: [ID!]! - ): ProductTypeBulkDelete - - """ - Creates a new product type. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - productTypeCreate( - """Fields required to create a product type.""" - input: ProductTypeInput! - ): ProductTypeCreate - - """ - Deletes a product type. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - productTypeDelete( - """ID of a product type to delete.""" - id: ID! - ): ProductTypeDelete - - """ - Reorder the attributes of a product type. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - productTypeReorderAttributes( - """The list of attribute reordering operations.""" - moves: [ReorderInput!]! - - """ID of a product type.""" - productTypeId: ID! - - """The attribute type to reorder.""" - type: ProductAttributeType! - ): ProductTypeReorderAttributes - - """ - Updates an existing product type. - - Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. - """ - productTypeUpdate( - """ID of a product type to update.""" - id: ID! - - """Fields required to update a product type.""" - input: ProductTypeInput! - ): ProductTypeUpdate - - """ - Updates an existing product. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productUpdate( - """ - External ID of a product to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a product to update.""" - id: ID - - """Fields required to update a product.""" - input: ProductInput! - ): ProductUpdate - - """ - Creates product variants for a given product. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantBulkCreate( - """ - Policies of error handling. DEFAULT: REJECT_EVERYTHING - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - errorPolicy: ErrorPolicyEnum - - """ID of the product to create the variants for.""" - product: ID! - - """Input list of product variants to create.""" - variants: [ProductVariantBulkCreateInput!]! - ): ProductVariantBulkCreate - - """ - Deletes product variants. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantBulkDelete( - """List of product variant IDs to delete.""" - ids: [ID!] - - """ - List of product variant SKUs to delete. - - Added in Saleor 3.8. - """ - skus: [String!] - ): ProductVariantBulkDelete - - """ - Creates/updates translations for products variants. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - - Triggers the following webhook events: - - TRANSLATION_CREATED (async): A translation was created. - - TRANSLATION_UPDATED (async): A translation was updated. - """ - productVariantBulkTranslate( - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - - """List of products variants translations.""" - translations: [ProductVariantBulkTranslateInput!]! - ): ProductVariantBulkTranslate - - """ - Update multiple product variants. - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantBulkUpdate( - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - - """ID of the product to update the variants for.""" - product: ID! - - """Input list of product variants to update.""" - variants: [ProductVariantBulkUpdateInput!]! - ): ProductVariantBulkUpdate - - """ - Manage product variant prices in channels. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantChannelListingUpdate( - """ID of a product variant to update.""" - id: ID - - """ - List of fields required to create or upgrade product variant channel listings. - """ - input: [ProductVariantChannelListingAddInput!]! - - """ - SKU of a product variant to update. - - Added in Saleor 3.8. - """ - sku: String - ): ProductVariantChannelListingUpdate - - """ - Creates a new variant for a product. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantCreate( - """Fields required to create a product variant.""" - input: ProductVariantCreateInput! - ): ProductVariantCreate - - """ - Deletes a product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantDelete( - """ - External ID of a product variant to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a product variant to delete.""" - id: ID - - """ - SKU of a product variant to delete. - - Added in Saleor 3.8. - """ - sku: String - ): ProductVariantDelete - - """ - Deactivates product variant preorder. It changes all preorder allocation into regular allocation. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantPreorderDeactivate( - """ID of a variant which preorder should be deactivated.""" - id: ID! - ): ProductVariantPreorderDeactivate - - """ - Reorder the variants of a product. Mutation updates updated_at on product and triggers PRODUCT_UPDATED webhook. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantReorder( - """The list of variant reordering operations.""" - moves: [ReorderInput!]! - - """Id of product that variants order will be altered.""" - productId: ID! - ): ProductVariantReorder - - """ - Reorder product variant attribute values. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantReorderAttributeValues( - """ID of an attribute.""" - attributeId: ID! - - """The list of reordering operations for given attribute values.""" - moves: [ReorderInput!]! - - """ID of a product variant.""" - variantId: ID! - ): ProductVariantReorderAttributeValues - - """ - Set default variant for a product. Mutation triggers PRODUCT_UPDATED webhook. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantSetDefault( - """Id of a product that will have the default variant set.""" - productId: ID! - - """Id of a variant that will be set as default.""" - variantId: ID! - ): ProductVariantSetDefault - - """ - Creates stocks for product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantStocksCreate( - """Input list of stocks to create.""" - stocks: [StockInput!]! - - """ID of a product variant for which stocks will be created.""" - variantId: ID! - ): ProductVariantStocksCreate - - """ - Delete stocks from product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantStocksDelete( - """SKU of product variant for which stocks will be deleted.""" - sku: String - - """ID of product variant for which stocks will be deleted.""" - variantId: ID - - """Input list of warehouse IDs.""" - warehouseIds: [ID!] - ): ProductVariantStocksDelete - - """ - Update stocks for product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantStocksUpdate( - """SKU of product variant for which stocks will be updated.""" - sku: String - - """Input list of stocks to create or update.""" - stocks: [StockInput!]! - - """ID of a product variant for which stocks will be updated.""" - variantId: ID - ): ProductVariantStocksUpdate - - """ - Creates/updates translations for a product variant. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - productVariantTranslate( - """ProductVariant ID or ProductVariantTranslatableContent ID.""" - id: ID! - - """Fields required to update product variant translations.""" - input: NameTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): ProductVariantTranslate - - """ - Updates an existing variant for product. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - productVariantUpdate( - """ - External ID of a product variant to update. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a product to update.""" - id: ID - - """Fields required to update a product variant.""" - input: ProductVariantInput! - - """ - SKU of a product variant to update. - - Added in Saleor 3.8. - """ - sku: String - ): ProductVariantUpdate - - """ - Deletes promotions. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - PROMOTION_DELETED (async): A promotion was deleted. - """ - promotionBulkDelete( - """List of promotion IDs to delete.""" - ids: [ID!]! - ): PromotionBulkDelete - - """ - Creates a new promotion. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - PROMOTION_CREATED (async): A promotion was created. - - PROMOTION_STARTED (async): Optionally called if promotion was started. - """ - promotionCreate( - """Fields requires to create a promotion.""" - input: PromotionCreateInput! - ): PromotionCreate - - """ - Deletes a promotion. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - PROMOTION_DELETED (async): A promotion was deleted. - """ - promotionDelete( - """The ID of the promotion to remove.""" - id: ID! - ): PromotionDelete - - """ - Creates a new promotion rule. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - PROMOTION_RULE_CREATED (async): A promotion rule was created. - """ - promotionRuleCreate( - """Fields required to create a promotion rule.""" - input: PromotionRuleCreateInput! - ): PromotionRuleCreate - - """ - Deletes a promotion rule. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - PROMOTION_RULE_DELETED (async): A promotion rule was deleted. - """ - promotionRuleDelete( - """The ID of the promotion to remove.""" - id: ID! - ): PromotionRuleDelete - - """ - Creates/updates translations for a promotion rule. - - Added in Saleor 3.17. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - promotionRuleTranslate( - """PromotionRule ID or PromotionRuleTranslatableContent ID.""" - id: ID! - - """Fields required to update promotion rule translations.""" - input: PromotionRuleTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): PromotionRuleTranslate - - """ - Updates an existing promotion rule. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - PROMOTION_RULE_UPDATED (async): A promotion rule was updated. - """ - promotionRuleUpdate( - """ID of the promotion rule to update.""" - id: ID! - - """Fields required to create a promotion rule.""" - input: PromotionRuleUpdateInput! - ): PromotionRuleUpdate - - """ - Creates/updates translations for a promotion. - - Added in Saleor 3.17. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - promotionTranslate( - """Promotion ID or PromotionTranslatableContent ID.""" - id: ID! - - """Fields required to update promotion translations.""" - input: PromotionTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): PromotionTranslate - - """ - Updates an existing promotion. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - PROMOTION_UPDATED (async): A promotion was updated. - - PROMOTION_STARTED (async): Optionally called if promotion was started. - - PROMOTION_ENDED (async): Optionally called if promotion was ended. - """ - promotionUpdate( - """ID of the promotion to update.""" - id: ID! - - """Fields required to update a promotion.""" - input: PromotionUpdateInput! - ): PromotionUpdate - - """ - Request email change of the logged in user. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - NOTIFY_USER (async): A notification for account email change. - - ACCOUNT_CHANGE_EMAIL_REQUESTED (async): An account email change was requested. - """ - requestEmailChange( - """ - Slug of a channel which will be used to notify users. Optional when only one channel exists. - """ - channel: String - - """New user email.""" - newEmail: String! - - """User password.""" - password: String! - - """ - URL of a view where users should be redirected to update the email address. URL in RFC 1808 format. - """ - redirectUrl: String! - ): RequestEmailChange - - """ - Sends an email with the account password modification link. - - Triggers the following webhook events: - - NOTIFY_USER (async): A notification for password reset. - - ACCOUNT_SET_PASSWORD_REQUESTED (async): Setting a new password for the account is requested. - - STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. - """ - requestPasswordReset( - """ - Slug of a channel which will be used for notify user. Optional when only one channel exists. - """ - channel: String - - """Email of the user that will be used for password recovery.""" - email: String! - - """ - URL of a view where users should be redirected to reset the password. URL in RFC 1808 format. - """ - redirectUrl: String! - ): RequestPasswordReset - - """ - Deletes sales. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - SALE_DELETED (async): A sale was deleted. - """ - saleBulkDelete( - """List of sale IDs to delete.""" - ids: [ID!]! - ): SaleBulkDelete - - """ - Adds products, categories, collections to a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` mutation instead. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - SALE_UPDATED (async): A sale was updated. - """ - saleCataloguesAdd( - """ID of a sale.""" - id: ID! - - """Fields required to modify catalogue IDs of sale.""" - input: CatalogueInput! - ): SaleAddCatalogues - - """ - Removes products, categories, collections from a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleUpdate` or `promotionRuleDelete` mutations instead. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - SALE_UPDATED (async): A sale was updated. - """ - saleCataloguesRemove( - """ID of a sale.""" - id: ID! - - """Fields required to modify catalogue IDs of sale.""" - input: CatalogueInput! - ): SaleRemoveCatalogues - - """ - Manage sale's availability in channels. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` or `promotionRuleUpdate` mutations instead. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - saleChannelListingUpdate( - """ID of a sale to update.""" - id: ID! - - """Fields required to update sale channel listings.""" - input: SaleChannelListingInput! - ): SaleChannelListingUpdate - - """ - Creates a new sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionCreate` mutation instead. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - SALE_CREATED (async): A sale was created. - """ - saleCreate( - """Fields required to create a sale.""" - input: SaleInput! - ): SaleCreate - - """ - Deletes a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionDelete` mutation instead. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - SALE_DELETED (async): A sale was deleted. - """ - saleDelete( - """ID of a sale to delete.""" - id: ID! - ): SaleDelete - - """ - Creates/updates translations for a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PromotionTranslate` mutation instead. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - saleTranslate( - """Sale ID or SaleTranslatableContent ID.""" - id: ID! - - """Fields required to update sale translations.""" - input: NameTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): SaleTranslate - - """ - Updates a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionUpdate` mutation instead. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - SALE_UPDATED (async): A sale was updated. - - SALE_TOGGLE (async): Optionally triggered when a sale is started or stopped. - """ - saleUpdate( - """ID of a sale to update.""" - id: ID! - - """Fields required to update a sale.""" - input: SaleInput! - ): SaleUpdate - - """ - Sends a notification confirmation. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - NOTIFY_USER (async): A notification for account confirmation. - - ACCOUNT_CONFIRMATION_REQUESTED (async): An account confirmation was requested. This event is always sent regardless of settings. - """ - sendConfirmationEmail( - """Slug of a channel which will be used for notify user.""" - channel: String! - - """Base of frontend URL that will be needed to create confirmation URL.""" - redirectUrl: String! - ): SendConfirmationEmail - - """ - Sets the user's password from the token sent by email using the RequestPasswordReset mutation. - """ - setPassword( - """Email of a user.""" - email: String! - - """Password of a user.""" - password: String! - - """A one-time token required to set the password.""" - token: String! - ): SetPassword - - """ - Manage shipping method's availability in channels. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingMethodChannelListingUpdate( - """ID of a shipping method to update.""" - id: ID! - - """Fields required to update shipping method channel listings.""" - input: ShippingMethodChannelListingInput! - ): ShippingMethodChannelListingUpdate - - """ - Deletes shipping prices. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingPriceBulkDelete( - """List of shipping price IDs to delete.""" - ids: [ID!]! - ): ShippingPriceBulkDelete - - """ - Creates a new shipping price. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingPriceCreate( - """Fields required to create a shipping price.""" - input: ShippingPriceInput! - ): ShippingPriceCreate - - """ - Deletes a shipping price. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingPriceDelete( - """ID of a shipping price to delete.""" - id: ID! - ): ShippingPriceDelete - - """ - Exclude products from shipping price. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingPriceExcludeProducts( - """ID of a shipping price.""" - id: ID! - - """Exclude products input.""" - input: ShippingPriceExcludeProductsInput! - ): ShippingPriceExcludeProducts - - """ - Remove product from excluded list for shipping price. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingPriceRemoveProductFromExclude( - """ID of a shipping price.""" - id: ID! - - """List of products which will be removed from excluded list.""" - products: [ID!]! - ): ShippingPriceRemoveProductFromExclude - - """ - Creates/updates translations for a shipping method. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - shippingPriceTranslate( - """ShippingMethodType ID or ShippingMethodTranslatableContent ID.""" - id: ID! - - """Fields required to update shipping price translations.""" - input: ShippingPriceTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): ShippingPriceTranslate - - """ - Updates a new shipping price. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingPriceUpdate( - """ID of a shipping price to update.""" - id: ID! - - """Fields required to update a shipping price.""" - input: ShippingPriceInput! - ): ShippingPriceUpdate - - """ - Deletes shipping zones. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingZoneBulkDelete( - """List of shipping zone IDs to delete.""" - ids: [ID!]! - ): ShippingZoneBulkDelete - - """ - Creates a new shipping zone. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingZoneCreate( - """Fields required to create a shipping zone.""" - input: ShippingZoneCreateInput! - ): ShippingZoneCreate - - """ - Deletes a shipping zone. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingZoneDelete( - """ID of a shipping zone to delete.""" - id: ID! - ): ShippingZoneDelete - - """ - Updates a new shipping zone. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingZoneUpdate( - """ID of a shipping zone to update.""" - id: ID! - - """Fields required to update a shipping zone.""" - input: ShippingZoneUpdateInput! - ): ShippingZoneUpdate - - """ - Update the shop's address. If the `null` value is passed, the currently selected address will be deleted. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - shopAddressUpdate( - """Fields required to update shop address.""" - input: AddressInput - ): ShopAddressUpdate - - """ - Updates site domain of the shop. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - shopDomainUpdate( - """Fields required to update site.""" - input: SiteDomainInput - ): ShopDomainUpdate @deprecated(reason: "\\n\\nDEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead.") - - """ - Fetch tax rates. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - shopFetchTaxRates: ShopFetchTaxRates @deprecated(reason: "\\n\\nDEPRECATED: this mutation will be removed in Saleor 4.0.") - - """ - Creates/updates translations for shop settings. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - shopSettingsTranslate( - """Fields required to update shop settings translations.""" - input: ShopSettingsTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): ShopSettingsTranslate - - """ - Updates shop settings. - - Requires one of the following permissions: MANAGE_SETTINGS. - - Triggers the following webhook events: - - SHOP_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. - """ - shopSettingsUpdate( - """Fields required to update shop settings.""" - input: ShopSettingsInput! - ): ShopSettingsUpdate - - """ - Deletes staff users. Apps are not allowed to perform this mutation. - - Requires one of the following permissions: MANAGE_STAFF. - - Triggers the following webhook events: - - STAFF_DELETED (async): A staff account was deleted. - """ - staffBulkDelete( - """List of user IDs to delete.""" - ids: [ID!]! - ): StaffBulkDelete - - """ - Creates a new staff user. Apps are not allowed to perform this mutation. - - Requires one of the following permissions: MANAGE_STAFF. - - Triggers the following webhook events: - - STAFF_CREATED (async): A new staff account was created. - - NOTIFY_USER (async): A notification for setting the password. - - STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. - """ - staffCreate( - """Fields required to create a staff user.""" - input: StaffCreateInput! - ): StaffCreate - - """ - Deletes a staff user. Apps are not allowed to perform this mutation. - - Requires one of the following permissions: MANAGE_STAFF. - - Triggers the following webhook events: - - STAFF_DELETED (async): A staff account was deleted. - """ - staffDelete( - """ID of a staff user to delete.""" - id: ID! - ): StaffDelete - - """ - Creates a new staff notification recipient. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - staffNotificationRecipientCreate( - """Fields required to create a staff notification recipient.""" - input: StaffNotificationRecipientInput! - ): StaffNotificationRecipientCreate - - """ - Delete staff notification recipient. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - staffNotificationRecipientDelete( - """ID of a staff notification recipient to delete.""" - id: ID! - ): StaffNotificationRecipientDelete - - """ - Updates a staff notification recipient. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - staffNotificationRecipientUpdate( - """ID of a staff notification recipient to update.""" - id: ID! - - """Fields required to update a staff notification recipient.""" - input: StaffNotificationRecipientInput! - ): StaffNotificationRecipientUpdate - - """ - Updates an existing staff user. Apps are not allowed to perform this mutation. - - Requires one of the following permissions: MANAGE_STAFF. - - Triggers the following webhook events: - - STAFF_UPDATED (async): A staff account was updated. - """ - staffUpdate( - """ID of a staff user to update.""" - id: ID! - - """Fields required to update a staff user.""" - input: StaffUpdateInput! - ): StaffUpdate - - """ - Updates stocks for a given variant and warehouse. Variant and warehouse selectors have to be the same for all stock inputs. Is not allowed to use 'variantId' in one input and 'variantExternalReference' in another. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_PRODUCTS. - - Triggers the following webhook events: - - PRODUCT_VARIANT_STOCK_UPDATED (async): A product variant stock details were updated. - """ - stockBulkUpdate( - """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" - errorPolicy: ErrorPolicyEnum - - """Input list of stocks to update.""" - stocks: [StockBulkUpdateInput!]! - ): StockBulkUpdate - - """ - Request to delete a stored payment method on payment provider side. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: AUTHENTICATED_USER. - - Triggers the following webhook events: - - STORED_PAYMENT_METHOD_DELETE_REQUESTED (sync): The customer requested to delete a payment method. - """ - storedPaymentMethodRequestDelete( - """Slug of a channel related to delete request.""" - channel: String! - - """The ID of the payment method.""" - id: ID! - ): StoredPaymentMethodRequestDelete - - """ - Create a tax class. - - Added in Saleor 3.9. - - Requires one of the following permissions: MANAGE_TAXES. - """ - taxClassCreate( - """Fields required to create a tax class.""" - input: TaxClassCreateInput! - ): TaxClassCreate - - """ - Delete a tax class. After deleting the tax class any products, product types or shipping methods using it are updated to use the default tax class. - - Added in Saleor 3.9. - - Requires one of the following permissions: MANAGE_TAXES. - """ - taxClassDelete( - """ID of a tax class to delete.""" - id: ID! - ): TaxClassDelete - - """ - Update a tax class. - - Added in Saleor 3.9. - - Requires one of the following permissions: MANAGE_TAXES. - """ - taxClassUpdate( - """ID of the tax class.""" - id: ID! - - """Fields required to update a tax class.""" - input: TaxClassUpdateInput! - ): TaxClassUpdate - - """ - Update tax configuration for a channel. - - Added in Saleor 3.9. - - Requires one of the following permissions: MANAGE_TAXES. - """ - taxConfigurationUpdate( - """ID of the tax configuration.""" - id: ID! - - """Fields required to update the tax configuration.""" - input: TaxConfigurationUpdateInput! - ): TaxConfigurationUpdate - - """ - Remove all tax class rates for a specific country. - - Added in Saleor 3.9. - - Requires one of the following permissions: MANAGE_TAXES. - """ - taxCountryConfigurationDelete( - """Country in which to update the tax class rates.""" - countryCode: CountryCode! - ): TaxCountryConfigurationDelete - - """ - Update tax class rates for a specific country. - - Added in Saleor 3.9. - - Requires one of the following permissions: MANAGE_TAXES. - """ - taxCountryConfigurationUpdate( - """Country in which to update the tax class rates.""" - countryCode: CountryCode! - - """ - List of tax rates per tax class to update. When `{taxClass: id, rate: null`} is passed, it deletes the rate object for given taxClass ID. When `{rate: Int}` is passed without a tax class, it updates the default tax class for this country. - """ - updateTaxClassRates: [TaxClassRateInput!]! - ): TaxCountryConfigurationUpdate - - """ - Exempt checkout or order from charging the taxes. When tax exemption is enabled, taxes won't be charged for the checkout or order. Taxes may still be calculated in cases when product prices are entered with the tax included and the net price needs to be known. - - Added in Saleor 3.8. - - Requires one of the following permissions: MANAGE_TAXES. - """ - taxExemptionManage( - """ID of the Checkout or Order object.""" - id: ID! - - """Determines if a taxes should be exempt.""" - taxExemption: Boolean! - ): TaxExemptionManage - - """Create JWT token.""" - tokenCreate( - """ - The audience that will be included to JWT tokens with prefix `custom:`. - - Added in Saleor 3.8. - """ - audience: String - - """Email of a user.""" - email: String! - - """Password of a user.""" - password: String! - ): CreateToken - - """ - Refresh JWT token. Mutation tries to take refreshToken from the input. If it fails it will try to take `refreshToken` from the http-only cookie `refreshToken`. `csrfToken` is required when `refreshToken` is provided as a cookie. - """ - tokenRefresh( - """ - CSRF token required to refresh token. This argument is required when `refreshToken` is provided as a cookie. - """ - csrfToken: String - - """Refresh token.""" - refreshToken: String - ): RefreshToken - - """Verify JWT token.""" - tokenVerify( - """JWT token to validate.""" - token: String! - ): VerifyToken - - """ - Deactivate all JWT tokens of the currently authenticated user. - - Requires one of the following permissions: AUTHENTICATED_USER. - """ - tokensDeactivateAll: DeactivateAllUserTokens - - """ - Create transaction for checkout or order. - - Added in Saleor 3.4. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: HANDLE_PAYMENTS. - """ - transactionCreate( - """The ID of the checkout or order.""" - id: ID! - - """Input data required to create a new transaction object.""" - transaction: TransactionCreateInput! - - """Data that defines a transaction event.""" - transactionEvent: TransactionEventInput - ): TransactionCreate - - """ - Report the event for the transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. - """ - transactionEventReport( - """ - The amount of the event to report. - - Required for all `REQUEST`, `SUCCESS`, `ACTION_REQUIRED`, and `ADJUSTMENT` events. For other events, the amount will be calculated based on the previous events with the same pspReference. If not possible to calculate, the mutation will return an error. - """ - amount: PositiveDecimal - - """List of all possible actions for the transaction""" - availableActions: [TransactionActionEnum!] - - """ - The url that will allow to redirect user to payment provider page with event details. - """ - externalUrl: String - - """The ID of the transaction. One of field id or token is required.""" - id: ID - - """The message related to the event.""" - message: String - - """PSP Reference of the event to report.""" - pspReference: String! - - """ - The time of the event to report. If not provide, the current time will be used. - """ - time: DateTime - - """ - The token of the transaction. One of field id or token is required. - - Added in Saleor 3.14. - """ - token: UUID - - """Current status of the event to report.""" - type: TransactionEventTypeEnum! - ): TransactionEventReport - - """ - Initializes a transaction session. It triggers the webhook `TRANSACTION_INITIALIZE_SESSION`, to the requested `paymentGateways`. There is a limit of 100 transaction items per checkout / order. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - transactionInitialize( - """ - The expected action called for the transaction. By default, the `channel.paymentSettings.defaultTransactionFlowStrategy` will be used.The field can be used only by app that has `HANDLE_PAYMENTS` permission. - """ - action: TransactionFlowStrategyEnum - - """ - The amount requested for initializing the payment gateway. If not provided, the difference between checkout.total - transactions that are already processed will be send. - """ - amount: PositiveDecimal - - """ - The customer's IP address. If not provided Saleor will try to determine the customer's IP address on its own. The customer's IP address will be passed to the payment app. The IP should be in ipv4 or ipv6 format. The field can be used only by an app that has `HANDLE_PAYMENTS` permission. - - Added in Saleor 3.16. - """ - customerIpAddress: String - - """The ID of the checkout or order.""" - id: ID! - - """ - The idempotency key assigned to the action. It will be passed to the payment app to discover potential duplicate actions. If not provided, the default one will be generated. If empty string provided, INVALID error code will be raised. - - Added in Saleor 3.14. - """ - idempotencyKey: String - - """Payment gateway used to initialize the transaction.""" - paymentGateway: PaymentGatewayToInitialize! - ): TransactionInitialize - - """ - Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - transactionProcess( - """ - The customer's IP address. If not provided Saleor will try to determine the customer's IP address on its own. The customer's IP address will be passed to the payment app. The IP should be in ipv4 or ipv6 format. The field can be used only by an app that has `HANDLE_PAYMENTS` permission. - - Added in Saleor 3.16. - """ - customerIpAddress: String - - """The data that will be passed to the payment gateway.""" - data: JSON - - """ - The ID of the transaction to process. One of field id or token is required. - """ - id: ID - - """ - The token of the transaction to process. One of field id or token is required. - - Added in Saleor 3.14. - """ - token: UUID - ): TransactionProcess - - """ - Request an action for payment transaction. - - Added in Saleor 3.4. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: HANDLE_PAYMENTS. - """ - transactionRequestAction( - """Determines the action type.""" - actionType: TransactionActionEnum! - - """ - Transaction request amount. If empty for refund or capture, maximal possible amount will be used. - """ - amount: PositiveDecimal - - """The ID of the transaction. One of field id or token is required.""" - id: ID - - """ - The token of the transaction. One of field id or token is required. - - Added in Saleor 3.14. - """ - token: UUID - ): TransactionRequestAction - - """ - Request a refund for payment transaction based on granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: HANDLE_PAYMENTS. - """ - transactionRequestRefundForGrantedRefund( - """The ID of the granted refund.""" - grantedRefundId: ID! - - """ - The ID of the transaction. One of field id or token is required, if `transactionItem` is not already assigned to the `orderGrantedRefund`. If `transactionItem` is already assigned to the grantedRefund the field will be ignored. - """ - id: ID - - """ - The token of the transaction. One of field id or token is required, if `transactionItem` is not already assigned to the `orderGrantedRefund`. If `transactionItem` is already assigned to the grantedRefund the field will be ignored. - """ - token: UUID - ): TransactionRequestRefundForGrantedRefund - - """ - Update transaction. - - Added in Saleor 3.4. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. - """ - transactionUpdate( - """The ID of the transaction. One of field id or token is required.""" - id: ID - - """ - The token of the transaction. One of field id or token is required. - - Added in Saleor 3.14. - """ - token: UUID - - """Input data required to create a new transaction object.""" - transaction: TransactionUpdateInput - - """Data that defines a transaction transaction.""" - transactionEvent: TransactionEventInput - ): TransactionUpdate - - """ - Remove shipping zone from given warehouse. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - unassignWarehouseShippingZone( - """ID of a warehouse to update.""" - id: ID! - - """List of shipping zone IDs.""" - shippingZoneIds: [ID!]! - ): WarehouseShippingZoneUnassign - - """ - Updates metadata of an object. To use it, you need to have access to the modified object. - """ - updateMetadata( - """ID or token (for Order and Checkout) of an object to update.""" - id: ID! - - """Fields required to update the object's metadata.""" - input: [MetadataInput!]! - ): UpdateMetadata - - """ - Updates private metadata of an object. To use it, you need to be an authenticated staff user or an app and have access to the modified object. - """ - updatePrivateMetadata( - """ID or token (for Order and Checkout) of an object to update.""" - id: ID! - - """Fields required to update the object's metadata.""" - input: [MetadataInput!]! - ): UpdatePrivateMetadata - - """ - Updates given warehouse. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - updateWarehouse( - """ - External reference of a warehouse. - - Added in Saleor 3.16. - """ - externalReference: String - - """ID of a warehouse to update.""" - id: ID - - """Fields required to update warehouse.""" - input: WarehouseUpdateInput! - ): WarehouseUpdate - - """ - Deletes a user avatar. Only for staff members. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER. - """ - userAvatarDelete: UserAvatarDelete - - """ - Create a user avatar. Only for staff members. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER. - """ - userAvatarUpdate( - """Represents an image file in a multipart request.""" - image: Upload! - ): UserAvatarUpdate - - """ - Activate or deactivate users. - - Requires one of the following permissions: MANAGE_USERS. - """ - userBulkSetActive( - """List of user IDs to activate/deactivate.""" - ids: [ID!]! - - """Determine if users will be set active or not.""" - isActive: Boolean! - ): UserBulkSetActive - - """ - Assign an media to a product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - variantMediaAssign( - """ID of a product media to assign to a variant.""" - mediaId: ID! - - """ID of a product variant.""" - variantId: ID! - ): VariantMediaAssign - - """ - Unassign an media from a product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - variantMediaUnassign( - """ID of a product media to unassign from a variant.""" - mediaId: ID! - - """ID of a product variant.""" - variantId: ID! - ): VariantMediaUnassign - - """ - Deletes vouchers. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_DELETED (async): A voucher was deleted. - """ - voucherBulkDelete( - """List of voucher IDs to delete.""" - ids: [ID!]! - ): VoucherBulkDelete - - """ - Adds products, categories, collections to a voucher. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_UPDATED (async): A voucher was updated. - """ - voucherCataloguesAdd( - """ID of a voucher.""" - id: ID! - - """Fields required to modify catalogue IDs of voucher.""" - input: CatalogueInput! - ): VoucherAddCatalogues - - """ - Removes products, categories, collections from a voucher. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_UPDATED (async): A voucher was updated. - """ - voucherCataloguesRemove( - """ID of a voucher.""" - id: ID! - - """Fields required to modify catalogue IDs of voucher.""" - input: CatalogueInput! - ): VoucherRemoveCatalogues - - """ - Manage voucher's availability in channels. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_UPDATED (async): A voucher was updated. - """ - voucherChannelListingUpdate( - """ID of a voucher to update.""" - id: ID! - - """Fields required to update voucher channel listings.""" - input: VoucherChannelListingInput! - ): VoucherChannelListingUpdate - - """ - Deletes voucher codes. - - Added in Saleor 3.18. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_CODES_DELETED (async): A voucher codes were deleted. - """ - voucherCodeBulkDelete( - """List of voucher codes IDs to delete.""" - ids: [ID!]! - ): VoucherCodeBulkDelete - - """ - Creates a new voucher. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_CREATED (async): A voucher was created. - - VOUCHER_CODES_CREATED (async): A voucher codes were created. - """ - voucherCreate( - """Fields required to create a voucher.""" - input: VoucherInput! - ): VoucherCreate - - """ - Deletes a voucher. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_DELETED (async): A voucher was deleted. - """ - voucherDelete( - """ID of a voucher to delete.""" - id: ID! - ): VoucherDelete - - """ - Creates/updates translations for a voucher. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - voucherTranslate( - """Voucher ID or VoucherTranslatableContent ID.""" - id: ID! - - """Fields required to update voucher translations.""" - input: NameTranslationInput! - - """Translation language code.""" - languageCode: LanguageCodeEnum! - ): VoucherTranslate - - """ - Updates a voucher. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - - Triggers the following webhook events: - - VOUCHER_UPDATED (async): A voucher was updated. - - VOUCHER_CODES_CREATED (async): A voucher code was created. - """ - voucherUpdate( - """ID of a voucher to update.""" - id: ID! - - """Fields required to update a voucher.""" - input: VoucherInput! - ): VoucherUpdate - - """ - Creates a new webhook subscription. - - Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. - """ - webhookCreate( - """Fields required to create a webhook.""" - input: WebhookCreateInput! - ): WebhookCreate - - """ - Delete a webhook. Before the deletion, the webhook is deactivated to pause any deliveries that are already scheduled. The deletion might fail if delivery is in progress. In such a case, the webhook is not deleted but remains deactivated. - - Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. - """ - webhookDelete( - """ID of a webhook to delete.""" - id: ID! - ): WebhookDelete - - """ - Performs a dry run of a webhook event. Supports a single event (the first, if multiple provided in the `query`). Requires permission relevant to processed event. - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER. - """ - webhookDryRun( - """The ID of an object to serialize.""" - objectId: ID! - - """The subscription query that defines the webhook event and its payload.""" - query: String! - ): WebhookDryRun - - """ - Trigger a webhook event. Supports a single event (the first, if multiple provided in the `webhook.subscription_query`). Requires permission relevant to processed event. Successfully delivered webhook returns `delivery` with status='PENDING' and empty payload. - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER. - """ - webhookTrigger( - """The ID of an object to serialize.""" - objectId: ID! - - """The ID of the webhook.""" - webhookId: ID! - ): WebhookTrigger - - """ - Updates a webhook subscription. - - Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. - """ - webhookUpdate( - """ID of a webhook to update.""" - id: ID! - - """Fields required to update a webhook.""" - input: WebhookUpdateInput! - ): WebhookUpdate -} - -input NameTranslationInput { - name: String -} - -enum NavigationType { - """Main storefront navigation.""" - MAIN - - """Secondary storefront navigation.""" - SECONDARY -} - -"""An object with an ID""" -interface Node { - """The ID of the object.""" - id: ID! -} - -interface ObjectWithMetadata { - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - """ - metafields(keys: [String!]): Metadata - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - """ - privateMetafields(keys: [String!]): Metadata -} - -"""Represents an order in the shop.""" -type Order implements Node & ObjectWithMetadata { - """ - List of actions that can be performed in the current state of an order. - """ - actions: [OrderAction!]! - - """ - The authorize status of the order. - - Added in Saleor 3.4. - """ - authorizeStatus: OrderAuthorizeStatusEnum! - - """ - Collection points that can be used for this order. - - Added in Saleor 3.1. - """ - availableCollectionPoints: [Warehouse!]! - - """Shipping methods that can be used with this order.""" - availableShippingMethods: [ShippingMethod!] @deprecated(reason: "Use `shippingMethods`, this field will be removed in 4.0") - - """ - Billing address. The full data can be access for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_ORDERS, OWNER. - """ - billingAddress: Address - - """ - Informs whether a draft order can be finalized(turned into a regular order). - """ - canFinalize: Boolean! - - """Channel through which the order was placed.""" - channel: Channel! - - """ - The charge status of the order. - - Added in Saleor 3.4. - """ - chargeStatus: OrderChargeStatusEnum! - - """ - ID of the checkout that the order was created from. - - Added in Saleor 3.11. - """ - checkoutId: ID - - """ - Name of the collection point where the order should be picked up by the customer. - """ - collectionPointName: String - - """Date and time when the order was created.""" - created: DateTime! - - """Additional information provided by the customer about the order.""" - customerNote: String! - - """ - The delivery method selected for this order. - - Added in Saleor 3.1. - """ - deliveryMethod: DeliveryMethod - - """Returns applied discount.""" - discount: Money @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `discounts` field instead.") - - """Discount name.""" - discountName: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `discounts` field instead.") - - """List of all discounts assigned to the order.""" - discounts: [OrderDiscount!]! - - """ - Determines whether displayed prices should include taxes. - - Added in Saleor 3.9. - """ - displayGrossPrices: Boolean! - - """List of errors that occurred during order validation.""" - errors: [OrderError!]! - - """ - List of events associated with the order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - events: [OrderEvent!]! - - """ - External ID of this order. - - Added in Saleor 3.10. - """ - externalReference: String - - """List of shipments for the order.""" - fulfillments: [Fulfillment!]! - - """List of user gift cards.""" - giftCards: [GiftCard!]! - - """ - List of granted refunds. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - grantedRefunds: [OrderGrantedRefund!]! - - """ID of the order.""" - id: ID! - - """ - List of order invoices. Can be fetched for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_ORDERS, OWNER. - """ - invoices: [Invoice!]! - - """Informs if an order is fully paid.""" - isPaid: Boolean! - - """Returns True, if order requires shipping.""" - isShippingRequired: Boolean! - languageCode: String! @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `languageCodeEnum` field to fetch the language code. ") - - """Order language code.""" - languageCodeEnum: LanguageCodeEnum! - - """List of order lines.""" - lines: [OrderLine!]! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """User-friendly number of an order.""" - number: String! - - """The order origin.""" - origin: OrderOriginEnum! - - """The ID of the order that was the base for this order.""" - original: ID - - """Internal payment status.""" - paymentStatus: PaymentChargeStatusEnum! - - """User-friendly payment status.""" - paymentStatusDisplay: String! - - """List of payments for the order.""" - payments: [Payment!]! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """URL to which user should be redirected after order is placed.""" - redirectUrl: String - - """ - Shipping address. The full data can be access for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_ORDERS, OWNER. - """ - shippingAddress: Address - - """Shipping method for this order.""" - shippingMethod: ShippingMethod @deprecated(reason: "This field will be removed in Saleor 4.0. Use `deliveryMethod` instead.") - - """Method used for shipping.""" - shippingMethodName: String - - """Shipping methods related to this order.""" - shippingMethods: [ShippingMethod!]! - - """Total price of shipping.""" - shippingPrice: TaxedMoney! - - """ - Denormalized tax class assigned to the shipping method. - - Added in Saleor 3.9. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - shippingTaxClass: TaxClass - - """ - Denormalized public metadata of the shipping method's tax class. - - Added in Saleor 3.9. - """ - shippingTaxClassMetadata: [MetadataItem!]! - - """ - Denormalized name of the tax class assigned to the shipping method. - - Added in Saleor 3.9. - """ - shippingTaxClassName: String - - """ - Denormalized private metadata of the shipping method's tax class. Requires staff permissions to access. - - Added in Saleor 3.9. - """ - shippingTaxClassPrivateMetadata: [MetadataItem!]! - - """The shipping tax rate value.""" - shippingTaxRate: Float! - - """Status of the order.""" - status: OrderStatus! - - """User-friendly order status.""" - statusDisplay: String! - - """The sum of line prices not including shipping.""" - subtotal: TaxedMoney! - - """ - Returns True if order has to be exempt from taxes. - - Added in Saleor 3.8. - """ - taxExemption: Boolean! - token: String! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `id` instead.") - - """Total amount of the order.""" - total: TaxedMoney! - - """ - Total amount of ongoing authorize requests for the order's transactions. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - totalAuthorizePending: Money! - - """Amount authorized for the order.""" - totalAuthorized: Money! - - """The difference between the paid and the order total amount.""" - totalBalance: Money! - - """ - Total amount of ongoing cancel requests for the order's transactions. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - totalCancelPending: Money! - - """ - Amount canceled for the order. - - Added in Saleor 3.13. - """ - totalCanceled: Money! - - """Amount captured for the order.""" - totalCaptured: Money! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `totalCharged` instead.") - - """ - Total amount of ongoing charge requests for the order's transactions. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - totalChargePending: Money! - - """ - Amount charged for the order. - - Added in Saleor 3.13. - """ - totalCharged: Money! - - """ - Total amount of granted refund. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - totalGrantedRefund: Money! - - """ - Total amount of ongoing refund requests for the order's transactions. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - totalRefundPending: Money! - - """ - Total refund amount for the order. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - totalRefunded: Money! - - """ - The difference amount between granted refund and the amounts that are pending and refunded. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - totalRemainingGrant: Money! - - """ - Google Analytics tracking client ID. This field will be removed in Saleor 4.0. - """ - trackingClientId: String! - - """ - List of transactions for the order. Requires one of the following permissions: MANAGE_ORDERS, HANDLE_PAYMENTS. - - Added in Saleor 3.4. - """ - transactions: [TransactionItem!]! - - """Translated discount name.""" - translatedDiscountName: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `discounts` field instead. ") - - """ - Undiscounted total price of shipping. - - Added in Saleor 3.19. - """ - undiscountedShippingPrice: Money - - """Undiscounted total amount of the order.""" - undiscountedTotal: TaxedMoney! - - """Date and time when the order was created.""" - updatedAt: DateTime! - - """ - User who placed the order. This field is set only for orders placed by authenticated users. Can be fetched for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_USERS, MANAGE_ORDERS, HANDLE_PAYMENTS, OWNER. - """ - user: User - - """ - Email address of the customer. The full data can be access for orders created in Saleor 3.2 and later, for other orders requires one of the following permissions: MANAGE_ORDERS, OWNER. - """ - userEmail: String - - """Voucher linked to the order.""" - voucher: Voucher - - """ - Voucher code that was used for Order. - - Added in Saleor 3.18. - """ - voucherCode: String - - """Weight of the order.""" - weight: Weight! -} - -enum OrderAction { - """Represents the capture action.""" - CAPTURE - - """Represents a mark-as-paid action.""" - MARK_AS_PAID - - """Represents a refund action.""" - REFUND - - """Represents a void action.""" - VOID -} - -""" -Adds note to the order. - -DEPRECATED: this mutation will be removed in Saleor 4.0. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderAddNote { - errors: [OrderError!]! - - """Order note created.""" - event: OrderEvent - - """Order with the note added.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input OrderAddNoteInput { - """ - Note message. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - message: String! -} - -""" -Determine a current authorize status for order. - - We treat the order as fully authorized when the sum of authorized and charged funds - cover the `order.total`-`order.totalGrantedRefund`. - We treat the order as partially authorized when the sum of authorized and charged - funds covers only part of the `order.total`-`order.totalGrantedRefund`. - We treat the order as not authorized when the sum of authorized and charged funds is - 0. - - NONE - the funds are not authorized - PARTIAL - the funds that are authorized and charged don't cover fully the - `order.total`-`order.totalGrantedRefund` - FULL - the funds that are authorized and charged fully cover the - `order.total`-`order.totalGrantedRefund` -""" -enum OrderAuthorizeStatusEnum { - FULL - NONE - PARTIAL -} - -""" -Cancels orders. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderBulkCancel { - """Returns how many objects were affected.""" - count: Int! - errors: [OrderError!]! - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Creates multiple orders. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_ORDERS_IMPORT. -""" -type OrderBulkCreate { - """Returns how many objects were created.""" - count: Int! - errors: [OrderBulkCreateError!]! - - """List of the created orders.""" - results: [OrderBulkCreateResult!]! -} - -input OrderBulkCreateDeliveryMethodInput { - """The ID of the shipping method.""" - shippingMethodId: ID - - """The name of the shipping method.""" - shippingMethodName: String - - """The price of the shipping.""" - shippingPrice: TaxedMoneyInput - - """The ID of the tax class.""" - shippingTaxClassId: ID - - """Metadata of the tax class.""" - shippingTaxClassMetadata: [MetadataInput!] - - """The name of the tax class.""" - shippingTaxClassName: String - - """Private metadata of the tax class.""" - shippingTaxClassPrivateMetadata: [MetadataInput!] - - """Tax rate of the shipping.""" - shippingTaxRate: PositiveDecimal - - """The ID of the warehouse.""" - warehouseId: ID - - """The name of the warehouse.""" - warehouseName: String -} - -type OrderBulkCreateError { - """The error code.""" - code: OrderBulkCreateErrorCode - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String -} - -"""An enumeration.""" -enum OrderBulkCreateErrorCode { - BULK_LIMIT - FUTURE_DATE - GRAPHQL_ERROR - INCORRECT_CURRENCY - INSUFFICIENT_STOCK - INVALID - INVALID_QUANTITY - METADATA_KEY_REQUIRED - NEGATIVE_INDEX - NON_EXISTING_STOCK - NOTE_LENGTH - NOT_FOUND - NO_RELATED_ORDER_LINE - ORDER_LINE_FULFILLMENT_LINE_MISMATCH - PRICE_ERROR - REQUIRED - TOO_MANY_IDENTIFIERS - UNIQUE -} - -input OrderBulkCreateFulfillmentInput { - """List of items informing how to fulfill the order.""" - lines: [OrderBulkCreateFulfillmentLineInput!] - - """Fulfillment's tracking code.""" - trackingCode: String -} - -input OrderBulkCreateFulfillmentLineInput { - """0-based index of order line, which the fulfillment line refers to.""" - orderLineIndex: Int! - - """The number of line items to be fulfilled from given warehouse.""" - quantity: Int! - - """The external ID of the product variant.""" - variantExternalReference: String - - """The ID of the product variant.""" - variantId: ID - - """The SKU of the product variant.""" - variantSku: String - - """ID of the warehouse from which the item will be fulfilled.""" - warehouse: ID! -} - -input OrderBulkCreateInput { - """Billing address of the customer.""" - billingAddress: AddressInput! - - """Slug of the channel associated with the order.""" - channel: String! - - """The date, when the order was inserted to Saleor database.""" - createdAt: DateTime! - - """Currency code.""" - currency: String! - - """Note about customer.""" - customerNote: String - - """The delivery method selected for this order.""" - deliveryMethod: OrderBulkCreateDeliveryMethodInput - - """List of discounts.""" - discounts: [OrderDiscountCommonInput!] - - """Determines whether displayed prices should include taxes.""" - displayGrossPrices: Boolean - - """External ID of the order.""" - externalReference: String - - """Fulfillments of the order.""" - fulfillments: [OrderBulkCreateFulfillmentInput!] - - """List of gift card codes associated with the order.""" - giftCards: [String!] - - """Invoices related to the order.""" - invoices: [OrderBulkCreateInvoiceInput!] - - """Order language code.""" - languageCode: LanguageCodeEnum! - - """List of order lines.""" - lines: [OrderBulkCreateOrderLineInput!]! - - """Metadata of the order.""" - metadata: [MetadataInput!] - - """Notes related to the order.""" - notes: [OrderBulkCreateNoteInput!] - - """Private metadata of the order.""" - privateMetadata: [MetadataInput!] - - """ - URL of a view, where users should be redirected to see the order details. - """ - redirectUrl: String - - """Shipping address of the customer.""" - shippingAddress: AddressInput - - """Status of the order.""" - status: OrderStatus - - """Transactions related to the order.""" - transactions: [TransactionCreateInput!] - - """Customer associated with the order.""" - user: OrderBulkCreateUserInput! - - """ - Code of a voucher associated with the order. - - Added in Saleor 3.18. - """ - voucherCode: String - - """Weight of the order in kg.""" - weight: WeightScalar -} - -input OrderBulkCreateInvoiceInput { - """The date, when the invoice was created.""" - createdAt: DateTime! - - """Metadata of the invoice.""" - metadata: [MetadataInput!] - - """Invoice number.""" - number: String - - """Private metadata of the invoice.""" - privateMetadata: [MetadataInput!] - - """URL of the invoice to download.""" - url: String -} - -input OrderBulkCreateNoteInput { - """The app ID associated with the message.""" - appId: ID - - """The date associated with the message.""" - date: DateTime - - """Note message. Max characters: 255.""" - message: String! - - """The user email associated with the message.""" - userEmail: ID - - """The user external ID associated with the message.""" - userExternalReference: ID - - """The user ID associated with the message.""" - userId: ID -} - -input OrderBulkCreateOrderLineInput { - """The date, when the order line was created.""" - createdAt: DateTime! - - """Gift card flag.""" - isGiftCard: Boolean! - - """Determines whether shipping of the order line items is required.""" - isShippingRequired: Boolean! - - """Metadata of the order line.""" - metadata: [MetadataInput!] - - """Private metadata of the order line.""" - privateMetadata: [MetadataInput!] - - """The name of the product.""" - productName: String - - """Number of items in the order line""" - quantity: Int! - - """The ID of the tax class.""" - taxClassId: ID - - """Metadata of the tax class.""" - taxClassMetadata: [MetadataInput!] - - """The name of the tax class.""" - taxClassName: String - - """Private metadata of the tax class.""" - taxClassPrivateMetadata: [MetadataInput!] - - """Tax rate of the order line.""" - taxRate: PositiveDecimal - - """Price of the order line.""" - totalPrice: TaxedMoneyInput! - - """Translation of the product name.""" - translatedProductName: String - - """Translation of the product variant name.""" - translatedVariantName: String - - """Price of the order line excluding applied discount.""" - undiscountedTotalPrice: TaxedMoneyInput! - - """The external ID of the product variant.""" - variantExternalReference: String - - """The ID of the product variant.""" - variantId: ID - - """The name of the product variant.""" - variantName: String - - """The SKU of the product variant.""" - variantSku: String - - """The ID of the warehouse, where the line will be allocated.""" - warehouse: ID! -} - -type OrderBulkCreateResult { - """List of errors occurred on create attempt.""" - errors: [OrderBulkCreateError!] - - """Order data.""" - order: Order -} - -input OrderBulkCreateUserInput { - """Customer email associated with the order.""" - email: String - - """Customer external ID associated with the order.""" - externalReference: String - - """Customer ID associated with the order.""" - id: ID -} - -""" -Event sent when orders are imported. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type OrderBulkCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The orders the event relates to.""" - orders: [Order!] - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Cancel an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderCancel { - errors: [OrderError!]! - - """Canceled order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when order is canceled. - -Added in Saleor 3.2. -""" -type OrderCancelled implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Capture an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderCapture { - errors: [OrderError!]! - - """Captured order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Determine the current charge status for the order. - - An order is considered overcharged when the sum of the - transactionItem's charge amounts exceeds the value of - `order.total` - `order.totalGrantedRefund`. - If the sum of the transactionItem's charge amounts equals - `order.total` - `order.totalGrantedRefund`, we consider the order to be fully - charged. - If the sum of the transactionItem's charge amounts covers a part of the - `order.total` - `order.totalGrantedRefund`, we treat the order as partially charged. - - NONE - the funds are not charged. - PARTIAL - the funds that are charged don't cover the - `order.total`-`order.totalGrantedRefund` - FULL - the funds that are charged fully cover the - `order.total`-`order.totalGrantedRefund` - OVERCHARGED - the charged funds are bigger than the - `order.total`-`order.totalGrantedRefund` -""" -enum OrderChargeStatusEnum { - FULL - NONE - OVERCHARGED - PARTIAL -} - -""" -Confirms an unconfirmed order by changing status to unfulfilled. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderConfirm { - errors: [OrderError!]! - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when order is confirmed. - -Added in Saleor 3.2. -""" -type OrderConfirmed implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type OrderCountableConnection { - edges: [OrderCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type OrderCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Order! -} - -""" -Create new order from existing checkout. Requires the following permissions: AUTHENTICATED_APP and HANDLE_CHECKOUTS. - -Added in Saleor 3.2. - -Triggers the following webhook events: -- SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. -- CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. -- CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. -- ORDER_CREATED (async): Triggered when order is created. -- NOTIFY_USER (async): A notification for order placement. -- NOTIFY_USER (async): A staff notification for order placement. -- ORDER_UPDATED (async): Triggered when order received the update after placement. -- ORDER_PAID (async): Triggered when newly created order is paid. -- ORDER_FULLY_PAID (async): Triggered when newly created order is fully paid. -- ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. -""" -type OrderCreateFromCheckout { - errors: [OrderCreateFromCheckoutError!]! - - """Placed order.""" - order: Order -} - -type OrderCreateFromCheckoutError { - """The error code.""" - code: OrderCreateFromCheckoutErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """List of line Ids which cause the error.""" - lines: [ID!] - - """The error message.""" - message: String - - """List of variant IDs which causes the error.""" - variants: [ID!] -} - -"""An enumeration.""" -enum OrderCreateFromCheckoutErrorCode { - BILLING_ADDRESS_NOT_SET - CHANNEL_INACTIVE - CHECKOUT_NOT_FOUND - EMAIL_NOT_SET - GIFT_CARD_NOT_APPLICABLE - GRAPHQL_ERROR - INSUFFICIENT_STOCK - INVALID_SHIPPING_METHOD - NO_LINES - SHIPPING_ADDRESS_NOT_SET - SHIPPING_METHOD_NOT_SET - TAX_ERROR - UNAVAILABLE_VARIANT_IN_CHANNEL - VOUCHER_NOT_APPLICABLE -} - -""" -Event sent when new order is created. - -Added in Saleor 3.2. -""" -type OrderCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -enum OrderDirection { - """Specifies an ascending sort order.""" - ASC - - """Specifies a descending sort order.""" - DESC -} - -"""Contains all details related to the applied discount to the order.""" -type OrderDiscount implements Node { - """Returns amount of discount.""" - amount: Money! - - """The ID of discount applied.""" - id: ID! - - """The name of applied discount.""" - name: String - - """ - Explanation for the applied discount. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - reason: String - - """Translated name of the applied discount.""" - translatedName: String - - """The type of applied discount: Sale, Voucher or Manual.""" - type: OrderDiscountType! - - """Value of the discount. Can store fixed value or percent value""" - value: PositiveDecimal! - - """Type of the discount: fixed or percent""" - valueType: DiscountValueTypeEnum! -} - -""" -Adds discount to the order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderDiscountAdd { - errors: [OrderError!]! - - """Order which has been discounted.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input OrderDiscountCommonInput { - """Explanation for the applied discount.""" - reason: String - - """Value of the discount. Can store fixed value or percent value""" - value: PositiveDecimal! - - """Type of the discount: fixed or percent""" - valueType: DiscountValueTypeEnum! -} - -""" -Remove discount from the order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderDiscountDelete { - errors: [OrderError!]! - - """Order which has removed discount.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""An enumeration.""" -enum OrderDiscountType { - MANUAL - ORDER_PROMOTION - PROMOTION - SALE - VOUCHER -} - -""" -Update discount for the order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderDiscountUpdate { - errors: [OrderError!]! - - """Order which has been discounted.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input OrderDraftFilterInput { - channels: [ID!] - created: DateRangeInput - customer: String - metadata: [MetadataFilter!] - search: String -} - -type OrderError { - """A type of address that causes the error.""" - addressType: AddressTypeEnum - - """The error code.""" - code: OrderErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of order line IDs that cause the error.""" - orderLines: [ID!] - - """List of product variants that are associated with the error""" - variants: [ID!] - - """Warehouse ID which causes the error.""" - warehouse: ID -} - -"""An enumeration.""" -enum OrderErrorCode { - BILLING_ADDRESS_NOT_SET - CANNOT_CANCEL_FULFILLMENT - CANNOT_CANCEL_ORDER - CANNOT_DELETE - CANNOT_DISCOUNT - CANNOT_FULFILL_UNPAID_ORDER - CANNOT_REFUND - CAPTURE_INACTIVE_PAYMENT - CHANNEL_INACTIVE - DUPLICATED_INPUT_ITEM - FULFILL_ORDER_LINE - GIFT_CARD_LINE - GRAPHQL_ERROR - INSUFFICIENT_STOCK - INVALID - INVALID_QUANTITY - INVALID_VOUCHER - INVALID_VOUCHER_CODE - NON_EDITABLE_GIFT_LINE - NON_REMOVABLE_GIFT_LINE - NOT_AVAILABLE_IN_CHANNEL - NOT_EDITABLE - NOT_FOUND - ORDER_NO_SHIPPING_ADDRESS - PAYMENT_ERROR - PAYMENT_MISSING - PRODUCT_NOT_PUBLISHED - PRODUCT_UNAVAILABLE_FOR_PURCHASE - REQUIRED - SHIPPING_METHOD_NOT_APPLICABLE - SHIPPING_METHOD_REQUIRED - TAX_ERROR - TRANSACTION_ERROR - UNIQUE - VOID_INACTIVE_PAYMENT - ZERO_QUANTITY -} - -"""History log of the order.""" -type OrderEvent implements Node { - """Amount of money.""" - amount: Float - - """ - App that performed the action. Requires of of the following permissions: MANAGE_APPS, MANAGE_ORDERS, OWNER. - """ - app: App - - """Composed ID of the Fulfillment.""" - composedId: String - - """Date when event happened at in ISO 8601 format.""" - date: DateTime - - """The discount applied to the order.""" - discount: OrderEventDiscountObject - - """Email of the customer.""" - email: String - - """Type of an email sent to the customer.""" - emailType: OrderEventsEmailsEnum - - """The lines fulfilled.""" - fulfilledItems: [FulfillmentLine!] - - """ID of the event associated with an order.""" - id: ID! - - """Number of an invoice related to the order.""" - invoiceNumber: String - - """The concerned lines.""" - lines: [OrderEventOrderLineObject!] - - """Content of the event.""" - message: String - - """User-friendly number of an order.""" - orderNumber: String - - """List of oversold lines names.""" - oversoldItems: [String!] - - """The payment gateway of the payment.""" - paymentGateway: String - - """The payment reference from the payment provider.""" - paymentId: String - - """Number of items.""" - quantity: Int - - """The reference of payment's transaction.""" - reference: String - - """ - The order event which is related to this event. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - related: OrderEvent - - """The order which is related to this order.""" - relatedOrder: Order - - """Define if shipping costs were included to the refund.""" - shippingCostsIncluded: Boolean - - """The transaction reference of captured payment.""" - transactionReference: String - - """Order event type.""" - type: OrderEventsEnum - - """User who performed the action.""" - user: User - - """The warehouse were items were restocked.""" - warehouse: Warehouse -} - -type OrderEventCountableConnection { - edges: [OrderEventCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type OrderEventCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: OrderEvent! -} - -type OrderEventDiscountObject { - """Returns amount of discount.""" - amount: Money - - """Returns amount of discount.""" - oldAmount: Money - - """Value of the discount. Can store fixed value or percent value.""" - oldValue: PositiveDecimal - - """Type of the discount: fixed or percent.""" - oldValueType: DiscountValueTypeEnum - - """Explanation for the applied discount.""" - reason: String - - """Value of the discount. Can store fixed value or percent value.""" - value: PositiveDecimal! - - """Type of the discount: fixed or percent.""" - valueType: DiscountValueTypeEnum! -} - -type OrderEventOrderLineObject { - """The discount applied to the order line.""" - discount: OrderEventDiscountObject - - """The variant name.""" - itemName: String - - """The order line.""" - orderLine: OrderLine - - """The variant quantity.""" - quantity: Int -} - -"""An enumeration.""" -enum OrderEventsEmailsEnum { - CONFIRMED - DIGITAL_LINKS - FULFILLMENT_CONFIRMATION - ORDER_CANCEL - ORDER_CONFIRMATION - ORDER_REFUND - PAYMENT_CONFIRMATION - SHIPPING_CONFIRMATION - TRACKING_UPDATED -} - -"""The different order event types.""" -enum OrderEventsEnum { - ADDED_PRODUCTS - CANCELED - CONFIRMED - DRAFT_CREATED - DRAFT_CREATED_FROM_REPLACE - EMAIL_SENT - EXPIRED - EXTERNAL_SERVICE_NOTIFICATION - FULFILLMENT_AWAITS_APPROVAL - FULFILLMENT_CANCELED - FULFILLMENT_FULFILLED_ITEMS - FULFILLMENT_REFUNDED - FULFILLMENT_REPLACED - FULFILLMENT_RESTOCKED_ITEMS - FULFILLMENT_RETURNED - INVOICE_GENERATED - INVOICE_REQUESTED - INVOICE_SENT - INVOICE_UPDATED - NOTE_ADDED - NOTE_UPDATED - ORDER_DISCOUNT_ADDED - ORDER_DISCOUNT_AUTOMATICALLY_UPDATED - ORDER_DISCOUNT_DELETED - ORDER_DISCOUNT_UPDATED - ORDER_FULLY_PAID - ORDER_LINE_DISCOUNT_REMOVED - ORDER_LINE_DISCOUNT_UPDATED - ORDER_LINE_PRODUCT_DELETED - ORDER_LINE_VARIANT_DELETED - ORDER_MARKED_AS_PAID - ORDER_REPLACEMENT_CREATED - OTHER - OVERSOLD_ITEMS - PAYMENT_AUTHORIZED - PAYMENT_CAPTURED - PAYMENT_FAILED - PAYMENT_REFUNDED - PAYMENT_VOIDED - PLACED - PLACED_FROM_DRAFT - REMOVED_PRODUCTS - TRACKING_UPDATED - TRANSACTION_CANCEL_REQUESTED - TRANSACTION_CHARGE_REQUESTED - TRANSACTION_EVENT - TRANSACTION_MARK_AS_PAID_FAILED - TRANSACTION_REFUND_REQUESTED - UPDATED_ADDRESS -} - -""" -Event sent when order becomes expired. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type OrderExpired implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input OrderFilterInput { - authorizeStatus: [OrderAuthorizeStatusEnum!] - channels: [ID!] - chargeStatus: [OrderChargeStatusEnum!] - checkoutIds: [ID!] - checkoutTokens: [UUID!] - created: DateRangeInput - customer: String - giftCardBought: Boolean - giftCardUsed: Boolean - ids: [ID!] - isClickAndCollect: Boolean - isPreorder: Boolean - metadata: [MetadataFilter!] - numbers: [String!] - paymentStatus: [PaymentChargeStatusEnum!] - search: String - status: [OrderStatusFilter!] - updatedAt: DateTimeRangeInput -} - -""" -Filter shipping methods for order. - -Added in Saleor 3.6. -""" -type OrderFilterShippingMethods implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """ - Shipping methods that can be used with this checkout. - - Added in Saleor 3.6. - """ - shippingMethods: [ShippingMethod!] - - """Saleor version that triggered the event.""" - version: String -} - -""" -Creates new fulfillments for an order. - -Requires one of the following permissions: MANAGE_ORDERS. - -Triggers the following webhook events: -- FULFILLMENT_CREATED (async): A new fulfillment is created. -- ORDER_FULFILLED (async): Order is fulfilled. -- FULFILLMENT_TRACKING_NUMBER_UPDATED (async): Sent when fulfillment tracking number is updated. -- FULFILLMENT_APPROVED (async): A fulfillment is approved. -""" -type OrderFulfill { - errors: [OrderError!]! - - """List of created fulfillments.""" - fulfillments: [Fulfillment!] - - """Fulfilled order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input OrderFulfillInput { - """If true, then allow proceed fulfillment when stock is exceeded.""" - allowStockToBeExceeded: Boolean = false - - """List of items informing how to fulfill the order.""" - lines: [OrderFulfillLineInput!]! - - """If true, send an email notification to the customer.""" - notifyCustomer: Boolean - - """ - Fulfillment tracking number. - - Added in Saleor 3.6. - """ - trackingNumber: String -} - -input OrderFulfillLineInput { - """The ID of the order line.""" - orderLineId: ID - - """List of stock items to create.""" - stocks: [OrderFulfillStockInput!]! -} - -input OrderFulfillStockInput { - """The number of line items to be fulfilled from given warehouse.""" - quantity: Int! - - """ID of the warehouse from which the item will be fulfilled.""" - warehouse: ID! -} - -""" -Event sent when order is fulfilled. - -Added in Saleor 3.2. -""" -type OrderFulfilled implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when order is fully paid. - -Added in Saleor 3.2. -""" -type OrderFullyPaid implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -The order is fully refunded. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type OrderFullyRefunded implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Adds granted refund to the order. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderGrantRefundCreate { - errors: [OrderGrantRefundCreateError!]! - - """Created granted refund.""" - grantedRefund: OrderGrantedRefund - - """Order which has assigned new grant refund.""" - order: Order -} - -type OrderGrantRefundCreateError { - """The error code.""" - code: OrderGrantRefundCreateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """ - List of lines which cause the error. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - lines: [OrderGrantRefundCreateLineError!] - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum OrderGrantRefundCreateErrorCode { - AMOUNT_GREATER_THAN_AVAILABLE - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - SHIPPING_COSTS_ALREADY_GRANTED -} - -input OrderGrantRefundCreateInput { - """ - Amount of the granted refund. If not provided, the amount will be calculated automatically based on provided `lines` and `grantRefundForShipping`. - """ - amount: Decimal - - """ - Determine if granted refund should include shipping costs. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - grantRefundForShipping: Boolean - - """ - Lines to assign to granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - lines: [OrderGrantRefundCreateLineInput!] - - """Reason of the granted refund.""" - reason: String - - """ - The ID of the transaction item related to the granted refund. If `amount` provided in the input, the transaction.chargedAmount needs to be equal or greater than provided `amount`.If `amount` is not provided in the input and calculated automatically by Saleor, the `min(calculatedAmount, transaction.chargedAmount)` will be used.Field will be required starting from Saleor 3.21. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - transactionId: ID -} - -type OrderGrantRefundCreateLineError { - """The error code.""" - code: OrderGrantRefundCreateLineErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The ID of the line related to the error.""" - lineId: ID! - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum OrderGrantRefundCreateLineErrorCode { - GRAPHQL_ERROR - NOT_FOUND - QUANTITY_GREATER_THAN_AVAILABLE -} - -input OrderGrantRefundCreateLineInput { - """The ID of the order line.""" - id: ID! - - """The quantity of line items to be marked to refund.""" - quantity: Int! - - """Reason of the granted refund for the line.""" - reason: String -} - -""" -Updates granted refund. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderGrantRefundUpdate { - errors: [OrderGrantRefundUpdateError!]! - - """Created granted refund.""" - grantedRefund: OrderGrantedRefund - - """Order which has assigned updated grant refund.""" - order: Order -} - -type OrderGrantRefundUpdateError { - """ - List of lines to add which cause the error. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - addLines: [OrderGrantRefundUpdateLineError!] - - """The error code.""" - code: OrderGrantRefundUpdateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """ - List of lines to remove which cause the error. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - removeLines: [OrderGrantRefundUpdateLineError!] -} - -"""An enumeration.""" -enum OrderGrantRefundUpdateErrorCode { - AMOUNT_GREATER_THAN_AVAILABLE - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - SHIPPING_COSTS_ALREADY_GRANTED -} - -input OrderGrantRefundUpdateInput { - """ - Lines to assign to granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - addLines: [OrderGrantRefundUpdateLineAddInput!] - - """ - Amount of the granted refund. if not provided and `addLines` or `removeLines` or `grantRefundForShipping` is provided, amount will be calculated automatically. - """ - amount: Decimal - - """ - Determine if granted refund should include shipping costs. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - grantRefundForShipping: Boolean - - """Reason of the granted refund.""" - reason: String - - """ - Lines to remove from granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - removeLines: [ID!] - - """ - The ID of the transaction item related to the granted refund. If `amount` provided in the input, the transaction.chargedAmount needs to be equal or greater than provided `amount`.If `amount` is not provided in the input and calculated automatically by Saleor, the `min(calculatedAmount, transaction.chargedAmount)` will be used.Field will be required starting from Saleor 3.21. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - transactionId: ID -} - -input OrderGrantRefundUpdateLineAddInput { - """The ID of the order line.""" - id: ID! - - """The quantity of line items to be marked to refund.""" - quantity: Int! - - """Reason of the granted refund for the line.""" - reason: String -} - -type OrderGrantRefundUpdateLineError { - """The error code.""" - code: OrderGrantRefundUpdateLineErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The ID of the line related to the error.""" - lineId: ID! - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum OrderGrantRefundUpdateLineErrorCode { - GRAPHQL_ERROR - NOT_FOUND - QUANTITY_GREATER_THAN_AVAILABLE -} - -""" -The details of granted refund. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type OrderGrantedRefund { - """Refund amount.""" - amount: Money! - - """App that performed the action.""" - app: App - - """Time of creation.""" - createdAt: DateTime! - id: ID! - - """ - Lines assigned to the granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - lines: [OrderGrantedRefundLine!] - - """Reason of the refund.""" - reason: String - - """ - If true, the refunded amount includes the shipping price.If false, the refunded amount does not include the shipping price. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - shippingCostsIncluded: Boolean! - - """ - Status of the granted refund calculated based on transactionItem assigned to granted refund. - - Added in Saleor 3.20. - """ - status: OrderGrantedRefundStatusEnum! - - """ - The transaction assigned to the granted refund. - - Added in Saleor 3.20. - """ - transaction: TransactionItem - - """ - List of refund events associated with the granted refund. - - Added in Saleor 3.20. - """ - transactionEvents: [TransactionEvent!] - - """Time of last update.""" - updatedAt: DateTime! - - """ - User who performed the action. Requires of of the following permissions: MANAGE_USERS, MANAGE_STAFF, OWNER. - """ - user: User -} - -""" -Represents granted refund line. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type OrderGrantedRefundLine { - id: ID! - - """Line of the order associated with this granted refund.""" - orderLine: OrderLine! - - """Number of items to refund.""" - quantity: Int! - - """Reason for refunding the line.""" - reason: String -} - -""" -Represents the status of a granted refund. - - NONE - the refund on related transactionItem is not processed - PENDING - the refund on related transactionItem is pending - FULL - the refund on related transactionItem is fully processed - FAIL - the refund on related transactionItem failed -""" -enum OrderGrantedRefundStatusEnum { - FAILURE - NONE - PENDING - SUCCESS -} - -"""Represents order line of particular order.""" -type OrderLine implements Node & ObjectWithMetadata { - """ - List of allocations across warehouses. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. - """ - allocations: [Allocation!] - digitalContentUrl: DigitalContentUrl - - """ID of the order line.""" - id: ID! - - """ - Determine if the line is a gift. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - isGift: Boolean - - """ - Returns True, if the line unit price was overridden. - - Added in Saleor 3.14. - """ - isPriceOverridden: Boolean - - """Whether the product variant requires shipping.""" - isShippingRequired: Boolean! - - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.5. - """ - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.5. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.5. - """ - metafields(keys: [String!]): Metadata - - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.5. - """ - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.5. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.5. - """ - privateMetafields(keys: [String!]): Metadata - - """Name of the product in order line.""" - productName: String! - - """SKU of the product variant.""" - productSku: String - - """The ID of the product variant.""" - productVariantId: String - - """Number of variant items ordered.""" - quantity: Int! - - """Number of variant items fulfilled.""" - quantityFulfilled: Int! - - """ - A quantity of items remaining to be fulfilled. - - Added in Saleor 3.1. - """ - quantityToFulfill: Int! - - """ - Denormalized sale ID, set when order line is created for a product variant that is on sale. - - Added in Saleor 3.14. - """ - saleId: ID - - """ - Denormalized tax class of the product in this order line. - - Added in Saleor 3.9. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxClass: TaxClass - - """ - Denormalized public metadata of the tax class. - - Added in Saleor 3.9. - """ - taxClassMetadata: [MetadataItem!]! - - """ - Denormalized name of the tax class. - - Added in Saleor 3.9. - """ - taxClassName: String - - """ - Denormalized private metadata of the tax class. Requires staff permissions to access. - - Added in Saleor 3.9. - """ - taxClassPrivateMetadata: [MetadataItem!]! - - """Rate of tax applied on product variant.""" - taxRate: Float! - thumbnail( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. - """ - format: ThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): Image - - """Price of the order line.""" - totalPrice: TaxedMoney! - - """Product name in the customer's language""" - translatedProductName: String! - - """Variant name in the customer's language""" - translatedVariantName: String! - - """Price of the order line without discounts.""" - undiscountedTotalPrice: TaxedMoney! - - """ - Price of the single item in the order line without applied an order line discount. - """ - undiscountedUnitPrice: TaxedMoney! - - """The discount applied to the single order line.""" - unitDiscount: Money! - - """Reason for any discounts applied on a product in the order.""" - unitDiscountReason: String - - """Type of the discount: fixed or percent""" - unitDiscountType: DiscountValueTypeEnum - - """Value of the discount. Can store fixed value or percent value""" - unitDiscountValue: PositiveDecimal! - - """Price of the single item in the order line.""" - unitPrice: TaxedMoney! - - """ - A purchased product variant. Note: this field may be null if the variant has been removed from stock at all. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - variant: ProductVariant - - """Name of the variant of product in order line.""" - variantName: String! - - """ - Voucher code that was used for this order line. - - Added in Saleor 3.14. - """ - voucherCode: String -} - -input OrderLineCreateInput { - """ - Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. - - Added in Saleor 3.6. - """ - forceNewLine: Boolean = false - - """ - Custom price of the item.When the line with the same variant will be provided multiple times, the last price will be used. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - price: PositiveDecimal - - """Number of variant items ordered.""" - quantity: Int! - - """Product variant ID.""" - variantId: ID! -} - -""" -Deletes an order line from an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderLineDelete { - errors: [OrderError!]! - - """A related order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """An order line that was deleted.""" - orderLine: OrderLine -} - -""" -Remove discount applied to the order line. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderLineDiscountRemove { - errors: [OrderError!]! - - """Order which is related to line which has removed discount.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Order line which has removed discount.""" - orderLine: OrderLine -} - -""" -Update discount for the order line. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderLineDiscountUpdate { - errors: [OrderError!]! - - """Order which is related to the discounted line.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Order line which has been discounted.""" - orderLine: OrderLine -} - -input OrderLineInput { - """Number of variant items ordered.""" - quantity: Int! -} - -""" -Updates an order line of an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderLineUpdate { - errors: [OrderError!]! - - """Related order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - orderLine: OrderLine -} - -""" -Create order lines for an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderLinesCreate { - errors: [OrderError!]! - - """Related order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """List of added order lines.""" - orderLines: [OrderLine!] -} - -""" -Mark order as manually paid. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderMarkAsPaid { - errors: [OrderError!]! - - """Order marked as paid.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when order metadata is updated. - -Added in Saleor 3.8. -""" -type OrderMetadataUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Adds note to the order. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderNoteAdd { - errors: [OrderNoteAddError!]! - - """Order note created.""" - event: OrderEvent - - """Order with the note added.""" - order: Order -} - -type OrderNoteAddError { - """The error code.""" - code: OrderNoteAddErrorCode - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum OrderNoteAddErrorCode { - GRAPHQL_ERROR - REQUIRED -} - -input OrderNoteInput { - """Note message.""" - message: String! -} - -""" -Updates note of an order. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderNoteUpdate { - errors: [OrderNoteUpdateError!]! - - """Order note updated.""" - event: OrderEvent - - """Order with the note updated.""" - order: Order -} - -type OrderNoteUpdateError { - """The error code.""" - code: OrderNoteUpdateErrorCode - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum OrderNoteUpdateErrorCode { - GRAPHQL_ERROR - NOT_FOUND - REQUIRED -} - -union OrderOrCheckout = Checkout | Order - -"""An enumeration.""" -enum OrderOriginEnum { - BULK_CREATE - CHECKOUT - DRAFT - REISSUE -} - -""" -Payment has been made. The order may be partially or fully paid. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type OrderPaid implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input OrderPredicateInput { - """List of conditions that must be met.""" - AND: [OrderPredicateInput!] - - """A list of conditions of which at least one must be met.""" - OR: [OrderPredicateInput!] - - """Defines the conditions related to checkout and order objects.""" - discountedObjectPredicate: DiscountedObjectWhereInput -} - -""" -Refund an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderRefund { - errors: [OrderError!]! - - """A refunded order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input OrderRefundFulfillmentLineInput { - """The ID of the fulfillment line to refund.""" - fulfillmentLineId: ID! - - """The number of items to be refunded.""" - quantity: Int! -} - -input OrderRefundLineInput { - """The ID of the order line to refund.""" - orderLineId: ID! - - """The number of items to be refunded.""" - quantity: Int! -} - -input OrderRefundProductsInput { - """The total amount of refund when the value is provided manually.""" - amountToRefund: PositiveDecimal - - """List of fulfilled lines to refund.""" - fulfillmentLines: [OrderRefundFulfillmentLineInput!] - - """ - If true, Saleor will refund shipping costs. If amountToRefund is providedincludeShippingCosts will be ignored. - """ - includeShippingCosts: Boolean = false - - """List of unfulfilled lines to refund.""" - orderLines: [OrderRefundLineInput!] -} - -""" -The order received a refund. The order may be partially or fully refunded. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type OrderRefunded implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input OrderReturnFulfillmentLineInput { - """The ID of the fulfillment line to return.""" - fulfillmentLineId: ID! - - """The number of items to be returned.""" - quantity: Int! - - """Determines, if the line should be added to replace order.""" - replace: Boolean = false -} - -input OrderReturnLineInput { - """The ID of the order line to return.""" - orderLineId: ID! - - """The number of items to be returned.""" - quantity: Int! - - """Determines, if the line should be added to replace order.""" - replace: Boolean = false -} - -input OrderReturnProductsInput { - """The total amount of refund when the value is provided manually.""" - amountToRefund: PositiveDecimal - - """List of fulfilled lines to return.""" - fulfillmentLines: [OrderReturnFulfillmentLineInput!] - - """ - If true, Saleor will refund shipping costs. If amountToRefund is providedincludeShippingCosts will be ignored. - """ - includeShippingCosts: Boolean = false - - """List of unfulfilled lines to return.""" - orderLines: [OrderReturnLineInput!] - - """If true, Saleor will call refund action for all lines.""" - refund: Boolean = false -} - -"""Represents the channel-specific order settings.""" -type OrderSettings { - """ - Determine if it is possible to place unpaid order by calling `checkoutComplete` mutation. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - allowUnpaidOrders: Boolean! - - """ - When disabled, all new orders from checkout will be marked as unconfirmed. When enabled orders from checkout will become unfulfilled immediately. - """ - automaticallyConfirmAllNewOrders: Boolean! - - """ - When enabled, all non-shippable gift card orders will be fulfilled automatically. - """ - automaticallyFulfillNonShippableGiftCard: Boolean! - - """ - The time in days after expired orders will be deleted. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - deleteExpiredOrdersAfter: Day! - - """ - Expiration time in minutes. Default null - means do not expire any orders. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - expireOrdersAfter: Minute - - """ - Determine if voucher applied on draft order should be count toward voucher usage. - - Added in Saleor 3.18. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - includeDraftOrderInVoucherUsage: Boolean! - - """ - Determine what strategy will be used to mark the order as paid. Based on the chosen option, the proper object will be created and attached to the order when it's manually marked as paid. - `PAYMENT_FLOW` - [default option] creates the `Payment` object. - `TRANSACTION_FLOW` - creates the `TransactionItem` object. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - markAsPaidStrategy: MarkAsPaidStrategyEnum! -} - -type OrderSettingsError { - """The error code.""" - code: OrderSettingsErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum OrderSettingsErrorCode { - INVALID -} - -input OrderSettingsInput { - """ - Determine if it is possible to place unpaid order by calling `checkoutComplete` mutation. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - allowUnpaidOrders: Boolean - - """ - When disabled, all new orders from checkout will be marked as unconfirmed. When enabled orders from checkout will become unfulfilled immediately. By default set to True - """ - automaticallyConfirmAllNewOrders: Boolean - - """ - When enabled, all non-shippable gift card orders will be fulfilled automatically. By default set to True. - """ - automaticallyFulfillNonShippableGiftCard: Boolean - - """ - The time in days after expired orders will be deleted.Allowed range is from 1 to 120. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - deleteExpiredOrdersAfter: Day - - """ - Expiration time in minutes. Default null - means do not expire any orders. Enter 0 or null to disable. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - expireOrdersAfter: Minute - - """ - Specify whether a coupon applied to draft orders will count toward voucher usage. - - Warning: when switching this setting from `false` to `true`, the vouchers will be disconnected from all draft orders. - - Added in Saleor 3.18. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - includeDraftOrderInVoucherUsage: Boolean - - """ - Determine what strategy will be used to mark the order as paid. Based on the chosen option, the proper object will be created and attached to the order when it's manually marked as paid. - `PAYMENT_FLOW` - [default option] creates the `Payment` object. - `TRANSACTION_FLOW` - creates the `TransactionItem` object. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - markAsPaidStrategy: MarkAsPaidStrategyEnum -} - -""" -Update shop order settings across all channels. Returns `orderSettings` for the first `channel` in alphabetical order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderSettingsUpdate { - errors: [OrderSettingsError!]! - - """Order settings.""" - orderSettings: OrderSettings - orderSettingsErrors: [OrderSettingsError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input OrderSettingsUpdateInput { - """ - When disabled, all new orders from checkout will be marked as unconfirmed. When enabled orders from checkout will become unfulfilled immediately. By default set to True - """ - automaticallyConfirmAllNewOrders: Boolean - - """ - When enabled, all non-shippable gift card orders will be fulfilled automatically. By default set to True. - """ - automaticallyFulfillNonShippableGiftCard: Boolean -} - -enum OrderSortField { - """ - Sort orders by creation date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - CREATED_AT - - """ - Sort orders by creation date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - CREATION_DATE - - """Sort orders by customer.""" - CUSTOMER - - """Sort orders by fulfillment status.""" - FULFILLMENT_STATUS - - """Sort orders by last modified at.""" - LAST_MODIFIED_AT - - """Sort orders by number.""" - NUMBER - - """Sort orders by payment.""" - PAYMENT - - """ - Sort orders by rank. Note: This option is available only with the `search` filter. - """ - RANK -} - -input OrderSortingInput { - """Specifies the direction in which to sort orders.""" - direction: OrderDirection! - - """Sort orders by the selected field.""" - field: OrderSortField! -} - -"""An enumeration.""" -enum OrderStatus { - CANCELED - DRAFT - EXPIRED - FULFILLED - PARTIALLY_FULFILLED - PARTIALLY_RETURNED - RETURNED - UNCONFIRMED - UNFULFILLED -} - -enum OrderStatusFilter { - CANCELED - FULFILLED - PARTIALLY_FULFILLED - READY_TO_CAPTURE - READY_TO_FULFILL - UNCONFIRMED - UNFULFILLED -} - -""" -Updates an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderUpdate { - errors: [OrderError!]! - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input OrderUpdateInput { - """Billing address of the customer.""" - billingAddress: AddressInput - - """ - External ID of this order. - - Added in Saleor 3.10. - """ - externalReference: String - - """Shipping address of the customer.""" - shippingAddress: AddressInput - - """Email address of the customer.""" - userEmail: String -} - -""" -Updates a shipping method of the order. Requires shipping method ID to update, when null is passed then currently assigned shipping method is removed. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderUpdateShipping { - errors: [OrderError!]! - - """Order with updated shipping method.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input OrderUpdateShippingInput { - """ - ID of the selected shipping method, pass null to remove currently assigned shipping method. - """ - shippingMethod: ID -} - -""" -Event sent when order is updated. - -Added in Saleor 3.2. -""" -type OrderUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The order the event relates to.""" - order: Order - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Void an order. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type OrderVoid { - errors: [OrderError!]! - - """A voided order.""" - order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -A static page that can be manually added by a shop operator through the dashboard. -""" -type Page implements Node & ObjectWithMetadata { - """List of attributes assigned to this product.""" - attributes: [SelectedAttribute!]! - - """ - Content of the page. - - Rich text format. For reference see https://editorjs.io/ - """ - content: JSONString - - """ - Content of the page. - - Rich text format. For reference see https://editorjs.io/ - """ - contentJson: JSONString! @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `content` field instead.") - - """Date and time at which page was created.""" - created: DateTime! - - """ID of the page.""" - id: ID! - - """Determines if the page is published.""" - isPublished: Boolean! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Determines the type of page""" - pageType: PageType! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - publicationDate: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date.") - - """ - The page publication date. - - Added in Saleor 3.3. - """ - publishedAt: DateTime - - """Description of the page for SEO.""" - seoDescription: String - - """Title of the page for SEO.""" - seoTitle: String - - """Slug of the page.""" - slug: String! - - """Title of the page.""" - title: String! - - """Returns translated page fields for the given language code.""" - translation( - """A language code to return the translation for page.""" - languageCode: LanguageCodeEnum! - ): PageTranslation -} - -""" -Assign attributes to a given page type. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. -""" -type PageAttributeAssign { - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """The updated page type.""" - pageType: PageType -} - -""" -Unassign attributes from a given page type. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. -""" -type PageAttributeUnassign { - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """The updated page type.""" - pageType: PageType -} - -""" -Deletes pages. - -Requires one of the following permissions: MANAGE_PAGES. -""" -type PageBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Publish pages. - -Requires one of the following permissions: MANAGE_PAGES. -""" -type PageBulkPublish { - """Returns how many objects were affected.""" - count: Int! - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type PageCountableConnection { - edges: [PageCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type PageCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Page! -} - -""" -Creates a new page. - -Requires one of the following permissions: MANAGE_PAGES. -""" -type PageCreate { - errors: [PageError!]! - page: Page - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input PageCreateInput { - """List of attributes.""" - attributes: [AttributeValueInput!] - - """ - Page content. - - Rich text format. For reference see https://editorjs.io/ - """ - content: JSONString - - """Determines if page is visible in the storefront.""" - isPublished: Boolean - - """ID of the page type that page belongs to.""" - pageType: ID! - - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - """ - publicationDate: String - - """ - Publication date time. ISO 8601 standard. - - Added in Saleor 3.3. - """ - publishedAt: DateTime - - """Search engine optimization fields.""" - seo: SeoInput - - """Page internal name.""" - slug: String - - """Page title.""" - title: String -} - -""" -Event sent when new page is created. - -Added in Saleor 3.2. -""" -type PageCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The page the event relates to.""" - page: Page - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a page. - -Requires one of the following permissions: MANAGE_PAGES. -""" -type PageDelete { - errors: [PageError!]! - page: Page - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when page is deleted. - -Added in Saleor 3.2. -""" -type PageDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The page the event relates to.""" - page: Page - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type PageError { - """List of attributes IDs which causes the error.""" - attributes: [ID!] - - """The error code.""" - code: PageErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of attribute values IDs which causes the error.""" - values: [ID!] -} - -"""An enumeration.""" -enum PageErrorCode { - ATTRIBUTE_ALREADY_ASSIGNED - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE -} - -input PageFilterInput { - ids: [ID!] - metadata: [MetadataFilter!] - pageTypes: [ID!] - search: String - slugs: [String!] -} - -""" -The Relay compliant `PageInfo` type, containing data necessary to paginate this connection. -""" -type PageInfo { - """When paginating forwards, the cursor to continue.""" - endCursor: String - - """When paginating forwards, are there more items?""" - hasNextPage: Boolean! - - """When paginating backwards, are there more items?""" - hasPreviousPage: Boolean! - - """When paginating backwards, the cursor to continue.""" - startCursor: String -} - -input PageInput { - """List of attributes.""" - attributes: [AttributeValueInput!] - - """ - Page content. - - Rich text format. For reference see https://editorjs.io/ - """ - content: JSONString - - """Determines if page is visible in the storefront.""" - isPublished: Boolean - - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - """ - publicationDate: String - - """ - Publication date time. ISO 8601 standard. - - Added in Saleor 3.3. - """ - publishedAt: DateTime - - """Search engine optimization fields.""" - seo: SeoInput - - """Page internal name.""" - slug: String - - """Page title.""" - title: String -} - -""" -Reorder page attribute values. - -Requires one of the following permissions: MANAGE_PAGES. -""" -type PageReorderAttributeValues { - errors: [PageError!]! - - """Page from which attribute values are reordered.""" - page: Page - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -enum PageSortField { - """ - Sort pages by creation date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - CREATED_AT - - """ - Sort pages by creation date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - CREATION_DATE - - """ - Sort pages by publication date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - PUBLICATION_DATE - - """ - Sort pages by publication date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - PUBLISHED_AT - - """Sort pages by slug.""" - SLUG - - """Sort pages by title.""" - TITLE - - """Sort pages by visibility.""" - VISIBILITY -} - -input PageSortingInput { - """Specifies the direction in which to sort pages.""" - direction: OrderDirection! - - """Sort pages by the selected field.""" - field: PageSortField! -} - -""" -Represents page's original translatable fields and related translations. -""" -type PageTranslatableContent implements Node { - """List of page content attribute values that can be translated.""" - attributeValues: [AttributeValueTranslatableContent!]! - - """ - Content of the page to translate. - - Rich text format. For reference see https://editorjs.io/ - """ - content: JSONString - - """ - Content of the page. - - Rich text format. For reference see https://editorjs.io/ - """ - contentJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `content` field instead.") - - """The ID of the page translatable content.""" - id: ID! - - """ - A static page that can be manually added by a shop operator through the dashboard. - """ - page: Page @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the page to translate. - - Added in Saleor 3.14. - """ - pageId: ID! - - """SEO description to translate.""" - seoDescription: String - - """SEO title to translate.""" - seoTitle: String - - """Page title to translate.""" - title: String! - - """Returns translated page fields for the given language code.""" - translation( - """A language code to return the translation for page.""" - languageCode: LanguageCodeEnum! - ): PageTranslation -} - -""" -Creates/updates translations for a page. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type PageTranslate { - errors: [TranslationError!]! - page: PageTranslatableContent - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""Represents page translations.""" -type PageTranslation implements Node { - """ - Translated content of the page. - - Rich text format. For reference see https://editorjs.io/ - """ - content: JSONString - - """ - Translated description of the page. - - Rich text format. For reference see https://editorjs.io/ - """ - contentJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `content` field instead.") - - """The ID of the page translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated SEO description.""" - seoDescription: String - - """Translated SEO title.""" - seoTitle: String - - """Translated page title.""" - title: String - - """ - Represents the page fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: PageTranslatableContent -} - -input PageTranslationInput { - """ - Translated page content. - - Rich text format. For reference see https://editorjs.io/ - """ - content: JSONString - seoDescription: String - seoTitle: String - title: String -} - -""" -Represents a type of page. It defines what attributes are available to pages of this type. -""" -type PageType implements Node & ObjectWithMetadata { - """Page attributes of that page type.""" - attributes: [Attribute!] - - """ - Attributes that can be assigned to the page type. - - Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - availableAttributes( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - filter: AttributeFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - where: AttributeWhereInput - ): AttributeCountableConnection - - """ - Whether page type has pages assigned. - - Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES. - """ - hasPages: Boolean - - """ID of the page type.""" - id: ID! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Name of the page type.""" - name: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Slug of the page type.""" - slug: String! -} - -""" -Delete page types. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. -""" -type PageTypeBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type PageTypeCountableConnection { - edges: [PageTypeCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type PageTypeCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: PageType! -} - -""" -Create a new page type. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. -""" -type PageTypeCreate { - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - pageType: PageType -} - -input PageTypeCreateInput { - """List of attribute IDs to be assigned to the page type.""" - addAttributes: [ID!] - - """Name of the page type.""" - name: String - - """Page type slug.""" - slug: String -} - -""" -Event sent when new page type is created. - -Added in Saleor 3.5. -""" -type PageTypeCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The page type the event relates to.""" - pageType: PageType - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Delete a page type. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. -""" -type PageTypeDelete { - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - pageType: PageType -} - -""" -Event sent when page type is deleted. - -Added in Saleor 3.5. -""" -type PageTypeDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The page type the event relates to.""" - pageType: PageType - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input PageTypeFilterInput { - search: String - slugs: [String!] -} - -""" -Reorder the attributes of a page type. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. -""" -type PageTypeReorderAttributes { - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Page type from which attributes are reordered.""" - pageType: PageType -} - -enum PageTypeSortField { - """Sort page types by name.""" - NAME - - """Sort page types by slug.""" - SLUG -} - -input PageTypeSortingInput { - """Specifies the direction in which to sort page types.""" - direction: OrderDirection! - - """Sort page types by the selected field.""" - field: PageTypeSortField! -} - -""" -Update page type. - -Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. -""" -type PageTypeUpdate { - errors: [PageError!]! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - pageType: PageType -} - -input PageTypeUpdateInput { - """List of attribute IDs to be assigned to the page type.""" - addAttributes: [ID!] - - """Name of the page type.""" - name: String - - """List of attribute IDs to be assigned to the page type.""" - removeAttributes: [ID!] - - """Page type slug.""" - slug: String -} - -""" -Event sent when page type is updated. - -Added in Saleor 3.5. -""" -type PageTypeUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The page type the event relates to.""" - pageType: PageType - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Updates an existing page. - -Requires one of the following permissions: MANAGE_PAGES. -""" -type PageUpdate { - errors: [PageError!]! - page: Page - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when page is updated. - -Added in Saleor 3.2. -""" -type PageUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The page the event relates to.""" - page: Page - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Change the password of the logged in user. - -Requires one of the following permissions: AUTHENTICATED_USER. -""" -type PasswordChange { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """A user instance with a new password.""" - user: User -} - -"""Represents a payment of a given type.""" -type Payment implements Node & ObjectWithMetadata { - """ - List of actions that can be performed in the current state of a payment. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - actions: [OrderAction!]! - - """ - Maximum amount of money that can be captured. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - availableCaptureAmount: Money - - """ - Maximum amount of money that can be refunded. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - availableRefundAmount: Money - - """Total amount captured for this payment.""" - capturedAmount: Money - - """Internal payment status.""" - chargeStatus: PaymentChargeStatusEnum! - - """Checkout associated with a payment.""" - checkout: Checkout - - """Date and time at which payment was created.""" - created: DateTime! - - """The details of the card used for this payment.""" - creditCard: CreditCard - - """ - IP address of the user who created the payment. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - customerIpAddress: String - - """Payment gateway used for payment.""" - gateway: String! - - """ID of the payment.""" - id: ID! - - """Determines if the payment is active or not.""" - isActive: Boolean! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Date and time at which payment was modified.""" - modified: DateTime! - - """Order associated with a payment.""" - order: Order - - """ - Informs whether this is a partial payment. - - Added in Saleor 3.14. - """ - partial: Boolean! - - """Type of method used for payment.""" - paymentMethodType: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - PSP reference of the payment. - - Added in Saleor 3.14. - """ - pspReference: String - - """Unique token associated with a payment.""" - token: String! - - """Total amount of the payment.""" - total: Money - - """ - List of all transactions within this payment. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - transactions: [Transaction!] -} - -""" -Authorize payment. - -Added in Saleor 3.6. -""" -type PaymentAuthorize implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """Look up a payment.""" - payment: Payment - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Captures the authorized payment amount. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type PaymentCapture { - errors: [PaymentError!]! - - """Updated payment.""" - payment: Payment - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Capture payment. - -Added in Saleor 3.6. -""" -type PaymentCaptureEvent implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """Look up a payment.""" - payment: Payment - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""An enumeration.""" -enum PaymentChargeStatusEnum { - CANCELLED - FULLY_CHARGED - FULLY_REFUNDED - NOT_CHARGED - PARTIALLY_CHARGED - PARTIALLY_REFUNDED - PENDING - REFUSED -} - -"""Check payment balance.""" -type PaymentCheckBalance { - """Response from the gateway.""" - data: JSONString - errors: [PaymentError!]! - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input PaymentCheckBalanceInput { - """Information about card.""" - card: CardInput! - - """Slug of a channel for which the data should be returned.""" - channel: String! - - """An ID of a payment gateway to check.""" - gatewayId: String! - - """Payment method name.""" - method: String! -} - -""" -Confirm payment. - -Added in Saleor 3.6. -""" -type PaymentConfirmEvent implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """Look up a payment.""" - payment: Payment - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type PaymentCountableConnection { - edges: [PaymentCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type PaymentCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Payment! -} - -type PaymentError { - """The error code.""" - code: PaymentErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of variant IDs which causes the error.""" - variants: [ID!] -} - -"""An enumeration.""" -enum PaymentErrorCode { - BALANCE_CHECK_ERROR - BILLING_ADDRESS_NOT_SET - CHANNEL_INACTIVE - CHECKOUT_COMPLETION_IN_PROGRESS - CHECKOUT_EMAIL_NOT_SET - GRAPHQL_ERROR - INVALID - INVALID_SHIPPING_METHOD - NOT_FOUND - NOT_SUPPORTED_GATEWAY - NO_CHECKOUT_LINES - PARTIAL_PAYMENT_NOT_ALLOWED - PAYMENT_ERROR - REQUIRED - SHIPPING_ADDRESS_NOT_SET - SHIPPING_METHOD_NOT_SET - UNAVAILABLE_VARIANT_IN_CHANNEL - UNIQUE -} - -input PaymentFilterInput { - checkouts: [ID!] - - """ - Filter by ids. - - Added in Saleor 3.8. - """ - ids: [ID!] -} - -""" -Available payment gateway backend with configuration necessary to setup client. -""" -type PaymentGateway { - """Payment gateway client configuration.""" - config: [GatewayConfigLine!]! - - """Payment gateway supported currencies.""" - currencies: [String!]! - - """Payment gateway ID.""" - id: ID! - - """Payment gateway name.""" - name: String! -} - -type PaymentGatewayConfig { - """The JSON data required to initialize the payment gateway.""" - data: JSON - errors: [PaymentGatewayConfigError!] - - """The app identifier.""" - id: String! -} - -type PaymentGatewayConfigError { - """The error code.""" - code: PaymentGatewayConfigErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PaymentGatewayConfigErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -""" -Initializes a payment gateway session. It triggers the webhook `PAYMENT_GATEWAY_INITIALIZE_SESSION`, to the requested `paymentGateways`. If `paymentGateways` is not provided, the webhook will be send to all subscribed payment gateways. There is a limit of 100 transaction items per checkout / order. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PaymentGatewayInitialize { - errors: [PaymentGatewayInitializeError!]! - - """List of payment gateway configurations.""" - gatewayConfigs: [PaymentGatewayConfig!] -} - -type PaymentGatewayInitializeError { - """The error code.""" - code: PaymentGatewayInitializeErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PaymentGatewayInitializeErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -""" -Event sent when user wants to initialize the payment gateway. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PaymentGatewayInitializeSession implements Event { - """Amount requested for initializing the payment gateway.""" - amount: PositiveDecimal - - """Payment gateway data in JSON format, received from storefront.""" - data: JSON - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Checkout or order""" - sourceObject: OrderOrCheckout! - - """Saleor version that triggered the event.""" - version: String -} - -""" -Initializes payment gateway for tokenizing payment method session. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION (sync): The customer requested to initialize payment gateway for tokenization. -""" -type PaymentGatewayInitializeTokenization { - """A data returned by payment app.""" - data: JSON - errors: [PaymentGatewayInitializeTokenizationError!]! - - """A status of the payment gateway initialization.""" - result: PaymentGatewayInitializeTokenizationResult! -} - -type PaymentGatewayInitializeTokenizationError { - """The error code.""" - code: PaymentGatewayInitializeTokenizationErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PaymentGatewayInitializeTokenizationErrorCode { - CHANNEL_INACTIVE - GATEWAY_ERROR - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -""" -Result of initialize payment gateway for tokenization of payment method. - - The result of initialize payment gateway for tokenization of payment method. - SUCCESSFULLY_INITIALIZED - The payment gateway was successfully initialized. - FAILED_TO_INITIALIZE - The payment gateway was not initialized. - FAILED_TO_DELIVER - The request to initialize payment gateway was not delivered. -""" -enum PaymentGatewayInitializeTokenizationResult { - FAILED_TO_DELIVER - FAILED_TO_INITIALIZE - SUCCESSFULLY_INITIALIZED -} - -""" -Event sent to initialize a new session in payment gateway to store the payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PaymentGatewayInitializeTokenizationSession implements Event { - """Channel related to the requested action.""" - channel: Channel! - - """Payment gateway data in JSON format, received from storefront.""" - data: JSON - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user related to the requested action.""" - user: User! - - """Saleor version that triggered the event.""" - version: String -} - -input PaymentGatewayToInitialize { - """The data that will be passed to the payment gateway.""" - data: JSON - - """The identifier of the payment gateway app to initialize.""" - id: String! -} - -"""Initializes payment process when it is required by gateway.""" -type PaymentInitialize { - errors: [PaymentError!]! - - """Payment that was initialized.""" - initializedPayment: PaymentInitialized - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Server-side data generated by a payment gateway. Optional step when the payment provider requires an additional action to initialize payment session. -""" -type PaymentInitialized { - """Initialized data by gateway.""" - data: JSONString - - """ID of a payment gateway.""" - gateway: String! - - """Payment gateway name.""" - name: String! -} - -input PaymentInput { - """ - Total amount of the transaction, including all taxes and discounts. If no amount is provided, the checkout total will be used. - """ - amount: PositiveDecimal - - """A gateway to use with that payment.""" - gateway: String! - - """ - User public metadata. - - Added in Saleor 3.1. - """ - metadata: [MetadataInput!] - - """ - URL of a storefront view where user should be redirected after requiring additional actions. Payment with additional actions will not be finished if this field is not provided. - """ - returnUrl: String - - """ - Payment store type. - - Added in Saleor 3.1. - """ - storePaymentMethod: StorePaymentMethodEnum = NONE - - """ - Client-side generated payment token, representing customer's billing data in a secure manner. - """ - token: String -} - -""" -List payment gateways. - -Added in Saleor 3.6. -""" -type PaymentListGateways implements Event { - """The checkout the event relates to.""" - checkout: Checkout - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Tokenize payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION (sync): The customer requested to tokenize payment method. -""" -type PaymentMethodInitializeTokenization { - """A data returned by the payment app.""" - data: JSON - errors: [PaymentMethodInitializeTokenizationError!]! - - """The identifier of the payment method.""" - id: String - - """A status of the payment method tokenization.""" - result: PaymentMethodTokenizationResult! -} - -type PaymentMethodInitializeTokenizationError { - """The error code.""" - code: PaymentMethodInitializeTokenizationErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PaymentMethodInitializeTokenizationErrorCode { - CHANNEL_INACTIVE - GATEWAY_ERROR - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -""" -Event sent when user requests a tokenization of payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PaymentMethodInitializeTokenizationSession implements Event { - """Channel related to the requested action.""" - channel: Channel! - - """Payment gateway data in JSON format, received from storefront.""" - data: JSON - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The payment flow that the tokenized payment method should support.""" - paymentFlowToSupport: TokenizedPaymentFlowEnum! - - """The application receiving the webhook.""" - recipient: App - - """The user related to the requested action.""" - user: User! - - """Saleor version that triggered the event.""" - version: String -} - -""" -Tokenize payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION (sync): The customer continues payment method tokenization. -""" -type PaymentMethodProcessTokenization { - """A data returned by the payment app.""" - data: JSON - errors: [PaymentMethodProcessTokenizationError!]! - - """The identifier of the payment method.""" - id: String - - """A status of the payment method tokenization.""" - result: PaymentMethodTokenizationResult! -} - -type PaymentMethodProcessTokenizationError { - """The error code.""" - code: PaymentMethodProcessTokenizationErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PaymentMethodProcessTokenizationErrorCode { - CHANNEL_INACTIVE - GATEWAY_ERROR - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -""" -Event sent when user continues a tokenization of payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PaymentMethodProcessTokenizationSession implements Event { - """Channel related to the requested action.""" - channel: Channel! - - """Payment gateway data in JSON format, received from storefront.""" - data: JSON - - """ - The ID returned by app from `PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION` webhook. - """ - id: String! - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user related to the requested action.""" - user: User! - - """Saleor version that triggered the event.""" - version: String -} - -type PaymentMethodRequestDeleteError { - """The error code.""" - code: StoredPaymentMethodRequestDeleteErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -""" -Result of tokenization of payment method. - - SUCCESSFULLY_TOKENIZED - The payment method was successfully tokenized. - ADDITIONAL_ACTION_REQUIRED - The additional action is required to tokenize payment - method. - PENDING - The payment method is pending tokenization. - FAILED_TO_TOKENIZE - The payment method was not tokenized. - FAILED_TO_DELIVER - The request to tokenize payment method was not delivered. -""" -enum PaymentMethodTokenizationResult { - ADDITIONAL_ACTION_REQUIRED - FAILED_TO_DELIVER - FAILED_TO_TOKENIZE - PENDING - SUCCESSFULLY_TOKENIZED -} - -""" -Process payment. - -Added in Saleor 3.6. -""" -type PaymentProcessEvent implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """Look up a payment.""" - payment: Payment - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Refunds the captured payment amount. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type PaymentRefund { - errors: [PaymentError!]! - - """Updated payment.""" - payment: Payment - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Refund payment. - -Added in Saleor 3.6. -""" -type PaymentRefundEvent implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """Look up a payment.""" - payment: Payment - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents the channel-specific payment settings.""" -type PaymentSettings { - """ - Determine the transaction flow strategy to be used. Include the selected option in the payload sent to the payment app, as a requested action for the transaction. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - defaultTransactionFlowStrategy: TransactionFlowStrategyEnum! -} - -input PaymentSettingsInput { - """ - Determine the transaction flow strategy to be used. Include the selected option in the payload sent to the payment app, as a requested action for the transaction. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - defaultTransactionFlowStrategy: TransactionFlowStrategyEnum -} - -""" -Represents a payment source stored for user in payment gateway, such as credit card. -""" -type PaymentSource { - """Stored credit card details if available.""" - creditCardInfo: CreditCard - - """Payment gateway name.""" - gateway: String! - - """ - List of public metadata items. - - Added in Saleor 3.1. - - Can be accessed without permissions. - """ - metadata: [MetadataItem!]! - - """ID of stored payment method.""" - paymentMethodId: String -} - -""" -Voids the authorized payment. - -Requires one of the following permissions: MANAGE_ORDERS. -""" -type PaymentVoid { - errors: [PaymentError!]! - - """Updated payment.""" - payment: Payment - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Void payment. - -Added in Saleor 3.6. -""" -type PaymentVoidEvent implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """Look up a payment.""" - payment: Payment - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents a permission object in a friendly form.""" -type Permission { - """Internal code for permission.""" - code: PermissionEnum! - - """Describe action(s) allowed to do by permission.""" - name: String! -} - -"""An enumeration.""" -enum PermissionEnum { - HANDLE_CHECKOUTS - HANDLE_PAYMENTS - HANDLE_TAXES - IMPERSONATE_USER - MANAGE_APPS - MANAGE_CHANNELS - MANAGE_CHECKOUTS - MANAGE_DISCOUNTS - MANAGE_GIFT_CARD - MANAGE_MENUS - MANAGE_OBSERVABILITY - MANAGE_ORDERS - MANAGE_ORDERS_IMPORT - MANAGE_PAGES - MANAGE_PAGE_TYPES_AND_ATTRIBUTES - MANAGE_PLUGINS - MANAGE_PRODUCTS - MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES - MANAGE_SETTINGS - MANAGE_SHIPPING - MANAGE_STAFF - MANAGE_TAXES - MANAGE_TRANSLATIONS - MANAGE_USERS -} - -""" -Create new permission group. Apps are not allowed to perform this mutation. - -Requires one of the following permissions: MANAGE_STAFF. - -Triggers the following webhook events: -- PERMISSION_GROUP_CREATED (async) -""" -type PermissionGroupCreate { - errors: [PermissionGroupError!]! - group: Group - permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input PermissionGroupCreateInput { - """ - List of channels to assign to this group. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - addChannels: [ID!] - - """List of permission code names to assign to this group.""" - addPermissions: [PermissionEnum!] - - """List of users to assign to this group.""" - addUsers: [ID!] - - """Group name.""" - name: String! - - """ - Determine if the group has restricted access to channels. DEFAULT: False - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - restrictedAccessToChannels: Boolean = false -} - -""" -Event sent when new permission group is created. - -Added in Saleor 3.6. -""" -type PermissionGroupCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The permission group the event relates to.""" - permissionGroup: Group - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Delete permission group. Apps are not allowed to perform this mutation. - -Requires one of the following permissions: MANAGE_STAFF. - -Triggers the following webhook events: -- PERMISSION_GROUP_DELETED (async) -""" -type PermissionGroupDelete { - errors: [PermissionGroupError!]! - group: Group - permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when permission group is deleted. - -Added in Saleor 3.6. -""" -type PermissionGroupDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The permission group the event relates to.""" - permissionGroup: Group - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type PermissionGroupError { - """List of channels IDs which causes the error.""" - channels: [ID!] - - """The error code.""" - code: PermissionGroupErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of permissions which causes the error.""" - permissions: [PermissionEnum!] - - """List of user IDs which causes the error.""" - users: [ID!] -} - -"""An enumeration.""" -enum PermissionGroupErrorCode { - ASSIGN_NON_STAFF_MEMBER - CANNOT_REMOVE_FROM_LAST_GROUP - DUPLICATED_INPUT_ITEM - LEFT_NOT_MANAGEABLE_PERMISSION - OUT_OF_SCOPE_CHANNEL - OUT_OF_SCOPE_PERMISSION - OUT_OF_SCOPE_USER - REQUIRED - UNIQUE -} - -input PermissionGroupFilterInput { - ids: [ID!] - search: String -} - -"""Sorting options for permission groups.""" -enum PermissionGroupSortField { - """Sort permission group accounts by name.""" - NAME -} - -input PermissionGroupSortingInput { - """Specifies the direction in which to sort permission group.""" - direction: OrderDirection! - - """Sort permission group by the selected field.""" - field: PermissionGroupSortField! -} - -""" -Update permission group. Apps are not allowed to perform this mutation. - -Requires one of the following permissions: MANAGE_STAFF. - -Triggers the following webhook events: -- PERMISSION_GROUP_UPDATED (async) -""" -type PermissionGroupUpdate { - errors: [PermissionGroupError!]! - group: Group - permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input PermissionGroupUpdateInput { - """ - List of channels to assign to this group. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - addChannels: [ID!] - - """List of permission code names to assign to this group.""" - addPermissions: [PermissionEnum!] - - """List of users to assign to this group.""" - addUsers: [ID!] - - """Group name.""" - name: String - - """ - List of channels to unassign from this group. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - removeChannels: [ID!] - - """List of permission code names to unassign from this group.""" - removePermissions: [PermissionEnum!] - - """List of users to unassign from this group.""" - removeUsers: [ID!] - - """ - Determine if the group has restricted access to channels. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - restrictedAccessToChannels: Boolean -} - -""" -Event sent when permission group is updated. - -Added in Saleor 3.6. -""" -type PermissionGroupUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The permission group the event relates to.""" - permissionGroup: Group - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Plugin.""" -type Plugin { - """Channel-specific plugin configuration.""" - channelConfigurations: [PluginConfiguration!]! - - """Description of the plugin.""" - description: String! - - """Global configuration of the plugin (not channel-specific).""" - globalConfiguration: PluginConfiguration - - """Identifier of the plugin.""" - id: ID! - - """Name of the plugin.""" - name: String! -} - -"""Stores information about a configuration of plugin.""" -type PluginConfiguration { - """Determines if plugin is active or not.""" - active: Boolean! - - """The channel to which the plugin configuration is assigned to.""" - channel: Channel - - """Configuration of the plugin.""" - configuration: [ConfigurationItem!] -} - -enum PluginConfigurationType { - GLOBAL - PER_CHANNEL -} - -type PluginCountableConnection { - edges: [PluginCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type PluginCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Plugin! -} - -type PluginError { - """The error code.""" - code: PluginErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PluginErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - PLUGIN_MISCONFIGURED - REQUIRED - UNIQUE -} - -input PluginFilterInput { - search: String - statusInChannels: PluginStatusInChannelsInput - type: PluginConfigurationType -} - -enum PluginSortField { - IS_ACTIVE - NAME -} - -input PluginSortingInput { - """Specifies the direction in which to sort plugins.""" - direction: OrderDirection! - - """Sort plugins by the selected field.""" - field: PluginSortField! -} - -input PluginStatusInChannelsInput { - active: Boolean! - channels: [ID!]! -} - -""" -Update plugin configuration. - -Requires one of the following permissions: MANAGE_PLUGINS. -""" -type PluginUpdate { - errors: [PluginError!]! - plugin: Plugin - pluginsErrors: [PluginError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input PluginUpdateInput { - """Indicates whether the plugin should be enabled.""" - active: Boolean - - """Configuration of the plugin.""" - configuration: [ConfigurationItemInput!] -} - -""" -Nonnegative Decimal scalar implementation. - -Should be used in places where value must be nonnegative (0 or greater). -""" -scalar PositiveDecimal - -"""An enumeration.""" -enum PostalCodeRuleInclusionTypeEnum { - EXCLUDE - INCLUDE -} - -"""Represents preorder settings for product variant.""" -type PreorderData { - """Preorder end date.""" - endDate: DateTime - - """ - Total number of sold product variant during preorder. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - globalSoldUnits: Int! - - """ - The global preorder threshold for product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - globalThreshold: Int -} - -input PreorderSettingsInput { - """The end date for preorder.""" - endDate: DateTime - - """The global threshold for preorder variant.""" - globalThreshold: Int -} - -"""Represents preorder variant data for channel.""" -type PreorderThreshold { - """Preorder threshold for product variant in this channel.""" - quantity: Int - - """Number of sold product variant in this channel.""" - soldUnits: Int! -} - -input PriceInput { - """Amount of money.""" - amount: PositiveDecimal! - - """Currency code.""" - currency: String! -} - -input PriceRangeInput { - """Price greater than or equal to.""" - gte: Float - - """Price less than or equal to.""" - lte: Float -} - -"""Represents an individual item for sale in the storefront.""" -type Product implements Node & ObjectWithMetadata { - """ - Get a single attribute attached to product by attribute slug. - - Added in Saleor 3.9. - """ - attribute( - """Slug of the attribute""" - slug: String! - ): SelectedAttribute - - """List of attributes assigned to this product.""" - attributes: [SelectedAttribute!]! - - """Date when product is available for purchase.""" - availableForPurchase: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `availableForPurchaseAt` field to fetch the available for purchase date.") - - """Date when product is available for purchase.""" - availableForPurchaseAt: DateTime - category: Category - - """ - Channel given to retrieve this product. Also used by federation gateway to resolve this object in a federated query. - """ - channel: String - - """ - List of availability in channels for the product. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - channelListings: [ProductChannelListing!] - chargeTaxes: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` field to determine whether tax collection is enabled.") - - """ - List of collections for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - collections: [Collection!] - - """The date and time when the product was created.""" - created: DateTime! - - """Default variant of the product.""" - defaultVariant: ProductVariant - - """ - Description of the product. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Description of the product. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """ - External ID of this product. - - Added in Saleor 3.10. - """ - externalReference: String - - """The ID of the product.""" - id: ID! - - """Get a single product image by ID.""" - imageById( - """ID of a product image.""" - id: ID - ): ProductImage @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `mediaById` field instead.") - - """List of images for the product.""" - images: [ProductImage!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `media` field instead.") - - """ - Whether the product is in stock, set as available for purchase in the given channel, and published. - """ - isAvailable( - """ - Destination address used to find warehouses where stock availability for this product is checked. If address is empty, uses `Shop.companyAddress` or fallbacks to server's `settings.DEFAULT_COUNTRY` configuration. - """ - address: AddressInput - ): Boolean - - """ - Refers to a state that can be set by admins to control whether a product is available for purchase in storefronts. This does not guarantee the availability of stock. When set to `False`, this product is still visible to customers, but it cannot be purchased. - """ - isAvailableForPurchase: Boolean - - """List of media for the product.""" - media( - """ - Sort media. - - Added in Saleor 3.9. - """ - sortBy: MediaSortingInput - ): [ProductMedia!] - - """Get a single product media by ID.""" - mediaById( - """ID of a product media.""" - id: ID - ): ProductMedia - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """SEO description of the product.""" - name: String! - - """ - Lists the storefront product's pricing, the current price and discounts, only meant for displaying. - """ - pricing( - """ - Destination address used to find warehouses where stock availability for this product is checked. If address is empty, uses `Shop.companyAddress` or fallbacks to server's `settings.DEFAULT_COUNTRY` configuration. - """ - address: AddressInput - ): ProductPricingInfo - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Type of the product.""" - productType: ProductType! - - """Rating of the product.""" - rating: Float - - """SEO description of the product.""" - seoDescription: String - - """SEO title of the product.""" - seoTitle: String - - """Slug of the product.""" - slug: String! - - """ - Tax class assigned to this product type. All products of this product type use this tax class, unless it's overridden in the `Product` type. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxClass: TaxClass - - """A type of tax. Assigned by enabled tax gateway""" - taxType: TaxType @deprecated(reason: "This field will be removed in Saleor 4.0. Use `taxClass` field instead.") - - """Thumbnail of the product.""" - thumbnail( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. - """ - format: ThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): Image - - """Returns translated product fields for the given language code.""" - translation( - """A language code to return the translation for product.""" - languageCode: LanguageCodeEnum! - ): ProductTranslation - - """The date and time when the product was last updated.""" - updatedAt: DateTime! - - """ - Get a single variant by SKU or ID. - - Added in Saleor 3.9. - """ - variant( - """ID of the variant.""" - id: ID - - """SKU of the variant.""" - sku: String - ): ProductVariant @deprecated(reason: "This field will be removed in Saleor 4.0. Use top-level `variant` query.") - - """ - List of variants for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - variants: [ProductVariant!] - - """Weight of the product.""" - weight: Weight -} - -""" -Assign attributes to a given product type. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. -""" -type ProductAttributeAssign { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """The updated product type.""" - productType: ProductType -} - -input ProductAttributeAssignInput { - """The ID of the attribute to assign.""" - id: ID! - - """The attribute type to be assigned as.""" - type: ProductAttributeType! - - """ - Whether attribute is allowed in variant selection. Allowed types are: ['dropdown', 'boolean', 'swatch', 'numeric']. - - Added in Saleor 3.1. - """ - variantSelection: Boolean -} - -""" -Update attributes assigned to product variant for given product type. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. -""" -type ProductAttributeAssignmentUpdate { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """The updated product type.""" - productType: ProductType -} - -input ProductAttributeAssignmentUpdateInput { - """The ID of the attribute to assign.""" - id: ID! - - """ - Whether attribute is allowed in variant selection. Allowed types are: ['dropdown', 'boolean', 'swatch', 'numeric']. - - Added in Saleor 3.1. - """ - variantSelection: Boolean! -} - -enum ProductAttributeType { - PRODUCT - VARIANT -} - -""" -Un-assign attributes from a given product type. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. -""" -type ProductAttributeUnassign { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """The updated product type.""" - productType: ProductType -} - -""" -Creates products. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductBulkCreate { - """Returns how many objects were created.""" - count: Int! - errors: [ProductBulkCreateError!]! - - """List of the created products.""" - results: [ProductBulkResult!]! -} - -type ProductBulkCreateError { - """List of attributes IDs which causes the error.""" - attributes: [ID!] - - """List of channel IDs which causes the error.""" - channels: [ID!] - - """The error code.""" - code: ProductBulkCreateErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String - - """List of attribute values IDs which causes the error.""" - values: [ID!] - - """List of warehouse IDs which causes the error.""" - warehouses: [ID!] -} - -"""An enumeration.""" -enum ProductBulkCreateErrorCode { - ATTRIBUTE_ALREADY_ASSIGNED - ATTRIBUTE_CANNOT_BE_ASSIGNED - ATTRIBUTE_VARIANTS_DISABLED - BLANK - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - INVALID_PRICE - MAX_LENGTH - NOT_FOUND - PRODUCT_NOT_ASSIGNED_TO_CHANNEL - PRODUCT_WITHOUT_CATEGORY - REQUIRED - UNIQUE - UNSUPPORTED_MEDIA_PROVIDER -} - -input ProductBulkCreateInput { - """List of attributes.""" - attributes: [AttributeValueInput!] - - """ID of the product's category.""" - category: ID - - """List of channels in which the product is available.""" - channelListings: [ProductChannelListingCreateInput!] - - """ - Determine if taxes are being charged for the product. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. - """ - chargeTaxes: Boolean - - """List of IDs of collections that the product belongs to.""" - collections: [ID!] - - """ - Product description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """External ID of this product.""" - externalReference: String - - """List of media inputs associated with the product.""" - media: [MediaInput!] - - """Fields required to update the product metadata.""" - metadata: [MetadataInput!] - - """Product name.""" - name: String - - """Fields required to update the product private metadata.""" - privateMetadata: [MetadataInput!] - - """ID of the type that product belongs to.""" - productType: ID! - - """Defines the product rating value.""" - rating: Float - - """Search engine optimization fields.""" - seo: SeoInput - - """Product slug.""" - slug: String - - """ - ID of a tax class to assign to this product. If not provided, product will use the tax class which is assigned to the product type. - """ - taxClass: ID - - """ - Tax rate for enabled tax gateway. - - DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. - """ - taxCode: String - - """Input list of product variants to create.""" - variants: [ProductVariantBulkCreateInput!] - - """Weight of the Product.""" - weight: WeightScalar -} - -""" -Deletes products. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type ProductBulkResult { - """List of errors occurred on create attempt.""" - errors: [ProductBulkCreateError!] - - """Product data.""" - product: Product -} - -""" -Creates/updates translations for products. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. - -Triggers the following webhook events: -- TRANSLATION_CREATED (async): Called when a translation was created. -- TRANSLATION_UPDATED (async): Called when a translation was updated. -""" -type ProductBulkTranslate { - """Returns how many translations were created/updated.""" - count: Int! - errors: [ProductBulkTranslateError!]! - - """List of the translations.""" - results: [ProductBulkTranslateResult!]! -} - -type ProductBulkTranslateError { - """The error code.""" - code: ProductTranslateErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String -} - -input ProductBulkTranslateInput { - """External reference of an product.""" - externalReference: String - - """Product ID.""" - id: ID - - """Translation language code.""" - languageCode: LanguageCodeEnum! - - """Translation fields.""" - translationFields: TranslationInput! -} - -type ProductBulkTranslateResult { - """List of errors occurred on translation attempt.""" - errors: [ProductBulkTranslateError!] - - """Product translation data.""" - translation: ProductTranslation -} - -"""Represents product channel listing.""" -type ProductChannelListing implements Node { - availableForPurchase: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `availableForPurchaseAt` field to fetch the available for purchase date.") - - """ - The product available for purchase date time. - - Added in Saleor 3.3. - """ - availableForPurchaseAt: DateTime - - """The channel in which the product is listed.""" - channel: Channel! - - """The price of the cheapest variant (including discounts).""" - discountedPrice: Money - - """The ID of the product channel listing.""" - id: ID! - - """ - Refers to a state that can be set by admins to control whether a product is available for purchase in storefronts in this channel. This does not guarantee the availability of stock. When set to `False`, this product is still visible to customers, but it cannot be purchased. - """ - isAvailableForPurchase: Boolean - - """Indicates if the product is published in the channel.""" - isPublished: Boolean! - - """ - Range of margin percentage value. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - margin: Margin - - """ - Lists the storefront product's pricing, the current price and discounts, only meant for displaying. - """ - pricing( - """ - Destination address used to find warehouses where stock availability for this product is checked. If address is empty, uses `Shop.companyAddress` or fallbacks to server's `settings.DEFAULT_COUNTRY` configuration. - """ - address: AddressInput - ): ProductPricingInfo - publicationDate: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date.") - - """ - The product publication date time. - - Added in Saleor 3.3. - """ - publishedAt: DateTime - - """ - Purchase cost of product. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - purchaseCost: MoneyRange - - """Indicates product visibility in the channel listings.""" - visibleInListings: Boolean! -} - -input ProductChannelListingAddInput { - """List of variants to which the channel should be assigned.""" - addVariants: [ID!] - - """ - A start date time from which a product will be available for purchase. When not set and `isAvailable` is set to True, the current day is assumed. - - Added in Saleor 3.3. - """ - availableForPurchaseAt: DateTime - - """ - A start date from which a product will be available for purchase. When not set and isAvailable is set to True, the current day is assumed. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `availableForPurchaseAt` field instead. - """ - availableForPurchaseDate: Date - - """ID of a channel.""" - channelId: ID! - - """ - Determines if product should be available for purchase in this channel. This does not guarantee the availability of stock. When set to `False`, this product is still visible to customers, but it cannot be purchased. - """ - isAvailableForPurchase: Boolean - - """Determines if object is visible to customers.""" - isPublished: Boolean - - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - """ - publicationDate: Date - - """ - Publication date time. ISO 8601 standard. - - Added in Saleor 3.3. - """ - publishedAt: DateTime - - """List of variants from which the channel should be unassigned.""" - removeVariants: [ID!] - - """ - Determines if product is visible in product listings (doesn't apply to product collections). - """ - visibleInListings: Boolean -} - -input ProductChannelListingCreateInput { - """ - A start date time from which a product will be available for purchase. When not set and `isAvailable` is set to True, the current day is assumed. - """ - availableForPurchaseAt: DateTime - - """ID of a channel.""" - channelId: ID! - - """ - Determines if product should be available for purchase in this channel. This does not guarantee the availability of stock. When set to `False`, this product is still visible to customers, but it cannot be purchased. - """ - isAvailableForPurchase: Boolean - - """Determines if object is visible to customers.""" - isPublished: Boolean - - """Publication date time. ISO 8601 standard.""" - publishedAt: DateTime - - """ - Determines if product is visible in product listings (doesn't apply to product collections). - """ - visibleInListings: Boolean -} - -type ProductChannelListingError { - """List of attributes IDs which causes the error.""" - attributes: [ID!] - - """List of channels IDs which causes the error.""" - channels: [ID!] - - """The error code.""" - code: ProductErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of attribute values IDs which causes the error.""" - values: [ID!] - - """List of variants IDs which causes the error.""" - variants: [ID!] -} - -""" -Manage product's availability in channels. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductChannelListingUpdate { - errors: [ProductChannelListingError!]! - - """An updated product instance.""" - product: Product - productChannelListingErrors: [ProductChannelListingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input ProductChannelListingUpdateInput { - """List of channels from which the product should be unassigned.""" - removeChannels: [ID!] - - """List of channels to which the product should be assigned or updated.""" - updateChannels: [ProductChannelListingAddInput!] -} - -type ProductCountableConnection { - edges: [ProductCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type ProductCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Product! -} - -""" -Creates a new product. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductCreate { - errors: [ProductError!]! - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input ProductCreateInput { - """List of attributes.""" - attributes: [AttributeValueInput!] - - """ID of the product's category.""" - category: ID - - """ - Determine if taxes are being charged for the product. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. - """ - chargeTaxes: Boolean - - """List of IDs of collections that the product belongs to.""" - collections: [ID!] - - """ - Product description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - External ID of this product. - - Added in Saleor 3.10. - """ - externalReference: String - - """ - Fields required to update the product metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Product name.""" - name: String - - """ - Fields required to update the product private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """ID of the type that product belongs to.""" - productType: ID! - - """Defines the product rating value.""" - rating: Float - - """Search engine optimization fields.""" - seo: SeoInput - - """Product slug.""" - slug: String - - """ - ID of a tax class to assign to this product. If not provided, product will use the tax class which is assigned to the product type. - """ - taxClass: ID - - """ - Tax rate for enabled tax gateway. - - DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. - """ - taxCode: String - - """Weight of the Product.""" - weight: WeightScalar -} - -""" -Event sent when new product is created. - -Added in Saleor 3.2. -""" -type ProductCreated implements Event { - """The category of the product.""" - category: Category - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product the event relates to.""" - product( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Product - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a product. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductDelete { - errors: [ProductError!]! - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when product is deleted. - -Added in Saleor 3.2. -""" -type ProductDeleted implements Event { - """The category of the product.""" - category: Category - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product the event relates to.""" - product( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Product - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -type ProductError { - """List of attributes IDs which causes the error.""" - attributes: [ID!] - - """The error code.""" - code: ProductErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of attribute values IDs which causes the error.""" - values: [ID!] -} - -"""An enumeration.""" -enum ProductErrorCode { - ALREADY_EXISTS - ATTRIBUTE_ALREADY_ASSIGNED - ATTRIBUTE_CANNOT_BE_ASSIGNED - ATTRIBUTE_VARIANTS_DISABLED - CANNOT_MANAGE_PRODUCT_WITHOUT_VARIANT - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - INVALID_PRICE - MEDIA_ALREADY_ASSIGNED - NOT_FOUND - NOT_PRODUCTS_IMAGE - NOT_PRODUCTS_VARIANT - PREORDER_VARIANT_CANNOT_BE_DEACTIVATED - PRODUCT_NOT_ASSIGNED_TO_CHANNEL - PRODUCT_WITHOUT_CATEGORY - REQUIRED - UNIQUE - UNSUPPORTED_MEDIA_PROVIDER - VARIANT_NO_DIGITAL_CONTENT -} - -""" -Event sent when product export is completed. - -Added in Saleor 3.16. -""" -type ProductExportCompleted implements Event { - """The export file for products.""" - export: ExportFile - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -enum ProductFieldEnum { - CATEGORY - CHARGE_TAXES - COLLECTIONS - DESCRIPTION - NAME - PRODUCT_MEDIA - PRODUCT_TYPE - PRODUCT_WEIGHT - VARIANT_ID - VARIANT_MEDIA - VARIANT_SKU - VARIANT_WEIGHT -} - -input ProductFilterInput { - attributes: [AttributeInput!] - - """ - Filter by the date of availability for purchase. - - Added in Saleor 3.8. - """ - availableFrom: DateTime - categories: [ID!] - - """ - Specifies the channel by which the data should be filtered. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String - collections: [ID!] - - """Filter on whether product is a gift card or not.""" - giftCard: Boolean - hasCategory: Boolean - hasPreorderedVariants: Boolean - ids: [ID!] - - """ - Filter by availability for purchase. - - Added in Saleor 3.8. - """ - isAvailable: Boolean - isPublished: Boolean - - """ - Filter by visibility in product listings. - - Added in Saleor 3.8. - """ - isVisibleInListing: Boolean - metadata: [MetadataFilter!] - - """Filter by the lowest variant price after discounts.""" - minimalPrice: PriceRangeInput - price: PriceRangeInput - productTypes: [ID!] - - """ - Filter by the publication date. - - Added in Saleor 3.8. - """ - publishedFrom: DateTime - search: String - slugs: [String!] - - """Filter by variants having specific stock status.""" - stockAvailability: StockAvailability - stocks: ProductStockFilterInput - - """Filter by when was the most recent update.""" - updatedAt: DateTimeRangeInput -} - -"""Represents a product image.""" -type ProductImage { - """The alt text of the image.""" - alt: String - - """The ID of the image.""" - id: ID! - - """ - The new relative sorting position of the item (from -inf to +inf). 1 moves the item one position forward, -1 moves the item one position backward, 0 leaves the item unchanged. - """ - sortOrder: Int - - """The URL of the image.""" - url( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. - """ - format: ThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): String! -} - -input ProductInput { - """List of attributes.""" - attributes: [AttributeValueInput!] - - """ID of the product's category.""" - category: ID - - """ - Determine if taxes are being charged for the product. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. - """ - chargeTaxes: Boolean - - """List of IDs of collections that the product belongs to.""" - collections: [ID!] - - """ - Product description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - External ID of this product. - - Added in Saleor 3.10. - """ - externalReference: String - - """ - Fields required to update the product metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Product name.""" - name: String - - """ - Fields required to update the product private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """Defines the product rating value.""" - rating: Float - - """Search engine optimization fields.""" - seo: SeoInput - - """Product slug.""" - slug: String - - """ - ID of a tax class to assign to this product. If not provided, product will use the tax class which is assigned to the product type. - """ - taxClass: ID - - """ - Tax rate for enabled tax gateway. - - DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. - """ - taxCode: String - - """Weight of the Product.""" - weight: WeightScalar -} - -"""Represents a product media.""" -type ProductMedia implements Node & ObjectWithMetadata { - """The alt text of the media.""" - alt: String! - - """The unique ID of the product media.""" - id: ID! - - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.12. - """ - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.12. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.12. - """ - metafields(keys: [String!]): Metadata - - """The oEmbed data of the media.""" - oembedData: JSONString! - - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.12. - """ - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.12. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.12. - """ - privateMetafields(keys: [String!]): Metadata - - """ - Product id the media refers to. - - Added in Saleor 3.12. - """ - productId: ID - - """The sort order of the media.""" - sortOrder: Int - - """The type of the media.""" - type: ProductMediaType! - - """The URL of the media.""" - url( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. - """ - format: ThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): String! -} - -""" -Deletes product media. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductMediaBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Create a media object (image or video URL) associated with product. For image, this mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductMediaCreate { - errors: [ProductError!]! - media: ProductMedia - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input ProductMediaCreateInput { - """Alt text for a product media.""" - alt: String - - """Represents an image file in a multipart request.""" - image: Upload - - """Represents an URL to an external media.""" - mediaUrl: String - - """ID of an product.""" - product: ID! -} - -""" -Event sent when new product media is created. - -Added in Saleor 3.12. -""" -type ProductMediaCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product media the event relates to.""" - productMedia: ProductMedia - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a product media. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductMediaDelete { - errors: [ProductError!]! - media: ProductMedia - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when product media is deleted. - -Added in Saleor 3.12. -""" -type ProductMediaDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product media the event relates to.""" - productMedia: ProductMedia - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Changes ordering of the product media. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductMediaReorder { - errors: [ProductError!]! - media: [ProductMedia!] - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""An enumeration.""" -enum ProductMediaType { - IMAGE - VIDEO -} - -""" -Updates a product media. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductMediaUpdate { - errors: [ProductError!]! - media: ProductMedia - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input ProductMediaUpdateInput { - """Alt text for a product media.""" - alt: String -} - -""" -Event sent when product media is updated. - -Added in Saleor 3.12. -""" -type ProductMediaUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product media the event relates to.""" - productMedia: ProductMedia - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when product metadata is updated. - -Added in Saleor 3.8. -""" -type ProductMetadataUpdated implements Event { - """The category of the product.""" - category: Category - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product the event relates to.""" - product( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Product - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input ProductOrder { - """ - Sort product by the selected attribute's values. - Note: this doesn't take translations into account yet. - """ - attributeId: ID - - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String - - """Specifies the direction in which to sort products.""" - direction: OrderDirection! - - """Sort products by the selected field.""" - field: ProductOrderField -} - -enum ProductOrderField { - """ - Sort products by collection. Note: This option is available only for the `Collection.products` query. - - This option requires a channel filter to work as the values can vary between channels. - """ - COLLECTION - - """ - Sort products by creation date. - - Added in Saleor 3.8. - """ - CREATED_AT - - """Sort products by update date.""" - DATE - - """Sort products by update date.""" - LAST_MODIFIED - - """Sort products by update date.""" - LAST_MODIFIED_AT - - """ - Sort products by a minimal price of a product's variant. - - This option requires a channel filter to work as the values can vary between channels. - """ - MINIMAL_PRICE - - """Sort products by name.""" - NAME - - """ - Sort products by price. - - This option requires a channel filter to work as the values can vary between channels. - """ - PRICE - - """ - Sort products by publication date. - - This option requires a channel filter to work as the values can vary between channels. - """ - PUBLICATION_DATE - - """ - Sort products by publication status. - - This option requires a channel filter to work as the values can vary between channels. - """ - PUBLISHED - - """ - Sort products by publication date. - - This option requires a channel filter to work as the values can vary between channels. - """ - PUBLISHED_AT - - """ - Sort products by rank. Note: This option is available only with the `search` filter. - """ - RANK - - """Sort products by rating.""" - RATING - - """Sort products by type.""" - TYPE -} - -"""Represents availability of a product in the storefront.""" -type ProductPricingInfo { - """The discount amount if in sale (null otherwise).""" - discount: TaxedMoney - - """The discount amount in the local currency.""" - discountLocalCurrency: TaxedMoney @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`.") - - """ - Determines whether displayed prices should include taxes. - - Added in Saleor 3.9. - """ - displayGrossPrices: Boolean! - - """Whether it is in sale or not.""" - onSale: Boolean - - """The discounted price range of the product variants.""" - priceRange: TaxedMoneyRange - - """ - The discounted price range of the product variants in the local currency. - """ - priceRangeLocalCurrency: TaxedMoneyRange @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`.") - - """The undiscounted price range of the product variants.""" - priceRangeUndiscounted: TaxedMoneyRange -} - -""" -Reorder product attribute values. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductReorderAttributeValues { - errors: [ProductError!]! - - """Product from which attribute values are reordered.""" - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input ProductStockFilterInput { - quantity: IntRangeInput - warehouseIds: [ID!] -} - -""" -Represents product's original translatable fields and related translations. -""" -type ProductTranslatableContent implements Node { - """List of product attribute values that can be translated.""" - attributeValues: [AttributeValueTranslatableContent!]! - - """ - Product's description to translate. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Description of the product. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """The ID of the product translatable content.""" - id: ID! - - """Product's name to translate.""" - name: String! - - """Represents an individual item for sale in the storefront.""" - product: Product @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the product to translate. - - Added in Saleor 3.14. - """ - productId: ID! - - """SEO description to translate.""" - seoDescription: String - - """SEO title to translate.""" - seoTitle: String - - """Returns translated product fields for the given language code.""" - translation( - """A language code to return the translation for product.""" - languageCode: LanguageCodeEnum! - ): ProductTranslation -} - -""" -Creates/updates translations for a product. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type ProductTranslate { - errors: [TranslationError!]! - product: Product - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""An enumeration.""" -enum ProductTranslateErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED -} - -"""Represents product translations.""" -type ProductTranslation implements Node { - """ - Translated description of the product. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - Translated description of the product. - - Rich text format. For reference see https://editorjs.io/ - """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") - - """The ID of the product translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated product name.""" - name: String - - """Translated SEO description.""" - seoDescription: String - - """Translated SEO title.""" - seoTitle: String - - """ - Represents the product fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: ProductTranslatableContent -} - -""" -Represents a type of product. It defines what attributes are available to products of this type. -""" -type ProductType implements Node & ObjectWithMetadata { - """ - Variant attributes of that product type with attached variant selection. - - Added in Saleor 3.1. - """ - assignedVariantAttributes( - """Define scope of returned attributes.""" - variantSelection: VariantAttributeScope - ): [AssignedVariantAttribute!] - - """ - List of attributes which can be assigned to this product type. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - availableAttributes( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - filter: AttributeFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - where: AttributeWhereInput - ): AttributeCountableConnection - - """Whether the product type has variants.""" - hasVariants: Boolean! - - """The ID of the product type.""" - id: ID! - - """Whether the product type is digital.""" - isDigital: Boolean! - - """Whether shipping is required for this product type.""" - isShippingRequired: Boolean! - - """The product type kind.""" - kind: ProductTypeKindEnum! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Name of the product type.""" - name: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Product attributes of that product type.""" - productAttributes: [Attribute!] - - """List of products of this type.""" - products( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ProductCountableConnection @deprecated(reason: "This field will be removed in Saleor 4.0. Use the top-level `products` query with the `productTypes` filter.") - - """Slug of the product type.""" - slug: String! - - """ - Tax class assigned to this product type. All products of this product type use this tax class, unless it's overridden in the `Product` type. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxClass: TaxClass - - """A type of tax. Assigned by enabled tax gateway""" - taxType: TaxType @deprecated(reason: "This field will be removed in Saleor 4.0. Use `taxClass` field instead.") - - """Variant attributes of that product type.""" - variantAttributes( - """Define scope of returned attributes.""" - variantSelection: VariantAttributeScope - ): [Attribute!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use `assignedVariantAttributes` instead.") - - """Weight of the product type.""" - weight: Weight -} - -""" -Deletes product types. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. -""" -type ProductTypeBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -enum ProductTypeConfigurable { - CONFIGURABLE - SIMPLE -} - -type ProductTypeCountableConnection { - edges: [ProductTypeCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type ProductTypeCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: ProductType! -} - -""" -Creates a new product type. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. -""" -type ProductTypeCreate { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - productType: ProductType -} - -""" -Deletes a product type. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. -""" -type ProductTypeDelete { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - productType: ProductType -} - -enum ProductTypeEnum { - DIGITAL - SHIPPABLE -} - -input ProductTypeFilterInput { - configurable: ProductTypeConfigurable - ids: [ID!] - kind: ProductTypeKindEnum - metadata: [MetadataFilter!] - productType: ProductTypeEnum - search: String - slugs: [String!] -} - -input ProductTypeInput { - """ - Determines if product of this type has multiple variants. This option mainly simplifies product management in the dashboard. There is always at least one variant created under the hood. - """ - hasVariants: Boolean - - """Determines if products are digital.""" - isDigital: Boolean - - """Determines if shipping is required for products of this variant.""" - isShippingRequired: Boolean - - """The product type kind.""" - kind: ProductTypeKindEnum - - """Name of the product type.""" - name: String - - """List of attributes shared among all product variants.""" - productAttributes: [ID!] - - """Product type slug.""" - slug: String - - """ - ID of a tax class to assign to this product type. All products of this product type would use this tax class, unless it's overridden in the `Product` type. - """ - taxClass: ID - - """ - Tax rate for enabled tax gateway. - - DEPRECATED: this field will be removed in Saleor 4.0.. Use tax classes to control the tax calculation for a product type. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. - """ - taxCode: String - - """ - List of attributes used to distinguish between different variants of a product. - """ - variantAttributes: [ID!] - - """Weight of the ProductType items.""" - weight: WeightScalar -} - -"""An enumeration.""" -enum ProductTypeKindEnum { - GIFT_CARD - NORMAL -} - -""" -Reorder the attributes of a product type. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. -""" -type ProductTypeReorderAttributes { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Product type from which attributes are reordered.""" - productType: ProductType -} - -enum ProductTypeSortField { - """Sort products by type.""" - DIGITAL - - """Sort products by name.""" - NAME - - """Sort products by shipping.""" - SHIPPING_REQUIRED -} - -input ProductTypeSortingInput { - """Specifies the direction in which to sort product types.""" - direction: OrderDirection! - - """Sort product types by the selected field.""" - field: ProductTypeSortField! -} - -""" -Updates an existing product type. - -Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. -""" -type ProductTypeUpdate { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - productType: ProductType -} - -""" -Updates an existing product. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductUpdate { - errors: [ProductError!]! - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when product is updated. - -Added in Saleor 3.2. -""" -type ProductUpdated implements Event { - """The category of the product.""" - category: Category - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product the event relates to.""" - product( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Product - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents a version of a product such as different size or color.""" -type ProductVariant implements Node & ObjectWithMetadata { - """List of attributes assigned to this variant.""" - attributes( - """Define scope of returned attributes.""" - variantSelection: VariantAttributeScope - ): [SelectedAttribute!]! - - """ - Channel given to retrieve this product variant. Also used by federation gateway to resolve this object in a federated query. - """ - channel: String - - """ - List of price information in channels for the product. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - channelListings: [ProductVariantChannelListing!] - - """The date and time when the product variant was created.""" - created: DateTime! - - """ - Digital content for the product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - digitalContent: DigitalContent - - """ - External ID of this product. - - Added in Saleor 3.10. - """ - externalReference: String - - """The ID of the product variant.""" - id: ID! - - """List of images for the product variant.""" - images: [ProductImage!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `media` field instead.") - - """Gross margin percentage value.""" - margin: Int - - """List of media for the product variant.""" - media: [ProductMedia!] - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """The name of the product variant.""" - name: String! - - """ - Preorder data for product variant. - - Added in Saleor 3.1. - """ - preorder: PreorderData - - """ - Lists the storefront variant's pricing, the current price and discounts, only meant for displaying. - """ - pricing( - """ - Destination address used to find warehouses where stock availability for this product is checked. If address is empty, uses `Shop.companyAddress` or fallbacks to server's `settings.DEFAULT_COUNTRY` configuration. - """ - address: AddressInput - ): VariantPricingInfo - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """The product to which the variant belongs.""" - product: Product! - - """ - Quantity of a product available for sale in one checkout. Field value will be `null` when no `limitQuantityPerCheckout` in global settings has been set, and `productVariant` stocks are not tracked. - """ - quantityAvailable( - """ - Destination address used to find warehouses where stock availability for this product is checked. If address is empty, uses `Shop.companyAddress` or fallbacks to server's `settings.DEFAULT_COUNTRY` configuration. - """ - address: AddressInput - - """ - Two-letter ISO 3166-1 country code. When provided, the exact quantity from a warehouse operating in shipping zones that contain this country will be returned. Otherwise, it will return the maximum quantity from all shipping zones. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `address` argument instead. - """ - countryCode: CountryCode - ): Int - - """The maximum quantity of this variant that a customer can purchase.""" - quantityLimitPerCustomer: Int - - """ - Total quantity ordered. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - quantityOrdered: Int - - """ - Total revenue generated by a variant in given period of time. Note: this field should be queried using `reportProductSales` query as it uses optimizations suitable for such calculations. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - revenue(period: ReportingPeriod): TaxedMoney - - """The SKU (stock keeping unit) of the product variant.""" - sku: String - - """ - Stocks for the product variant. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. - """ - stocks( - """ - Destination address used to find warehouses where stock availability for this product is checked. If address is empty, uses `Shop.companyAddress` or fallbacks to server's `settings.DEFAULT_COUNTRY` configuration. - """ - address: AddressInput - - """ - Two-letter ISO 3166-1 country code. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `address` argument instead. - """ - countryCode: CountryCode - ): [Stock!] - - """ - Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. - """ - trackInventory: Boolean! - - """Returns translated product variant fields for the given language code.""" - translation( - """A language code to return the translation for product variant.""" - languageCode: LanguageCodeEnum! - ): ProductVariantTranslation - - """The date and time when the product variant was last updated.""" - updatedAt: DateTime! - - """The weight of the product variant.""" - weight: Weight -} - -""" -Event sent when product variant is back in stock. - -Added in Saleor 3.2. -""" -type ProductVariantBackInStock implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product variant the event relates to.""" - productVariant( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ProductVariant - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """Look up a warehouse.""" - warehouse: Warehouse -} - -""" -Creates product variants for a given product. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantBulkCreate { - bulkProductErrors: [BulkProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Returns how many objects were created.""" - count: Int! - errors: [BulkProductError!]! - - """List of the created variants.This field will be removed in Saleor 4.0.""" - productVariants: [ProductVariant!]! - - """ - List of the created variants. - - Added in Saleor 3.11. - """ - results: [ProductVariantBulkResult!]! -} - -input ProductVariantBulkCreateInput { - """List of attributes specific to this variant.""" - attributes: [BulkAttributeValueInput!]! - - """List of prices assigned to channels.""" - channelListings: [ProductVariantChannelListingAddInput!] - - """ - External ID of this product variant. - - Added in Saleor 3.10. - """ - externalReference: String - - """ - Fields required to update the product variant metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Variant name.""" - name: String - - """ - Determines if variant is in preorder. - - Added in Saleor 3.1. - """ - preorder: PreorderSettingsInput - - """ - Fields required to update the product variant private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """ - Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - - Added in Saleor 3.1. - """ - quantityLimitPerCustomer: Int - - """Stock keeping unit.""" - sku: String - - """Stocks of a product available for sale.""" - stocks: [StockInput!] - - """ - Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. - """ - trackInventory: Boolean - - """Weight of the Product Variant.""" - weight: WeightScalar -} - -""" -Deletes product variants. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type ProductVariantBulkError { - """List of attributes IDs which causes the error.""" - attributes: [ID!] - - """List of channel listings IDs which causes the error.""" - channelListings: [ID!] - - """ - List of channel IDs which causes the error. - - Added in Saleor 3.12. - """ - channels: [ID!] - - """The error code.""" - code: ProductVariantBulkErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - - Added in Saleor 3.14. - """ - path: String - - """ - List of stocks IDs which causes the error. - - Added in Saleor 3.12. - """ - stocks: [ID!] - - """List of attribute values IDs which causes the error.""" - values: [ID!] - - """List of warehouse IDs which causes the error.""" - warehouses: [ID!] -} - -"""An enumeration.""" -enum ProductVariantBulkErrorCode { - ATTRIBUTE_ALREADY_ASSIGNED - ATTRIBUTE_CANNOT_BE_ASSIGNED - ATTRIBUTE_VARIANTS_DISABLED - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - INVALID_PRICE - NOT_FOUND - NOT_PRODUCTS_VARIANT - PRODUCT_NOT_ASSIGNED_TO_CHANNEL - REQUIRED - STOCK_ALREADY_EXISTS - UNIQUE -} - -type ProductVariantBulkResult { - """List of errors occurred on create attempt.""" - errors: [ProductVariantBulkError!] - - """Product variant data.""" - productVariant: ProductVariant -} - -""" -Creates/updates translations for products variants. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. - -Triggers the following webhook events: -- TRANSLATION_CREATED (async): A translation was created. -- TRANSLATION_UPDATED (async): A translation was updated. -""" -type ProductVariantBulkTranslate { - """Returns how many translations were created/updated.""" - count: Int! - errors: [ProductVariantBulkTranslateError!]! - - """List of the translations.""" - results: [ProductVariantBulkTranslateResult!]! -} - -type ProductVariantBulkTranslateError { - """The error code.""" - code: ProductVariantTranslateErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String -} - -input ProductVariantBulkTranslateInput { - """External reference of a product variant.""" - externalReference: String - - """Product variant ID.""" - id: ID - - """Translation language code.""" - languageCode: LanguageCodeEnum! - - """Translation fields.""" - translationFields: NameTranslationInput! -} - -type ProductVariantBulkTranslateResult { - """List of errors occurred on translation attempt.""" - errors: [ProductVariantBulkTranslateError!] - - """Product variant translation data.""" - translation: ProductVariantTranslation -} - -""" -Update multiple product variants. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantBulkUpdate { - """Returns how many objects were updated.""" - count: Int! - errors: [ProductVariantBulkError!]! - - """List of the updated variants.""" - results: [ProductVariantBulkResult!]! -} - -""" -Input fields to update product variants. - -Added in Saleor 3.11. -""" -input ProductVariantBulkUpdateInput { - """List of attributes specific to this variant.""" - attributes: [BulkAttributeValueInput!] - - """ - Channel listings input. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - channelListings: ProductVariantChannelListingUpdateInput - - """ - External ID of this product variant. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of the product variant to update.""" - id: ID! - - """ - Fields required to update the product variant metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Variant name.""" - name: String - - """ - Determines if variant is in preorder. - - Added in Saleor 3.1. - """ - preorder: PreorderSettingsInput - - """ - Fields required to update the product variant private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """ - Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - - Added in Saleor 3.1. - """ - quantityLimitPerCustomer: Int - - """Stock keeping unit.""" - sku: String - - """ - Stocks input. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - stocks: ProductVariantStocksUpdateInput - - """ - Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. - """ - trackInventory: Boolean - - """Weight of the Product Variant.""" - weight: WeightScalar -} - -"""Represents product variant channel listing.""" -type ProductVariantChannelListing implements Node { - """The channel to which the variant listing belongs.""" - channel: Channel! - - """Cost price of the variant.""" - costPrice: Money - - """The ID of the variant channel listing.""" - id: ID! - - """ - Gross margin percentage value. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - margin: Int - - """ - Preorder variant data. - - Added in Saleor 3.1. - """ - preorderThreshold: PreorderThreshold - - """The price of the variant.""" - price: Money -} - -input ProductVariantChannelListingAddInput { - """ID of a channel.""" - channelId: ID! - - """Cost price of the variant in channel.""" - costPrice: PositiveDecimal - - """ - The threshold for preorder variant in channel. - - Added in Saleor 3.1. - """ - preorderThreshold: Int - - """Price of the particular variant in channel.""" - price: PositiveDecimal! -} - -""" -Manage product variant prices in channels. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantChannelListingUpdate { - errors: [ProductChannelListingError!]! - productChannelListingErrors: [ProductChannelListingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """An updated product variant instance.""" - variant: ProductVariant -} - -input ProductVariantChannelListingUpdateInput { - """List of channels to create variant channel listings.""" - create: [ProductVariantChannelListingAddInput!] - - """List of channel listings to remove.""" - remove: [ID!] - - """List of channel listings to update.""" - update: [ChannelListingUpdateInput!] -} - -type ProductVariantCountableConnection { - edges: [ProductVariantCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type ProductVariantCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: ProductVariant! -} - -""" -Creates a new variant for a product. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantCreate { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - productVariant: ProductVariant -} - -input ProductVariantCreateInput { - """List of attributes specific to this variant.""" - attributes: [AttributeValueInput!]! - - """ - External ID of this product variant. - - Added in Saleor 3.10. - """ - externalReference: String - - """ - Fields required to update the product variant metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Variant name.""" - name: String - - """ - Determines if variant is in preorder. - - Added in Saleor 3.1. - """ - preorder: PreorderSettingsInput - - """ - Fields required to update the product variant private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """Product ID of which type is the variant.""" - product: ID! - - """ - Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - - Added in Saleor 3.1. - """ - quantityLimitPerCustomer: Int - - """Stock keeping unit.""" - sku: String - - """Stocks of a product available for sale.""" - stocks: [StockInput!] - - """ - Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. - """ - trackInventory: Boolean - - """Weight of the Product Variant.""" - weight: WeightScalar -} - -""" -Event sent when new product variant is created. - -Added in Saleor 3.2. -""" -type ProductVariantCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product variant the event relates to.""" - productVariant( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ProductVariant - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a product variant. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantDelete { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - productVariant: ProductVariant -} - -""" -Event sent when product variant is deleted. - -Added in Saleor 3.2. -""" -type ProductVariantDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product variant the event relates to.""" - productVariant( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ProductVariant - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input ProductVariantFilterInput { - isPreorder: Boolean - metadata: [MetadataFilter!] - search: String - sku: [String!] - updatedAt: DateTimeRangeInput -} - -input ProductVariantInput { - """List of attributes specific to this variant.""" - attributes: [AttributeValueInput!] - - """ - External ID of this product variant. - - Added in Saleor 3.10. - """ - externalReference: String - - """ - Fields required to update the product variant metadata. - - Added in Saleor 3.8. - """ - metadata: [MetadataInput!] - - """Variant name.""" - name: String - - """ - Determines if variant is in preorder. - - Added in Saleor 3.1. - """ - preorder: PreorderSettingsInput - - """ - Fields required to update the product variant private metadata. - - Added in Saleor 3.8. - """ - privateMetadata: [MetadataInput!] - - """ - Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - - Added in Saleor 3.1. - """ - quantityLimitPerCustomer: Int - - """Stock keeping unit.""" - sku: String - - """ - Determines if the inventory of this variant should be tracked. If false, the quantity won't change when customers buy this item. If the field is not provided, `Shop.trackInventoryByDefault` will be used. - """ - trackInventory: Boolean - - """Weight of the Product Variant.""" - weight: WeightScalar -} - -""" -Event sent when product variant metadata is updated. - -Added in Saleor 3.8. -""" -type ProductVariantMetadataUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product variant the event relates to.""" - productVariant( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ProductVariant - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when product variant is out of stock. - -Added in Saleor 3.2. -""" -type ProductVariantOutOfStock implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product variant the event relates to.""" - productVariant( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ProductVariant - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """Look up a warehouse.""" - warehouse: Warehouse -} - -""" -Deactivates product variant preorder. It changes all preorder allocation into regular allocation. - -Added in Saleor 3.1. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantPreorderDeactivate { - errors: [ProductError!]! - - """Product variant with ended preorder.""" - productVariant: ProductVariant -} - -""" -Reorder the variants of a product. Mutation updates updated_at on product and triggers PRODUCT_UPDATED webhook. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantReorder { - errors: [ProductError!]! - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Reorder product variant attribute values. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantReorderAttributeValues { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Product variant from which attribute values are reordered.""" - productVariant: ProductVariant -} - -""" -Set default variant for a product. Mutation triggers PRODUCT_UPDATED webhook. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantSetDefault { - errors: [ProductError!]! - product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -enum ProductVariantSortField { - """Sort products variants by last modified at.""" - LAST_MODIFIED_AT -} - -input ProductVariantSortingInput { - """Specifies the direction in which to sort productVariants.""" - direction: OrderDirection! - - """Sort productVariants by the selected field.""" - field: ProductVariantSortField! -} - -""" -Event sent when product variant stock is updated. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type ProductVariantStockUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product variant the event relates to.""" - productVariant( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ProductVariant - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """Look up a warehouse.""" - warehouse: Warehouse -} - -""" -Creates stocks for product variant. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantStocksCreate { - bulkStockErrors: [BulkStockError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [BulkStockError!]! - - """Updated product variant.""" - productVariant: ProductVariant -} - -""" -Delete stocks from product variant. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantStocksDelete { - errors: [StockError!]! - - """Updated product variant.""" - productVariant: ProductVariant - stockErrors: [StockError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Update stocks for product variant. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantStocksUpdate { - bulkStockErrors: [BulkStockError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [BulkStockError!]! - - """Updated product variant.""" - productVariant: ProductVariant -} - -input ProductVariantStocksUpdateInput { - """List of warehouses to create stocks.""" - create: [StockInput!] - - """List of stocks to remove.""" - remove: [ID!] - - """List of stocks to update.""" - update: [StockUpdateInput!] -} - -""" -Represents product variant's original translatable fields and related translations. -""" -type ProductVariantTranslatableContent implements Node { - """List of product variant attribute values that can be translated.""" - attributeValues: [AttributeValueTranslatableContent!]! - - """The ID of the product variant translatable content.""" - id: ID! - - """Name of the product variant to translate.""" - name: String! - - """Represents a version of a product such as different size or color.""" - productVariant: ProductVariant @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the product variant to translate. - - Added in Saleor 3.14. - """ - productVariantId: ID! - - """Returns translated product variant fields for the given language code.""" - translation( - """A language code to return the translation for product variant.""" - languageCode: LanguageCodeEnum! - ): ProductVariantTranslation -} - -""" -Creates/updates translations for a product variant. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type ProductVariantTranslate { - errors: [TranslationError!]! - productVariant: ProductVariant - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""An enumeration.""" -enum ProductVariantTranslateErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED -} - -"""Represents product variant translations.""" -type ProductVariantTranslation implements Node { - """The ID of the product variant translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated product variant name.""" - name: String! - - """ - Represents the product variant fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: ProductVariantTranslatableContent -} - -""" -Updates an existing variant for product. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type ProductVariantUpdate { - errors: [ProductError!]! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - productVariant: ProductVariant -} - -""" -Event sent when product variant is updated. - -Added in Saleor 3.2. -""" -type ProductVariantUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The product variant the event relates to.""" - productVariant( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ProductVariant - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -input ProductVariantWhereInput { - """List of conditions that must be met.""" - AND: [ProductVariantWhereInput!] - - """A list of conditions of which at least one must be met.""" - OR: [ProductVariantWhereInput!] - ids: [ID!] - metadata: [MetadataFilter!] -} - -input ProductWhereInput { - """List of conditions that must be met.""" - AND: [ProductWhereInput!] - - """A list of conditions of which at least one must be met.""" - OR: [ProductWhereInput!] - - """Filter by attributes associated with the product.""" - attributes: [AttributeInput!] - - """Filter by the date of availability for purchase.""" - availableFrom: DateTime - - """Filter by product category.""" - category: GlobalIDFilterInput - - """Filter by collection.""" - collection: GlobalIDFilterInput - - """Filter on whether product is a gift card or not.""" - giftCard: Boolean - - """Filter by product with category assigned.""" - hasCategory: Boolean - - """Filter by product with preordered variants.""" - hasPreorderedVariants: Boolean - ids: [ID!] - - """Filter by availability for purchase.""" - isAvailable: Boolean - - """Filter by public visibility.""" - isPublished: Boolean - - """Filter by visibility on the channel.""" - isVisibleInListing: Boolean - metadata: [MetadataFilter!] - - """Filter by the lowest variant price after discounts.""" - minimalPrice: DecimalFilterInput - - """Filter by product name.""" - name: StringFilterInput - - """Filter by product variant price.""" - price: DecimalFilterInput - - """Filter by product type.""" - productType: GlobalIDFilterInput - - """Filter by the publication date.""" - publishedFrom: DateTime - - """Filter by product slug.""" - slug: StringFilterInput - - """Filter by variants having specific stock status.""" - stockAvailability: StockAvailability - - """Filter by stock of the product variant.""" - stocks: ProductStockFilterInput - - """Filter by when was the most recent update.""" - updatedAt: DateTimeFilterInput -} - -""" -Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type Promotion implements Node & ObjectWithMetadata { - """Date time of promotion creation.""" - createdAt: DateTime! - - """Description of the promotion.""" - description: JSON - - """End date of the promotion.""" - endDate: DateTime - - """The list of events associated with the promotion.""" - events: [PromotionEvent!] - id: ID! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Name of the promotion.""" - name: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """The list of promotion rules.""" - rules: [PromotionRule!] - - """Start date of the promotion.""" - startDate: DateTime! - - """Returns translated promotion fields for the given language code.""" - translation( - """A language code to return the translation for promotion.""" - languageCode: LanguageCodeEnum! - ): PromotionTranslation - - """ - The type of the promotion. Implicate if the discount is applied on catalogue or order level. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - type: PromotionTypeEnum - - """Date time of last update of promotion.""" - updatedAt: DateTime! -} - -""" -Deletes promotions. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- PROMOTION_DELETED (async): A promotion was deleted. -""" -type PromotionBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [DiscountError!]! -} - -type PromotionCountableConnection { - edges: [PromotionCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type PromotionCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Promotion! -} - -""" -Creates a new promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- PROMOTION_CREATED (async): A promotion was created. -- PROMOTION_STARTED (async): Optionally called if promotion was started. -""" -type PromotionCreate { - errors: [PromotionCreateError!]! - promotion: Promotion -} - -type PromotionCreateError { - """The error code.""" - code: PromotionCreateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """Limit of gifts assigned to promotion rule.""" - giftsLimit: Int - - """Number of gifts defined for this promotion rule exceeding the limit.""" - giftsLimitExceedBy: Int - - """Index of an input list item that caused the error.""" - index: Int - - """The error message.""" - message: String - - """Limit of rules with orderPredicate defined.""" - rulesLimit: Int - - """Number of rules with orderPredicate defined exceeding the limit.""" - rulesLimitExceedBy: Int -} - -"""An enumeration.""" -enum PromotionCreateErrorCode { - GIFTS_NUMBER_LIMIT - GRAPHQL_ERROR - INVALID - INVALID_GIFT_TYPE - INVALID_PRECISION - MISSING_CHANNELS - MULTIPLE_CURRENCIES_NOT_ALLOWED - NOT_FOUND - REQUIRED - RULES_NUMBER_LIMIT -} - -input PromotionCreateInput { - """Promotion description.""" - description: JSON - - """The end date of the promotion in ISO 8601 format.""" - endDate: DateTime - - """Promotion name.""" - name: String! - - """List of promotion rules.""" - rules: [PromotionRuleInput!] - - """The start date of the promotion in ISO 8601 format.""" - startDate: DateTime - - """ - Defines the promotion type. Implicate the required promotion rules predicate type and whether the promotion rules will give the catalogue or order discount. - - Added in Saleor 3.19. - """ - type: PromotionTypeEnum! -} - -""" -Event sent when new promotion is created. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The promotion the event relates to.""" - promotion: Promotion - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -History log of the promotion created event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionCreatedEvent implements Node & PromotionEventInterface { - """ - User or App that created the promotion event. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. - """ - createdBy: UserOrApp - - """Date when event happened.""" - date: DateTime! - id: ID! - - """Promotion event type.""" - type: PromotionEventsEnum! -} - -""" -Deletes a promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- PROMOTION_DELETED (async): A promotion was deleted. -""" -type PromotionDelete { - errors: [PromotionDeleteError!]! - promotion: Promotion -} - -type PromotionDeleteError { - """The error code.""" - code: PromotionDeleteErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PromotionDeleteErrorCode { - GRAPHQL_ERROR - NOT_FOUND -} - -""" -Event sent when promotion is deleted. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The promotion the event relates to.""" - promotion: Promotion - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -The event informs about the end of the promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionEnded implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The promotion the event relates to.""" - promotion: Promotion - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -History log of the promotion ended event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionEndedEvent implements Node & PromotionEventInterface { - """ - User or App that created the promotion event. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. - """ - createdBy: UserOrApp - - """Date when event happened.""" - date: DateTime! - id: ID! - - """Promotion event type.""" - type: PromotionEventsEnum! -} - -union PromotionEvent = PromotionCreatedEvent | PromotionEndedEvent | PromotionRuleCreatedEvent | PromotionRuleDeletedEvent | PromotionRuleUpdatedEvent | PromotionStartedEvent | PromotionUpdatedEvent - -interface PromotionEventInterface { - """ - User or App that created the promotion event. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. - """ - createdBy: UserOrApp - - """Date when event happened.""" - date: DateTime! - id: ID! - - """Promotion event type.""" - type: PromotionEventsEnum! -} - -"""An enumeration.""" -enum PromotionEventsEnum { - PROMOTION_CREATED - PROMOTION_ENDED - PROMOTION_STARTED - PROMOTION_UPDATED - RULE_CREATED - RULE_DELETED - RULE_UPDATED -} - -""" -Represents the promotion rule that specifies the conditions that must be met to apply the promotion discount. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionRule implements Node { - """The catalogue predicate that must be met to apply the rule reward.""" - cataloguePredicate: JSON - - """ - List of channels where the rule applies. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - channels: [Channel!] - - """Description of the promotion rule.""" - description: JSON - - """ - Product variant IDs available as a gift to choose. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - giftIds: [ID!] - - """ - Defines the maximum number of gifts to choose from the gifts list. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - giftsLimit: Int - id: ID! - - """Name of the promotion rule.""" - name: String - - """ - The checkout/order predicate that must be met to apply the rule reward. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderPredicate: JSON - - """ - The type of the predicate that must be met to apply the reward. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - predicateType: PromotionTypeEnum - - """Promotion to which the rule belongs.""" - promotion: Promotion - - """ - The reward type of the promotion rule. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - rewardType: RewardTypeEnum - - """ - The reward value of the promotion rule. Defines the discount value applied when the rule conditions are met. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - rewardValue: PositiveDecimal - - """The type of reward value of the promotion rule.""" - rewardValueType: RewardValueTypeEnum - - """Returns translated promotion rule fields for the given language code.""" - translation( - """A language code to return the translation for promotion rule.""" - languageCode: LanguageCodeEnum! - ): PromotionRuleTranslation -} - -""" -Creates a new promotion rule. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- PROMOTION_RULE_CREATED (async): A promotion rule was created. -""" -type PromotionRuleCreate { - errors: [PromotionRuleCreateError!]! - promotionRule: PromotionRule -} - -type PromotionRuleCreateError { - """The error code.""" - code: PromotionRuleCreateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """Limit of gifts assigned to promotion rule.""" - giftsLimit: Int - - """Number of gifts defined for this promotion rule exceeding the limit.""" - giftsLimitExceedBy: Int - - """The error message.""" - message: String - - """Limit of rules with orderPredicate defined.""" - rulesLimit: Int - - """Number of rules with orderPredicate defined exceeding the limit.""" - rulesLimitExceedBy: Int -} - -"""An enumeration.""" -enum PromotionRuleCreateErrorCode { - GIFTS_NUMBER_LIMIT - GRAPHQL_ERROR - INVALID - INVALID_GIFT_TYPE - INVALID_PRECISION - MISSING_CHANNELS - MULTIPLE_CURRENCIES_NOT_ALLOWED - NOT_FOUND - REQUIRED - RULES_NUMBER_LIMIT -} - -input PromotionRuleCreateInput { - """ - Defines the conditions on the catalogue level that must be met for the reward to be applied. - """ - cataloguePredicate: CataloguePredicateInput - - """List of channel ids to which the rule should apply to.""" - channels: [ID!] - - """Promotion rule description.""" - description: JSON - - """ - Product variant IDs available as a gift to choose. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - gifts: [ID!] - - """Promotion rule name.""" - name: String - - """ - Defines the conditions on the checkout/draft order level that must be met for the reward to be applied. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderPredicate: OrderPredicateInput - - """The ID of the promotion that rule belongs to.""" - promotion: ID! - - """ - Defines the reward type of the promotion rule. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - rewardType: RewardTypeEnum - - """ - Defines the discount value. Required when catalogue predicate is provided. - """ - rewardValue: PositiveDecimal - - """ - Defines the promotion rule reward value type. Must be provided together with reward value. - """ - rewardValueType: RewardValueTypeEnum -} - -""" -Event sent when new promotion rule is created. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionRuleCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The promotion rule the event relates to.""" - promotionRule: PromotionRule - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -History log of the promotion rule created event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionRuleCreatedEvent implements Node & PromotionEventInterface & PromotionRuleEventInterface { - """ - User or App that created the promotion event. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. - """ - createdBy: UserOrApp - - """Date when event happened.""" - date: DateTime! - id: ID! - - """The rule ID associated with the promotion event.""" - ruleId: String - - """Promotion event type.""" - type: PromotionEventsEnum! -} - -""" -Deletes a promotion rule. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- PROMOTION_RULE_DELETED (async): A promotion rule was deleted. -""" -type PromotionRuleDelete { - errors: [PromotionRuleDeleteError!]! - promotionRule: PromotionRule -} - -type PromotionRuleDeleteError { - """The error code.""" - code: PromotionRuleDeleteErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PromotionRuleDeleteErrorCode { - GRAPHQL_ERROR - NOT_FOUND -} - -""" -Event sent when new promotion rule is deleted. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionRuleDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The promotion rule the event relates to.""" - promotionRule: PromotionRule - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -History log of the promotion rule created event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionRuleDeletedEvent implements Node & PromotionEventInterface & PromotionRuleEventInterface { - """ - User or App that created the promotion event. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. - """ - createdBy: UserOrApp - - """Date when event happened.""" - date: DateTime! - id: ID! - - """The rule ID associated with the promotion event.""" - ruleId: String - - """Promotion event type.""" - type: PromotionEventsEnum! -} - -""" -History log of the promotion event related to rule. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -interface PromotionRuleEventInterface { - """The rule ID associated with the promotion event.""" - ruleId: String -} - -input PromotionRuleInput { - """ - Defines the conditions on the catalogue level that must be met for the reward to be applied. - """ - cataloguePredicate: CataloguePredicateInput - - """List of channel ids to which the rule should apply to.""" - channels: [ID!] - - """Promotion rule description.""" - description: JSON - - """ - Product variant IDs available as a gift to choose. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - gifts: [ID!] - - """Promotion rule name.""" - name: String - - """ - Defines the conditions on the checkout/draft order level that must be met for the reward to be applied. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderPredicate: OrderPredicateInput - - """ - Defines the reward type of the promotion rule. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - rewardType: RewardTypeEnum - - """ - Defines the discount value. Required when catalogue predicate is provided. - """ - rewardValue: PositiveDecimal - - """ - Defines the promotion rule reward value type. Must be provided together with reward value. - """ - rewardValueType: RewardValueTypeEnum -} - -""" -Represents promotion rule's original translatable fields and related translations. - -Added in Saleor 3.17. -""" -type PromotionRuleTranslatableContent implements Node { - """ - Description of the promotion rule. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ID of the promotion rule translatable content.""" - id: ID! - - """Name of the promotion rule.""" - name: String - - """ - ID of the promotion rule to translate. - - Added in Saleor 3.14. - """ - promotionRuleId: ID! - - """Returns translated promotion rule fields for the given language code.""" - translation( - """A language code to return the translation for promotion rule.""" - languageCode: LanguageCodeEnum! - ): PromotionRuleTranslation -} - -""" -Creates/updates translations for a promotion rule. - -Added in Saleor 3.17. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type PromotionRuleTranslate { - errors: [TranslationError!]! - promotionRule: PromotionRule -} - -""" -Represents promotion rule translations. - -Added in Saleor 3.17. -""" -type PromotionRuleTranslation implements Node { - """ - Translated description of the promotion rule. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ID of the promotion rule translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated name of the promotion rule.""" - name: String - - """ - Represents the promotion rule fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: PromotionRuleTranslatableContent -} - -input PromotionRuleTranslationInput { - """ - Translated promotion description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSON - name: String -} - -""" -Updates an existing promotion rule. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- PROMOTION_RULE_UPDATED (async): A promotion rule was updated. -""" -type PromotionRuleUpdate { - errors: [PromotionRuleUpdateError!]! - promotionRule: PromotionRule -} - -type PromotionRuleUpdateError { - """List of channel IDs which causes the error.""" - channels: [ID!] - - """The error code.""" - code: PromotionRuleUpdateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """Limit of gifts assigned to promotion rule.""" - giftsLimit: Int - - """Number of gifts defined for this promotion rule exceeding the limit.""" - giftsLimitExceedBy: Int - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PromotionRuleUpdateErrorCode { - DUPLICATED_INPUT_ITEM - GIFTS_NUMBER_LIMIT - GRAPHQL_ERROR - INVALID - INVALID_GIFT_TYPE - INVALID_PRECISION - MISSING_CHANNELS - MULTIPLE_CURRENCIES_NOT_ALLOWED - NOT_FOUND - REQUIRED -} - -input PromotionRuleUpdateInput { - """List of channel ids to add.""" - addChannels: [ID!] - - """ - List of variant IDs available as a gift to add. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - addGifts: [ID!] - - """ - Defines the conditions on the catalogue level that must be met for the reward to be applied. - """ - cataloguePredicate: CataloguePredicateInput - - """Promotion rule description.""" - description: JSON - - """Promotion rule name.""" - name: String - - """ - Defines the conditions on the checkout/draft order level that must be met for the reward to be applied. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderPredicate: OrderPredicateInput - - """List of channel ids to remove.""" - removeChannels: [ID!] - - """ - List of variant IDs available as a gift to remove. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - removeGifts: [ID!] - - """ - Defines the reward type of the promotion rule. - - Added in Saleor 3.19. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - rewardType: RewardTypeEnum - - """ - Defines the discount value. Required when catalogue predicate is provided. - """ - rewardValue: PositiveDecimal - - """ - Defines the promotion rule reward value type. Must be provided together with reward value. - """ - rewardValueType: RewardValueTypeEnum -} - -""" -Event sent when new promotion rule is updated. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionRuleUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The promotion rule the event relates to.""" - promotionRule: PromotionRule - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -History log of the promotion rule created event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionRuleUpdatedEvent implements Node & PromotionEventInterface & PromotionRuleEventInterface { - """ - User or App that created the promotion event. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. - """ - createdBy: UserOrApp - - """Date when event happened.""" - date: DateTime! - id: ID! - - """The rule ID associated with the promotion event.""" - ruleId: String - - """Promotion event type.""" - type: PromotionEventsEnum! -} - -enum PromotionSortField { - """Sort promotions by created at.""" - CREATED_AT - - """Sort promotions by end date.""" - END_DATE - - """Sort promotions by name.""" - NAME - - """Sort promotions by start date.""" - START_DATE -} - -input PromotionSortingInput { - """Specifies the direction in which to sort promotions.""" - direction: OrderDirection! - - """Sort promotions by the selected field.""" - field: PromotionSortField! -} - -""" -The event informs about the start of the promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionStarted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The promotion the event relates to.""" - promotion: Promotion - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -History log of the promotion started event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionStartedEvent implements Node & PromotionEventInterface { - """ - User or App that created the promotion event. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. - """ - createdBy: UserOrApp - - """Date when event happened.""" - date: DateTime! - id: ID! - - """Promotion event type.""" - type: PromotionEventsEnum! -} - -""" -Represents promotion's original translatable fields and related translations. - -Added in Saleor 3.17. -""" -type PromotionTranslatableContent implements Node { - """ - Description of the promotion. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ID of the promotion translatable content.""" - id: ID! - - """Name of the promotion.""" - name: String! - - """ID of the promotion to translate.""" - promotionId: ID! - - """Returns translated promotion fields for the given language code.""" - translation( - """A language code to return the translation for promotion.""" - languageCode: LanguageCodeEnum! - ): PromotionTranslation -} - -""" -Creates/updates translations for a promotion. - -Added in Saleor 3.17. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type PromotionTranslate { - errors: [TranslationError!]! - promotion: Promotion -} - -""" -Represents promotion translations. - -Added in Saleor 3.17. -""" -type PromotionTranslation implements Node { - """ - Translated description of the promotion. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ID of the promotion translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated name of the promotion.""" - name: String - - """ - Represents the promotion fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: PromotionTranslatableContent -} - -input PromotionTranslationInput { - """ - Translated promotion description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSON - name: String -} - -"""An enumeration.""" -enum PromotionTypeEnum { - CATALOGUE - ORDER -} - -input PromotionTypeEnumFilterInput { - """The value equal to.""" - eq: PromotionTypeEnum - - """The value included in.""" - oneOf: [PromotionTypeEnum!] -} - -""" -Updates an existing promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- PROMOTION_UPDATED (async): A promotion was updated. -- PROMOTION_STARTED (async): Optionally called if promotion was started. -- PROMOTION_ENDED (async): Optionally called if promotion was ended. -""" -type PromotionUpdate { - errors: [PromotionUpdateError!]! - promotion: Promotion -} - -type PromotionUpdateError { - """The error code.""" - code: PromotionUpdateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum PromotionUpdateErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED -} - -input PromotionUpdateInput { - """Promotion description.""" - description: JSON - - """The end date of the promotion in ISO 8601 format.""" - endDate: DateTime - - """Promotion name.""" - name: String - - """The start date of the promotion in ISO 8601 format.""" - startDate: DateTime -} - -""" -Event sent when promotion is updated. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The promotion the event relates to.""" - promotion: Promotion - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -History log of the promotion updated event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type PromotionUpdatedEvent implements Node & PromotionEventInterface { - """ - User or App that created the promotion event. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_APPS, OWNER. - """ - createdBy: UserOrApp - - """Date when event happened.""" - date: DateTime! - id: ID! - - """Promotion event type.""" - type: PromotionEventsEnum! -} - -input PromotionWhereInput { - """List of conditions that must be met.""" - AND: [PromotionWhereInput!] - - """A list of conditions of which at least one must be met.""" - OR: [PromotionWhereInput!] - - """Filter promotions by end date.""" - endDate: DateTimeFilterInput - ids: [ID!] - isOldSale: Boolean - metadata: [MetadataFilter!] - - """Filter by promotion name.""" - name: StringFilterInput - - """Filter promotions by start date.""" - startDate: DateTimeFilterInput - type: PromotionTypeEnumFilterInput -} - -input PublishableChannelListingInput { - """ID of a channel.""" - channelId: ID! - - """Determines if object is visible to customers.""" - isPublished: Boolean - - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - """ - publicationDate: Date - - """ - Publication date time. ISO 8601 standard. - - Added in Saleor 3.3. - """ - publishedAt: DateTime -} - -type Query { - _entities(representations: [_Any]): [_Entity] - _service: _Service - - """ - Look up an address by ID. - - Requires one of the following permissions: MANAGE_USERS, OWNER. - """ - address( - """ID of an address.""" - id: ID! - ): Address - - """Returns address validation rules.""" - addressValidationRules( - """City or a town name.""" - city: String - - """Sublocality like a district.""" - cityArea: String - - """Designation of a region, province or state.""" - countryArea: String - - """Two-letter ISO 3166-1 country code.""" - countryCode: CountryCode! - ): AddressValidationData - - """ - Look up an app by ID. If ID is not provided, return the currently authenticated app. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER AUTHENTICATED_APP. The authenticated app has access to its resources. Fetching different apps requires MANAGE_APPS permission. - """ - app( - """ID of the app.""" - id: ID - ): App - - """ - Look up an app extension by ID. - - Added in Saleor 3.1. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - appExtension( - """ID of the app extension.""" - id: ID! - ): AppExtension - - """ - List of all extensions. - - Added in Saleor 3.1. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - appExtensions( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for apps extensions.""" - filter: AppExtensionFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): AppExtensionCountableConnection - - """ - List of the apps. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, MANAGE_APPS. - """ - apps( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for apps.""" - filter: AppFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort apps.""" - sortBy: AppSortingInput - ): AppCountableConnection - - """ - List of all apps installations - - Requires one of the following permissions: MANAGE_APPS. - """ - appsInstallations: [AppInstallation!]! - - """Look up an attribute by ID, slug or external reference.""" - attribute( - """ - External ID of the attribute. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of the attribute.""" - id: ID - - """Slug of the attribute.""" - slug: String - ): Attribute - - """List of the shop's attributes.""" - attributes( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for attributes.""" - filter: AttributeFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """ - Search attributes. - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - search: String - - """Sorting options for attributes.""" - sortBy: AttributeSortingInput - - """ - Filtering options for attributes. - - Added in Saleor 3.11. - """ - where: AttributeWhereInput - ): AttributeCountableConnection - - """List of the shop's categories.""" - categories( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for categories.""" - filter: CategoryFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Filter categories by the nesting level in the category tree.""" - level: Int - - """Sort categories.""" - sortBy: CategorySortingInput - - """ - Where filtering options. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - where: CategoryWhereInput - ): CategoryCountableConnection - - """Look up a category by ID or slug.""" - category( - """ID of the category.""" - id: ID - - """Slug of the category""" - slug: String - ): Category - - """Look up a channel by ID or slug.""" - channel( - """ID of the channel.""" - id: ID - - """ - Slug of the channel. - - Added in Saleor 3.6. - """ - slug: String - ): Channel - - """ - List of all channels. - - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. - """ - channels: [Channel!] - - """ - Look up a checkout by id. - - Requires one of the following permissions to query a checkout, if a checkout is in inactive channel: MANAGE_CHECKOUTS, IMPERSONATE_USER, HANDLE_PAYMENTS. - """ - checkout( - """ - The checkout's ID. - - Added in Saleor 3.4. - """ - id: ID - - """ - The checkout's token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): Checkout - - """ - List of checkout lines. - - Requires one of the following permissions: MANAGE_CHECKOUTS. - """ - checkoutLines( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): CheckoutLineCountableConnection - - """ - List of checkouts. - - Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS. - """ - checkouts( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """ - Filtering options for checkouts. - - Added in Saleor 3.1. - """ - filter: CheckoutFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """ - Sort checkouts. - - Added in Saleor 3.1. - """ - sortBy: CheckoutSortingInput - ): CheckoutCountableConnection - - """ - Look up a collection by ID. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - collection( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ID of the collection.""" - id: ID - - """Slug of the category""" - slug: String - ): Collection - - """ - List of the shop's collections. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - collections( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for collections.""" - filter: CollectionFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort collections.""" - sortBy: CollectionSortingInput - - """ - Where filtering options. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - where: CollectionWhereInput - ): CollectionCountableConnection - - """ - List of the shop's customers. This list includes all users who registered through the accountRegister mutation. Additionally, staff users who have placed an order using their account will also appear in this list. - - Requires one of the following permissions: MANAGE_ORDERS, MANAGE_USERS. - """ - customers( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for customers.""" - filter: CustomerFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort customers.""" - sortBy: UserSortingInput - ): UserCountableConnection - - """ - Look up digital content by ID. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - digitalContent( - """ID of the digital content.""" - id: ID! - ): DigitalContent - - """ - List of digital content. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - digitalContents( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): DigitalContentCountableConnection - - """ - List of draft orders. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - draftOrders( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for draft orders.""" - filter: OrderDraftFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort draft orders.""" - sortBy: OrderSortingInput - ): OrderCountableConnection - - """ - Look up a export file by ID. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - exportFile( - """ID of the export file job.""" - id: ID! - ): ExportFile - - """ - List of export files. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - exportFiles( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for export files.""" - filter: ExportFileFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort export files.""" - sortBy: ExportFileSortingInput - ): ExportFileCountableConnection - - """ - Look up a gift card by ID. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - """ - giftCard( - """ID of the gift card.""" - id: ID! - ): GiftCard - - """ - List of gift card currencies. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - """ - giftCardCurrencies: [String!]! - - """ - Gift card related settings from site settings. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - """ - giftCardSettings: GiftCardSettings! - - """ - List of gift card tags. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - """ - giftCardTags( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for gift card tags.""" - filter: GiftCardTagFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): GiftCardTagCountableConnection - - """ - List of gift cards. - - Requires one of the following permissions: MANAGE_GIFT_CARD. - """ - giftCards( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Filtering options for gift cards. - - Added in Saleor 3.1. - """ - filter: GiftCardFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """ - Search gift cards by email and name of user, who created or used the gift card, and by code. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - search: String - - """ - Sort gift cards. - - Added in Saleor 3.1. - """ - sortBy: GiftCardSortingInput - ): GiftCardCountableConnection - - """ - List of activity events to display on homepage (at the moment it only contains order-events). - - Requires one of the following permissions: MANAGE_ORDERS. - """ - homepageEvents( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): OrderEventCountableConnection @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """Return the currently authenticated user.""" - me: User - - """Look up a navigation menu by ID or name.""" - menu( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ID of the menu.""" - id: ID - - """The menu's name.""" - name: String - - """The menu's slug.""" - slug: String - ): Menu - - """Look up a menu item by ID.""" - menuItem( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ID of the menu item.""" - id: ID! - ): MenuItem - - """List of the storefronts's menu items.""" - menuItems( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for menu items.""" - filter: MenuItemFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort menus items.""" - sortBy: MenuItemSortingInput - ): MenuItemCountableConnection - - """List of the storefront's menus.""" - menus( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """ - Filtering options for menus. - - `slug`: This field will be removed in Saleor 4.0. Use `slugs` instead. - """ - filter: MenuFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort menus.""" - sortBy: MenuSortingInput - ): MenuCountableConnection - - """Look up an order by ID or external reference.""" - order( - """ - External ID of an order. - - Added in Saleor 3.10.. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - externalReference: String - - """ID of an order.""" - id: ID - ): Order - - """Look up an order by token.""" - orderByToken( - """The order's token.""" - token: UUID! - ): Order @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """ - Order related settings from site settings. Returns `orderSettings` for the first `channel` in alphabetical order. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orderSettings: OrderSettings @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `channel` query to fetch the `orderSettings` field instead.") - - """ - List of orders. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - orders( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for orders.""" - filter: OrderFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort orders.""" - sortBy: OrderSortingInput - ): OrderCountableConnection - - """ - Return the total sales amount from a specific period. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - ordersTotal( - """Slug of a channel for which the data should be returned.""" - channel: String - - """A period of time.""" - period: ReportingPeriod - ): TaxedMoney @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """Look up a page by ID or slug.""" - page( - """ID of the page.""" - id: ID - - """The slug of the page.""" - slug: String - ): Page - - """Look up a page type by ID.""" - pageType( - """ID of the page type.""" - id: ID! - ): PageType - - """List of the page types.""" - pageTypes( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for page types.""" - filter: PageTypeFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort page types.""" - sortBy: PageTypeSortingInput - ): PageTypeCountableConnection - - """List of the shop's pages.""" - pages( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for pages.""" - filter: PageFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort pages.""" - sortBy: PageSortingInput - ): PageCountableConnection - - """ - Look up a payment by ID. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - payment( - """ID of the payment.""" - id: ID! - ): Payment - - """ - List of payments. - - Requires one of the following permissions: MANAGE_ORDERS. - """ - payments( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for payments.""" - filter: PaymentFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): PaymentCountableConnection - - """ - Look up permission group by ID. - - Requires one of the following permissions: MANAGE_STAFF. - """ - permissionGroup( - """ID of the group.""" - id: ID! - ): Group - - """ - List of permission groups. - - Requires one of the following permissions: MANAGE_STAFF. - """ - permissionGroups( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for permission groups.""" - filter: PermissionGroupFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort permission groups.""" - sortBy: PermissionGroupSortingInput - ): GroupCountableConnection - - """ - Look up a plugin by ID. - - Requires one of the following permissions: MANAGE_PLUGINS. - """ - plugin( - """ID of the plugin.""" - id: ID! - ): Plugin - - """ - List of plugins. - - Requires one of the following permissions: MANAGE_PLUGINS. - """ - plugins( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for plugins.""" - filter: PluginFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort plugins.""" - sortBy: PluginSortingInput - ): PluginCountableConnection - - """ - Look up a product by ID. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - product( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ - External ID of the product. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of the product.""" - id: ID - - """Slug of the product.""" - slug: String - ): Product - - """Look up a product type by ID.""" - productType( - """ID of the product type.""" - id: ID! - ): ProductType - - """List of the shop's product types.""" - productTypes( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for product types.""" - filter: ProductTypeFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort product types.""" - sortBy: ProductTypeSortingInput - ): ProductTypeCountableConnection - - """ - Look up a product variant by ID or SKU. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - productVariant( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ - External ID of the product. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of the product variant.""" - id: ID - - """SKU of the product variant.""" - sku: String - ): ProductVariant - - """ - List of product variants. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - productVariants( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for product variant.""" - filter: ProductVariantFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """Filter product variants by given IDs.""" - ids: [ID!] - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort products variants.""" - sortBy: ProductVariantSortingInput - - """ - Where filtering options. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - where: ProductVariantWhereInput - ): ProductVariantCountableConnection - - """ - List of the shop's products. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. - """ - products( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for products.""" - filter: ProductFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """ - Search products. - - Added in Saleor 3.14. - """ - search: String - - """Sort products.""" - sortBy: ProductOrder - - """ - Where filtering options. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - where: ProductWhereInput - ): ProductCountableConnection - - """ - Look up a promotion by ID. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - promotion( - """ID of the promotion.""" - id: ID! - ): Promotion - - """ - List of the promotions. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - promotions( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort promotions.""" - sortBy: PromotionSortingInput - - """Where filtering options.""" - where: PromotionWhereInput - ): PromotionCountableConnection - - """ - List of top selling products. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - reportProductSales( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String! - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Span of time.""" - period: ReportingPeriod! - ): ProductVariantCountableConnection @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """ - Look up a sale by ID. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - sale( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ID of the sale.""" - id: ID! - ): Sale @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `promotion` query instead.") - - """ - List of the shop's sales. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - sales( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for sales.""" - filter: SaleFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """ - Search sales by name, value or type. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `filter.search` input instead. - """ - query: String - - """Sort sales.""" - sortBy: SaleSortingInput - ): SaleCountableConnection @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `promotions` query instead.") - - """ - Look up a shipping zone by ID. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingZone( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ID of the shipping zone.""" - id: ID! - ): ShippingZone - - """ - List of the shop's shipping zones. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingZones( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for shipping zones.""" - filter: ShippingZoneFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ShippingZoneCountableConnection - - """Return information about the shop.""" - shop: Shop! - - """ - List of the shop's staff users. - - Requires one of the following permissions: MANAGE_STAFF. - """ - staffUsers( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for staff users.""" - filter: StaffUserInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort staff users.""" - sortBy: UserSortingInput - ): UserCountableConnection - - """ - Look up a stock by ID - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - stock( - """ID of a stock""" - id: ID! - ): Stock - - """ - List of stocks. - - Requires one of the following permissions: MANAGE_PRODUCTS. - """ - stocks( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - filter: StockFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): StockCountableConnection - - """ - Look up a tax class. - - Added in Saleor 3.9. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxClass( - """ID of a tax class.""" - id: ID! - ): TaxClass - - """ - List of tax classes. - - Added in Saleor 3.9. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxClasses( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for tax classes.""" - filter: TaxClassFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Sort tax classes.""" - sortBy: TaxClassSortingInput - ): TaxClassCountableConnection - - """ - Look up a tax configuration. - - Added in Saleor 3.9. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxConfiguration( - """ID of a tax configuration.""" - id: ID! - ): TaxConfiguration - - """ - List of tax configurations. - - Added in Saleor 3.9. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxConfigurations( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Filtering options for tax configurations.""" - filter: TaxConfigurationFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): TaxConfigurationCountableConnection - - """ - Tax class rates grouped by country. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxCountryConfiguration( - """Country for which to return tax class rates.""" - countryCode: CountryCode! - ): TaxCountryConfiguration - - """ - \n\nRequires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxCountryConfigurations: [TaxCountryConfiguration!] - - """List of all tax rates available from tax gateway.""" - taxTypes: [TaxType!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use `taxClasses` field instead.") - - """ - Look up a transaction by ID. - - Added in Saleor 3.6. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - - Requires one of the following permissions: HANDLE_PAYMENTS. - """ - transaction( - """ - ID of a transaction. Either it or token is required to fetch the transaction data. - """ - id: ID - - """ - Token of a transaction. Either it or ID is required to fetch the transaction data. - """ - token: UUID - ): TransactionItem - - """ - Lookup a translatable item by ID. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - translation( - """ID of the object to retrieve.""" - id: ID! - - """Kind of the object to retrieve.""" - kind: TranslatableKinds! - ): TranslatableItem - - """ - Returns a list of all translatable items of a given kind. - - Requires one of the following permissions: MANAGE_TRANSLATIONS. - """ - translations( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """Kind of objects to retrieve.""" - kind: TranslatableKinds! - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): TranslatableItemConnection - - """ - Look up a user by ID or email address. - - Requires one of the following permissions: MANAGE_STAFF, MANAGE_USERS, MANAGE_ORDERS. - """ - user( - """Email address of the user.""" - email: String - - """ - External ID of the user. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of the user.""" - id: ID - ): User - - """ - Look up a voucher by ID. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - voucher( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ID of the voucher.""" - id: ID! - ): Voucher - - """ - List of the shop's vouchers. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - vouchers( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """Filtering options for vouchers.""" - filter: VoucherFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """ - Search vouchers by name or code. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `filter.search` input instead. - """ - query: String - - """Sort voucher.""" - sortBy: VoucherSortingInput - ): VoucherCountableConnection - - """ - Look up a warehouse by ID. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS, MANAGE_SHIPPING. - """ - warehouse( - """ - External ID of a warehouse. - - Added in Saleor 3.10. - """ - externalReference: String - - """ID of a warehouse.""" - id: ID - ): Warehouse - - """ - List of warehouses. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS, MANAGE_SHIPPING. - """ - warehouses( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - filter: WarehouseFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - sortBy: WarehouseSortingInput - ): WarehouseCountableConnection - - """ - Look up a webhook by ID. Requires one of the following permissions: MANAGE_APPS, OWNER. - """ - webhook( - """ID of the webhook.""" - id: ID! - ): Webhook - - """ - List of all available webhook events. - - Requires one of the following permissions: MANAGE_APPS. - """ - webhookEvents: [WebhookEvent!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use `WebhookEventTypeAsyncEnum` and `WebhookEventTypeSyncEnum` to get available event types.") - - """ - Retrieve a sample payload for a given webhook event based on real data. It can be useful for some integrations where sample payload is required. - """ - webhookSamplePayload( - """Name of the requested event type.""" - eventType: WebhookSampleEventTypeEnum! - ): JSONString -} - -"""Represents a reduced VAT rate for a particular type of goods.""" -type ReducedRate { - """Reduced VAT rate in percent.""" - rate: Float! - - """A type of goods.""" - rateType: String! -} - -""" -Refresh JWT token. Mutation tries to take refreshToken from the input. If it fails it will try to take `refreshToken` from the http-only cookie `refreshToken`. `csrfToken` is required when `refreshToken` is provided as a cookie. -""" -type RefreshToken { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """JWT token, required to authenticate.""" - token: String - - """A user instance.""" - user: User -} - -input ReorderInput { - """The ID of the item to move.""" - id: ID! - - """ - The new relative sorting position of the item (from -inf to +inf). 1 moves the item one position forward, -1 moves the item one position backward, 0 leaves the item unchanged. - """ - sortOrder: Int -} - -enum ReportingPeriod { - THIS_MONTH - TODAY -} - -""" -Request email change of the logged in user. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- NOTIFY_USER (async): A notification for account email change. -- ACCOUNT_CHANGE_EMAIL_REQUESTED (async): An account email change was requested. -""" -type RequestEmailChange { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """A user instance.""" - user: User -} - -""" -Sends an email with the account password modification link. - -Triggers the following webhook events: -- NOTIFY_USER (async): A notification for password reset. -- ACCOUNT_SET_PASSWORD_REQUESTED (async): Setting a new password for the account is requested. -- STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. -""" -type RequestPasswordReset { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! -} - -"""An enumeration.""" -enum RewardTypeEnum { - GIFT - SUBTOTAL_DISCOUNT -} - -"""An enumeration.""" -enum RewardValueTypeEnum { - FIXED - PERCENTAGE -} - -""" -Sales allow creating discounts for categories, collections or products and are visible to all the customers. - -DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. -""" -type Sale implements Node & ObjectWithMetadata { - """List of categories this sale applies to.""" - categories( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): CategoryCountableConnection - - """ - List of channels available for the sale. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - channelListings: [SaleChannelListing!] - - """ - List of collections this sale applies to. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - collections( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): CollectionCountableConnection - - """The date and time when the sale was created.""" - created: DateTime! - - """Currency code for sale.""" - currency: String - - """Sale value.""" - discountValue: Float - - """The end date and time of the sale.""" - endDate: DateTime - - """The ID of the sale.""" - id: ID! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """The name of the sale.""" - name: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - List of products this sale applies to. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - products( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ProductCountableConnection - - """The start date and time of the sale.""" - startDate: DateTime! - - """Returns translated sale fields for the given language code.""" - translation( - """A language code to return the translation for sale.""" - languageCode: LanguageCodeEnum! - ): SaleTranslation - - """Type of the sale, fixed or percentage.""" - type: SaleType! - - """The date and time when the sale was updated.""" - updatedAt: DateTime! - - """ - List of product variants this sale applies to. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - variants( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ProductVariantCountableConnection -} - -""" -Adds products, categories, collections to a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` mutation instead. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- SALE_UPDATED (async): A sale was updated. -""" -type SaleAddCatalogues { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - - """Sale of which catalogue IDs will be modified.""" - sale: Sale -} - -""" -Deletes sales. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- SALE_DELETED (async): A sale was deleted. -""" -type SaleBulkDelete { - """Returns how many objects were affected.""" - count: Int! - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! -} - -""" -Represents sale channel listing. - -DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionRule` type instead. -""" -type SaleChannelListing implements Node { - """The channel in which the sale is available.""" - channel: Channel! - - """The currency in which the discount value is specified.""" - currency: String! - - """The value of the discount applied to the sale in the channel.""" - discountValue: Float! - - """The ID of the channel listing.""" - id: ID! -} - -input SaleChannelListingAddInput { - """ID of a channel.""" - channelId: ID! - - """The value of the discount.""" - discountValue: PositiveDecimal! -} - -input SaleChannelListingInput { - """List of channels to which the sale should be assigned.""" - addChannels: [SaleChannelListingAddInput!] - - """List of channels from which the sale should be unassigned.""" - removeChannels: [ID!] -} - -""" -Manage sale's availability in channels. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` or `promotionRuleUpdate` mutations instead. - -Requires one of the following permissions: MANAGE_DISCOUNTS. -""" -type SaleChannelListingUpdate { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - - """An updated sale instance.""" - sale: Sale -} - -type SaleCountableConnection { - edges: [SaleCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type SaleCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Sale! -} - -""" -Creates a new sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionCreate` mutation instead. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- SALE_CREATED (async): A sale was created. -""" -type SaleCreate { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - sale: Sale -} - -""" -Event sent when new sale is created. - -Added in Saleor 3.2. - -DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionCreated` event instead. -""" -type SaleCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The sale the event relates to.""" - sale( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Sale - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionDelete` mutation instead. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- SALE_DELETED (async): A sale was deleted. -""" -type SaleDelete { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - sale: Sale -} - -""" -Event sent when sale is deleted. - -Added in Saleor 3.2. - -DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionDeleted` event instead. -""" -type SaleDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The sale the event relates to.""" - sale( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Sale - - """Saleor version that triggered the event.""" - version: String -} - -input SaleFilterInput { - metadata: [MetadataFilter!] - saleType: DiscountValueTypeEnum - search: String - started: DateTimeRangeInput - status: [DiscountStatusEnum!] - updatedAt: DateTimeRangeInput -} - -input SaleInput { - """Categories related to the discount.""" - categories: [ID!] - - """Collections related to the discount.""" - collections: [ID!] - - """End date of the voucher in ISO 8601 format.""" - endDate: DateTime - - """Voucher name.""" - name: String - - """Products related to the discount.""" - products: [ID!] - - """Start date of the voucher in ISO 8601 format.""" - startDate: DateTime - - """Fixed or percentage.""" - type: DiscountValueTypeEnum - - """Value of the voucher.""" - value: PositiveDecimal - variants: [ID!] -} - -""" -Removes products, categories, collections from a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleUpdate` or `promotionRuleDelete` mutations instead. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- SALE_UPDATED (async): A sale was updated. -""" -type SaleRemoveCatalogues { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - - """Sale of which catalogue IDs will be modified.""" - sale: Sale -} - -enum SaleSortField { - """Sort sales by created at.""" - CREATED_AT - - """Sort sales by end date.""" - END_DATE - - """Sort sales by last modified at.""" - LAST_MODIFIED_AT - - """Sort sales by name.""" - NAME - - """Sort sales by start date.""" - START_DATE - - """Sort sales by type.""" - TYPE - - """ - Sort sales by value. - - This option requires a channel filter to work as the values can vary between channels. - """ - VALUE -} - -input SaleSortingInput { - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String - - """Specifies the direction in which to sort sales.""" - direction: OrderDirection! - - """Sort sales by the selected field.""" - field: SaleSortField! -} - -""" -The event informs about the start or end of the sale. - -Added in Saleor 3.5. - -DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionStarted` and `PromotionEnded` events instead. -""" -type SaleToggle implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """ - The sale the event relates to. - - Added in Saleor 3.5. - """ - sale( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Sale - - """Saleor version that triggered the event.""" - version: String -} - -""" -Represents sale's original translatable fields and related translations. - -DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionTranslatableContent` instead. -""" -type SaleTranslatableContent implements Node { - """The ID of the sale translatable content.""" - id: ID! - - """Name of the sale to translate.""" - name: String! - - """ - Sales allow creating discounts for categories, collections or products and are visible to all the customers. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - sale: Sale @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the sale to translate. - - Added in Saleor 3.14. - """ - saleId: ID! - - """Returns translated sale fields for the given language code.""" - translation( - """A language code to return the translation for sale.""" - languageCode: LanguageCodeEnum! - ): SaleTranslation -} - -""" -Creates/updates translations for a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PromotionTranslate` mutation instead. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type SaleTranslate { - errors: [TranslationError!]! - sale: Sale - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Represents sale translations. - -DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionTranslation` instead. -""" -type SaleTranslation implements Node { - """The ID of the sale translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated name of sale.""" - name: String - - """ - Represents the sale fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: SaleTranslatableContent -} - -enum SaleType { - FIXED - PERCENTAGE -} - -""" -Updates a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionUpdate` mutation instead. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- SALE_UPDATED (async): A sale was updated. -- SALE_TOGGLE (async): Optionally triggered when a sale is started or stopped. -""" -type SaleUpdate { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - sale: Sale -} - -""" -Event sent when sale is updated. - -Added in Saleor 3.2. - -DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionUpdated` event instead. -""" -type SaleUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The sale the event relates to.""" - sale( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Sale - - """Saleor version that triggered the event.""" - version: String -} - -"""Represents a custom attribute.""" -type SelectedAttribute { - """Name of an attribute displayed in the interface.""" - attribute: Attribute! - - """Values of an attribute.""" - values: [AttributeValue!]! -} - -""" -Sends a notification confirmation. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- NOTIFY_USER (async): A notification for account confirmation. -- ACCOUNT_CONFIRMATION_REQUESTED (async): An account confirmation was requested. This event is always sent regardless of settings. -""" -type SendConfirmationEmail { - errors: [SendConfirmationEmailError!]! -} - -type SendConfirmationEmailError { - """The error code.""" - code: SendConfirmationEmailErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum SendConfirmationEmailErrorCode { - ACCOUNT_CONFIRMED - CONFIRMATION_ALREADY_REQUESTED - INVALID - MISSING_CHANNEL_SLUG -} - -input SeoInput { - """SEO description.""" - description: String - - """SEO title.""" - title: String -} - -""" -Sets the user's password from the token sent by email using the RequestPasswordReset mutation. -""" -type SetPassword { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """CSRF token required to re-generate access token.""" - csrfToken: String - errors: [AccountError!]! - - """JWT refresh token, required to re-generate access token.""" - refreshToken: String - - """JWT token, required to authenticate.""" - token: String - - """A user instance.""" - user: User -} - -type ShippingError { - """List of channels IDs which causes the error.""" - channels: [ID!] - - """The error code.""" - code: ShippingErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of warehouse IDs which causes the error.""" - warehouses: [ID!] -} - -"""An enumeration.""" -enum ShippingErrorCode { - ALREADY_EXISTS - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - MAX_LESS_THAN_MIN - NOT_FOUND - REQUIRED - UNIQUE -} - -""" -List shipping methods for checkout. - -Added in Saleor 3.6. -""" -type ShippingListMethodsForCheckout implements Event { - """The checkout the event relates to.""" - checkout: Checkout - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """ - Shipping methods that can be used with this checkout. - - Added in Saleor 3.6. - """ - shippingMethods: [ShippingMethod!] - - """Saleor version that triggered the event.""" - version: String -} - -""" -Shipping methods that can be used as means of shipping for orders and checkouts. -""" -type ShippingMethod implements Node & ObjectWithMetadata { - """Describes if this shipping method is active and can be selected.""" - active: Boolean! - - """ - Shipping method description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """Unique ID of ShippingMethod available for Order.""" - id: ID! - - """Maximum delivery days for this shipping method.""" - maximumDeliveryDays: Int - - """Maximum order price for this shipping method.""" - maximumOrderPrice: Money - - """Maximum order weight for this shipping method.""" - maximumOrderWeight: Weight @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """Message connected to this shipping method.""" - message: String - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - """ - metafields(keys: [String!]): Metadata - - """Minimum delivery days for this shipping method.""" - minimumDeliveryDays: Int - - """Minimal order price for this shipping method.""" - minimumOrderPrice: Money - - """Minimum order weight for this shipping method.""" - minimumOrderWeight: Weight @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """Shipping method name.""" - name: String! - - """The price of selected shipping method.""" - price: Money! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - """ - privateMetafields(keys: [String!]): Metadata - - """Returns translated shipping method fields for the given language code.""" - translation( - """A language code to return the translation for shipping method.""" - languageCode: LanguageCodeEnum! - ): ShippingMethodTranslation - - """Type of the shipping method.""" - type: ShippingMethodTypeEnum @deprecated(reason: "This field will be removed in Saleor 4.0.") -} - -"""Represents shipping method channel listing.""" -type ShippingMethodChannelListing implements Node { - """The channel associated with the shipping method channel listing.""" - channel: Channel! - - """The ID of shipping method channel listing.""" - id: ID! - - """Maximum order price.""" - maximumOrderPrice: Money - - """Minimum order price.""" - minimumOrderPrice: Money - - """Price of the shipping method in the associated channel.""" - price: Money -} - -input ShippingMethodChannelListingAddInput { - """ID of a channel.""" - channelId: ID! - - """Maximum order price to use this shipping method.""" - maximumOrderPrice: PositiveDecimal - - """Minimum order price to use this shipping method.""" - minimumOrderPrice: PositiveDecimal - - """Shipping price of the shipping method in this channel.""" - price: PositiveDecimal -} - -input ShippingMethodChannelListingInput { - """List of channels to which the shipping method should be assigned.""" - addChannels: [ShippingMethodChannelListingAddInput!] - - """List of channels from which the shipping method should be unassigned.""" - removeChannels: [ID!] -} - -""" -Manage shipping method's availability in channels. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingMethodChannelListingUpdate { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """An updated shipping method instance.""" - shippingMethod: ShippingMethodType -} - -"""Represents shipping method postal code rule.""" -type ShippingMethodPostalCodeRule implements Node { - """End address range.""" - end: String - - """The ID of the object.""" - id: ID! - - """Inclusion type of the postal code rule.""" - inclusionType: PostalCodeRuleInclusionTypeEnum - - """Start address range.""" - start: String -} - -""" -Represents shipping method's original translatable fields and related translations. -""" -type ShippingMethodTranslatableContent implements Node { - """ - Shipping method description to translate. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """The ID of the shipping method translatable content.""" - id: ID! - - """Shipping method name to translate.""" - name: String! - - """ - Shipping method are the methods you'll use to get customer's orders to them. They are directly exposed to the customers. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - shippingMethod: ShippingMethodType @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the shipping method to translate. - - Added in Saleor 3.14. - """ - shippingMethodId: ID! - - """Returns translated shipping method fields for the given language code.""" - translation( - """A language code to return the translation for shipping method.""" - languageCode: LanguageCodeEnum! - ): ShippingMethodTranslation -} - -"""Represents shipping method translations.""" -type ShippingMethodTranslation implements Node { - """ - Translated description of the shipping method. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """The ID of the shipping method translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated shipping method name.""" - name: String - - """ - Represents the shipping method fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: ShippingMethodTranslatableContent -} - -""" -Shipping method are the methods you'll use to get customer's orders to them. They are directly exposed to the customers. -""" -type ShippingMethodType implements Node & ObjectWithMetadata { - """ - List of channels available for the method. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - channelListings: [ShippingMethodChannelListing!] - - """ - Shipping method description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - - """ - List of excluded products for the shipping method. - - Requires one of the following permissions: MANAGE_SHIPPING. - """ - excludedProducts( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ProductCountableConnection - - """Shipping method ID.""" - id: ID! - - """Maximum number of days for delivery.""" - maximumDeliveryDays: Int - - """The price of the cheapest variant (including discounts).""" - maximumOrderPrice: Money - - """Maximum order weight to use this shipping method.""" - maximumOrderWeight: Weight - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Minimal number of days for delivery.""" - minimumDeliveryDays: Int - - """The price of the cheapest variant (including discounts).""" - minimumOrderPrice: Money - - """Minimum order weight to use this shipping method.""" - minimumOrderWeight: Weight - - """Shipping method name.""" - name: String! - - """ - Postal code ranges rule of exclusion or inclusion of the shipping method. - """ - postalCodeRules: [ShippingMethodPostalCodeRule!] - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - Tax class assigned to this shipping method. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - taxClass: TaxClass - - """Returns translated shipping method fields for the given language code.""" - translation( - """A language code to return the translation for shipping method.""" - languageCode: LanguageCodeEnum! - ): ShippingMethodTranslation - - """Type of the shipping method.""" - type: ShippingMethodTypeEnum -} - -"""An enumeration.""" -enum ShippingMethodTypeEnum { - PRICE - WEIGHT -} - -""" -List of shipping methods available for the country. - -Added in Saleor 3.6. -""" -type ShippingMethodsPerCountry { - """The country code.""" - countryCode: CountryCode! - - """List of available shipping methods.""" - shippingMethods: [ShippingMethod!] -} - -input ShippingPostalCodeRulesCreateInputRange { - """End range of the postal code.""" - end: String - - """Start range of the postal code.""" - start: String! -} - -""" -Deletes shipping prices. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingPriceBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Creates a new shipping price. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingPriceCreate { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - shippingMethod: ShippingMethodType - - """A shipping zone to which the shipping method belongs.""" - shippingZone: ShippingZone -} - -""" -Event sent when new shipping price is created. - -Added in Saleor 3.2. -""" -type ShippingPriceCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The shipping method the event relates to.""" - shippingMethod( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingMethodType - - """The shipping zone the shipping method belongs to.""" - shippingZone( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingZone - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a shipping price. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingPriceDelete { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """A shipping method to delete.""" - shippingMethod: ShippingMethodType - - """A shipping zone to which the shipping method belongs.""" - shippingZone: ShippingZone -} - -""" -Event sent when shipping price is deleted. - -Added in Saleor 3.2. -""" -type ShippingPriceDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The shipping method the event relates to.""" - shippingMethod( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingMethodType - - """The shipping zone the shipping method belongs to.""" - shippingZone( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingZone - - """Saleor version that triggered the event.""" - version: String -} - -""" -Exclude products from shipping price. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingPriceExcludeProducts { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """A shipping method with new list of excluded products.""" - shippingMethod: ShippingMethodType -} - -input ShippingPriceExcludeProductsInput { - """List of products which will be excluded.""" - products: [ID!]! -} - -input ShippingPriceInput { - """Postal code rules to add.""" - addPostalCodeRules: [ShippingPostalCodeRulesCreateInputRange!] - - """Postal code rules to delete.""" - deletePostalCodeRules: [ID!] - - """Shipping method description.""" - description: JSONString - - """Inclusion type for currently assigned postal code rules.""" - inclusionType: PostalCodeRuleInclusionTypeEnum - - """Maximum number of days for delivery.""" - maximumDeliveryDays: Int - - """Maximum order weight to use this shipping method.""" - maximumOrderWeight: WeightScalar - - """Minimal number of days for delivery.""" - minimumDeliveryDays: Int - - """Minimum order weight to use this shipping method.""" - minimumOrderWeight: WeightScalar - - """Name of the shipping method.""" - name: String - - """Shipping zone this method belongs to.""" - shippingZone: ID - - """ - ID of a tax class to assign to this shipping method. If not provided, the default tax class will be used. - """ - taxClass: ID - - """Shipping type: price or weight based.""" - type: ShippingMethodTypeEnum -} - -""" -Remove product from excluded list for shipping price. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingPriceRemoveProductFromExclude { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """A shipping method with new list of excluded products.""" - shippingMethod: ShippingMethodType -} - -""" -Creates/updates translations for a shipping method. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type ShippingPriceTranslate { - errors: [TranslationError!]! - shippingMethod: ShippingMethodType - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input ShippingPriceTranslationInput { - """ - Translated shipping method description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - name: String -} - -""" -Updates a new shipping price. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingPriceUpdate { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - shippingMethod: ShippingMethodType - - """A shipping zone to which the shipping method belongs.""" - shippingZone: ShippingZone -} - -""" -Event sent when shipping price is updated. - -Added in Saleor 3.2. -""" -type ShippingPriceUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The shipping method the event relates to.""" - shippingMethod( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingMethodType - - """The shipping zone the shipping method belongs to.""" - shippingZone( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingZone - - """Saleor version that triggered the event.""" - version: String -} - -""" -Represents a shipping zone in the shop. Zones are the concept used only for grouping shipping methods in the dashboard, and are never exposed to the customers directly. -""" -type ShippingZone implements Node & ObjectWithMetadata { - """List of channels for shipping zone.""" - channels: [Channel!]! - - """List of countries available for the method.""" - countries: [CountryDisplay!]! - - """Indicates if the shipping zone is default one.""" - default: Boolean! - - """Description of a shipping zone.""" - description: String - - """The ID of shipping zone.""" - id: ID! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Shipping zone name.""" - name: String! - - """Lowest and highest prices for the shipping.""" - priceRange: MoneyRange - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - List of shipping methods available for orders shipped to countries within this shipping zone. - """ - shippingMethods: [ShippingMethodType!] - - """List of warehouses for shipping zone.""" - warehouses: [Warehouse!]! -} - -""" -Deletes shipping zones. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingZoneBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type ShippingZoneCountableConnection { - edges: [ShippingZoneCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type ShippingZoneCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: ShippingZone! -} - -""" -Creates a new shipping zone. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingZoneCreate { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - shippingZone: ShippingZone -} - -input ShippingZoneCreateInput { - """List of channels to assign to the shipping zone.""" - addChannels: [ID!] - - """List of warehouses to assign to a shipping zone""" - addWarehouses: [ID!] - - """List of countries in this shipping zone.""" - countries: [String!] - - """ - Default shipping zone will be used for countries not covered by other zones. - """ - default: Boolean - - """Description of the shipping zone.""" - description: String - - """Shipping zone's name. Visible only to the staff.""" - name: String -} - -""" -Event sent when new shipping zone is created. - -Added in Saleor 3.2. -""" -type ShippingZoneCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The shipping zone the event relates to.""" - shippingZone( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingZone - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a shipping zone. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingZoneDelete { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - shippingZone: ShippingZone -} - -""" -Event sent when shipping zone is deleted. - -Added in Saleor 3.2. -""" -type ShippingZoneDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The shipping zone the event relates to.""" - shippingZone( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingZone - - """Saleor version that triggered the event.""" - version: String -} - -input ShippingZoneFilterInput { - channels: [ID!] - search: String -} - -""" -Event sent when shipping zone metadata is updated. - -Added in Saleor 3.8. -""" -type ShippingZoneMetadataUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The shipping zone the event relates to.""" - shippingZone( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingZone - - """Saleor version that triggered the event.""" - version: String -} - -""" -Updates a new shipping zone. - -Requires one of the following permissions: MANAGE_SHIPPING. -""" -type ShippingZoneUpdate { - errors: [ShippingError!]! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - shippingZone: ShippingZone -} - -input ShippingZoneUpdateInput { - """List of channels to assign to the shipping zone.""" - addChannels: [ID!] - - """List of warehouses to assign to a shipping zone""" - addWarehouses: [ID!] - - """List of countries in this shipping zone.""" - countries: [String!] - - """ - Default shipping zone will be used for countries not covered by other zones. - """ - default: Boolean - - """Description of the shipping zone.""" - description: String - - """Shipping zone's name. Visible only to the staff.""" - name: String - - """List of channels to unassign from the shipping zone.""" - removeChannels: [ID!] - - """List of warehouses to unassign from a shipping zone""" - removeWarehouses: [ID!] -} - -""" -Event sent when shipping zone is updated. - -Added in Saleor 3.2. -""" -type ShippingZoneUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The shipping zone the event relates to.""" - shippingZone( - """Slug of a channel for which the data should be returned.""" - channel: String - ): ShippingZone - - """Saleor version that triggered the event.""" - version: String -} - -""" -Represents a shop resource containing general shop data and configuration. -""" -type Shop implements ObjectWithMetadata { - """ - Determines if user can login without confirmation when `enableAccountConfirmation` is enabled. - - Added in Saleor 3.15. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - allowLoginWithoutConfirmation: Boolean - - """ - Enable automatic fulfillment for all digital products. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - automaticFulfillmentDigitalProducts: Boolean - - """List of available external authentications.""" - availableExternalAuthentications: [ExternalAuthentication!]! - - """List of available payment gateways.""" - availablePaymentGateways( - """Slug of a channel for which the data should be returned.""" - channel: String - - """ - A currency for which gateways will be returned. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `channel` argument instead. - """ - currency: String - ): [PaymentGateway!]! - - """Shipping methods that are available for the shop.""" - availableShippingMethods( - """Address for which available shipping methods should be returned.""" - address: AddressInput - - """Slug of a channel for which the data should be returned.""" - channel: String! - ): [ShippingMethod!] - - """ - List of tax apps that can be assigned to the channel. The list will be calculated by Saleor based on the apps that are subscribed to webhooks related to tax calculations: CHECKOUT_CALCULATE_TAXES - - Added in Saleor 3.19. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, MANAGE_APPS. - """ - availableTaxApps: [App!]! - - """ - List of all currencies supported by shop's channels. - - Added in Saleor 3.1. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - channelCurrencies: [String!]! - - """Charge taxes on shipping.""" - chargeTaxesOnShipping: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `ShippingMethodType.taxClass` to determine whether taxes are calculated for shipping methods; if a tax class is set, the taxes will be calculated, otherwise no tax rate will be applied.") - - """Company address.""" - companyAddress: Address - - """List of countries available in the shop.""" - countries( - """Filtering options for countries""" - filter: CountryFilterInput - - """ - A language code to return the translation for. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - languageCode: LanguageCodeEnum - ): [CountryDisplay!]! - - """URL of a view where customers can set their password.""" - customerSetPasswordUrl: String - - """Shop's default country.""" - defaultCountry: CountryDisplay - - """ - Default number of max downloads per digital content URL. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - defaultDigitalMaxDownloads: Int - - """ - Default number of days which digital content URL will be valid. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - defaultDigitalUrlValidDays: Int - - """ - Default shop's email sender's address. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - defaultMailSenderAddress: String - - """ - Default shop's email sender's name. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - defaultMailSenderName: String - - """Default weight unit.""" - defaultWeightUnit: WeightUnitsEnum - - """Shop's description.""" - description: String - - """Display prices with tax in store.""" - displayGrossPrices: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to determine whether to display gross or net prices.") - - """Shop's domain data.""" - domain: Domain! - - """ - Determines if account confirmation by email is enabled. - - Added in Saleor 3.14. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - enableAccountConfirmationByEmail: Boolean - - """ - Allow to approve fulfillments which are unpaid. - - Added in Saleor 3.1. - """ - fulfillmentAllowUnpaid: Boolean! - - """ - Automatically approve all new fulfillments. - - Added in Saleor 3.1. - """ - fulfillmentAutoApprove: Boolean! - - """Header text.""" - headerText: String - - """ID of the shop.""" - id: ID! - - """Include taxes in prices.""" - includeTaxesInPrices: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration.pricesEnteredWithTax` to determine whether prices are entered with tax.") - - """List of the shops's supported languages.""" - languages: [LanguageDisplay!]! - - """ - Default number of maximum line quantity in single checkout (per single checkout line). - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - limitQuantityPerCheckout: Int - - """ - Resource limitations and current usage if any set for a shop - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER. - """ - limits: LimitInfo! @deprecated(reason: "This field will be removed in Saleor 4.0.") - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - """ - metafields(keys: [String!]): Metadata - - """Shop's name.""" - name: String! - - """List of available permissions.""" - permissions: [Permission!]! - - """List of possible phone prefixes.""" - phonePrefixes: [String!]! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - """ - privateMetafields(keys: [String!]): Metadata - - """ - Default number of minutes stock will be reserved for anonymous checkout or null when stock reservation is disabled. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - reserveStockDurationAnonymousUser: Int - - """ - Default number of minutes stock will be reserved for authenticated checkout or null when stock reservation is disabled. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - reserveStockDurationAuthenticatedUser: Int - - """ - Minor Saleor API version. - - Added in Saleor 3.5. - """ - schemaVersion: String! - - """ - List of staff notification recipients. - - Requires one of the following permissions: MANAGE_SETTINGS. - """ - staffNotificationRecipients: [StaffNotificationRecipient!] - - """ - This field is used as a default value for `ProductVariant.trackInventory`. - """ - trackInventoryByDefault: Boolean - - """Returns translated shop fields for the given language code.""" - translation( - """A language code to return the translation for shop.""" - languageCode: LanguageCodeEnum! - ): ShopTranslation - - """ - Saleor API version. - - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. - """ - version: String! -} - -""" -Update the shop's address. If the `null` value is passed, the currently selected address will be deleted. - -Requires one of the following permissions: MANAGE_SETTINGS. -""" -type ShopAddressUpdate { - errors: [ShopError!]! - - """Updated shop.""" - shop: Shop - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Updates site domain of the shop. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead. - -Requires one of the following permissions: MANAGE_SETTINGS. -""" -type ShopDomainUpdate { - errors: [ShopError!]! - - """Updated shop.""" - shop: Shop - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -type ShopError { - """The error code.""" - code: ShopErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum ShopErrorCode { - ALREADY_EXISTS - CANNOT_FETCH_TAX_RATES - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE -} - -""" -Fetch tax rates. - -Requires one of the following permissions: MANAGE_SETTINGS. -""" -type ShopFetchTaxRates { - errors: [ShopError!]! - - """Updated shop.""" - shop: Shop - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when shop metadata is updated. - -Added in Saleor 3.15. -""" -type ShopMetadataUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Shop data.""" - shop: Shop - - """Saleor version that triggered the event.""" - version: String -} - -input ShopSettingsInput { - """ - Enable possibility to login without account confirmation. - - Added in Saleor 3.15. - """ - allowLoginWithoutConfirmation: Boolean - - """Enable automatic fulfillment for all digital products.""" - automaticFulfillmentDigitalProducts: Boolean - - """ - Charge taxes on shipping. - - DEPRECATED: this field will be removed in Saleor 4.0. To enable taxes for a shipping method, assign a tax class to the shipping method with `shippingPriceCreate` or `shippingPriceUpdate` mutations. - """ - chargeTaxesOnShipping: Boolean - - """URL of a view where customers can set their password.""" - customerSetPasswordUrl: String - - """Default number of max downloads per digital content URL.""" - defaultDigitalMaxDownloads: Int - - """Default number of days which digital content URL will be valid.""" - defaultDigitalUrlValidDays: Int - - """Default email sender's address.""" - defaultMailSenderAddress: String - - """Default email sender's name.""" - defaultMailSenderName: String - - """Default weight unit.""" - defaultWeightUnit: WeightUnitsEnum - - """SEO description.""" - description: String - - """ - Display prices with tax in store. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `taxConfigurationUpdate` mutation to configure this setting per channel or country. - """ - displayGrossPrices: Boolean - - """ - Enable automatic account confirmation by email. - - Added in Saleor 3.14. - """ - enableAccountConfirmationByEmail: Boolean - - """ - Enable ability to approve fulfillments which are unpaid. - - Added in Saleor 3.1. - """ - fulfillmentAllowUnpaid: Boolean - - """ - Enable automatic approval of all new fulfillments. - - Added in Saleor 3.1. - """ - fulfillmentAutoApprove: Boolean - - """Header text.""" - headerText: String - - """ - Include taxes in prices. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `taxConfigurationUpdate` mutation to configure this setting per channel or country. - """ - includeTaxesInPrices: Boolean - - """ - Default number of maximum line quantity in single checkout. Minimum possible value is 1, default value is 50. - - Added in Saleor 3.1. - """ - limitQuantityPerCheckout: Int - - """ - Shop public metadata. - - Added in Saleor 3.15. - """ - metadata: [MetadataInput!] - - """ - Shop private metadata. - - Added in Saleor 3.15. - """ - privateMetadata: [MetadataInput!] - - """ - Default number of minutes stock will be reserved for anonymous checkout. Enter 0 or null to disable. - - Added in Saleor 3.1. - """ - reserveStockDurationAnonymousUser: Int - - """ - Default number of minutes stock will be reserved for authenticated checkout. Enter 0 or null to disable. - - Added in Saleor 3.1. - """ - reserveStockDurationAuthenticatedUser: Int - - """ - This field is used as a default value for `ProductVariant.trackInventory`. - """ - trackInventoryByDefault: Boolean -} - -""" -Creates/updates translations for shop settings. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type ShopSettingsTranslate { - errors: [TranslationError!]! - - """Updated shop settings.""" - shop: Shop - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input ShopSettingsTranslationInput { - description: String - headerText: String -} - -""" -Updates shop settings. - -Requires one of the following permissions: MANAGE_SETTINGS. - -Triggers the following webhook events: -- SHOP_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. -""" -type ShopSettingsUpdate { - errors: [ShopError!]! - - """Updated shop.""" - shop: Shop - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -"""Represents shop translations.""" -type ShopTranslation implements Node { - """Translated description of sale.""" - description: String! - - """Translated header text of sale.""" - headerText: String! - - """The ID of the shop translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! -} - -input SiteDomainInput { - """Domain name for shop.""" - domain: String - - """Shop site name.""" - name: String -} - -""" -Deletes staff users. Apps are not allowed to perform this mutation. - -Requires one of the following permissions: MANAGE_STAFF. - -Triggers the following webhook events: -- STAFF_DELETED (async): A staff account was deleted. -""" -type StaffBulkDelete { - """Returns how many objects were affected.""" - count: Int! - errors: [StaffError!]! - staffErrors: [StaffError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Creates a new staff user. Apps are not allowed to perform this mutation. - -Requires one of the following permissions: MANAGE_STAFF. - -Triggers the following webhook events: -- STAFF_CREATED (async): A new staff account was created. -- NOTIFY_USER (async): A notification for setting the password. -- STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. -""" -type StaffCreate { - errors: [StaffError!]! - staffErrors: [StaffError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - user: User -} - -"""Fields required to create a staff user.""" -input StaffCreateInput { - """List of permission group IDs to which user should be assigned.""" - addGroups: [ID!] - - """The unique email address of the user.""" - email: String - - """Given name.""" - firstName: String - - """User account is active.""" - isActive: Boolean - - """Family name.""" - lastName: String - - """ - Fields required to update the user metadata. - - Added in Saleor 3.14. - """ - metadata: [MetadataInput!] - - """A note about the user.""" - note: String - - """ - Fields required to update the user private metadata. - - Added in Saleor 3.14. - """ - privateMetadata: [MetadataInput!] - - """ - URL of a view where users should be redirected to set the password. URL in RFC 1808 format. - """ - redirectUrl: String -} - -""" -Event sent when new staff user is created. - -Added in Saleor 3.5. -""" -type StaffCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Deletes a staff user. Apps are not allowed to perform this mutation. - -Requires one of the following permissions: MANAGE_STAFF. - -Triggers the following webhook events: -- STAFF_DELETED (async): A staff account was deleted. -""" -type StaffDelete { - errors: [StaffError!]! - staffErrors: [StaffError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - user: User -} - -""" -Event sent when staff user is deleted. - -Added in Saleor 3.5. -""" -type StaffDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -type StaffError { - """A type of address that causes the error.""" - addressType: AddressTypeEnum - - """The error code.""" - code: AccountErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """List of permission group IDs which cause the error.""" - groups: [ID!] - - """The error message.""" - message: String - - """List of permissions which causes the error.""" - permissions: [PermissionEnum!] - - """List of user IDs which causes the error.""" - users: [ID!] -} - -"""Represents status of a staff account.""" -enum StaffMemberStatus { - """User account has been activated.""" - ACTIVE - - """User account has not been activated yet.""" - DEACTIVATED -} - -""" -Represents a recipient of email notifications send by Saleor, such as notifications about new orders. Notifications can be assigned to staff users or arbitrary email addresses. -""" -type StaffNotificationRecipient implements Node { - """Determines if a notification active.""" - active: Boolean - - """Returns email address of a user subscribed to email notifications.""" - email: String - - """The ID of the staff notification recipient.""" - id: ID! - - """Returns a user subscribed to email notifications.""" - user: User -} - -""" -Creates a new staff notification recipient. - -Requires one of the following permissions: MANAGE_SETTINGS. -""" -type StaffNotificationRecipientCreate { - errors: [ShopError!]! - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - staffNotificationRecipient: StaffNotificationRecipient -} - -""" -Delete staff notification recipient. - -Requires one of the following permissions: MANAGE_SETTINGS. -""" -type StaffNotificationRecipientDelete { - errors: [ShopError!]! - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - staffNotificationRecipient: StaffNotificationRecipient -} - -input StaffNotificationRecipientInput { - """Determines if a notification active.""" - active: Boolean - - """Email address of a user subscribed to email notifications.""" - email: String - - """The ID of the user subscribed to email notifications..""" - user: ID -} - -""" -Updates a staff notification recipient. - -Requires one of the following permissions: MANAGE_SETTINGS. -""" -type StaffNotificationRecipientUpdate { - errors: [ShopError!]! - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - staffNotificationRecipient: StaffNotificationRecipient -} - -""" -Event sent when setting a new password for staff is requested. - -Added in Saleor 3.15. -""" -type StaffSetPasswordRequested implements Event { - """The channel data.""" - channel: Channel - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The URL to redirect the user after he accepts the request.""" - redirectUrl: String - - """Shop data.""" - shop: Shop - - """The token required to confirm request.""" - token: String - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -""" -Updates an existing staff user. Apps are not allowed to perform this mutation. - -Requires one of the following permissions: MANAGE_STAFF. - -Triggers the following webhook events: -- STAFF_UPDATED (async): A staff account was updated. -""" -type StaffUpdate { - errors: [StaffError!]! - staffErrors: [StaffError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - user: User -} - -"""Fields required to update a staff user.""" -input StaffUpdateInput { - """List of permission group IDs to which user should be assigned.""" - addGroups: [ID!] - - """The unique email address of the user.""" - email: String - - """Given name.""" - firstName: String - - """User account is active.""" - isActive: Boolean - - """Family name.""" - lastName: String - - """ - Fields required to update the user metadata. - - Added in Saleor 3.14. - """ - metadata: [MetadataInput!] - - """A note about the user.""" - note: String - - """ - Fields required to update the user private metadata. - - Added in Saleor 3.14. - """ - privateMetadata: [MetadataInput!] - - """List of permission group IDs from which user should be unassigned.""" - removeGroups: [ID!] -} - -""" -Event sent when staff user is updated. - -Added in Saleor 3.5. -""" -type StaffUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The user the event relates to.""" - user: User - - """Saleor version that triggered the event.""" - version: String -} - -input StaffUserInput { - ids: [ID!] - search: String - status: StaffMemberStatus -} - -"""Represents stock.""" -type Stock implements Node { - """The ID of stock.""" - id: ID! - - """Information about the product variant.""" - productVariant: ProductVariant! - - """ - Quantity of a product in the warehouse's possession, including the allocated stock that is waiting for shipment. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. - """ - quantity: Int! - - """ - Quantity allocated for orders. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. - """ - quantityAllocated: Int! - - """ - Quantity reserved for checkouts. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. - """ - quantityReserved: Int! - - """The warehouse associated with the stock.""" - warehouse: Warehouse! -} - -enum StockAvailability { - IN_STOCK - OUT_OF_STOCK -} - -type StockBulkResult { - """List of errors occurred on create or update attempt.""" - errors: [StockBulkUpdateError!] - - """Stock data.""" - stock: Stock -} - -""" -Updates stocks for a given variant and warehouse. Variant and warehouse selectors have to be the same for all stock inputs. Is not allowed to use 'variantId' in one input and 'variantExternalReference' in another. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: MANAGE_PRODUCTS. - -Triggers the following webhook events: -- PRODUCT_VARIANT_STOCK_UPDATED (async): A product variant stock details were updated. -""" -type StockBulkUpdate { - """Returns how many objects were updated.""" - count: Int! - errors: [StockBulkUpdateError!]! - - """List of the updated stocks.""" - results: [StockBulkResult!]! -} - -type StockBulkUpdateError { - """The error code.""" - code: StockBulkUpdateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum StockBulkUpdateErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED -} - -input StockBulkUpdateInput { - """Quantity of items available for sell.""" - quantity: Int! - - """Variant external reference.""" - variantExternalReference: String - - """Variant ID.""" - variantId: ID - - """Warehouse external reference.""" - warehouseExternalReference: String - - """Warehouse ID.""" - warehouseId: ID -} - -type StockCountableConnection { - edges: [StockCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type StockCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Stock! -} - -type StockError { - """The error code.""" - code: StockErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum StockErrorCode { - ALREADY_EXISTS - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE -} - -input StockFilterInput { - quantity: Float - search: String -} - -input StockInput { - """Quantity of items available for sell.""" - quantity: Int! - - """Warehouse in which stock is located.""" - warehouse: ID! -} - -""" -Represents the channel stock settings. - -Added in Saleor 3.7. -""" -type StockSettings { - """ - Allocation strategy defines the preference of warehouses for allocations and reservations. - """ - allocationStrategy: AllocationStrategyEnum! -} - -input StockSettingsInput { - """ - Allocation strategy options. Strategy defines the preference of warehouses for allocations and reservations. - """ - allocationStrategy: AllocationStrategyEnum! -} - -input StockUpdateInput { - """Quantity of items available for sell.""" - quantity: Int! - - """Stock.""" - stock: ID! -} - -""" -Determine how stocks should be updated, while processing an order. - - SKIP - stocks are not checked and not updated. - UPDATE - only do update, if there is enough stock. - FORCE - force update, if there is not enough stock. -""" -enum StockUpdatePolicyEnum { - FORCE - SKIP - UPDATE -} - -"""Enum representing the type of a payment storage in a gateway.""" -enum StorePaymentMethodEnum { - """Storage is disabled. The payment is not stored.""" - NONE - - """ - Off session storage type. The payment is stored to be reused even if the customer is absent. - """ - OFF_SESSION - - """ - On session storage type. The payment is stored only to be reused when the customer is present in the checkout flow. - """ - ON_SESSION -} - -""" -Represents a payment method stored for user (tokenized) in payment gateway. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type StoredPaymentMethod { - """Stored credit card details if available.""" - creditCardInfo: CreditCard - - """JSON data returned by Payment Provider app for this payment method.""" - data: JSON - - """Payment gateway that stores this payment method.""" - gateway: PaymentGateway! - - """Stored payment method ID.""" - id: ID! - - """ - Payment method name. Example: last 4 digits of credit card, obfuscated email, etc. - """ - name: String - - """ - ID of stored payment method used to make payment actions. Note: method ID is unique only within the payment gateway. - """ - paymentMethodId: String! - supportedPaymentFlows: [TokenizedPaymentFlowEnum!] - - """Type of the payment method. Example: credit card, wallet, etc.""" - type: String! -} - -""" -Event sent when user requests to delete a payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type StoredPaymentMethodDeleteRequested implements Event { - """Channel related to the requested delete action.""" - channel: Channel! - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """ - The ID of the payment method that should be deleted by the payment gateway. - """ - paymentMethodId: String! - - """The application receiving the webhook.""" - recipient: App - - """ - The user for which the app should proceed with payment method delete request. - """ - user: User! - - """Saleor version that triggered the event.""" - version: String -} - -""" -Request to delete a stored payment method on payment provider side. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: AUTHENTICATED_USER. - -Triggers the following webhook events: -- STORED_PAYMENT_METHOD_DELETE_REQUESTED (sync): The customer requested to delete a payment method. -""" -type StoredPaymentMethodRequestDelete { - errors: [PaymentMethodRequestDeleteError!]! - - """The result of deleting a stored payment method.""" - result: StoredPaymentMethodRequestDeleteResult! -} - -"""An enumeration.""" -enum StoredPaymentMethodRequestDeleteErrorCode { - CHANNEL_INACTIVE - GATEWAY_ERROR - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -""" -Result of deleting a stored payment method. - - This enum is used to determine the result of deleting a stored payment method. - SUCCESSFULLY_DELETED - The stored payment method was successfully deleted. - FAILED_TO_DELETE - The stored payment method was not deleted. - FAILED_TO_DELIVER - The request to delete the stored payment method was not - delivered. -""" -enum StoredPaymentMethodRequestDeleteResult { - FAILED_TO_DELETE - FAILED_TO_DELIVER - SUCCESSFULLY_DELETED -} - -""" -Define the filtering options for string fields. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -input StringFilterInput { - """The value equal to.""" - eq: String - - """The value included in.""" - oneOf: [String!] -} - -type Subscription { - """ - Event sent when new draft order is created. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - draftOrderCreated( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): DraftOrderCreated - - """ - Event sent when draft order is deleted. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - draftOrderDeleted( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): DraftOrderDeleted - - """ - Event sent when draft order is updated. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - draftOrderUpdated( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): DraftOrderUpdated - - """ - Look up subscription event. - - Added in Saleor 3.2. - """ - event: Event - - """ - Event sent when orders are imported. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderBulkCreated( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderBulkCreated - - """ - Event sent when order is cancelled. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderCancelled( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderCancelled - - """ - Event sent when order is confirmed. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderConfirmed( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderConfirmed - - """ - Event sent when new order is created. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderCreated( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderCreated - - """ - Event sent when order becomes expired. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderExpired( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderExpired - - """ - Event sent when order is fulfilled. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderFulfilled( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderFulfilled - - """ - Event sent when order is fully paid. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderFullyPaid( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderFullyPaid - - """ - The order is fully refunded. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderFullyRefunded( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderFullyRefunded - - """ - Event sent when order metadata is updated. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderMetadataUpdated( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderMetadataUpdated - - """ - Payment has been made. The order may be partially or fully paid. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderPaid( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderPaid - - """ - The order received a refund. The order may be partially or fully refunded. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderRefunded( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderRefunded - - """ - Event sent when order is updated. - - Added in Saleor 3.20. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - orderUpdated( - """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. - """ - channels: [String!] - ): OrderUpdated -} - -enum TaxCalculationStrategy { - FLAT_RATES - TAX_APP -} - -""" -Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. - -Added in Saleor 3.9. -""" -type TaxClass implements Node & ObjectWithMetadata { - """Country-specific tax rates for this tax class.""" - countries: [TaxClassCountryRate!]! - - """The ID of the object.""" - id: ID! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Name of the tax class.""" - name: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata -} - -type TaxClassCountableConnection { - edges: [TaxClassCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type TaxClassCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: TaxClass! -} - -""" -Tax rate for a country. When tax class is null, it represents the default tax rate for that country; otherwise it's a country tax rate specific to the given tax class. - -Added in Saleor 3.9. -""" -type TaxClassCountryRate { - """Country in which this tax rate applies.""" - country: CountryDisplay! - - """Tax rate value.""" - rate: Float! - - """Related tax class.""" - taxClass: TaxClass -} - -""" -Create a tax class. - -Added in Saleor 3.9. - -Requires one of the following permissions: MANAGE_TAXES. -""" -type TaxClassCreate { - errors: [TaxClassCreateError!]! - taxClass: TaxClass -} - -type TaxClassCreateError { - """The error code.""" - code: TaxClassCreateErrorCode! - - """List of country codes for which the configuration is invalid.""" - countryCodes: [String!]! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TaxClassCreateErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -input TaxClassCreateInput { - """List of country-specific tax rates to create for this tax class.""" - createCountryRates: [CountryRateInput!] - - """Name of the tax class.""" - name: String! -} - -""" -Delete a tax class. After deleting the tax class any products, product types or shipping methods using it are updated to use the default tax class. - -Added in Saleor 3.9. - -Requires one of the following permissions: MANAGE_TAXES. -""" -type TaxClassDelete { - errors: [TaxClassDeleteError!]! - taxClass: TaxClass -} - -type TaxClassDeleteError { - """The error code.""" - code: TaxClassDeleteErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TaxClassDeleteErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -input TaxClassFilterInput { - countries: [CountryCode!] - ids: [ID!] - metadata: [MetadataFilter!] -} - -input TaxClassRateInput { - """Tax rate value.""" - rate: Float - - """ID of a tax class for which to update the tax rate""" - taxClassId: ID -} - -enum TaxClassSortField { - """Sort tax classes by name.""" - NAME -} - -input TaxClassSortingInput { - """Specifies the direction in which to sort tax classes.""" - direction: OrderDirection! - - """Sort tax classes by the selected field.""" - field: TaxClassSortField! -} - -""" -Update a tax class. - -Added in Saleor 3.9. - -Requires one of the following permissions: MANAGE_TAXES. -""" -type TaxClassUpdate { - errors: [TaxClassUpdateError!]! - taxClass: TaxClass -} - -type TaxClassUpdateError { - """The error code.""" - code: TaxClassUpdateErrorCode! - - """List of country codes for which the configuration is invalid.""" - countryCodes: [String!]! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TaxClassUpdateErrorCode { - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -input TaxClassUpdateInput { - """Name of the tax class.""" - name: String - - """ - List of country codes for which to remove the tax class rates. Note: It removes all rates for given country code. - """ - removeCountryRates: [CountryCode!] - - """ - List of country-specific tax rates to create or update for this tax class. - """ - updateCountryRates: [CountryRateUpdateInput!] -} - -""" -Channel-specific tax configuration. - -Added in Saleor 3.9. -""" -type TaxConfiguration implements Node & ObjectWithMetadata { - """A channel to which the tax configuration applies to.""" - channel: Channel! - - """Determines whether taxes are charged in the given channel.""" - chargeTaxes: Boolean! - - """List of country-specific exceptions in tax configuration.""" - countries: [TaxConfigurationPerCountry!]! - - """Determines whether displayed prices should include taxes.""" - displayGrossPrices: Boolean! - - """The ID of the object.""" - id: ID! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Determines whether prices are entered with the tax included.""" - pricesEnteredWithTax: Boolean! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - The tax app `App.identifier` that will be used to calculate the taxes for the given channel. Empty value for `TAX_APP` set as `taxCalculationStrategy` means that Saleor will iterate over all installed tax apps. If multiple tax apps exist with provided tax app id use the `App` with newest `created` date. Will become mandatory in 4.0 for `TAX_APP` `taxCalculationStrategy`. - - Added in Saleor 3.19. - """ - taxAppId: String - - """ - The default strategy to use for tax calculation in the given channel. Taxes can be calculated either using user-defined flat rates or with a tax app. Empty value means that no method is selected and taxes are not calculated. - """ - taxCalculationStrategy: TaxCalculationStrategy -} - -type TaxConfigurationCountableConnection { - edges: [TaxConfigurationCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type TaxConfigurationCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: TaxConfiguration! -} - -input TaxConfigurationFilterInput { - ids: [ID!] - metadata: [MetadataFilter!] -} - -""" -Country-specific exceptions of a channel's tax configuration. - -Added in Saleor 3.9. -""" -type TaxConfigurationPerCountry { - """Determines whether taxes are charged in this country.""" - chargeTaxes: Boolean! - - """Country in which this configuration applies.""" - country: CountryDisplay! - - """ - Determines whether displayed prices should include taxes for this country. - """ - displayGrossPrices: Boolean! - - """ - The tax app `App.identifier` that will be used to calculate the taxes for the given channel and country. If not provided, use the value from the channel's tax configuration. - - Added in Saleor 3.19. - """ - taxAppId: String - - """ - A country-specific strategy to use for tax calculation. Taxes can be calculated either using user-defined flat rates or with a tax app. If not provided, use the value from the channel's tax configuration. - """ - taxCalculationStrategy: TaxCalculationStrategy -} - -input TaxConfigurationPerCountryInput { - """Determines whether taxes are charged in this country.""" - chargeTaxes: Boolean! - - """Country in which this configuration applies.""" - countryCode: CountryCode! - - """ - Determines whether displayed prices should include taxes for this country. - """ - displayGrossPrices: Boolean! - - """ - The tax app `App.identifier` that will be used to calculate the taxes for the given channel and country. If not provided, use the value from the channel's tax configuration. - - Added in Saleor 3.19. - """ - taxAppId: String - - """ - A country-specific strategy to use for tax calculation. Taxes can be calculated either using user-defined flat rates or with a tax app. If not provided, use the value from the channel's tax configuration. - """ - taxCalculationStrategy: TaxCalculationStrategy -} - -""" -Update tax configuration for a channel. - -Added in Saleor 3.9. - -Requires one of the following permissions: MANAGE_TAXES. -""" -type TaxConfigurationUpdate { - errors: [TaxConfigurationUpdateError!]! - taxConfiguration: TaxConfiguration -} - -type TaxConfigurationUpdateError { - """The error code.""" - code: TaxConfigurationUpdateErrorCode! - - """List of country codes for which the configuration is invalid.""" - countryCodes: [String!]! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TaxConfigurationUpdateErrorCode { - DUPLICATED_INPUT_ITEM - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -input TaxConfigurationUpdateInput { - """Determines whether taxes are charged in the given channel.""" - chargeTaxes: Boolean - - """Determines whether displayed prices should include taxes.""" - displayGrossPrices: Boolean - - """Determines whether prices are entered with the tax included.""" - pricesEnteredWithTax: Boolean - - """List of country codes for which to remove the tax configuration.""" - removeCountriesConfiguration: [CountryCode!] - - """ - The tax app `App.identifier` that will be used to calculate the taxes for the given channel. Empty value for `TAX_APP` set as `taxCalculationStrategy` means that Saleor will iterate over all installed tax apps. If multiple tax apps exist with provided tax app id use the `App` with newest `created` date. It's possible to set plugin by using prefix `plugin:` with `PLUGIN_ID` e.g. with Avalara `plugin:mirumee.taxes.avalara`.Will become mandatory in 4.0 for `TAX_APP` `taxCalculationStrategy`. - - Added in Saleor 3.19. - """ - taxAppId: String - - """ - The default strategy to use for tax calculation in the given channel. Taxes can be calculated either using user-defined flat rates or with a tax app. Empty value means that no method is selected and taxes are not calculated. - """ - taxCalculationStrategy: TaxCalculationStrategy - - """ - List of tax country configurations to create or update (identified by a country code). - """ - updateCountriesConfiguration: [TaxConfigurationPerCountryInput!] -} - -""" -Tax class rates grouped by country. - -Added in Saleor 3.9. -""" -type TaxCountryConfiguration { - """A country for which tax class rates are grouped.""" - country: CountryDisplay! - - """List of tax class rates.""" - taxClassCountryRates: [TaxClassCountryRate!]! -} - -""" -Remove all tax class rates for a specific country. - -Added in Saleor 3.9. - -Requires one of the following permissions: MANAGE_TAXES. -""" -type TaxCountryConfigurationDelete { - errors: [TaxCountryConfigurationDeleteError!]! - - """Updated tax class rates grouped by a country.""" - taxCountryConfiguration: TaxCountryConfiguration -} - -type TaxCountryConfigurationDeleteError { - """The error code.""" - code: TaxCountryConfigurationDeleteErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TaxCountryConfigurationDeleteErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -""" -Update tax class rates for a specific country. - -Added in Saleor 3.9. - -Requires one of the following permissions: MANAGE_TAXES. -""" -type TaxCountryConfigurationUpdate { - errors: [TaxCountryConfigurationUpdateError!]! - - """Updated tax class rates grouped by a country.""" - taxCountryConfiguration: TaxCountryConfiguration -} - -type TaxCountryConfigurationUpdateError { - """The error code.""" - code: TaxCountryConfigurationUpdateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of tax class IDs for which the update failed.""" - taxClassIds: [String!]! -} - -"""An enumeration.""" -enum TaxCountryConfigurationUpdateErrorCode { - CANNOT_CREATE_NEGATIVE_RATE - GRAPHQL_ERROR - INVALID - NOT_FOUND - ONLY_ONE_DEFAULT_COUNTRY_RATE_ALLOWED -} - -""" -Exempt checkout or order from charging the taxes. When tax exemption is enabled, taxes won't be charged for the checkout or order. Taxes may still be calculated in cases when product prices are entered with the tax included and the net price needs to be known. - -Added in Saleor 3.8. - -Requires one of the following permissions: MANAGE_TAXES. -""" -type TaxExemptionManage { - errors: [TaxExemptionManageError!]! - taxableObject: TaxSourceObject -} - -type TaxExemptionManageError { - """The error code.""" - code: TaxExemptionManageErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TaxExemptionManageErrorCode { - GRAPHQL_ERROR - INVALID - NOT_EDITABLE_ORDER - NOT_FOUND -} - -union TaxSourceLine = CheckoutLine | OrderLine - -union TaxSourceObject = Checkout | Order - -"""Representation of tax types fetched from tax gateway.""" -type TaxType { - """Description of the tax type.""" - description: String - - """External tax code used to identify given tax group.""" - taxCode: String -} - -"""Taxable object.""" -type TaxableObject { - """The address data.""" - address: Address - channel: Channel! - - """The currency of the object.""" - currency: String! - - """List of discounts.""" - discounts: [TaxableObjectDiscount!]! - - """List of lines assigned to the object.""" - lines: [TaxableObjectLine!]! - - """Determines if prices contain entered tax..""" - pricesEnteredWithTax: Boolean! - - """ - The price of shipping method, includes shipping voucher discount if applied. - """ - shippingPrice: Money! - - """The source object related to this tax object.""" - sourceObject: TaxSourceObject! -} - -"""Taxable object discount.""" -type TaxableObjectDiscount { - """The amount of the discount.""" - amount: Money! - - """The name of the discount.""" - name: String - - """ - Indicates which part of the order the discount should affect: SUBTOTAL or SHIPPING. - """ - type: TaxableObjectDiscountTypeEnum! -} - -""" -Indicates which part of the order the discount should affect: SUBTOTAL or SHIPPING. -""" -enum TaxableObjectDiscountTypeEnum { - SHIPPING - SUBTOTAL -} - -type TaxableObjectLine { - """Determines if taxes are being charged for the product.""" - chargeTaxes: Boolean! - - """The product name.""" - productName: String! - - """The product sku.""" - productSku: String - - """Number of items.""" - quantity: Int! - - """The source line related to this tax line.""" - sourceLine: TaxSourceLine! - - """ - Price of the order line. The price includes catalogue promotions, specific product and applied once per order voucher discounts. The price does not include the entire order discount. - """ - totalPrice: Money! - - """ - Price of the single item in the order line. The price includes catalogue promotions, specific product and applied once per order voucher discounts. The price does not include the entire order discount. - """ - unitPrice: Money! - - """The variant name.""" - variantName: String! -} - -""" -Represents a monetary value with taxes. In cases where taxes were not applied, net and gross values will be equal. -""" -type TaxedMoney { - """Currency code.""" - currency: String! - - """Amount of money including taxes.""" - gross: Money! - - """Amount of money without taxes.""" - net: Money! - - """Amount of taxes.""" - tax: Money! -} - -input TaxedMoneyInput { - """Gross value of an item.""" - gross: PositiveDecimal! - - """Net value of an item.""" - net: PositiveDecimal! -} - -"""Represents a range of monetary values.""" -type TaxedMoneyRange { - """Lower bound of a price range.""" - start: TaxedMoney - - """Upper bound of a price range.""" - stop: TaxedMoney -} - -""" -Event sent when thumbnail is created. - -Added in Saleor 3.12. -""" -type ThumbnailCreated implements Event { - """ - Thumbnail id. - - Added in Saleor 3.12. - """ - id: ID - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """ - Original media url. - - Added in Saleor 3.12. - """ - mediaUrl: String - - """ - Object the thumbnail refers to. - - Added in Saleor 3.12. - """ - objectId: ID - - """The application receiving the webhook.""" - recipient: App - - """ - Thumbnail url. - - Added in Saleor 3.12. - """ - url: String - - """Saleor version that triggered the event.""" - version: String -} - -"""An enumeration.""" -enum ThumbnailFormatEnum { - AVIF - ORIGINAL - WEBP -} - -type TimePeriod { - """The length of the period.""" - amount: Int! - - """The type of the period.""" - type: TimePeriodTypeEnum! -} - -input TimePeriodInputType { - """The length of the period.""" - amount: Int! - - """The type of the period.""" - type: TimePeriodTypeEnum! -} - -"""An enumeration.""" -enum TimePeriodTypeEnum { - DAY - MONTH - WEEK - YEAR -} - -""" -Represents possible tokenized payment flows that can be used to process payment. - - The following flows are possible: - INTERACTIVE - Payment method can be used for 1 click checkout - it's prefilled in - checkout form (might require additional authentication from user) -""" -enum TokenizedPaymentFlowEnum { - INTERACTIVE -} - -"""An object representing a single payment.""" -type Transaction implements Node { - """Total amount of the transaction.""" - amount: Money - - """Date and time at which transaction was created.""" - created: DateTime! - - """Error associated with transaction, if any.""" - error: String - - """Response returned by payment gateway.""" - gatewayResponse: JSONString! - - """ID of the transaction.""" - id: ID! - - """Determines if the transaction was successful.""" - isSuccess: Boolean! - - """Determines the type of transaction.""" - kind: TransactionKind! - - """Determines the payment associated with a transaction.""" - payment: Payment! - - """Unique token associated with a transaction.""" - token: String! -} - -type TransactionAction { - """Determines the action type.""" - actionType: TransactionActionEnum! - - """Transaction request amount. Null when action type is VOID.""" - amount: PositiveDecimal - - """ - Currency code. - - Added in Saleor 3.16. - """ - currency: String! -} - -""" -Represents possible actions on payment transaction. - - The following actions are possible: - CHARGE - Represents the charge action. - REFUND - Represents a refund action. - CANCEL - Represents a cancel action. Added in Saleor 3.12. -""" -enum TransactionActionEnum { - CANCEL - CHARGE - REFUND -} - -""" -Event sent when transaction cancelation is requested. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type TransactionCancelationRequested implements Event { - """Requested action data.""" - action: TransactionAction! - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Look up a transaction.""" - transaction: TransactionItem - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when transaction charge is requested. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type TransactionChargeRequested implements Event { - """Requested action data.""" - action: TransactionAction! - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Look up a transaction.""" - transaction: TransactionItem - - """Saleor version that triggered the event.""" - version: String -} - -""" -Create transaction for checkout or order. - -Added in Saleor 3.4. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: HANDLE_PAYMENTS. -""" -type TransactionCreate { - errors: [TransactionCreateError!]! - transaction: TransactionItem -} - -type TransactionCreateError { - """The error code.""" - code: TransactionCreateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TransactionCreateErrorCode { - GRAPHQL_ERROR - INCORRECT_CURRENCY - INVALID - METADATA_KEY_REQUIRED - NOT_FOUND - UNIQUE -} - -input TransactionCreateInput { - """Amount authorized by this transaction.""" - amountAuthorized: MoneyInput - - """ - Amount canceled by this transaction. - - Added in Saleor 3.13. - """ - amountCanceled: MoneyInput - - """Amount charged by this transaction.""" - amountCharged: MoneyInput - - """Amount refunded by this transaction.""" - amountRefunded: MoneyInput - - """List of all possible actions for the transaction""" - availableActions: [TransactionActionEnum!] - - """ - The url that will allow to redirect user to payment provider page with transaction event details. - - Added in Saleor 3.13. - """ - externalUrl: String - - """ - The message of the transaction. - - Added in Saleor 3.13. - """ - message: String - - """Payment public metadata.""" - metadata: [MetadataInput!] - - """ - Payment name of the transaction. - - Added in Saleor 3.13. - """ - name: String - - """Payment private metadata.""" - privateMetadata: [MetadataInput!] - - """ - PSP Reference of the transaction. - - Added in Saleor 3.13. - """ - pspReference: String -} - -"""Represents transaction's event.""" -type TransactionEvent implements Node { - """ - The amount related to this event. - - Added in Saleor 3.13. - """ - amount: Money! - - """Date and time at which a transaction event was created.""" - createdAt: DateTime! - - """ - User or App that created the transaction event. - - Added in Saleor 3.13. - """ - createdBy: UserOrApp - - """ - The url that will allow to redirect user to payment provider page with transaction details. - - Added in Saleor 3.13. - """ - externalUrl: String! - - """The ID of the object.""" - id: ID! - - """ - Idempotency key assigned to the event. - - Added in Saleor 3.14. - """ - idempotencyKey: String - - """ - Message related to the transaction's event. - - Added in Saleor 3.13. - """ - message: String! - - """ - PSP reference of transaction. - - Added in Saleor 3.13. - """ - pspReference: String! - - """ - The type of action related to this event. - - Added in Saleor 3.13. - """ - type: TransactionEventTypeEnum -} - -input TransactionEventInput { - """ - The message related to the event. - - Added in Saleor 3.13. - """ - message: String - - """ - PSP Reference related to this action. - - Added in Saleor 3.13. - """ - pspReference: String -} - -""" -Report the event for the transaction. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. -""" -type TransactionEventReport { - """Defines if the reported event hasn't been processed earlier.""" - alreadyProcessed: Boolean - errors: [TransactionEventReportError!]! - - """The transaction related to the reported event.""" - transaction: TransactionItem - - """ - The event assigned to this report. if `alreadyProcessed` is set to `true`, the previously processed event will be returned. - """ - transactionEvent: TransactionEvent -} - -type TransactionEventReportError { - """The error code.""" - code: TransactionEventReportErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TransactionEventReportErrorCode { - ALREADY_EXISTS - GRAPHQL_ERROR - INCORRECT_DETAILS - INVALID - NOT_FOUND - REQUIRED -} - -""" -Represents possible event types. - - Added in Saleor 3.12. - - The following types are possible: - AUTHORIZATION_SUCCESS - represents success authorization. - AUTHORIZATION_FAILURE - represents failure authorization. - AUTHORIZATION_ADJUSTMENT - represents authorization adjustment. - AUTHORIZATION_REQUEST - represents authorization request. - AUTHORIZATION_ACTION_REQUIRED - represents authorization that needs - additional actions from the customer. - CHARGE_ACTION_REQUIRED - represents charge that needs - additional actions from the customer. - CHARGE_SUCCESS - represents success charge. - CHARGE_FAILURE - represents failure charge. - CHARGE_BACK - represents chargeback. - CHARGE_REQUEST - represents charge request. - REFUND_SUCCESS - represents success refund. - REFUND_FAILURE - represents failure refund. - REFUND_REVERSE - represents reverse refund. - REFUND_REQUEST - represents refund request. - CANCEL_SUCCESS - represents success cancel. - CANCEL_FAILURE - represents failure cancel. - CANCEL_REQUEST - represents cancel request. - INFO - represents info event. -""" -enum TransactionEventTypeEnum { - AUTHORIZATION_ACTION_REQUIRED - AUTHORIZATION_ADJUSTMENT - AUTHORIZATION_FAILURE - AUTHORIZATION_REQUEST - AUTHORIZATION_SUCCESS - CANCEL_FAILURE - CANCEL_REQUEST - CANCEL_SUCCESS - CHARGE_ACTION_REQUIRED - CHARGE_BACK - CHARGE_FAILURE - CHARGE_REQUEST - CHARGE_SUCCESS - INFO - REFUND_FAILURE - REFUND_REQUEST - REFUND_REVERSE - REFUND_SUCCESS -} - -""" -Determine the transaction flow strategy. - - AUTHORIZATION - the processed transaction should be only authorized - CHARGE - the processed transaction should be charged. -""" -enum TransactionFlowStrategyEnum { - AUTHORIZATION - CHARGE -} - -""" -Initializes a transaction session. It triggers the webhook `TRANSACTION_INITIALIZE_SESSION`, to the requested `paymentGateways`. There is a limit of 100 transaction items per checkout / order. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type TransactionInitialize { - """The JSON data required to finalize the payment.""" - data: JSON - errors: [TransactionInitializeError!]! - - """The initialized transaction.""" - transaction: TransactionItem - - """The event created for the initialized transaction.""" - transactionEvent: TransactionEvent -} - -type TransactionInitializeError { - """The error code.""" - code: TransactionInitializeErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TransactionInitializeErrorCode { - CHECKOUT_COMPLETION_IN_PROGRESS - GRAPHQL_ERROR - INVALID - NOT_FOUND - UNIQUE -} - -""" -Event sent when user starts processing the payment. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type TransactionInitializeSession implements Event { - """Action to proceed for the transaction""" - action: TransactionProcessAction! - - """ - The customer's IP address. If not provided as a parameter in the mutation, Saleor will try to determine the customer's IP address on its own. - - Added in Saleor 3.16. - """ - customerIpAddress: String - - """Payment gateway data in JSON format, received from storefront.""" - data: JSON - - """ - Idempotency key assigned to the transaction initialize. - - Added in Saleor 3.14. - """ - idempotencyKey: String! - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """Merchant reference assigned to this payment.""" - merchantReference: String! - - """The application receiving the webhook.""" - recipient: App - - """Checkout or order""" - sourceObject: OrderOrCheckout! - - """Look up a transaction.""" - transaction: TransactionItem! - - """Saleor version that triggered the event.""" - version: String -} - -""" -Represents a payment transaction. - -Added in Saleor 3.4. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type TransactionItem implements Node & ObjectWithMetadata { - """ - List of actions that can be performed in the current state of a payment. - """ - actions: [TransactionActionEnum!]! - - """ - Total amount of ongoing authorization requests for the transaction. - - Added in Saleor 3.13. - """ - authorizePendingAmount: Money! - - """Total amount authorized for this payment.""" - authorizedAmount: Money! - - """ - Total amount of ongoing cancel requests for the transaction. - - Added in Saleor 3.13. - """ - cancelPendingAmount: Money! - - """ - Total amount canceled for this payment. - - Added in Saleor 3.13. - """ - canceledAmount: Money! - - """ - Total amount of ongoing charge requests for the transaction. - - Added in Saleor 3.13. - """ - chargePendingAmount: Money! - - """Total amount charged for this payment.""" - chargedAmount: Money! - - """ - The related checkout. - - Added in Saleor 3.14. - """ - checkout: Checkout - - """Date and time at which payment transaction was created.""" - createdAt: DateTime! - - """ - User or App that created the transaction. - - Added in Saleor 3.13. - """ - createdBy: UserOrApp - - """List of all transaction's events.""" - events: [TransactionEvent!]! - - """ - The url that will allow to redirect user to payment provider page with transaction details. - - Added in Saleor 3.13. - """ - externalUrl: String! - - """The ID of the object.""" - id: ID! - - """ - Message related to the transaction. - - Added in Saleor 3.13. - """ - message: String! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Date and time at which payment transaction was modified.""" - modifiedAt: DateTime! - - """ - Name of the transaction. - - Added in Saleor 3.13. - """ - name: String! - - """ - The related order. - - Added in Saleor 3.6. - """ - order: Order - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - PSP reference of transaction. - - Added in Saleor 3.13. - """ - pspReference: String! - - """ - Total amount of ongoing refund requests for the transaction. - - Added in Saleor 3.13. - """ - refundPendingAmount: Money! - - """Total amount refunded for this payment.""" - refundedAmount: Money! - - """ - The transaction token. - - Added in Saleor 3.14. - """ - token: UUID! -} - -""" -Event sent when transaction item metadata is updated. - -Added in Saleor 3.8. -""" -type TransactionItemMetadataUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Look up a transaction.""" - transaction: TransactionItem - - """Saleor version that triggered the event.""" - version: String -} - -"""An enumeration.""" -enum TransactionKind { - ACTION_TO_CONFIRM - AUTH - CANCEL - CAPTURE - CONFIRM - EXTERNAL - PENDING - REFUND - REFUND_ONGOING - VOID -} - -""" -Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type TransactionProcess { - """The json data required to finalize the payment.""" - data: JSON - errors: [TransactionProcessError!]! - - """The processed transaction.""" - transaction: TransactionItem - - """The event created for the processed transaction.""" - transactionEvent: TransactionEvent -} - -type TransactionProcessAction { - actionType: TransactionFlowStrategyEnum! - - """Transaction amount to process.""" - amount: PositiveDecimal! - - """Currency of the amount.""" - currency: String! -} - -type TransactionProcessError { - """The error code.""" - code: TransactionProcessErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TransactionProcessErrorCode { - CHECKOUT_COMPLETION_IN_PROGRESS - GRAPHQL_ERROR - INVALID - MISSING_PAYMENT_APP - MISSING_PAYMENT_APP_RELATION - NOT_FOUND - TRANSACTION_ALREADY_PROCESSED -} - -""" -Event sent when user has additional payment action to process. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type TransactionProcessSession implements Event { - """Action to proceed for the transaction""" - action: TransactionProcessAction! - - """ - The customer's IP address. If not provided as a parameter in the mutation, Saleor will try to determine the customer's IP address on its own. - - Added in Saleor 3.16. - """ - customerIpAddress: String - - """Payment gateway data in JSON format, received from storefront.""" - data: JSON - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """Merchant reference assigned to this payment.""" - merchantReference: String! - - """The application receiving the webhook.""" - recipient: App - - """Checkout or order""" - sourceObject: OrderOrCheckout! - - """Look up a transaction.""" - transaction: TransactionItem! - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when transaction refund is requested. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type TransactionRefundRequested implements Event { - """Requested action data.""" - action: TransactionAction! - - """ - Granted refund related to refund request. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - grantedRefund: OrderGrantedRefund - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Look up a transaction.""" - transaction: TransactionItem - - """Saleor version that triggered the event.""" - version: String -} - -""" -Request an action for payment transaction. - -Added in Saleor 3.4. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: HANDLE_PAYMENTS. -""" -type TransactionRequestAction { - errors: [TransactionRequestActionError!]! - transaction: TransactionItem -} - -type TransactionRequestActionError { - """The error code.""" - code: TransactionRequestActionErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TransactionRequestActionErrorCode { - GRAPHQL_ERROR - INVALID - MISSING_TRANSACTION_ACTION_REQUEST_WEBHOOK - NOT_FOUND -} - -""" -Request a refund for payment transaction based on granted refund. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: HANDLE_PAYMENTS. -""" -type TransactionRequestRefundForGrantedRefund { - errors: [TransactionRequestRefundForGrantedRefundError!]! - transaction: TransactionItem -} - -type TransactionRequestRefundForGrantedRefundError { - """The error code.""" - code: TransactionRequestRefundForGrantedRefundErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TransactionRequestRefundForGrantedRefundErrorCode { - AMOUNT_GREATER_THAN_AVAILABLE - GRAPHQL_ERROR - INVALID - MISSING_TRANSACTION_ACTION_REQUEST_WEBHOOK - NOT_FOUND - REFUND_ALREADY_PROCESSED - REFUND_IS_PENDING -} - -""" -Update transaction. - -Added in Saleor 3.4. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. -""" -type TransactionUpdate { - errors: [TransactionUpdateError!]! - transaction: TransactionItem -} - -type TransactionUpdateError { - """The error code.""" - code: TransactionUpdateErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TransactionUpdateErrorCode { - GRAPHQL_ERROR - INCORRECT_CURRENCY - INVALID - METADATA_KEY_REQUIRED - NOT_FOUND - UNIQUE -} - -input TransactionUpdateInput { - """Amount authorized by this transaction.""" - amountAuthorized: MoneyInput - - """ - Amount canceled by this transaction. - - Added in Saleor 3.13. - """ - amountCanceled: MoneyInput - - """Amount charged by this transaction.""" - amountCharged: MoneyInput - - """Amount refunded by this transaction.""" - amountRefunded: MoneyInput - - """List of all possible actions for the transaction""" - availableActions: [TransactionActionEnum!] - - """ - The url that will allow to redirect user to payment provider page with transaction event details. - - Added in Saleor 3.13. - """ - externalUrl: String - - """ - The message of the transaction. - - Added in Saleor 3.13. - """ - message: String - - """Payment public metadata.""" - metadata: [MetadataInput!] - - """ - Payment name of the transaction. - - Added in Saleor 3.13. - """ - name: String - - """Payment private metadata.""" - privateMetadata: [MetadataInput!] - - """ - PSP Reference of the transaction. - - Added in Saleor 3.13. - """ - pspReference: String -} - -union TranslatableItem = AttributeTranslatableContent | AttributeValueTranslatableContent | CategoryTranslatableContent | CollectionTranslatableContent | MenuItemTranslatableContent | PageTranslatableContent | ProductTranslatableContent | ProductVariantTranslatableContent | PromotionRuleTranslatableContent | PromotionTranslatableContent | SaleTranslatableContent | ShippingMethodTranslatableContent | VoucherTranslatableContent - -type TranslatableItemConnection { - edges: [TranslatableItemEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type TranslatableItemEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: TranslatableItem! -} - -enum TranslatableKinds { - ATTRIBUTE - ATTRIBUTE_VALUE - CATEGORY - COLLECTION - MENU_ITEM - PAGE - PRODUCT - PROMOTION - PROMOTION_RULE - SALE - SHIPPING_METHOD - VARIANT - VOUCHER -} - -""" -Event sent when new translation is created. - -Added in Saleor 3.2. -""" -type TranslationCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The translation the event relates to.""" - translation: TranslationTypes - - """Saleor version that triggered the event.""" - version: String -} - -type TranslationError { - """The error code.""" - code: TranslationErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum TranslationErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED -} - -input TranslationInput { - """ - Translated description. - - Rich text format. For reference see https://editorjs.io/ - """ - description: JSONString - name: String - seoDescription: String - seoTitle: String -} - -union TranslationTypes = AttributeTranslation | AttributeValueTranslation | CategoryTranslation | CollectionTranslation | MenuItemTranslation | PageTranslation | ProductTranslation | ProductVariantTranslation | PromotionRuleTranslation | PromotionTranslation | SaleTranslation | ShippingMethodTranslation | VoucherTranslation - -""" -Event sent when translation is updated. - -Added in Saleor 3.2. -""" -type TranslationUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The translation the event relates to.""" - translation: TranslationTypes - - """Saleor version that triggered the event.""" - version: String -} - -scalar UUID - -input UpdateInvoiceInput { - """ - Fields required to update the invoice metadata. - - Added in Saleor 3.14. - """ - metadata: [MetadataInput!] - - """Invoice number""" - number: String - - """ - Fields required to update the invoice private metadata. - - Added in Saleor 3.14. - """ - privateMetadata: [MetadataInput!] - - """URL of an invoice to download.""" - url: String -} - -""" -Updates metadata of an object. To use it, you need to have access to the modified object. -""" -type UpdateMetadata { - errors: [MetadataError!]! - item: ObjectWithMetadata - metadataErrors: [MetadataError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Updates private metadata of an object. To use it, you need to be an authenticated staff user or an app and have access to the modified object. -""" -type UpdatePrivateMetadata { - errors: [MetadataError!]! - item: ObjectWithMetadata - metadataErrors: [MetadataError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Variables of this type must be set to null in mutations. They will be replaced with a filename from a following multipart part containing a binary file. See: https://github.com/jaydenseric/graphql-multipart-request-spec. -""" -scalar Upload - -type UploadError { - """The error code.""" - code: UploadErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum UploadErrorCode { - GRAPHQL_ERROR -} - -"""Represents user data.""" -type User implements Node & ObjectWithMetadata { - """ - List of channels the user has access to. The sum of channels from all user groups. If at least one group has `restrictedAccessToChannels` set to False - all channels are returned. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - accessibleChannels: [Channel!] - - """List of all user's addresses.""" - addresses: [Address!]! - - """The avatar of the user.""" - avatar( - """ - The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. - """ - format: ThumbnailFormatEnum = ORIGINAL - - """ - Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). - """ - size: Int - ): Image - - """Returns the last open checkout of this user.""" - checkout: Checkout @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `checkoutTokens` field to fetch the user checkouts.") - - """Returns the checkout ID's assigned to this user.""" - checkoutIds( - """Slug of a channel for which the data should be returned.""" - channel: String - ): [ID!] - - """Returns the checkout UUID's assigned to this user.""" - checkoutTokens( - """Slug of a channel for which the data should be returned.""" - channel: String - ): [UUID!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use `checkoutIds` instead.") - - """ - Returns checkouts assigned to this user. - - Added in Saleor 3.8. - """ - checkouts( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Slug of a channel for which the data should be returned.""" - channel: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): CheckoutCountableConnection - - """The data when the user create account.""" - dateJoined: DateTime! - - """The default billing address of the user.""" - defaultBillingAddress: Address - - """The default shipping address of the user.""" - defaultShippingAddress: Address - - """List of user's permission groups which user can manage.""" - editableGroups: [Group!] - - """The email address of the user.""" - email: String! - - """ - List of events associated with the user. - - Requires one of the following permissions: MANAGE_USERS, MANAGE_STAFF. - """ - events: [CustomerEvent!] - - """ - External ID of this user. - - Added in Saleor 3.10. - """ - externalReference: String - - """The given name of the address.""" - firstName: String! - - """List of the user gift cards.""" - giftCards( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): GiftCardCountableConnection - - """The ID of the user.""" - id: ID! - - """Determine if the user is active.""" - isActive: Boolean! - - """ - Determines if user has confirmed email. - - Added in Saleor 3.15. - """ - isConfirmed: Boolean! - - """Determine if the user is a staff admin.""" - isStaff: Boolean! - - """User language code.""" - languageCode: LanguageCodeEnum! - - """The date when the user last time log in to the system.""" - lastLogin: DateTime - - """The family name of the address.""" - lastName: String! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """ - A note about the customer. - - Requires one of the following permissions: MANAGE_USERS, MANAGE_STAFF. - """ - note: String - - """ - List of user's orders. Requires one of the following permissions: MANAGE_STAFF, OWNER. - """ - orders( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): OrderCountableConnection - - """List of user's permission groups.""" - permissionGroups: [Group!] - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - Determine if user have restricted access to channels. False if at least one user group has `restrictedAccessToChannels` set to False. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - restrictedAccessToChannels: Boolean! - - """ - Returns a list of user's stored payment methods that can be used in provided channel. The field returns a list of stored payment methods by payment apps. When `amount` is not provided, 0 will be used as default value. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - storedPaymentMethods( - """Slug of a channel for which the data should be returned.""" - channel: String! - ): [StoredPaymentMethod!] - - """ - List of stored payment sources. The field returns a list of payment sources stored for payment plugins. - """ - storedPaymentSources( - """Slug of a channel for which the data should be returned.""" - channel: String - ): [PaymentSource!] - - """The data when the user last update the account information.""" - updatedAt: DateTime! - - """List of user's permissions.""" - userPermissions: [UserPermission!] -} - -""" -Deletes a user avatar. Only for staff members. - -Requires one of the following permissions: AUTHENTICATED_STAFF_USER. -""" -type UserAvatarDelete { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """An updated user instance.""" - user: User -} - -""" -Create a user avatar. Only for staff members. This mutation must be sent as a `multipart` request. More detailed specs of the upload format can be found here: https://github.com/jaydenseric/graphql-multipart-request-spec - -Requires one of the following permissions: AUTHENTICATED_STAFF_USER. -""" -type UserAvatarUpdate { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """An updated user instance.""" - user: User -} - -""" -Activate or deactivate users. - -Requires one of the following permissions: MANAGE_USERS. -""" -type UserBulkSetActive { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - - """Returns how many objects were affected.""" - count: Int! - errors: [AccountError!]! -} - -type UserCountableConnection { - edges: [UserCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type UserCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: User! -} - -input UserCreateInput { - """ - Slug of a channel which will be used for notify user. Optional when only one channel exists. - """ - channel: String - - """Billing address of the customer.""" - defaultBillingAddress: AddressInput - - """Shipping address of the customer.""" - defaultShippingAddress: AddressInput - - """The unique email address of the user.""" - email: String - - """ - External ID of the customer. - - Added in Saleor 3.10. - """ - externalReference: String - - """Given name.""" - firstName: String - - """User account is active.""" - isActive: Boolean - - """ - User account is confirmed. - - Added in Saleor 3.15. - - DEPRECATED: this field will be removed in Saleor 4.0. - - The user will be always set as unconfirmed. The confirmation will take place when the user sets the password. - """ - isConfirmed: Boolean - - """User language code.""" - languageCode: LanguageCodeEnum - - """Family name.""" - lastName: String - - """ - Fields required to update the user metadata. - - Added in Saleor 3.14. - """ - metadata: [MetadataInput!] - - """A note about the user.""" - note: String - - """ - Fields required to update the user private metadata. - - Added in Saleor 3.14. - """ - privateMetadata: [MetadataInput!] - - """ - URL of a view where users should be redirected to set the password. URL in RFC 1808 format. - """ - redirectUrl: String -} - -union UserOrApp = App | User - -"""Represents user's permissions.""" -type UserPermission { - """Internal code for permission.""" - code: PermissionEnum! - - """Describe action(s) allowed to do by permission.""" - name: String! - - """List of user permission groups which contains this permission.""" - sourcePermissionGroups( - """ID of user whose groups should be returned.""" - userId: ID! - ): [Group!] -} - -enum UserSortField { - """Sort users by created at.""" - CREATED_AT - - """Sort users by email.""" - EMAIL - - """Sort users by first name.""" - FIRST_NAME - - """Sort users by last modified at.""" - LAST_MODIFIED_AT - - """Sort users by last name.""" - LAST_NAME - - """Sort users by order count.""" - ORDER_COUNT -} - -input UserSortingInput { - """Specifies the direction in which to sort users.""" - direction: OrderDirection! - - """Sort users by the selected field.""" - field: UserSortField! -} - -"""Represents a VAT rate for a country.""" -type VAT { - """Country code.""" - countryCode: String! - - """Country's VAT rate exceptions for specific types of goods.""" - reducedRates: [ReducedRate!]! - - """Standard VAT rate in percent.""" - standardRate: Float -} - -enum VariantAttributeScope { - ALL - NOT_VARIANT_SELECTION - VARIANT_SELECTION -} - -""" -Assign an media to a product variant. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type VariantMediaAssign { - errors: [ProductError!]! - media: ProductMedia - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - productVariant: ProductVariant -} - -""" -Unassign an media from a product variant. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type VariantMediaUnassign { - errors: [ProductError!]! - media: ProductMedia - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - productVariant: ProductVariant -} - -"""Represents availability of a variant in the storefront.""" -type VariantPricingInfo { - """The discount amount if in sale (null otherwise).""" - discount: TaxedMoney - - """The discount amount in the local currency.""" - discountLocalCurrency: TaxedMoney @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`.") - - """Whether it is in sale or not.""" - onSale: Boolean - - """The price, with any discount subtracted.""" - price: TaxedMoney - - """The discounted price in the local currency.""" - priceLocalCurrency: TaxedMoney @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`.") - - """The price without any discount.""" - priceUndiscounted: TaxedMoney -} - -"""Verify JWT token.""" -type VerifyToken { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [AccountError!]! - - """Determine if token is valid or not.""" - isValid: Boolean! - - """JWT payload.""" - payload: GenericScalar - - """User assigned to token.""" - user: User -} - -"""An enumeration.""" -enum VolumeUnitsEnum { - ACRE_FT - ACRE_IN - CUBIC_CENTIMETER - CUBIC_DECIMETER - CUBIC_FOOT - CUBIC_INCH - CUBIC_METER - CUBIC_MILLIMETER - CUBIC_YARD - FL_OZ - LITER - PINT - QT -} - -""" -Vouchers allow giving discounts to particular customers on categories, collections or specific products. They can be used during checkout by providing valid voucher codes. -""" -type Voucher implements Node & ObjectWithMetadata { - """ - Determine if the voucher usage should be limited to one use per customer. - """ - applyOncePerCustomer: Boolean! - - """ - Determine if the voucher should be applied once per order. If set to True, the voucher is applied to a single cheapest eligible product in checkout. - """ - applyOncePerOrder: Boolean! - - """List of categories this voucher applies to.""" - categories( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): CategoryCountableConnection - - """ - List of availability in channels for the voucher. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - channelListings: [VoucherChannelListing!] - - """The code of the voucher.This field will be removed in Saleor 4.0.""" - code: String - - """ - List of codes available for this voucher. - - Added in Saleor 3.18. - """ - codes( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): VoucherCodeCountableConnection - - """ - List of collections this voucher applies to. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - collections( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): CollectionCountableConnection - - """List of countries available for the shipping voucher.""" - countries: [CountryDisplay!] - - """Currency code for voucher.""" - currency: String - - """Voucher value.""" - discountValue: Float - - """Determines a type of discount for voucher - value or percentage""" - discountValueType: DiscountValueTypeEnum! - - """The end date and time of voucher.""" - endDate: DateTime - - """The ID of the voucher.""" - id: ID! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Determine minimum quantity of items for checkout.""" - minCheckoutItemsQuantity: Int - - """Minimum order value to apply voucher.""" - minSpent: Money - - """The name of the voucher.""" - name: String - - """Determine if the voucher is available only for staff members.""" - onlyForStaff: Boolean! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """ - List of products this voucher applies to. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - products( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ProductCountableConnection - - """ - Determine if the voucher codes can be used once or multiple times. - - Added in Saleor 3.18. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - singleUse: Boolean! - - """The start date and time of voucher.""" - startDate: DateTime! - - """Returns translated voucher fields for the given language code.""" - translation( - """A language code to return the translation for voucher.""" - languageCode: LanguageCodeEnum! - ): VoucherTranslation - - """Determines a type of voucher.""" - type: VoucherTypeEnum! - - """The number of times a voucher can be used.""" - usageLimit: Int - - """Usage count of the voucher.""" - used: Int! - - """ - List of product variants this voucher applies to. - - Added in Saleor 3.1. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - variants( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ProductVariantCountableConnection -} - -""" -Adds products, categories, collections to a voucher. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_UPDATED (async): A voucher was updated. -""" -type VoucherAddCatalogues { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - - """Voucher of which catalogue IDs will be modified.""" - voucher: Voucher -} - -""" -Deletes vouchers. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_DELETED (async): A voucher was deleted. -""" -type VoucherBulkDelete { - """Returns how many objects were affected.""" - count: Int! - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! -} - -"""Represents voucher channel listing.""" -type VoucherChannelListing implements Node { - """The channel in which voucher can be applied.""" - channel: Channel! - - """Currency code for voucher in a channel.""" - currency: String! - - """The value of the discount on voucher in a channel.""" - discountValue: Float! - - """The ID of channel listing.""" - id: ID! - - """Minimum order value for voucher to apply in channel.""" - minSpent: Money -} - -input VoucherChannelListingAddInput { - """ID of a channel.""" - channelId: ID! - - """Value of the voucher.""" - discountValue: PositiveDecimal - - """Min purchase amount required to apply the voucher.""" - minAmountSpent: PositiveDecimal -} - -input VoucherChannelListingInput { - """List of channels to which the voucher should be assigned.""" - addChannels: [VoucherChannelListingAddInput!] - - """List of channels from which the voucher should be unassigned.""" - removeChannels: [ID!] -} - -""" -Manage voucher's availability in channels. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_UPDATED (async): A voucher was updated. -""" -type VoucherChannelListingUpdate { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - - """An updated voucher instance.""" - voucher: Voucher -} - -""" -Represents voucher code. - -Added in Saleor 3.18. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type VoucherCode { - """Code to use the voucher.""" - code: String - - """Date time of code creation.""" - createdAt: DateTime! - - """The ID of the voucher code.""" - id: ID! - - """Whether a code is active or not.""" - isActive: Boolean - - """Number of times a code has been used.""" - used: Int -} - -""" -Deletes voucher codes. - -Added in Saleor 3.18. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_CODES_DELETED (async): A voucher codes were deleted. -""" -type VoucherCodeBulkDelete { - """Returns how many codes were deleted.""" - count: Int! - errors: [VoucherCodeBulkDeleteError!]! -} - -type VoucherCodeBulkDeleteError { - """The error code.""" - code: VoucherCodeBulkDeleteErrorCode! - - """The error message.""" - message: String - - """ - Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - path: String - - """List of voucher codes which causes the error.""" - voucherCodes: [ID!] -} - -"""An enumeration.""" -enum VoucherCodeBulkDeleteErrorCode { - GRAPHQL_ERROR - INVALID - NOT_FOUND -} - -type VoucherCodeCountableConnection { - edges: [VoucherCodeCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type VoucherCodeCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: VoucherCode! -} - -""" -Event sent when voucher code export is completed. - -Added in Saleor 3.18. -""" -type VoucherCodeExportCompleted implements Event { - """The export file for voucher codes.""" - export: ExportFile - - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String -} - -""" -Event sent when new voucher codes were created. - -Added in Saleor 3.19. -""" -type VoucherCodesCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The voucher codes the event relates to.""" - voucherCodes: [VoucherCode!] -} - -""" -Event sent when voucher codes were deleted. - -Added in Saleor 3.19. -""" -type VoucherCodesDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The voucher codes the event relates to.""" - voucherCodes: [VoucherCode!] -} - -type VoucherCountableConnection { - edges: [VoucherCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type VoucherCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Voucher! -} - -""" -Creates a new voucher. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_CREATED (async): A voucher was created. -- VOUCHER_CODES_CREATED (async): A voucher codes were created. -""" -type VoucherCreate { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - voucher: Voucher -} - -""" -Event sent when new voucher is created. - -Added in Saleor 3.4. -""" -type VoucherCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The voucher the event relates to.""" - voucher( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Voucher -} - -""" -Deletes a voucher. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_DELETED (async): A voucher was deleted. -""" -type VoucherDelete { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - voucher: Voucher -} - -""" -Event sent when voucher is deleted. - -Added in Saleor 3.4. -""" -type VoucherDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The voucher the event relates to.""" - voucher( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Voucher -} - -enum VoucherDiscountType { - FIXED - PERCENTAGE - SHIPPING -} - -input VoucherFilterInput { - discountType: [VoucherDiscountType!] - ids: [ID!] - metadata: [MetadataFilter!] - search: String - started: DateTimeRangeInput - status: [DiscountStatusEnum!] - timesUsed: IntRangeInput -} - -input VoucherInput { - """ - List of codes to add. - - Added in Saleor 3.18. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - addCodes: [String!] - - """Voucher should be applied once per customer.""" - applyOncePerCustomer: Boolean - - """Voucher should be applied to the cheapest item or entire order.""" - applyOncePerOrder: Boolean - - """Categories discounted by the voucher.""" - categories: [ID!] - - """ - Code to use the voucher. This field will be removed in Saleor 4.0. Use `addCodes` instead. - """ - code: String - - """Collections discounted by the voucher.""" - collections: [ID!] - - """Country codes that can be used with the shipping voucher.""" - countries: [String!] - - """Choices: fixed or percentage.""" - discountValueType: DiscountValueTypeEnum - - """End date of the voucher in ISO 8601 format.""" - endDate: DateTime - - """Minimal quantity of checkout items required to apply the voucher.""" - minCheckoutItemsQuantity: Int - - """Voucher name.""" - name: String - - """Voucher can be used only by staff user.""" - onlyForStaff: Boolean - - """Products discounted by the voucher.""" - products: [ID!] - - """ - When set to 'True', each voucher code can be used only once; otherwise, codes can be used multiple times depending on `usageLimit`. - - The option can only be changed if none of the voucher codes have been used. - - Added in Saleor 3.18. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - singleUse: Boolean - - """Start date of the voucher in ISO 8601 format.""" - startDate: DateTime - - """Voucher type: PRODUCT, CATEGORY SHIPPING or ENTIRE_ORDER.""" - type: VoucherTypeEnum - - """Limit number of times this voucher can be used in total.""" - usageLimit: Int - - """ - Variants discounted by the voucher. - - Added in Saleor 3.1. - """ - variants: [ID!] -} - -""" -Event sent when voucher metadata is updated. - -Added in Saleor 3.8. -""" -type VoucherMetadataUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The voucher the event relates to.""" - voucher( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Voucher -} - -""" -Removes products, categories, collections from a voucher. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_UPDATED (async): A voucher was updated. -""" -type VoucherRemoveCatalogues { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - - """Voucher of which catalogue IDs will be modified.""" - voucher: Voucher -} - -enum VoucherSortField { - """ - Sort vouchers by code. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - CODE - - """Sort vouchers by end date.""" - END_DATE - - """ - Sort vouchers by minimum spent amount. - - This option requires a channel filter to work as the values can vary between channels. - """ - MINIMUM_SPENT_AMOUNT - - """ - Sort vouchers by name. - - Added in Saleor 3.18. - """ - NAME - - """Sort vouchers by start date.""" - START_DATE - - """Sort vouchers by type.""" - TYPE - - """Sort vouchers by usage limit.""" - USAGE_LIMIT - - """ - Sort vouchers by value. - - This option requires a channel filter to work as the values can vary between channels. - """ - VALUE -} - -input VoucherSortingInput { - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String - - """Specifies the direction in which to sort vouchers.""" - direction: OrderDirection! - - """Sort vouchers by the selected field.""" - field: VoucherSortField! -} - -""" -Represents voucher's original translatable fields and related translations. -""" -type VoucherTranslatableContent implements Node { - """The ID of the voucher translatable content.""" - id: ID! - - """Voucher name to translate.""" - name: String - - """Returns translated voucher fields for the given language code.""" - translation( - """A language code to return the translation for voucher.""" - languageCode: LanguageCodeEnum! - ): VoucherTranslation - - """ - Vouchers allow giving discounts to particular customers on categories, collections or specific products. They can be used during checkout by providing valid voucher codes. - - Requires one of the following permissions: MANAGE_DISCOUNTS. - """ - voucher: Voucher @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") - - """ - The ID of the voucher to translate. - - Added in Saleor 3.14. - """ - voucherId: ID! -} - -""" -Creates/updates translations for a voucher. - -Requires one of the following permissions: MANAGE_TRANSLATIONS. -""" -type VoucherTranslate { - errors: [TranslationError!]! - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - voucher: Voucher -} - -"""Represents voucher translations.""" -type VoucherTranslation implements Node { - """The ID of the voucher translation.""" - id: ID! - - """Translation language.""" - language: LanguageDisplay! - - """Translated voucher name.""" - name: String - - """ - Represents the voucher fields to translate. - - Added in Saleor 3.14. - """ - translatableContent: VoucherTranslatableContent -} - -enum VoucherTypeEnum { - ENTIRE_ORDER - SHIPPING - SPECIFIC_PRODUCT -} - -""" -Updates a voucher. - -Requires one of the following permissions: MANAGE_DISCOUNTS. - -Triggers the following webhook events: -- VOUCHER_UPDATED (async): A voucher was updated. -- VOUCHER_CODES_CREATED (async): A voucher code was created. -""" -type VoucherUpdate { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") - errors: [DiscountError!]! - voucher: Voucher -} - -""" -Event sent when voucher is updated. - -Added in Saleor 3.4. -""" -type VoucherUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The voucher the event relates to.""" - voucher( - """Slug of a channel for which the data should be returned.""" - channel: String - ): Voucher -} - -"""Represents warehouse.""" -type Warehouse implements Node & ObjectWithMetadata { - """Address of the warehouse.""" - address: Address! - - """ - Click and collect options: local, all or disabled. - - Added in Saleor 3.1. - """ - clickAndCollectOption: WarehouseClickAndCollectOptionEnum! - - """Warehouse company name.""" - companyName: String! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `Address.companyName` instead.") - - """Warehouse email.""" - email: String! - - """ - External ID of this warehouse. - - Added in Saleor 3.10. - """ - externalReference: String - - """The ID of the warehouse.""" - id: ID! - - """Determine if the warehouse is private.""" - isPrivate: Boolean! - - """List of public metadata items. Can be accessed without permissions.""" - metadata: [MetadataItem!]! - - """ - A single key from public metadata. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - metafield(key: String!): String - - """ - Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - metafields(keys: [String!]): Metadata - - """Warehouse name.""" - name: String! - - """List of private metadata items. Requires staff permissions to access.""" - privateMetadata: [MetadataItem!]! - - """ - A single key from private metadata. Requires staff permissions to access. - - Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. - """ - privateMetafield(key: String!): String - - """ - Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. - """ - privateMetafields(keys: [String!]): Metadata - - """Shipping zones supported by the warehouse.""" - shippingZones( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): ShippingZoneCountableConnection! - - """Warehouse slug.""" - slug: String! - - """ - Stocks that belong to this warehouse. - - Added in Saleor 3.20. - - Requires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS. - """ - stocks( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - ): StockCountableConnection -} - -"""An enumeration.""" -enum WarehouseClickAndCollectOptionEnum { - ALL - DISABLED - LOCAL -} - -type WarehouseCountableConnection { - edges: [WarehouseCountableEdge!]! - - """Pagination data for this connection.""" - pageInfo: PageInfo! - - """A total count of items in the collection.""" - totalCount: Int -} - -type WarehouseCountableEdge { - """A cursor for use in pagination.""" - cursor: String! - - """The item at the end of the edge.""" - node: Warehouse! -} - -""" -Creates new warehouse. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type WarehouseCreate { - errors: [WarehouseError!]! - warehouse: Warehouse - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input WarehouseCreateInput { - """Address of the warehouse.""" - address: AddressInput! - - """The email address of the warehouse.""" - email: String - - """ - External ID of the warehouse. - - Added in Saleor 3.10. - """ - externalReference: String - - """Warehouse name.""" - name: String! - - """ - Shipping zones supported by the warehouse. - - DEPRECATED: this field will be removed in Saleor 4.0. Providing the zone ids will raise a ValidationError. - """ - shippingZones: [ID!] - - """Warehouse slug.""" - slug: String -} - -""" -Event sent when new warehouse is created. - -Added in Saleor 3.4. -""" -type WarehouseCreated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The warehouse the event relates to.""" - warehouse: Warehouse -} - -""" -Deletes selected warehouse. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type WarehouseDelete { - errors: [WarehouseError!]! - warehouse: Warehouse - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Event sent when warehouse is deleted. - -Added in Saleor 3.4. -""" -type WarehouseDeleted implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The warehouse the event relates to.""" - warehouse: Warehouse -} - -type WarehouseError { - """The error code.""" - code: WarehouseErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String - - """List of shipping zones IDs which causes the error.""" - shippingZones: [ID!] -} - -"""An enumeration.""" -enum WarehouseErrorCode { - ALREADY_EXISTS - GRAPHQL_ERROR - INVALID - NOT_FOUND - REQUIRED - UNIQUE -} - -input WarehouseFilterInput { - channels: [ID!] - clickAndCollectOption: WarehouseClickAndCollectOptionEnum - ids: [ID!] - isPrivate: Boolean - metadata: [MetadataFilter!] - search: String - slugs: [String!] -} - -""" -Event sent when warehouse metadata is updated. - -Added in Saleor 3.8. -""" -type WarehouseMetadataUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The warehouse the event relates to.""" - warehouse: Warehouse -} - -""" -Add shipping zone to given warehouse. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type WarehouseShippingZoneAssign { - errors: [WarehouseError!]! - warehouse: Warehouse - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Remove shipping zone from given warehouse. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type WarehouseShippingZoneUnassign { - errors: [WarehouseError!]! - warehouse: Warehouse - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -enum WarehouseSortField { - """Sort warehouses by name.""" - NAME -} - -input WarehouseSortingInput { - """Specifies the direction in which to sort warehouses.""" - direction: OrderDirection! - - """Sort warehouses by the selected field.""" - field: WarehouseSortField! -} - -""" -Updates given warehouse. - -Requires one of the following permissions: MANAGE_PRODUCTS. -""" -type WarehouseUpdate { - errors: [WarehouseError!]! - warehouse: Warehouse - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input WarehouseUpdateInput { - """Address of the warehouse.""" - address: AddressInput - - """ - Click and collect options: local, all or disabled. - - Added in Saleor 3.1. - """ - clickAndCollectOption: WarehouseClickAndCollectOptionEnum - - """The email address of the warehouse.""" - email: String - - """ - External ID of the warehouse. - - Added in Saleor 3.10. - """ - externalReference: String - - """ - Visibility of warehouse stocks. - - Added in Saleor 3.1. - """ - isPrivate: Boolean - - """Warehouse name.""" - name: String - - """Warehouse slug.""" - slug: String -} - -""" -Event sent when warehouse is updated. - -Added in Saleor 3.4. -""" -type WarehouseUpdated implements Event { - """Time of the event.""" - issuedAt: DateTime - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """Saleor version that triggered the event.""" - version: String - - """The warehouse the event relates to.""" - warehouse: Warehouse -} - -"""Webhook.""" -type Webhook implements Node { - """The app associated with Webhook.""" - app: App! - - """List of asynchronous webhook events.""" - asyncEvents: [WebhookEventAsync!]! - - """ - Custom headers, which will be added to HTTP request. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - customHeaders: JSONString - - """Event deliveries.""" - eventDeliveries( - """Return the elements in the list that come after the specified cursor.""" - after: String - - """Return the elements in the list that come before the specified cursor.""" - before: String - - """Event delivery filter options.""" - filter: EventDeliveryFilterInput - - """ - Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - first: Int - - """ - Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. - """ - last: Int - - """Event delivery sorter.""" - sortBy: EventDeliverySortingInput - ): EventDeliveryCountableConnection - - """List of webhook events.""" - events: [WebhookEvent!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead.") - - """The ID of webhook.""" - id: ID! - - """Informs if webhook is activated.""" - isActive: Boolean! - - """The name of webhook.""" - name: String - - """Used to create a hash signature for each payload.""" - secretKey: String @deprecated(reason: "This field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS.") - - """Used to define payloads for specific events.""" - subscriptionQuery: String - - """List of synchronous webhook events.""" - syncEvents: [WebhookEventSync!]! - - """Target URL for webhook.""" - targetUrl: String! -} - -""" -Creates a new webhook subscription. - -Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. -""" -type WebhookCreate { - errors: [WebhookError!]! - webhook: Webhook - webhookErrors: [WebhookError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input WebhookCreateInput { - """ID of the app to which webhook belongs.""" - app: ID - - """The asynchronous events that webhook wants to subscribe.""" - asyncEvents: [WebhookEventTypeAsyncEnum!] - - """ - Custom headers, which will be added to HTTP request. There is a limitation of 5 headers per webhook and 998 characters per header.Only `X-*`, `Authorization*`, and `BrokerProperties` keys are allowed. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - customHeaders: JSONString - - """ - The events that webhook wants to subscribe. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead. - """ - events: [WebhookEventTypeEnum!] - - """Determine if webhook will be set active or not.""" - isActive: Boolean - - """The name of the webhook.""" - name: String - - """ - Subscription query used to define a webhook payload. - - Added in Saleor 3.2. - """ - query: String - - """ - The secret key used to create a hash signature with each payload. - - DEPRECATED: this field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. - """ - secretKey: String - - """The synchronous events that webhook wants to subscribe.""" - syncEvents: [WebhookEventTypeSyncEnum!] - - """The url to receive the payload.""" - targetUrl: String -} - -""" -Delete a webhook. Before the deletion, the webhook is deactivated to pause any deliveries that are already scheduled. The deletion might fail if delivery is in progress. In such a case, the webhook is not deleted but remains deactivated. - -Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. -""" -type WebhookDelete { - errors: [WebhookError!]! - webhook: Webhook - webhookErrors: [WebhookError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -""" -Performs a dry run of a webhook event. Supports a single event (the first, if multiple provided in the `query`). Requires permission relevant to processed event. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: AUTHENTICATED_STAFF_USER. -""" -type WebhookDryRun { - errors: [WebhookDryRunError!]! - - """JSON payload, that would be sent out to webhook's target URL.""" - payload: JSONString -} - -type WebhookDryRunError { - """The error code.""" - code: WebhookDryRunErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum WebhookDryRunErrorCode { - GRAPHQL_ERROR - INVALID_ID - MISSING_EVENT - MISSING_PERMISSION - MISSING_SUBSCRIPTION - NOT_FOUND - SYNTAX - TYPE_NOT_SUPPORTED - UNABLE_TO_PARSE -} - -type WebhookError { - """The error code.""" - code: WebhookErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum WebhookErrorCode { - DELETE_FAILED - GRAPHQL_ERROR - INVALID - INVALID_CUSTOM_HEADERS - INVALID_NOTIFY_WITH_SUBSCRIPTION - MISSING_EVENT - MISSING_SUBSCRIPTION - NOT_FOUND - REQUIRED - SYNTAX - UNABLE_TO_PARSE - UNIQUE -} - -"""Webhook event.""" -type WebhookEvent { - """Internal name of the event type.""" - eventType: WebhookEventTypeEnum! - - """Display name of the event.""" - name: String! -} - -"""Asynchronous webhook event.""" -type WebhookEventAsync { - """Internal name of the event type.""" - eventType: WebhookEventTypeAsyncEnum! - - """Display name of the event.""" - name: String! -} - -"""Synchronous webhook event.""" -type WebhookEventSync { - """Internal name of the event type.""" - eventType: WebhookEventTypeSyncEnum! - - """Display name of the event.""" - name: String! -} - -"""Enum determining type of webhook.""" -enum WebhookEventTypeAsyncEnum { - """An account email change is requested.""" - ACCOUNT_CHANGE_EMAIL_REQUESTED - - """An account confirmation is requested.""" - ACCOUNT_CONFIRMATION_REQUESTED - - """An account is confirmed.""" - ACCOUNT_CONFIRMED - - """An account is deleted.""" - ACCOUNT_DELETED - - """An account delete is requested.""" - ACCOUNT_DELETE_REQUESTED - - """An account email was changed""" - ACCOUNT_EMAIL_CHANGED - - """Setting a new password for the account is requested.""" - ACCOUNT_SET_PASSWORD_REQUESTED - - """A new address created.""" - ADDRESS_CREATED - - """An address deleted.""" - ADDRESS_DELETED - - """An address updated.""" - ADDRESS_UPDATED - - """ - All the events. - - DEPRECATED: this value will be removed in Saleor 4.0. - """ - ANY_EVENTS - - """An app deleted.""" - APP_DELETED - - """A new app installed.""" - APP_INSTALLED - - """An app status is changed.""" - APP_STATUS_CHANGED - - """An app updated.""" - APP_UPDATED - - """A new attribute is created.""" - ATTRIBUTE_CREATED - - """An attribute is deleted.""" - ATTRIBUTE_DELETED - - """An attribute is updated.""" - ATTRIBUTE_UPDATED - - """A new attribute value is created.""" - ATTRIBUTE_VALUE_CREATED - - """An attribute value is deleted.""" - ATTRIBUTE_VALUE_DELETED - - """An attribute value is updated.""" - ATTRIBUTE_VALUE_UPDATED - - """A new category created.""" - CATEGORY_CREATED - - """A category is deleted.""" - CATEGORY_DELETED - - """A category is updated.""" - CATEGORY_UPDATED - - """A new channel created.""" - CHANNEL_CREATED - - """A channel is deleted.""" - CHANNEL_DELETED - - """A channel metadata is updated.""" - CHANNEL_METADATA_UPDATED - - """A channel status is changed.""" - CHANNEL_STATUS_CHANGED - - """A channel is updated.""" - CHANNEL_UPDATED - - """A new checkout is created.""" - CHECKOUT_CREATED - CHECKOUT_FULLY_PAID - - """ - A checkout metadata is updated. - - Added in Saleor 3.8. - """ - CHECKOUT_METADATA_UPDATED - - """ - A checkout is updated. It also triggers all updates related to the checkout. - """ - CHECKOUT_UPDATED - - """A new collection is created.""" - COLLECTION_CREATED - - """A collection is deleted.""" - COLLECTION_DELETED - - """ - A collection metadata is updated. - - Added in Saleor 3.8. - """ - COLLECTION_METADATA_UPDATED - - """A collection is updated.""" - COLLECTION_UPDATED - - """A new customer account is created.""" - CUSTOMER_CREATED - - """A customer account is deleted.""" - CUSTOMER_DELETED - - """ - A customer account metadata is updated. - - Added in Saleor 3.8. - """ - CUSTOMER_METADATA_UPDATED - - """A customer account is updated.""" - CUSTOMER_UPDATED - - """A draft order is created.""" - DRAFT_ORDER_CREATED - - """A draft order is deleted.""" - DRAFT_ORDER_DELETED - - """A draft order is updated.""" - DRAFT_ORDER_UPDATED - - """A fulfillment is approved.""" - FULFILLMENT_APPROVED - - """A fulfillment is cancelled.""" - FULFILLMENT_CANCELED - - """A new fulfillment is created.""" - FULFILLMENT_CREATED - - """ - A fulfillment metadata is updated. - - Added in Saleor 3.8. - """ - FULFILLMENT_METADATA_UPDATED - FULFILLMENT_TRACKING_NUMBER_UPDATED - - """A new gift card created.""" - GIFT_CARD_CREATED - - """A gift card is deleted.""" - GIFT_CARD_DELETED - - """ - A gift card export is completed. - - Added in Saleor 3.16. - """ - GIFT_CARD_EXPORT_COMPLETED - - """ - A gift card metadata is updated. - - Added in Saleor 3.8. - """ - GIFT_CARD_METADATA_UPDATED - - """ - A gift card has been sent. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - GIFT_CARD_SENT - - """A gift card status is changed.""" - GIFT_CARD_STATUS_CHANGED - - """A gift card is updated.""" - GIFT_CARD_UPDATED - - """An invoice is deleted.""" - INVOICE_DELETED - - """An invoice for order requested.""" - INVOICE_REQUESTED - - """Invoice has been sent.""" - INVOICE_SENT - - """A new menu created.""" - MENU_CREATED - - """A menu is deleted.""" - MENU_DELETED - - """A new menu item created.""" - MENU_ITEM_CREATED - - """A menu item is deleted.""" - MENU_ITEM_DELETED - - """A menu item is updated.""" - MENU_ITEM_UPDATED - - """A menu is updated.""" - MENU_UPDATED - - """ - User notification triggered. - - DEPRECATED: this value will be removed in Saleor 4.0. See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/docs/next/upgrade-guides/notify-user-deprecation - """ - NOTIFY_USER - - """An observability event is created.""" - OBSERVABILITY - - """ - Orders are imported. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - ORDER_BULK_CREATED - - """An order is cancelled.""" - ORDER_CANCELLED - - """ - An order is confirmed (status change unconfirmed -> unfulfilled) by a staff user using the OrderConfirm mutation. It also triggers when the user completes the checkout and the shop setting `automatically_confirm_all_new_orders` is enabled. - """ - ORDER_CONFIRMED - - """A new order is placed.""" - ORDER_CREATED - - """An order is expired.""" - ORDER_EXPIRED - - """An order is fulfilled.""" - ORDER_FULFILLED - - """Payment is made and an order is fully paid.""" - ORDER_FULLY_PAID - - """ - The order is fully refunded. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - ORDER_FULLY_REFUNDED - - """ - An order metadata is updated. - - Added in Saleor 3.8. - """ - ORDER_METADATA_UPDATED - - """ - Payment has been made. The order may be partially or fully paid. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - ORDER_PAID - - """ - The order received a refund. The order may be partially or fully refunded. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - ORDER_REFUNDED - - """ - An order is updated; triggered for all changes related to an order; covers all other order webhooks, except for ORDER_CREATED. - """ - ORDER_UPDATED - - """A new page is created.""" - PAGE_CREATED - - """A page is deleted.""" - PAGE_DELETED - - """A new page type is created.""" - PAGE_TYPE_CREATED - - """A page type is deleted.""" - PAGE_TYPE_DELETED - - """A page type is updated.""" - PAGE_TYPE_UPDATED - - """A page is updated.""" - PAGE_UPDATED - - """A new permission group is created.""" - PERMISSION_GROUP_CREATED - - """A permission group is deleted.""" - PERMISSION_GROUP_DELETED - - """A permission group is updated.""" - PERMISSION_GROUP_UPDATED - - """A new product is created.""" - PRODUCT_CREATED - - """A product is deleted.""" - PRODUCT_DELETED - - """ - A product export is completed. - - Added in Saleor 3.16. - """ - PRODUCT_EXPORT_COMPLETED - - """ - A new product media is created. - - Added in Saleor 3.12. - """ - PRODUCT_MEDIA_CREATED - - """ - A product media is deleted. - - Added in Saleor 3.12. - """ - PRODUCT_MEDIA_DELETED - - """ - A product media is updated. - - Added in Saleor 3.12. - """ - PRODUCT_MEDIA_UPDATED - - """ - A product metadata is updated. - - Added in Saleor 3.8. - """ - PRODUCT_METADATA_UPDATED - - """A product is updated.""" - PRODUCT_UPDATED - - """A product variant is back in stock.""" - PRODUCT_VARIANT_BACK_IN_STOCK - - """A new product variant is created.""" - PRODUCT_VARIANT_CREATED - - """ - A product variant is deleted. Warning: this event will not be executed when parent product has been deleted. Check PRODUCT_DELETED. - """ - PRODUCT_VARIANT_DELETED - - """ - A product variant metadata is updated. - - Added in Saleor 3.8. - """ - PRODUCT_VARIANT_METADATA_UPDATED - - """A product variant is out of stock.""" - PRODUCT_VARIANT_OUT_OF_STOCK - - """A product variant stock is updated""" - PRODUCT_VARIANT_STOCK_UPDATED - - """A product variant is updated.""" - PRODUCT_VARIANT_UPDATED - - """A promotion is created.""" - PROMOTION_CREATED - - """A promotion is deleted.""" - PROMOTION_DELETED - - """A promotion is deactivated.""" - PROMOTION_ENDED - - """A promotion rule is created.""" - PROMOTION_RULE_CREATED - - """A promotion rule is deleted.""" - PROMOTION_RULE_DELETED - - """A promotion rule is updated.""" - PROMOTION_RULE_UPDATED - - """A promotion is activated.""" - PROMOTION_STARTED - - """A promotion is updated.""" - PROMOTION_UPDATED - - """A sale is created.""" - SALE_CREATED - - """A sale is deleted.""" - SALE_DELETED - - """A sale is activated or deactivated.""" - SALE_TOGGLE - - """A sale is updated.""" - SALE_UPDATED - - """A new shipping price is created.""" - SHIPPING_PRICE_CREATED - - """A shipping price is deleted.""" - SHIPPING_PRICE_DELETED - - """A shipping price is updated.""" - SHIPPING_PRICE_UPDATED - - """A new shipping zone is created.""" - SHIPPING_ZONE_CREATED - - """A shipping zone is deleted.""" - SHIPPING_ZONE_DELETED - - """ - A shipping zone metadata is updated. - - Added in Saleor 3.8. - """ - SHIPPING_ZONE_METADATA_UPDATED - - """A shipping zone is updated.""" - SHIPPING_ZONE_UPDATED - - """ - Shop metadata is updated. - - Added in Saleor 3.15. - """ - SHOP_METADATA_UPDATED - - """A new staff user is created.""" - STAFF_CREATED - - """A staff user is deleted.""" - STAFF_DELETED - - """Setting a new password for the staff account is requested.""" - STAFF_SET_PASSWORD_REQUESTED - - """A staff user is updated.""" - STAFF_UPDATED - - """ - A thumbnail is created. - - Added in Saleor 3.12. - """ - THUMBNAIL_CREATED - - """ - Transaction item metadata is updated. - - Added in Saleor 3.8. - """ - TRANSACTION_ITEM_METADATA_UPDATED - - """A new translation is created.""" - TRANSLATION_CREATED - - """A translation is updated.""" - TRANSLATION_UPDATED - VOUCHER_CODES_CREATED - VOUCHER_CODES_DELETED - - """ - A voucher code export is completed. - - Added in Saleor 3.18. - """ - VOUCHER_CODE_EXPORT_COMPLETED - - """A new voucher created.""" - VOUCHER_CREATED - - """A voucher is deleted.""" - VOUCHER_DELETED - - """ - A voucher metadata is updated. - - Added in Saleor 3.8. - """ - VOUCHER_METADATA_UPDATED - - """A voucher is updated.""" - VOUCHER_UPDATED - - """A new warehouse created.""" - WAREHOUSE_CREATED - - """A warehouse is deleted.""" - WAREHOUSE_DELETED - - """ - A warehouse metadata is updated. - - Added in Saleor 3.8. - """ - WAREHOUSE_METADATA_UPDATED - - """A warehouse is updated.""" - WAREHOUSE_UPDATED -} - -"""Enum determining type of webhook.""" -enum WebhookEventTypeEnum { - """An account email change is requested.""" - ACCOUNT_CHANGE_EMAIL_REQUESTED - - """An account confirmation is requested.""" - ACCOUNT_CONFIRMATION_REQUESTED - - """An account is confirmed.""" - ACCOUNT_CONFIRMED - - """An account is deleted.""" - ACCOUNT_DELETED - - """An account delete is requested.""" - ACCOUNT_DELETE_REQUESTED - - """An account email was changed""" - ACCOUNT_EMAIL_CHANGED - - """Setting a new password for the account is requested.""" - ACCOUNT_SET_PASSWORD_REQUESTED - - """A new address created.""" - ADDRESS_CREATED - - """An address deleted.""" - ADDRESS_DELETED - - """An address updated.""" - ADDRESS_UPDATED - - """ - All the events. - - DEPRECATED: this value will be removed in Saleor 4.0. - """ - ANY_EVENTS - - """An app deleted.""" - APP_DELETED - - """A new app installed.""" - APP_INSTALLED - - """An app status is changed.""" - APP_STATUS_CHANGED - - """An app updated.""" - APP_UPDATED - - """A new attribute is created.""" - ATTRIBUTE_CREATED - - """An attribute is deleted.""" - ATTRIBUTE_DELETED - - """An attribute is updated.""" - ATTRIBUTE_UPDATED - - """A new attribute value is created.""" - ATTRIBUTE_VALUE_CREATED - - """An attribute value is deleted.""" - ATTRIBUTE_VALUE_DELETED - - """An attribute value is updated.""" - ATTRIBUTE_VALUE_UPDATED - - """A new category created.""" - CATEGORY_CREATED - - """A category is deleted.""" - CATEGORY_DELETED - - """A category is updated.""" - CATEGORY_UPDATED - - """A new channel created.""" - CHANNEL_CREATED - - """A channel is deleted.""" - CHANNEL_DELETED - - """A channel metadata is updated.""" - CHANNEL_METADATA_UPDATED - - """A channel status is changed.""" - CHANNEL_STATUS_CHANGED - - """A channel is updated.""" - CHANNEL_UPDATED - - """ - Event called for checkout tax calculation. - - Added in Saleor 3.6. - """ - CHECKOUT_CALCULATE_TAXES - - """A new checkout is created.""" - CHECKOUT_CREATED - - """Filter shipping methods for checkout.""" - CHECKOUT_FILTER_SHIPPING_METHODS - CHECKOUT_FULLY_PAID - - """ - A checkout metadata is updated. - - Added in Saleor 3.8. - """ - CHECKOUT_METADATA_UPDATED - - """ - A checkout is updated. It also triggers all updates related to the checkout. - """ - CHECKOUT_UPDATED - - """A new collection is created.""" - COLLECTION_CREATED - - """A collection is deleted.""" - COLLECTION_DELETED - - """ - A collection metadata is updated. - - Added in Saleor 3.8. - """ - COLLECTION_METADATA_UPDATED - - """A collection is updated.""" - COLLECTION_UPDATED - - """A new customer account is created.""" - CUSTOMER_CREATED - - """A customer account is deleted.""" - CUSTOMER_DELETED - - """ - A customer account metadata is updated. - - Added in Saleor 3.8. - """ - CUSTOMER_METADATA_UPDATED - - """A customer account is updated.""" - CUSTOMER_UPDATED - - """A draft order is created.""" - DRAFT_ORDER_CREATED - - """A draft order is deleted.""" - DRAFT_ORDER_DELETED - - """A draft order is updated.""" - DRAFT_ORDER_UPDATED - - """A fulfillment is approved.""" - FULFILLMENT_APPROVED - - """A fulfillment is cancelled.""" - FULFILLMENT_CANCELED - - """A new fulfillment is created.""" - FULFILLMENT_CREATED - - """ - A fulfillment metadata is updated. - - Added in Saleor 3.8. - """ - FULFILLMENT_METADATA_UPDATED - FULFILLMENT_TRACKING_NUMBER_UPDATED - - """A new gift card created.""" - GIFT_CARD_CREATED - - """A gift card is deleted.""" - GIFT_CARD_DELETED - - """ - A gift card export is completed. - - Added in Saleor 3.16. - """ - GIFT_CARD_EXPORT_COMPLETED - - """ - A gift card metadata is updated. - - Added in Saleor 3.8. - """ - GIFT_CARD_METADATA_UPDATED - - """ - A gift card has been sent. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - GIFT_CARD_SENT - - """A gift card status is changed.""" - GIFT_CARD_STATUS_CHANGED - - """A gift card is updated.""" - GIFT_CARD_UPDATED - - """An invoice is deleted.""" - INVOICE_DELETED - - """An invoice for order requested.""" - INVOICE_REQUESTED - - """Invoice has been sent.""" - INVOICE_SENT - LIST_STORED_PAYMENT_METHODS - - """A new menu created.""" - MENU_CREATED - - """A menu is deleted.""" - MENU_DELETED - - """A new menu item created.""" - MENU_ITEM_CREATED - - """A menu item is deleted.""" - MENU_ITEM_DELETED - - """A menu item is updated.""" - MENU_ITEM_UPDATED - - """A menu is updated.""" - MENU_UPDATED - - """ - User notification triggered. - - DEPRECATED: this value will be removed in Saleor 4.0. See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/docs/next/upgrade-guides/notify-user-deprecation - """ - NOTIFY_USER - - """An observability event is created.""" - OBSERVABILITY - - """ - Orders are imported. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - ORDER_BULK_CREATED - - """ - Event called for order tax calculation. - - Added in Saleor 3.6. - """ - ORDER_CALCULATE_TAXES - - """An order is cancelled.""" - ORDER_CANCELLED - - """ - An order is confirmed (status change unconfirmed -> unfulfilled) by a staff user using the OrderConfirm mutation. It also triggers when the user completes the checkout and the shop setting `automatically_confirm_all_new_orders` is enabled. - """ - ORDER_CONFIRMED - - """A new order is placed.""" - ORDER_CREATED - - """An order is expired.""" - ORDER_EXPIRED - - """Filter shipping methods for order.""" - ORDER_FILTER_SHIPPING_METHODS - - """An order is fulfilled.""" - ORDER_FULFILLED - - """Payment is made and an order is fully paid.""" - ORDER_FULLY_PAID - - """ - The order is fully refunded. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - ORDER_FULLY_REFUNDED - - """ - An order metadata is updated. - - Added in Saleor 3.8. - """ - ORDER_METADATA_UPDATED - - """ - Payment has been made. The order may be partially or fully paid. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - ORDER_PAID - - """ - The order received a refund. The order may be partially or fully refunded. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - ORDER_REFUNDED - - """ - An order is updated; triggered for all changes related to an order; covers all other order webhooks, except for ORDER_CREATED. - """ - ORDER_UPDATED - - """A new page is created.""" - PAGE_CREATED - - """A page is deleted.""" - PAGE_DELETED - - """A new page type is created.""" - PAGE_TYPE_CREATED - - """A page type is deleted.""" - PAGE_TYPE_DELETED - - """A page type is updated.""" - PAGE_TYPE_UPDATED - - """A page is updated.""" - PAGE_UPDATED - - """Authorize payment.""" - PAYMENT_AUTHORIZE - - """Capture payment.""" - PAYMENT_CAPTURE - - """Confirm payment.""" - PAYMENT_CONFIRM - PAYMENT_GATEWAY_INITIALIZE_SESSION - PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION - - """Listing available payment gateways.""" - PAYMENT_LIST_GATEWAYS - PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION - PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION - - """Process payment.""" - PAYMENT_PROCESS - - """Refund payment.""" - PAYMENT_REFUND - - """Void payment.""" - PAYMENT_VOID - - """A new permission group is created.""" - PERMISSION_GROUP_CREATED - - """A permission group is deleted.""" - PERMISSION_GROUP_DELETED - - """A permission group is updated.""" - PERMISSION_GROUP_UPDATED - - """A new product is created.""" - PRODUCT_CREATED - - """A product is deleted.""" - PRODUCT_DELETED - - """ - A product export is completed. - - Added in Saleor 3.16. - """ - PRODUCT_EXPORT_COMPLETED - - """ - A new product media is created. - - Added in Saleor 3.12. - """ - PRODUCT_MEDIA_CREATED - - """ - A product media is deleted. - - Added in Saleor 3.12. - """ - PRODUCT_MEDIA_DELETED - - """ - A product media is updated. - - Added in Saleor 3.12. - """ - PRODUCT_MEDIA_UPDATED - - """ - A product metadata is updated. - - Added in Saleor 3.8. - """ - PRODUCT_METADATA_UPDATED - - """A product is updated.""" - PRODUCT_UPDATED - - """A product variant is back in stock.""" - PRODUCT_VARIANT_BACK_IN_STOCK - - """A new product variant is created.""" - PRODUCT_VARIANT_CREATED - - """ - A product variant is deleted. Warning: this event will not be executed when parent product has been deleted. Check PRODUCT_DELETED. - """ - PRODUCT_VARIANT_DELETED - - """ - A product variant metadata is updated. - - Added in Saleor 3.8. - """ - PRODUCT_VARIANT_METADATA_UPDATED - - """A product variant is out of stock.""" - PRODUCT_VARIANT_OUT_OF_STOCK - - """A product variant stock is updated""" - PRODUCT_VARIANT_STOCK_UPDATED - - """A product variant is updated.""" - PRODUCT_VARIANT_UPDATED - - """A promotion is created.""" - PROMOTION_CREATED - - """A promotion is deleted.""" - PROMOTION_DELETED - - """A promotion is deactivated.""" - PROMOTION_ENDED - - """A promotion rule is created.""" - PROMOTION_RULE_CREATED - - """A promotion rule is deleted.""" - PROMOTION_RULE_DELETED - - """A promotion rule is updated.""" - PROMOTION_RULE_UPDATED - - """A promotion is activated.""" - PROMOTION_STARTED - - """A promotion is updated.""" - PROMOTION_UPDATED - - """A sale is created.""" - SALE_CREATED - - """A sale is deleted.""" - SALE_DELETED - - """A sale is activated or deactivated.""" - SALE_TOGGLE - - """A sale is updated.""" - SALE_UPDATED - - """Fetch external shipping methods for checkout.""" - SHIPPING_LIST_METHODS_FOR_CHECKOUT - - """A new shipping price is created.""" - SHIPPING_PRICE_CREATED - - """A shipping price is deleted.""" - SHIPPING_PRICE_DELETED - - """A shipping price is updated.""" - SHIPPING_PRICE_UPDATED - - """A new shipping zone is created.""" - SHIPPING_ZONE_CREATED - - """A shipping zone is deleted.""" - SHIPPING_ZONE_DELETED - - """ - A shipping zone metadata is updated. - - Added in Saleor 3.8. - """ - SHIPPING_ZONE_METADATA_UPDATED - - """A shipping zone is updated.""" - SHIPPING_ZONE_UPDATED - - """ - Shop metadata is updated. - - Added in Saleor 3.15. - """ - SHOP_METADATA_UPDATED - - """A new staff user is created.""" - STAFF_CREATED - - """A staff user is deleted.""" - STAFF_DELETED - - """Setting a new password for the staff account is requested.""" - STAFF_SET_PASSWORD_REQUESTED - - """A staff user is updated.""" - STAFF_UPDATED - STORED_PAYMENT_METHOD_DELETE_REQUESTED - - """ - A thumbnail is created. - - Added in Saleor 3.12. - """ - THUMBNAIL_CREATED - - """ - Event called when cancel has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - TRANSACTION_CANCELATION_REQUESTED - - """ - Event called when charge has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - TRANSACTION_CHARGE_REQUESTED - TRANSACTION_INITIALIZE_SESSION - - """ - Transaction item metadata is updated. - - Added in Saleor 3.8. - """ - TRANSACTION_ITEM_METADATA_UPDATED - TRANSACTION_PROCESS_SESSION - - """ - Event called when refund has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - TRANSACTION_REFUND_REQUESTED - - """A new translation is created.""" - TRANSLATION_CREATED - - """A translation is updated.""" - TRANSLATION_UPDATED - VOUCHER_CODES_CREATED - VOUCHER_CODES_DELETED - - """ - A voucher code export is completed. - - Added in Saleor 3.18. - """ - VOUCHER_CODE_EXPORT_COMPLETED - - """A new voucher created.""" - VOUCHER_CREATED - - """A voucher is deleted.""" - VOUCHER_DELETED - - """ - A voucher metadata is updated. - - Added in Saleor 3.8. - """ - VOUCHER_METADATA_UPDATED - - """A voucher is updated.""" - VOUCHER_UPDATED - - """A new warehouse created.""" - WAREHOUSE_CREATED - - """A warehouse is deleted.""" - WAREHOUSE_DELETED - - """ - A warehouse metadata is updated. - - Added in Saleor 3.8. - """ - WAREHOUSE_METADATA_UPDATED - - """A warehouse is updated.""" - WAREHOUSE_UPDATED -} - -"""Enum determining type of webhook.""" -enum WebhookEventTypeSyncEnum { - """ - Event called for checkout tax calculation. - - Added in Saleor 3.6. - """ - CHECKOUT_CALCULATE_TAXES - - """Filter shipping methods for checkout.""" - CHECKOUT_FILTER_SHIPPING_METHODS - LIST_STORED_PAYMENT_METHODS - - """ - Event called for order tax calculation. - - Added in Saleor 3.6. - """ - ORDER_CALCULATE_TAXES - - """Filter shipping methods for order.""" - ORDER_FILTER_SHIPPING_METHODS - - """Authorize payment.""" - PAYMENT_AUTHORIZE - - """Capture payment.""" - PAYMENT_CAPTURE - - """Confirm payment.""" - PAYMENT_CONFIRM - PAYMENT_GATEWAY_INITIALIZE_SESSION - PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION - - """Listing available payment gateways.""" - PAYMENT_LIST_GATEWAYS - PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION - PAYMENT_METHOD_PROCESS_TOKENIZATION_SESSION - - """Process payment.""" - PAYMENT_PROCESS - - """Refund payment.""" - PAYMENT_REFUND - - """Void payment.""" - PAYMENT_VOID - - """Fetch external shipping methods for checkout.""" - SHIPPING_LIST_METHODS_FOR_CHECKOUT - STORED_PAYMENT_METHOD_DELETE_REQUESTED - - """ - Event called when cancel has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - TRANSACTION_CANCELATION_REQUESTED - - """ - Event called when charge has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - TRANSACTION_CHARGE_REQUESTED - TRANSACTION_INITIALIZE_SESSION - TRANSACTION_PROCESS_SESSION - - """ - Event called when refund has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - TRANSACTION_REFUND_REQUESTED -} - -"""An enumeration.""" -enum WebhookSampleEventTypeEnum { - ACCOUNT_CHANGE_EMAIL_REQUESTED - ACCOUNT_CONFIRMATION_REQUESTED - ACCOUNT_CONFIRMED - ACCOUNT_DELETED - ACCOUNT_DELETE_REQUESTED - ACCOUNT_EMAIL_CHANGED - ACCOUNT_SET_PASSWORD_REQUESTED - ADDRESS_CREATED - ADDRESS_DELETED - ADDRESS_UPDATED - APP_DELETED - APP_INSTALLED - APP_STATUS_CHANGED - APP_UPDATED - ATTRIBUTE_CREATED - ATTRIBUTE_DELETED - ATTRIBUTE_UPDATED - ATTRIBUTE_VALUE_CREATED - ATTRIBUTE_VALUE_DELETED - ATTRIBUTE_VALUE_UPDATED - CATEGORY_CREATED - CATEGORY_DELETED - CATEGORY_UPDATED - CHANNEL_CREATED - CHANNEL_DELETED - CHANNEL_METADATA_UPDATED - CHANNEL_STATUS_CHANGED - CHANNEL_UPDATED - CHECKOUT_CREATED - CHECKOUT_FULLY_PAID - CHECKOUT_METADATA_UPDATED - CHECKOUT_UPDATED - COLLECTION_CREATED - COLLECTION_DELETED - COLLECTION_METADATA_UPDATED - COLLECTION_UPDATED - CUSTOMER_CREATED - CUSTOMER_DELETED - CUSTOMER_METADATA_UPDATED - CUSTOMER_UPDATED - DRAFT_ORDER_CREATED - DRAFT_ORDER_DELETED - DRAFT_ORDER_UPDATED - FULFILLMENT_APPROVED - FULFILLMENT_CANCELED - FULFILLMENT_CREATED - FULFILLMENT_METADATA_UPDATED - FULFILLMENT_TRACKING_NUMBER_UPDATED - GIFT_CARD_CREATED - GIFT_CARD_DELETED - GIFT_CARD_EXPORT_COMPLETED - GIFT_CARD_METADATA_UPDATED - GIFT_CARD_SENT - GIFT_CARD_STATUS_CHANGED - GIFT_CARD_UPDATED - INVOICE_DELETED - INVOICE_REQUESTED - INVOICE_SENT - MENU_CREATED - MENU_DELETED - MENU_ITEM_CREATED - MENU_ITEM_DELETED - MENU_ITEM_UPDATED - MENU_UPDATED - NOTIFY_USER - OBSERVABILITY - ORDER_BULK_CREATED - ORDER_CANCELLED - ORDER_CONFIRMED - ORDER_CREATED - ORDER_EXPIRED - ORDER_FULFILLED - ORDER_FULLY_PAID - ORDER_FULLY_REFUNDED - ORDER_METADATA_UPDATED - ORDER_PAID - ORDER_REFUNDED - ORDER_UPDATED - PAGE_CREATED - PAGE_DELETED - PAGE_TYPE_CREATED - PAGE_TYPE_DELETED - PAGE_TYPE_UPDATED - PAGE_UPDATED - PERMISSION_GROUP_CREATED - PERMISSION_GROUP_DELETED - PERMISSION_GROUP_UPDATED - PRODUCT_CREATED - PRODUCT_DELETED - PRODUCT_EXPORT_COMPLETED - PRODUCT_MEDIA_CREATED - PRODUCT_MEDIA_DELETED - PRODUCT_MEDIA_UPDATED - PRODUCT_METADATA_UPDATED - PRODUCT_UPDATED - PRODUCT_VARIANT_BACK_IN_STOCK - PRODUCT_VARIANT_CREATED - PRODUCT_VARIANT_DELETED - PRODUCT_VARIANT_METADATA_UPDATED - PRODUCT_VARIANT_OUT_OF_STOCK - PRODUCT_VARIANT_STOCK_UPDATED - PRODUCT_VARIANT_UPDATED - PROMOTION_CREATED - PROMOTION_DELETED - PROMOTION_ENDED - PROMOTION_RULE_CREATED - PROMOTION_RULE_DELETED - PROMOTION_RULE_UPDATED - PROMOTION_STARTED - PROMOTION_UPDATED - SALE_CREATED - SALE_DELETED - SALE_TOGGLE - SALE_UPDATED - SHIPPING_PRICE_CREATED - SHIPPING_PRICE_DELETED - SHIPPING_PRICE_UPDATED - SHIPPING_ZONE_CREATED - SHIPPING_ZONE_DELETED - SHIPPING_ZONE_METADATA_UPDATED - SHIPPING_ZONE_UPDATED - SHOP_METADATA_UPDATED - STAFF_CREATED - STAFF_DELETED - STAFF_SET_PASSWORD_REQUESTED - STAFF_UPDATED - THUMBNAIL_CREATED - TRANSACTION_ITEM_METADATA_UPDATED - TRANSLATION_CREATED - TRANSLATION_UPDATED - VOUCHER_CODES_CREATED - VOUCHER_CODES_DELETED - VOUCHER_CODE_EXPORT_COMPLETED - VOUCHER_CREATED - VOUCHER_DELETED - VOUCHER_METADATA_UPDATED - VOUCHER_UPDATED - WAREHOUSE_CREATED - WAREHOUSE_DELETED - WAREHOUSE_METADATA_UPDATED - WAREHOUSE_UPDATED -} - -""" -Trigger a webhook event. Supports a single event (the first, if multiple provided in the `webhook.subscription_query`). Requires permission relevant to processed event. Successfully delivered webhook returns `delivery` with status='PENDING' and empty payload. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - -Requires one of the following permissions: AUTHENTICATED_STAFF_USER. -""" -type WebhookTrigger { - delivery: EventDelivery - errors: [WebhookTriggerError!]! -} - -type WebhookTriggerError { - """The error code.""" - code: WebhookTriggerErrorCode! - - """ - Name of a field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - """ - field: String - - """The error message.""" - message: String -} - -"""An enumeration.""" -enum WebhookTriggerErrorCode { - GRAPHQL_ERROR - INVALID_ID - MISSING_EVENT - MISSING_PERMISSION - MISSING_QUERY - MISSING_SUBSCRIPTION - NOT_FOUND - SYNTAX - TYPE_NOT_SUPPORTED - UNABLE_TO_PARSE -} - -""" -Updates a webhook subscription. - -Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. -""" -type WebhookUpdate { - errors: [WebhookError!]! - webhook: Webhook - webhookErrors: [WebhookError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") -} - -input WebhookUpdateInput { - """ID of the app to which webhook belongs.""" - app: ID - - """The asynchronous events that webhook wants to subscribe.""" - asyncEvents: [WebhookEventTypeAsyncEnum!] - - """ - Custom headers, which will be added to HTTP request. There is a limitation of 5 headers per webhook and 998 characters per header.Only `X-*`, `Authorization*`, and `BrokerProperties` keys are allowed. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ - customHeaders: JSONString - - """ - The events that webhook wants to subscribe. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead. - """ - events: [WebhookEventTypeEnum!] - - """Determine if webhook will be set active or not.""" - isActive: Boolean - - """The new name of the webhook.""" - name: String - - """ - Subscription query used to define a webhook payload. - - Added in Saleor 3.2. - """ - query: String - - """ - Use to create a hash signature with each payload. - - DEPRECATED: this field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. - """ - secretKey: String - - """The synchronous events that webhook wants to subscribe.""" - syncEvents: [WebhookEventTypeSyncEnum!] - - """The url to receive the payload.""" - targetUrl: String -} - -"""Represents weight value in a specific weight unit.""" -type Weight { - """Weight unit.""" - unit: WeightUnitsEnum! - - """Weight value. Returns a value with maximal three decimal places""" - value: Float! -} - -scalar WeightScalar - -"""An enumeration.""" -enum WeightUnitsEnum { - G - KG - LB - OZ - TONNE -} - -"""_Any value scalar as defined by Federation spec.""" -scalar _Any - -"""_Entity union as defined by Federation spec.""" -union _Entity = Address | App | Category | Collection | Group | Order | PageType | Product | ProductMedia | ProductType | ProductVariant | User - -"""_Service manifest as defined by Federation spec.""" -type _Service { - sdl: String -} \ No newline at end of file diff --git a/graphql/fragments/order-filter-shipping-methods.graphql b/graphql/fragments/order-filter-shipping-methods.graphql new file mode 100644 index 00000000..bf300824 --- /dev/null +++ b/graphql/fragments/order-filter-shipping-methods.graphql @@ -0,0 +1,9 @@ +fragment OrderFilterShippingMethodsPayload on OrderFilterShippingMethods { + order { + id + } + shippingMethods { + id + name + } +} diff --git a/graphql/queries/.gitkeep b/graphql/queries/.gitkeep deleted file mode 100644 index e69de29b..00000000 diff --git a/graphql/queries/last-order.graphql b/graphql/queries/last-order.graphql new file mode 100644 index 00000000..1004b4d7 --- /dev/null +++ b/graphql/queries/last-order.graphql @@ -0,0 +1,29 @@ +query LastOrder { + orders(first: 1) { + edges { + node { + id + number + created + user { + firstName + lastName + } + shippingAddress { + country { + country + } + } + total { + gross { + amount + currency + } + } + lines { + id + } + } + } + } +} diff --git a/graphql/schema.graphql b/graphql/schema.graphql index fb6981de..30863aa2 100644 --- a/graphql/schema.graphql +++ b/graphql/schema.graphql @@ -33,7 +33,7 @@ type Query { Requires one of the following permissions: MANAGE_APPS. """ - webhookEvents: [WebhookEvent!] @doc(category: "Webhooks") @deprecated(reason: "This field will be removed in Saleor 4.0. Use `WebhookEventTypeAsyncEnum` and `WebhookEventTypeSyncEnum` to get available event types.") + webhookEvents: [WebhookEvent!] @doc(category: "Webhooks") @deprecated(reason: "Use `WebhookEventTypeAsyncEnum` and `WebhookEventTypeSyncEnum` to get available event types.") """ Retrieve a sample payload for a given webhook event based on real data. It can be useful for some integrations where sample payload is required. @@ -52,11 +52,7 @@ type Query { """ID of a warehouse.""" id: ID - """ - External ID of a warehouse. - - Added in Saleor 3.10. - """ + """External ID of a warehouse.""" externalReference: String ): Warehouse @doc(category: "Products") @@ -128,8 +124,6 @@ type Query { """ Look up a tax configuration. - Added in Saleor 3.9. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ taxConfiguration( @@ -140,8 +134,6 @@ type Query { """ List of tax configurations. - Added in Saleor 3.9. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ taxConfigurations( @@ -168,8 +160,6 @@ type Query { """ Look up a tax class. - Added in Saleor 3.9. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ taxClass( @@ -180,8 +170,6 @@ type Query { """ List of tax classes. - Added in Saleor 3.9. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ taxClasses( @@ -264,7 +252,7 @@ type Query { Requires one of the following permissions: MANAGE_ORDERS. """ - orderSettings: OrderSettings @doc(category: "Orders") @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `channel` query to fetch the `orderSettings` field instead.") + orderSettings: OrderSettings @doc(category: "Orders") @deprecated(reason: "Use the `channel` query to fetch the `orderSettings` field instead.") """ Gift card related settings from site settings. @@ -353,13 +341,7 @@ type Query { """Filtering options for categories.""" filter: CategoryFilterInput - """ - Where filtering options. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Where filtering options.""" where: CategoryWhereInput """Sort categories.""" @@ -392,18 +374,32 @@ type Query { """Slug of the category""" slug: String + + """ + Language code of the category slug, omit to use primary slug. + + Added in Saleor 3.21. + """ + slugLanguageCode: LanguageCodeEnum ): Category @doc(category: "Products") """ - Look up a collection by ID. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. + Look up a collection by ID or slug. If slugLanguageCode is provided, category will be fetched by slug translation. Requires one of the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. """ collection( """ID of the collection.""" id: ID - """Slug of the category""" + """Slug of the collection""" slug: String + """ + Language code of the collection slug, omit to use primary slug. + + Added in Saleor 3.21. + """ + slugLanguageCode: LanguageCodeEnum + """Slug of a channel for which the data should be returned.""" channel: String ): Collection @doc(category: "Products") @@ -415,13 +411,7 @@ type Query { """Filtering options for collections.""" filter: CollectionFilterInput - """ - Where filtering options. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Where filtering options.""" where: CollectionWhereInput """Sort collections.""" @@ -458,10 +448,13 @@ type Query { slug: String """ - External ID of the product. + Language code of the product slug, omit to use primary slug. - Added in Saleor 3.10. + Added in Saleor 3.21. """ + slugLanguageCode: LanguageCodeEnum + + """External ID of the product.""" externalReference: String """Slug of a channel for which the data should be returned.""" @@ -475,23 +468,13 @@ type Query { """Filtering options for products.""" filter: ProductFilterInput - """ - Where filtering options. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Where filtering options.""" where: ProductWhereInput """Sort products.""" sortBy: ProductOrder - """ - Search products. - - Added in Saleor 3.14. - """ + """Search products.""" search: String """Slug of a channel for which the data should be returned.""" @@ -555,11 +538,7 @@ type Query { """SKU of the product variant.""" sku: String - """ - External ID of the product. - - Added in Saleor 3.10. - """ + """External ID of the product.""" externalReference: String """Slug of a channel for which the data should be returned.""" @@ -579,13 +558,7 @@ type Query { """Filtering options for product variant.""" filter: ProductVariantFilterInput - """ - Where filtering options. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Where filtering options.""" where: ProductVariantWhereInput """Sort products variants.""" @@ -635,7 +608,7 @@ type Query { Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. """ last: Int - ): ProductVariantCountableConnection @doc(category: "Products") @deprecated(reason: "This field will be removed in Saleor 4.0.") + ): ProductVariantCountableConnection @doc(category: "Products") @deprecated """ Look up a payment by ID. @@ -676,10 +649,6 @@ type Query { """ Look up a transaction by ID. - Added in Saleor 3.6. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: HANDLE_PAYMENTS. """ transaction( @@ -701,6 +670,13 @@ type Query { """The slug of the page.""" slug: String + + """ + Language code of the page slug, omit to use primary slug. + + Added in Saleor 3.21. + """ + slugLanguageCode: LanguageCodeEnum ): Page @doc(category: "Pages") """List of the shop's pages.""" @@ -780,7 +756,7 @@ type Query { Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. """ last: Int - ): OrderEventCountableConnection @doc(category: "Orders") @deprecated(reason: "This field will be removed in Saleor 4.0.") + ): OrderEventCountableConnection @doc(category: "Orders") @deprecated """Look up an order by ID or external reference.""" order( @@ -790,15 +766,13 @@ type Query { """ External ID of an order. - Added in Saleor 3.10.. - Requires one of the following permissions: MANAGE_ORDERS. """ externalReference: String ): Order @doc(category: "Orders") """ - List of orders. + List of orders. The query will not initiate any external requests, including filtering available shipping methods, or performing external tax calculations. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -830,7 +804,7 @@ type Query { ): OrderCountableConnection @doc(category: "Orders") """ - List of draft orders. + List of draft orders. The query will not initiate any external requests, including filtering available shipping methods, or performing external tax calculations. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -869,13 +843,13 @@ type Query { """Slug of a channel for which the data should be returned.""" channel: String - ): TaxedMoney @doc(category: "Orders") @deprecated(reason: "This field will be removed in Saleor 4.0.") + ): TaxedMoney @doc(category: "Orders") @deprecated """Look up an order by token.""" orderByToken( """The order's token.""" token: UUID! - ): Order @doc(category: "Orders") @deprecated(reason: "This field will be removed in Saleor 4.0.") + ): Order @doc(category: "Orders") @deprecated """Look up a navigation menu by ID or name.""" menu( @@ -901,9 +875,9 @@ type Query { sortBy: MenuSortingInput """ - Filtering options for menus. + Filtering options for menus. - `slug`: This field will be removed in Saleor 4.0. Use `slugs` instead. + `slug`: Use `slugs` instead. """ filter: MenuFilterInput @@ -977,26 +951,14 @@ type Query { Requires one of the following permissions: MANAGE_GIFT_CARD. """ giftCards( - """ - Sort gift cards. - - Added in Saleor 3.1. - """ + """Sort gift cards.""" sortBy: GiftCardSortingInput - """ - Filtering options for gift cards. - - Added in Saleor 3.1. - """ + """Filtering options for gift cards.""" filter: GiftCardFilterInput """ Search gift cards by email and name of user, who created or used the gift card, and by code. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ search: String @@ -1020,8 +982,6 @@ type Query { """ List of gift card currencies. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_GIFT_CARD. """ giftCardCurrencies: [String!]! @doc(category: "Gift cards") @@ -1029,8 +989,6 @@ type Query { """ List of gift card tags. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_GIFT_CARD. """ giftCardTags( @@ -1104,7 +1062,7 @@ type Query { """Slug of a channel for which the data should be returned.""" channel: String - ): Sale @doc(category: "Discounts") @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `promotion` query instead.") + ): Sale @doc(category: "Discounts") @deprecated(reason: "Use the `promotion` query instead.") """ List of the shop's sales. @@ -1118,12 +1076,8 @@ type Query { """Sort sales.""" sortBy: SaleSortingInput - """ - Search sales by name, value or type. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `filter.search` input instead. - """ - query: String + """Search sales by name, value or type.""" + query: String @deprecated(reason: "Use `filter.search` input instead.") """Slug of a channel for which the data should be returned.""" channel: String @@ -1143,7 +1097,7 @@ type Query { Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. """ last: Int - ): SaleCountableConnection @doc(category: "Discounts") @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `promotions` query instead.") + ): SaleCountableConnection @doc(category: "Discounts") @deprecated(reason: "Use the `promotions` query instead.") """ Look up a voucher by ID. @@ -1170,12 +1124,8 @@ type Query { """Sort voucher.""" sortBy: VoucherSortingInput - """ - Search vouchers by name or code. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `filter.search` input instead. - """ - query: String + """Search vouchers by name or code.""" + query: String @deprecated(reason: "Use `filter.search` input instead.") """Slug of a channel for which the data should be returned.""" channel: String @@ -1200,10 +1150,6 @@ type Query { """ Look up a promotion by ID. - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_DISCOUNTS. """ promotion( @@ -1214,10 +1160,6 @@ type Query { """ List of the promotions. - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_DISCOUNTS. """ promotions( @@ -1284,7 +1226,7 @@ type Query { ): ExportFileCountableConnection """List of all tax rates available from tax gateway.""" - taxTypes: [TaxType!] @doc(category: "Taxes") @deprecated(reason: "This field will be removed in Saleor 4.0. Use `taxClasses` field instead.") + taxTypes: [TaxType!] @doc(category: "Taxes") @deprecated(reason: "Use `taxClasses` field instead.") """ Look up a checkout by id. @@ -1292,39 +1234,23 @@ type Query { Requires one of the following permissions to query a checkout, if a checkout is in inactive channel: MANAGE_CHECKOUTS, IMPERSONATE_USER, HANDLE_PAYMENTS. """ checkout( - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID - """ - The checkout's token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """The checkout's token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): Checkout @doc(category: "Checkout") """ - List of checkouts. + List of checkouts. The query will not initiate any external requests, including fetching external shipping methods, filtering available shipping methods, or performing external tax calculations. Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS. """ checkouts( - """ - Sort checkouts. - - Added in Saleor 3.1. - """ + """Sort checkouts.""" sortBy: CheckoutSortingInput - """ - Filtering options for checkouts. - - Added in Saleor 3.1. - """ + """Filtering options for checkouts.""" filter: CheckoutFilterInput """Slug of a channel for which the data should be returned.""" @@ -1348,7 +1274,7 @@ type Query { ): CheckoutCountableConnection @doc(category: "Checkout") """ - List of checkout lines. + List of checkout lines. The query will not initiate any external requests, including fetching external shipping methods, filtering available shipping methods, or performing external tax calculations. Requires one of the following permissions: MANAGE_CHECKOUTS. """ @@ -1375,11 +1301,7 @@ type Query { """ID of the channel.""" id: ID - """ - Slug of the channel. - - Added in Saleor 3.6. - """ + """Slug of the channel.""" slug: String ): Channel @doc(category: "Channels") @@ -1395,20 +1317,10 @@ type Query { """Filtering options for attributes.""" filter: AttributeFilterInput - """ - Filtering options for attributes. - - Added in Saleor 3.11. - """ + """Filtering options for attributes.""" where: AttributeWhereInput - """ - Search attributes. - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Search attributes.""" search: String """Sorting options for attributes.""" @@ -1442,11 +1354,7 @@ type Query { """Slug of the attribute.""" slug: String - """ - External ID of the attribute. - - Added in Saleor 3.10. - """ + """External ID of the attribute.""" externalReference: String ): Attribute @doc(category: "Attributes") @@ -1499,8 +1407,6 @@ type Query { """ List of all extensions. - Added in Saleor 3.1. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ appExtensions( @@ -1527,8 +1433,6 @@ type Query { """ Look up an app extension by ID. - Added in Saleor 3.1. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ appExtension( @@ -1673,11 +1577,7 @@ type Query { """Email address of the user.""" email: String - """ - External ID of the user. - - Added in Saleor 3.10. - """ + """External ID of the user.""" externalReference: String ): User @doc(category: "Users") _entities(representations: [_Any]): [_Entity] @@ -1693,7 +1593,7 @@ type Webhook implements Node @doc(category: "Webhooks") { name: String """List of webhook events.""" - events: [WebhookEvent!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead.") + events: [WebhookEvent!]! @deprecated(reason: "Use `asyncEvents` or `syncEvents` instead.") """List of synchronous webhook events.""" syncEvents: [WebhookEventSync!]! @@ -1736,18 +1636,12 @@ type Webhook implements Node @doc(category: "Webhooks") { isActive: Boolean! """Used to create a hash signature for each payload.""" - secretKey: String @deprecated(reason: "This field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS.") + secretKey: String @deprecated(reason: "As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS.") """Used to define payloads for specific events.""" subscriptionQuery: String - """ - Custom headers, which will be added to HTTP request. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Custom headers, which will be added to HTTP request.""" customHeaders: JSONString } @@ -1768,12 +1662,8 @@ type WebhookEvent @doc(category: "Webhooks") { """Enum determining type of webhook.""" enum WebhookEventTypeEnum @doc(category: "Webhooks") { - """ - All the events. - - DEPRECATED: this value will be removed in Saleor 4.0. - """ - ANY_EVENTS + """All the events.""" + ANY_EVENTS @deprecated """An account confirmation is requested.""" ACCOUNT_CONFIRMATION_REQUESTED @@ -1868,30 +1758,16 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """A gift card is deleted.""" GIFT_CARD_DELETED - """ - A gift card has been sent. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """A gift card has been sent.""" GIFT_CARD_SENT """A gift card status is changed.""" GIFT_CARD_STATUS_CHANGED - """ - A gift card metadata is updated. - - Added in Saleor 3.8. - """ + """A gift card metadata is updated.""" GIFT_CARD_METADATA_UPDATED - """ - A gift card export is completed. - - Added in Saleor 3.16. - """ + """A gift card export is completed.""" GIFT_CARD_EXPORT_COMPLETED """A new menu created.""" @@ -1920,13 +1796,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """ ORDER_CONFIRMED - """ - Payment has been made. The order may be partially or fully paid. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Payment has been made. The order may be partially or fully paid.""" ORDER_PAID """Payment is made and an order is fully paid.""" @@ -1934,20 +1804,10 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """ The order received a refund. The order may be partially or fully refunded. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ ORDER_REFUNDED - """ - The order is fully refunded. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The order is fully refunded.""" ORDER_FULLY_REFUNDED """ @@ -1964,20 +1824,10 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """An order is fulfilled.""" ORDER_FULFILLED - """ - An order metadata is updated. - - Added in Saleor 3.8. - """ + """An order metadata is updated.""" ORDER_METADATA_UPDATED - """ - Orders are imported. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Orders are imported.""" ORDER_BULK_CREATED """A new fulfillment is created.""" @@ -1989,11 +1839,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """A fulfillment is approved.""" FULFILLMENT_APPROVED - """ - A fulfillment metadata is updated. - - Added in Saleor 3.8. - """ + """A fulfillment metadata is updated.""" FULFILLMENT_METADATA_UPDATED FULFILLMENT_TRACKING_NUMBER_UPDATED @@ -2060,11 +1906,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """A customer account is deleted.""" CUSTOMER_DELETED - """ - A customer account metadata is updated. - - Added in Saleor 3.8. - """ + """A customer account metadata is updated.""" CUSTOMER_METADATA_UPDATED """A new collection is created.""" @@ -2076,11 +1918,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """A collection is deleted.""" COLLECTION_DELETED - """ - A collection metadata is updated. - - Added in Saleor 3.8. - """ + """A collection metadata is updated.""" COLLECTION_METADATA_UPDATED """A new product is created.""" @@ -2092,39 +1930,19 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """A product is deleted.""" PRODUCT_DELETED - """ - A product metadata is updated. - - Added in Saleor 3.8. - """ + """A product metadata is updated.""" PRODUCT_METADATA_UPDATED - """ - A product export is completed. - - Added in Saleor 3.16. - """ + """A product export is completed.""" PRODUCT_EXPORT_COMPLETED - """ - A new product media is created. - - Added in Saleor 3.12. - """ + """A new product media is created.""" PRODUCT_MEDIA_CREATED - """ - A product media is updated. - - Added in Saleor 3.12. - """ + """A product media is updated.""" PRODUCT_MEDIA_UPDATED - """ - A product media is deleted. - - Added in Saleor 3.12. - """ + """A product media is deleted.""" PRODUCT_MEDIA_DELETED """A new product variant is created.""" @@ -2138,11 +1956,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """ PRODUCT_VARIANT_DELETED - """ - A product variant metadata is updated. - - Added in Saleor 3.8. - """ + """A product variant metadata is updated.""" PRODUCT_VARIANT_METADATA_UPDATED """A product variant is out of stock.""" @@ -2163,19 +1977,11 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { CHECKOUT_UPDATED CHECKOUT_FULLY_PAID - """ - A checkout metadata is updated. - - Added in Saleor 3.8. - """ + """A checkout metadata is updated.""" CHECKOUT_METADATA_UPDATED - """ - User notification triggered. - - DEPRECATED: this value will be removed in Saleor 4.0. See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/docs/next/upgrade-guides/notify-user-deprecation - """ - NOTIFY_USER + """User notification triggered.""" + NOTIFY_USER @deprecated(reason: "See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/upgrade-guides/core/3-16-to-3-17#migrating-from-notify_user") """A new page is created.""" PAGE_CREATED @@ -2222,11 +2028,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """A shipping zone is deleted.""" SHIPPING_ZONE_DELETED - """ - A shipping zone metadata is updated. - - Added in Saleor 3.8. - """ + """A shipping zone metadata is updated.""" SHIPPING_ZONE_METADATA_UPDATED """A new staff user is created.""" @@ -2241,11 +2043,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """Setting a new password for the staff account is requested.""" STAFF_SET_PASSWORD_REQUESTED - """ - Transaction item metadata is updated. - - Added in Saleor 3.8. - """ + """Transaction item metadata is updated.""" TRANSACTION_ITEM_METADATA_UPDATED """A new translation is created.""" @@ -2263,11 +2061,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """A warehouse is deleted.""" WAREHOUSE_DELETED - """ - A warehouse metadata is updated. - - Added in Saleor 3.8. - """ + """A warehouse metadata is updated.""" WAREHOUSE_METADATA_UPDATED """A new voucher created.""" @@ -2281,11 +2075,7 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { VOUCHER_CODES_CREATED VOUCHER_CODES_DELETED - """ - A voucher metadata is updated. - - Added in Saleor 3.8. - """ + """A voucher metadata is updated.""" VOUCHER_METADATA_UPDATED """ @@ -2298,18 +2088,10 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """An observability event is created.""" OBSERVABILITY - """ - A thumbnail is created. - - Added in Saleor 3.12. - """ + """A thumbnail is created.""" THUMBNAIL_CREATED - """ - Shop metadata is updated. - - Added in Saleor 3.15. - """ + """Shop metadata is updated.""" SHOP_METADATA_UPDATED """Listing available payment gateways.""" @@ -2333,45 +2115,19 @@ enum WebhookEventTypeEnum @doc(category: "Webhooks") { """Process payment.""" PAYMENT_PROCESS - """ - Event called for checkout tax calculation. - - Added in Saleor 3.6. - """ + """Event called for checkout tax calculation.""" CHECKOUT_CALCULATE_TAXES - """ - Event called for order tax calculation. - - Added in Saleor 3.6. - """ + """Event called for order tax calculation.""" ORDER_CALCULATE_TAXES - """ - Event called when charge has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Event called when charge has been requested for transaction.""" TRANSACTION_CHARGE_REQUESTED - """ - Event called when refund has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Event called when refund has been requested for transaction.""" TRANSACTION_REFUND_REQUESTED - """ - Event called when cancel has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Event called when cancel has been requested for transaction.""" TRANSACTION_CANCELATION_REQUESTED """Fetch external shipping methods for checkout.""" @@ -2424,45 +2180,19 @@ enum WebhookEventTypeSyncEnum @doc(category: "Webhooks") { """Process payment.""" PAYMENT_PROCESS - """ - Event called for checkout tax calculation. - - Added in Saleor 3.6. - """ + """Event called for checkout tax calculation.""" CHECKOUT_CALCULATE_TAXES - """ - Event called for order tax calculation. - - Added in Saleor 3.6. - """ + """Event called for order tax calculation.""" ORDER_CALCULATE_TAXES - """ - Event called when charge has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Event called when charge has been requested for transaction.""" TRANSACTION_CHARGE_REQUESTED - """ - Event called when refund has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Event called when refund has been requested for transaction.""" TRANSACTION_REFUND_REQUESTED - """ - Event called when cancel has been requested for transaction. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Event called when cancel has been requested for transaction.""" TRANSACTION_CANCELATION_REQUESTED """Fetch external shipping methods for checkout.""" @@ -2494,12 +2224,8 @@ type WebhookEventAsync @doc(category: "Webhooks") { """Enum determining type of webhook.""" enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { - """ - All the events. - - DEPRECATED: this value will be removed in Saleor 4.0. - """ - ANY_EVENTS + """All the events.""" + ANY_EVENTS @deprecated """An account confirmation is requested.""" ACCOUNT_CONFIRMATION_REQUESTED @@ -2594,30 +2320,16 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """A gift card is deleted.""" GIFT_CARD_DELETED - """ - A gift card has been sent. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """A gift card has been sent.""" GIFT_CARD_SENT """A gift card status is changed.""" GIFT_CARD_STATUS_CHANGED - """ - A gift card metadata is updated. - - Added in Saleor 3.8. - """ + """A gift card metadata is updated.""" GIFT_CARD_METADATA_UPDATED - """ - A gift card export is completed. - - Added in Saleor 3.16. - """ + """A gift card export is completed.""" GIFT_CARD_EXPORT_COMPLETED """A new menu created.""" @@ -2646,13 +2358,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """ ORDER_CONFIRMED - """ - Payment has been made. The order may be partially or fully paid. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Payment has been made. The order may be partially or fully paid.""" ORDER_PAID """Payment is made and an order is fully paid.""" @@ -2660,20 +2366,10 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """ The order received a refund. The order may be partially or fully refunded. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ ORDER_REFUNDED - """ - The order is fully refunded. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The order is fully refunded.""" ORDER_FULLY_REFUNDED """ @@ -2690,20 +2386,10 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """An order is fulfilled.""" ORDER_FULFILLED - """ - An order metadata is updated. - - Added in Saleor 3.8. - """ + """An order metadata is updated.""" ORDER_METADATA_UPDATED - """ - Orders are imported. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Orders are imported.""" ORDER_BULK_CREATED """A new fulfillment is created.""" @@ -2715,11 +2401,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """A fulfillment is approved.""" FULFILLMENT_APPROVED - """ - A fulfillment metadata is updated. - - Added in Saleor 3.8. - """ + """A fulfillment metadata is updated.""" FULFILLMENT_METADATA_UPDATED FULFILLMENT_TRACKING_NUMBER_UPDATED @@ -2786,11 +2468,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """A customer account is deleted.""" CUSTOMER_DELETED - """ - A customer account metadata is updated. - - Added in Saleor 3.8. - """ + """A customer account metadata is updated.""" CUSTOMER_METADATA_UPDATED """A new collection is created.""" @@ -2802,11 +2480,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """A collection is deleted.""" COLLECTION_DELETED - """ - A collection metadata is updated. - - Added in Saleor 3.8. - """ + """A collection metadata is updated.""" COLLECTION_METADATA_UPDATED """A new product is created.""" @@ -2818,39 +2492,19 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """A product is deleted.""" PRODUCT_DELETED - """ - A product metadata is updated. - - Added in Saleor 3.8. - """ + """A product metadata is updated.""" PRODUCT_METADATA_UPDATED - """ - A product export is completed. - - Added in Saleor 3.16. - """ + """A product export is completed.""" PRODUCT_EXPORT_COMPLETED - """ - A new product media is created. - - Added in Saleor 3.12. - """ + """A new product media is created.""" PRODUCT_MEDIA_CREATED - """ - A product media is updated. - - Added in Saleor 3.12. - """ + """A product media is updated.""" PRODUCT_MEDIA_UPDATED - """ - A product media is deleted. - - Added in Saleor 3.12. - """ + """A product media is deleted.""" PRODUCT_MEDIA_DELETED """A new product variant is created.""" @@ -2864,11 +2518,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """ PRODUCT_VARIANT_DELETED - """ - A product variant metadata is updated. - - Added in Saleor 3.8. - """ + """A product variant metadata is updated.""" PRODUCT_VARIANT_METADATA_UPDATED """A product variant is out of stock.""" @@ -2889,19 +2539,11 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { CHECKOUT_UPDATED CHECKOUT_FULLY_PAID - """ - A checkout metadata is updated. - - Added in Saleor 3.8. - """ + """A checkout metadata is updated.""" CHECKOUT_METADATA_UPDATED - """ - User notification triggered. - - DEPRECATED: this value will be removed in Saleor 4.0. See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/docs/next/upgrade-guides/notify-user-deprecation - """ - NOTIFY_USER + """User notification triggered.""" + NOTIFY_USER @deprecated(reason: "See the docs for more details about migrating from NOTIFY_USER to other events: https://docs.saleor.io/upgrade-guides/core/3-16-to-3-17#migrating-from-notify_user") """A new page is created.""" PAGE_CREATED @@ -2948,11 +2590,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """A shipping zone is deleted.""" SHIPPING_ZONE_DELETED - """ - A shipping zone metadata is updated. - - Added in Saleor 3.8. - """ + """A shipping zone metadata is updated.""" SHIPPING_ZONE_METADATA_UPDATED """A new staff user is created.""" @@ -2967,11 +2605,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """Setting a new password for the staff account is requested.""" STAFF_SET_PASSWORD_REQUESTED - """ - Transaction item metadata is updated. - - Added in Saleor 3.8. - """ + """Transaction item metadata is updated.""" TRANSACTION_ITEM_METADATA_UPDATED """A new translation is created.""" @@ -2989,11 +2623,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """A warehouse is deleted.""" WAREHOUSE_DELETED - """ - A warehouse metadata is updated. - - Added in Saleor 3.8. - """ + """A warehouse metadata is updated.""" WAREHOUSE_METADATA_UPDATED """A new voucher created.""" @@ -3007,11 +2637,7 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { VOUCHER_CODES_CREATED VOUCHER_CODES_DELETED - """ - A voucher metadata is updated. - - Added in Saleor 3.8. - """ + """A voucher metadata is updated.""" VOUCHER_METADATA_UPDATED """ @@ -3024,18 +2650,10 @@ enum WebhookEventTypeAsyncEnum @doc(category: "Webhooks") { """An observability event is created.""" OBSERVABILITY - """ - A thumbnail is created. - - Added in Saleor 3.12. - """ + """A thumbnail is created.""" THUMBNAIL_CREATED - """ - Shop metadata is updated. - - Added in Saleor 3.15. - """ + """Shop metadata is updated.""" SHOP_METADATA_UPDATED } @@ -3051,15 +2669,11 @@ type App implements Node & ObjectWithMetadata @doc(category: "Apps") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -3070,15 +2684,11 @@ type App implements Node & ObjectWithMetadata @doc(category: "Apps") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -3122,7 +2732,7 @@ type App implements Node & ObjectWithMetadata @doc(category: "Apps") { aboutApp: String """Description of the data privacy defined for this app.""" - dataPrivacy: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `dataPrivacyUrl` instead.") + dataPrivacy: String @deprecated(reason: "Use `dataPrivacyUrl` instead.") """URL to details about the privacy policy on the app owner page.""" dataPrivacyUrl: String @@ -3134,16 +2744,12 @@ type App implements Node & ObjectWithMetadata @doc(category: "Apps") { supportUrl: String """URL to iframe with the configuration for the app.""" - configurationUrl: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `appUrl` instead.") + configurationUrl: String @deprecated(reason: "Use `appUrl` instead.") """URL to iframe with the app.""" appUrl: String - """ - URL to manifest used during app's installation. - - Added in Saleor 3.5. - """ + """URL to manifest used during app's installation.""" manifestUrl: String """Version number of the app.""" @@ -3152,30 +2758,28 @@ type App implements Node & ObjectWithMetadata @doc(category: "Apps") { """JWT token used to authenticate by third-party app.""" accessToken: String - """ - The App's author name. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The App's author name.""" author: String + """App's dashboard extensions.""" + extensions: [AppExtension!]! + + """App's brand data.""" + brand: AppBrand + """ - App's dashboard extensions. + Circuit breaker state, if open, sync webhooks operation is disrupted. - Added in Saleor 3.1. + Added in Saleor 3.21. """ - extensions: [AppExtension!]! + breakerState: CircuitBreakerStateEnum! """ - App's brand data. + Circuit breaker last state change date. - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Added in Saleor 3.21. """ - brand: AppBrand + breakerLastStateChange: DateTime } interface ObjectWithMetadata { @@ -3240,7 +2844,6 @@ type Permission @doc(category: "Authentication") { name: String! } -"""An enumeration.""" enum PermissionEnum @doc(category: "Users") { MANAGE_USERS MANAGE_STAFF @@ -3357,39 +2960,15 @@ enum AppExtensionTargetEnum @doc(category: "Apps") { APP_PAGE } -""" -Represents the app's brand data. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents the app's brand data.""" type AppBrand @doc(category: "Apps") { - """ - App's logos details. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """App's logos details.""" logo: AppBrandLogo! } -""" -Represents the app's brand logo data. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents the app's brand logo data.""" type AppBrandLogo @doc(category: "Apps") { - """ - URL to the default logo image. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """URL to the default logo image.""" default( """ Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). @@ -3398,10 +2977,6 @@ type AppBrandLogo @doc(category: "Apps") { """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ format: IconThumbnailFormatEnum = ORIGINAL ): String! @@ -3413,6 +2988,22 @@ enum IconThumbnailFormatEnum { WEBP } +"""Enum determining the state of a circuit breaker.""" +enum CircuitBreakerStateEnum @doc(category: "Apps") { + """The breaker is conducting (requests are passing through).""" + CLOSED + + """ + The breaker is in a trial period (to close or open). Note that unlike classic breaker patterns, this is not a state where we are throttling the number of requests, it's a state similar to CLOSED but with different thresholds. + """ + HALF_OPEN + + """ + The breaker is tripped (no requests are passing). Breaker will enter half-open state after cooldown period. + """ + OPEN +} + type EventDeliveryCountableConnection { """Pagination data for this connection.""" pageInfo: PageInfo! @@ -3581,7 +3172,6 @@ input EventDeliveryFilterInput { scalar JSONString -"""An enumeration.""" enum WebhookSampleEventTypeEnum @doc(category: "Webhooks") { ACCOUNT_CONFIRMATION_REQUESTED ACCOUNT_CHANGE_EMAIL_REQUESTED @@ -3738,15 +3328,11 @@ type Warehouse implements Node & ObjectWithMetadata @doc(category: "Products") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -3757,15 +3343,11 @@ type Warehouse implements Node & ObjectWithMetadata @doc(category: "Products") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -3785,13 +3367,9 @@ type Warehouse implements Node & ObjectWithMetadata @doc(category: "Products") { address: Address! """Warehouse company name.""" - companyName: String! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `Address.companyName` instead.") + companyName: String! @deprecated(reason: "Use `Address.companyName` instead.") - """ - Click and collect options: local, all or disabled. - - Added in Saleor 3.1. - """ + """Click and collect options: local, all or disabled.""" clickAndCollectOption: WarehouseClickAndCollectOptionEnum! """Shipping zones supported by the warehouse.""" @@ -3838,11 +3416,7 @@ type Warehouse implements Node & ObjectWithMetadata @doc(category: "Products") { last: Int ): StockCountableConnection - """ - External ID of this warehouse. - - Added in Saleor 3.10. - """ + """External ID of this warehouse.""" externalReference: String } @@ -3851,49 +3425,33 @@ type Address implements Node & ObjectWithMetadata @doc(category: "Users") { """The ID of the address.""" id: ID! - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.10. - """ + """List of private metadata items. Requires staff permissions to access.""" privateMetadata: [MetadataItem!]! """ A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.10. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.10. """ privateMetafields(keys: [String!]): Metadata - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.10. - """ + """List of public metadata items. Can be accessed without permissions.""" metadata: [MetadataItem!]! """ A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.10. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.10. """ metafields(keys: [String!]): Metadata @@ -3945,7 +3503,7 @@ type CountryDisplay { country: String! """Country tax.""" - vat: VAT @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`. Use `TaxClassCountryRate` type to manage tax rates per country.") + vat: VAT @deprecated(reason: "Always returns `null`. Use `TaxClassCountryRate` type to manage tax rates per country.") } """Represents a VAT rate for a country.""" @@ -3969,7 +3527,6 @@ type ReducedRate @doc(category: "Taxes") { rateType: String! } -"""An enumeration.""" enum WarehouseClickAndCollectOptionEnum @doc(category: "Products") { DISABLED LOCAL @@ -4007,15 +3564,11 @@ type ShippingZone implements Node & ObjectWithMetadata @doc(category: "Shipping" A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -4026,15 +3579,11 @@ type ShippingZone implements Node & ObjectWithMetadata @doc(category: "Shipping" A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -4097,15 +3646,11 @@ type ShippingMethodType implements Node & ObjectWithMetadata @doc(category: "Shi A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -4116,15 +3661,11 @@ type ShippingMethodType implements Node & ObjectWithMetadata @doc(category: "Shi A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -4208,7 +3749,6 @@ type ShippingMethodType implements Node & ObjectWithMetadata @doc(category: "Shi taxClass: TaxClass } -"""An enumeration.""" enum ShippingMethodTypeEnum @doc(category: "Shipping") { PRICE WEIGHT @@ -4232,11 +3772,7 @@ type ShippingMethodTranslation implements Node @doc(category: "Shipping") { """ description: JSONString - """ - Represents the shipping method fields to translate. - - Added in Saleor 3.14. - """ + """Represents the shipping method fields to translate.""" translatableContent: ShippingMethodTranslatableContent } @@ -4248,7 +3784,6 @@ type LanguageDisplay { language: String! } -"""An enumeration.""" enum LanguageCodeEnum { AF AF_NA @@ -5038,11 +4573,7 @@ type ShippingMethodTranslatableContent implements Node @doc(category: "Shipping" """The ID of the shipping method translatable content.""" id: ID! - """ - The ID of the shipping method to translate. - - Added in Saleor 3.14. - """ + """The ID of the shipping method to translate.""" shippingMethodId: ID! """Shipping method name to translate.""" @@ -5066,7 +4597,7 @@ type ShippingMethodTranslatableContent implements Node @doc(category: "Shipping" Requires one of the following permissions: MANAGE_SHIPPING. """ - shippingMethod: ShippingMethodType @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + shippingMethod: ShippingMethodType @deprecated(reason: "Get model fields from the root level queries.") } """Represents shipping method channel listing.""" @@ -5092,49 +4623,33 @@ type Channel implements Node & ObjectWithMetadata @doc(category: "Channels") { """The ID of the channel.""" id: ID! - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.15. - """ + """List of private metadata items. Requires staff permissions to access.""" privateMetadata: [MetadataItem!]! """ A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.15. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.15. """ privateMetafields(keys: [String!]): Metadata - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.15. - """ + """List of public metadata items. Can be accessed without permissions.""" metadata: [MetadataItem!]! """ A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.15. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.15. """ metafields(keys: [String!]): Metadata @@ -5172,8 +4687,6 @@ type Channel implements Node & ObjectWithMetadata @doc(category: "Channels") { """ Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. - Added in Saleor 3.1. - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. """ defaultCountry: CountryDisplay! @@ -5181,31 +4694,19 @@ type Channel implements Node & ObjectWithMetadata @doc(category: "Channels") { """ List of warehouses assigned to this channel. - Added in Saleor 3.5. - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. """ warehouses: [Warehouse!]! - """ - List of shippable countries for the channel. - - Added in Saleor 3.6. - """ + """List of shippable countries for the channel.""" countries: [CountryDisplay!] - """ - Shipping methods that are available for the channel. - - Added in Saleor 3.6. - """ + """Shipping methods that are available for the channel.""" availableShippingMethodsPerCountry(countries: [CountryCode!]): [ShippingMethodsPerCountry!] """ Define the stock setting for this channel. - Added in Saleor 3.7. - Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAFF_USER. """ stockSettings: StockSettings! @@ -5213,8 +4714,6 @@ type Channel implements Node & ObjectWithMetadata @doc(category: "Channels") { """ Channel-specific order settings. - Added in Saleor 3.12. - Requires one of the following permissions: MANAGE_CHANNELS, MANAGE_ORDERS. """ orderSettings: OrderSettings! @@ -5222,10 +4721,6 @@ type Channel implements Node & ObjectWithMetadata @doc(category: "Channels") { """ Channel-specific checkout settings. - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_CHANNELS, MANAGE_CHECKOUTS. """ checkoutSettings: CheckoutSettings! @@ -5233,10 +4728,6 @@ type Channel implements Node & ObjectWithMetadata @doc(category: "Channels") { """ Channel-specific payment settings. - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_CHANNELS, HANDLE_PAYMENTS. """ paymentSettings: PaymentSettings! @@ -5251,11 +4742,7 @@ type Channel implements Node & ObjectWithMetadata @doc(category: "Channels") { taxConfiguration: TaxConfiguration! } -""" -List of shipping methods available for the country. - -Added in Saleor 3.6. -""" +"""List of shipping methods available for the country.""" type ShippingMethodsPerCountry @doc(category: "Shipping") { """The country code.""" countryCode: CountryCode! @@ -5560,7 +5047,7 @@ type ShippingMethod implements Node & ObjectWithMetadata @doc(category: "Shippin metafields(keys: [String!]): Metadata """Type of the shipping method.""" - type: ShippingMethodTypeEnum @deprecated(reason: "This field will be removed in Saleor 4.0.") + type: ShippingMethodTypeEnum @deprecated """Shipping method name.""" name: String! @@ -5579,10 +5066,10 @@ type ShippingMethod implements Node & ObjectWithMetadata @doc(category: "Shippin minimumDeliveryDays: Int """Maximum order weight for this shipping method.""" - maximumOrderWeight: Weight @deprecated(reason: "This field will be removed in Saleor 4.0.") + maximumOrderWeight: Weight @deprecated """Minimum order weight for this shipping method.""" - minimumOrderWeight: Weight @deprecated(reason: "This field will be removed in Saleor 4.0.") + minimumOrderWeight: Weight @deprecated """Returns translated shipping method fields for the given language code.""" translation( @@ -5615,7 +5102,6 @@ type Weight { value: Float! } -"""An enumeration.""" enum WeightUnitsEnum { G LB @@ -5624,11 +5110,7 @@ enum WeightUnitsEnum { TONNE } -""" -Represents the channel stock settings. - -Added in Saleor 3.7. -""" +"""Represents the channel stock settings.""" type StockSettings @doc(category: "Products") { """ Allocation strategy defines the preference of warehouses for allocations and reservations. @@ -5663,10 +5145,6 @@ type OrderSettings { """ Expiration time in minutes. Default null - means do not expire any orders. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ expireOrdersAfter: Minute @@ -5674,28 +5152,14 @@ type OrderSettings { Determine what strategy will be used to mark the order as paid. Based on the chosen option, the proper object will be created and attached to the order when it's manually marked as paid. `PAYMENT_FLOW` - [default option] creates the `Payment` object. `TRANSACTION_FLOW` - creates the `TransactionItem` object. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ markAsPaidStrategy: MarkAsPaidStrategyEnum! - """ - The time in days after expired orders will be deleted. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The time in days after expired orders will be deleted.""" deleteExpiredOrdersAfter: Day! """ Determine if it is possible to place unpaid order by calling `checkoutComplete` mutation. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ allowUnpaidOrders: Boolean! @@ -5707,6 +5171,25 @@ type OrderSettings { Note: this API is currently in Feature Preview and can be subject to changes at later point. """ includeDraftOrderInVoucherUsage: Boolean! + + """ + Time in hours after which the draft order line price will be refreshed. + + Added in Saleor 3.21. + + Note: this API is currently in Feature Preview and can be subject to changes at later point. + """ + draftOrderLinePriceFreezePeriod: Hour + + """ + This flag only affects orders created from checkout and applies specifically to vouchers of the types: `SPECIFIC_PRODUCT` and `ENTIRE_ORDER` with `applyOncePerOrder` enabled. + - When legacy propagation is enabled, discounts from these vouchers are represented as `OrderDiscount` objects, attached to the order and returned in the `Order.discounts` field. Additionally, percentage-based vouchers are converted to fixed-value discounts. + - When legacy propagation is disabled, discounts are represented as `OrderLineDiscount` objects, attached to individual lines and returned in the `OrderLine.discounts` field. In this case, percentage-based vouchers retain their original type. + In future releases, `OrderLineDiscount` will become the default behavior, and this flag will be deprecated and removed. + + Added in Saleor 3.21. + """ + useLegacyLineDiscountPropagation: Boolean! } """ @@ -5731,30 +5214,28 @@ enum MarkAsPaidStrategyEnum @doc(category: "Channels") { """The `Day` scalar type represents number of days by integer value.""" scalar Day -""" -Represents the channel-specific checkout settings. - -Added in Saleor 3.15. +"""The `Hour` scalar type represents number of hours by integer value.""" +scalar Hour -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents the channel-specific checkout settings.""" type CheckoutSettings { """ Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. - - Added in Saleor 3.15.This field will be removed in Saleor 4.0. """ useLegacyErrorFlow: Boolean! + + """ + Default `false`. Determines if the paid checkouts should be automatically completed. This setting applies only to checkouts where payment was processed through transactions.When enabled, the checkout will be automatically completed once the checkout `charge_status` reaches `FULL`. This occurs when the total sum of charged and authorized transaction amounts equals or exceeds the checkout's total amount. + + Added in Saleor 3.20. + """ + automaticallyCompleteFullyPaidCheckouts: Boolean! } """Represents the channel-specific payment settings.""" type PaymentSettings { """ Determine the transaction flow strategy to be used. Include the selected option in the payload sent to the payment app, as a requested action for the transaction. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ defaultTransactionFlowStrategy: TransactionFlowStrategyEnum! } @@ -5770,11 +5251,7 @@ enum TransactionFlowStrategyEnum @doc(category: "Payments") { CHARGE } -""" -Channel-specific tax configuration. - -Added in Saleor 3.9. -""" +"""Channel-specific tax configuration.""" type TaxConfiguration implements Node & ObjectWithMetadata @doc(category: "Taxes") { """The ID of the object.""" id: ID! @@ -5786,15 +5263,11 @@ type TaxConfiguration implements Node & ObjectWithMetadata @doc(category: "Taxes A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -5805,15 +5278,11 @@ type TaxConfiguration implements Node & ObjectWithMetadata @doc(category: "Taxes A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -5843,6 +5312,13 @@ type TaxConfiguration implements Node & ObjectWithMetadata @doc(category: "Taxes Added in Saleor 3.19. """ taxAppId: String + + """ + Determines whether to use weighted tax for shipping. When set to true, the tax rate for shipping will be calculated based on the weighted average of tax rates from the order or checkout lines. + + Added in Saleor 3.21. + """ + useWeightedTaxForShipping: Boolean } enum TaxCalculationStrategy @doc(category: "Taxes") { @@ -5850,11 +5326,7 @@ enum TaxCalculationStrategy @doc(category: "Taxes") { TAX_APP } -""" -Country-specific exceptions of a channel's tax configuration. - -Added in Saleor 3.9. -""" +"""Country-specific exceptions of a channel's tax configuration.""" type TaxConfigurationPerCountry @doc(category: "Taxes") { """Country in which this configuration applies.""" country: CountryDisplay! @@ -5878,6 +5350,13 @@ type TaxConfigurationPerCountry @doc(category: "Taxes") { Added in Saleor 3.19. """ taxAppId: String + + """ + Determines whether to use weighted tax for shipping. When set to true, the tax rate for shipping will be calculated based on the weighted average of tax rates from the order or checkout lines. + + Added in Saleor 3.21. + """ + useWeightedTaxForShipping: Boolean } """Represents shipping method postal code rule.""" @@ -5895,7 +5374,6 @@ type ShippingMethodPostalCodeRule implements Node @doc(category: "Shipping") { inclusionType: PostalCodeRuleInclusionTypeEnum } -"""An enumeration.""" enum PostalCodeRuleInclusionTypeEnum @doc(category: "Shipping") { INCLUDE EXCLUDE @@ -5930,15 +5408,11 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -5949,15 +5423,11 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -5989,7 +5459,7 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { """The date and time when the product was last updated.""" updatedAt: DateTime! - chargeTaxes: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` field to determine whether tax collection is enabled.") + chargeTaxes: Boolean! @deprecated(reason: "Use `Channel.taxConfiguration` field to determine whether tax collection is enabled.") """Weight of the product.""" weight: Weight @@ -6010,7 +5480,7 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") """Thumbnail of the product.""" thumbnail( @@ -6021,8 +5491,6 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. """ format: ThumbnailFormatEnum = ORIGINAL ): Image @@ -6048,13 +5516,9 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { ): Boolean """A type of tax. Assigned by enabled tax gateway""" - taxType: TaxType @deprecated(reason: "This field will be removed in Saleor 4.0. Use `taxClass` field instead.") + taxType: TaxType @deprecated(reason: "Use `taxClass` field instead.") - """ - Get a single attribute attached to product by attribute slug. - - Added in Saleor 3.9. - """ + """Get a single attribute attached to product by attribute slug.""" attribute( """Slug of the attribute""" slug: String! @@ -6080,38 +5544,62 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { imageById( """ID of a product image.""" id: ID - ): ProductImage @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `mediaById` field instead.") + ): ProductImage @deprecated(reason: "Use the `mediaById` field instead.") - """ - Get a single variant by SKU or ID. - - Added in Saleor 3.9. - """ + """Get a single variant by SKU or ID.""" variant( """ID of the variant.""" id: ID """SKU of the variant.""" sku: String - ): ProductVariant @deprecated(reason: "This field will be removed in Saleor 4.0. Use top-level `variant` query.") + ): ProductVariant @deprecated(reason: "Use top-level `variant` query.") """ List of variants for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. """ - variants: [ProductVariant!] + variants: [ProductVariant!] @deprecated(reason: "Use `productVariants` field instead.") + + """ + List of variants for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. + + Added in Saleor 3.21. + """ + productVariants( + """Filtering options for product variant.""" + filter: ProductVariantFilterInput + + """Where filtering options.""" + where: ProductVariantWhereInput + + """Sort products variants.""" + sortBy: ProductVariantSortingInput + + """Return the elements in the list that come before the specified cursor.""" + before: String + + """Return the elements in the list that come after the specified cursor.""" + after: String - """List of media for the product.""" - media( """ - Sort media. - - Added in Saleor 3.9. + Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. + """ + first: Int + + """ + Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. """ + last: Int + ): ProductVariantCountableConnection + + """List of media for the product.""" + media( + """Sort media.""" sortBy: MediaSortingInput ): [ProductMedia!] """List of images for the product.""" - images: [ProductImage!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `media` field instead.") + images: [ProductImage!] @deprecated(reason: "Use the `media` field instead.") """ List of collections for the product. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. @@ -6125,7 +5613,7 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { ): ProductTranslation """Date when product is available for purchase.""" - availableForPurchase: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `availableForPurchaseAt` field to fetch the available for purchase date.") + availableForPurchase: Date @deprecated(reason: "Use the `availableForPurchaseAt` field to fetch the available for purchase date.") """Date when product is available for purchase.""" availableForPurchaseAt: DateTime @@ -6142,11 +5630,7 @@ type Product implements Node & ObjectWithMetadata @doc(category: "Products") { """ taxClass: TaxClass - """ - External ID of this product. - - Added in Saleor 3.10. - """ + """External ID of this product.""" externalReference: String } @@ -6164,15 +5648,11 @@ type ProductType implements Node & ObjectWithMetadata @doc(category: "Products") A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -6183,15 +5663,11 @@ type ProductType implements Node & ObjectWithMetadata @doc(category: "Products") A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -6236,10 +5712,10 @@ type ProductType implements Node & ObjectWithMetadata @doc(category: "Products") Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query. """ last: Int - ): ProductCountableConnection @deprecated(reason: "This field will be removed in Saleor 4.0. Use the top-level `products` query with the `productTypes` filter.") + ): ProductCountableConnection @deprecated(reason: "Use the top-level `products` query with the `productTypes` filter.") """A type of tax. Assigned by enabled tax gateway""" - taxType: TaxType @deprecated(reason: "This field will be removed in Saleor 4.0. Use `taxClass` field instead.") + taxType: TaxType @deprecated(reason: "Use `taxClass` field instead.") """ Tax class assigned to this product type. All products of this product type use this tax class, unless it's overridden in the `Product` type. @@ -6252,12 +5728,10 @@ type ProductType implements Node & ObjectWithMetadata @doc(category: "Products") variantAttributes( """Define scope of returned attributes.""" variantSelection: VariantAttributeScope - ): [Attribute!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use `assignedVariantAttributes` instead.") + ): [Attribute!] @deprecated(reason: "Use `assignedVariantAttributes` instead.") """ Variant attributes of that product type with attached variant selection. - - Added in Saleor 3.1. """ assignedVariantAttributes( """Define scope of returned attributes.""" @@ -6294,7 +5768,6 @@ type ProductType implements Node & ObjectWithMetadata @doc(category: "Products") ): AttributeCountableConnection } -"""An enumeration.""" enum ProductTypeKindEnum @doc(category: "Products") { NORMAL GIFT_CARD @@ -6311,8 +5784,6 @@ type TaxType @doc(category: "Taxes") { """ Tax class is a named object used to define tax rates per country. Tax class can be assigned to product types, products and shipping methods to define their tax rates. - -Added in Saleor 3.9. """ type TaxClass implements Node & ObjectWithMetadata @doc(category: "Taxes") { """The ID of the object.""" @@ -6325,15 +5796,11 @@ type TaxClass implements Node & ObjectWithMetadata @doc(category: "Taxes") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -6344,15 +5811,11 @@ type TaxClass implements Node & ObjectWithMetadata @doc(category: "Taxes") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -6365,8 +5828,6 @@ type TaxClass implements Node & ObjectWithMetadata @doc(category: "Taxes") { """ Tax rate for a country. When tax class is null, it represents the default tax rate for that country; otherwise it's a country tax rate specific to the given tax class. - -Added in Saleor 3.9. """ type TaxClassCountryRate @doc(category: "Taxes") { """Country in which this tax rate applies.""" @@ -6393,15 +5854,11 @@ type Attribute implements Node & ObjectWithMetadata @doc(category: "Attributes") A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -6412,15 +5869,11 @@ type Attribute implements Node & ObjectWithMetadata @doc(category: "Attributes") A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -6480,7 +5933,7 @@ type Attribute implements Node & ObjectWithMetadata @doc(category: "Attributes") """ Whether the attribute can be filtered in storefront. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. """ - filterableInStorefront: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0.") + filterableInStorefront: Boolean! @deprecated """ Whether the attribute can be filtered in dashboard. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. @@ -6490,12 +5943,12 @@ type Attribute implements Node & ObjectWithMetadata @doc(category: "Attributes") """ Whether the attribute can be displayed in the admin product list. Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. """ - availableInGrid: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0.") + availableInGrid: Boolean! @deprecated """ The position of the attribute in the storefront navigation (0 by default). Requires one of the following permissions: MANAGE_PAGES, MANAGE_PAGE_TYPES_AND_ATTRIBUTES, MANAGE_PRODUCTS, MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. """ - storefrontSearchPosition: Int! @deprecated(reason: "This field will be removed in Saleor 4.0.") + storefrontSearchPosition: Int! @deprecated """Returns translated attribute fields for the given language code.""" translation( @@ -6548,15 +6001,10 @@ type Attribute implements Node & ObjectWithMetadata @doc(category: "Attributes") last: Int ): ProductTypeCountableConnection! - """ - External ID of this attribute. - - Added in Saleor 3.10. - """ + """External ID of this attribute.""" externalReference: String } -"""An enumeration.""" enum AttributeInputTypeEnum @doc(category: "Attributes") { DROPDOWN MULTISELECT @@ -6571,20 +6019,17 @@ enum AttributeInputTypeEnum @doc(category: "Attributes") { DATE_TIME } -"""An enumeration.""" enum AttributeEntityTypeEnum @doc(category: "Attributes") { PAGE PRODUCT PRODUCT_VARIANT } -"""An enumeration.""" enum AttributeTypeEnum @doc(category: "Attributes") { PRODUCT_TYPE PAGE_TYPE } -"""An enumeration.""" enum MeasurementUnitsEnum { MM CM @@ -6691,11 +6136,7 @@ type AttributeValue implements Node @doc(category: "Attributes") { """Represents the date/time value of the attribute value.""" dateTime: DateTime - """ - External ID of this attribute value. - - Added in Saleor 3.10. - """ + """External ID of this attribute value.""" externalReference: String } @@ -6720,11 +6161,7 @@ type AttributeValueTranslation implements Node @doc(category: "Attributes") { """Translated plain text attribute value .""" plainText: String - """ - Represents the attribute value fields to translate. - - Added in Saleor 3.14. - """ + """Represents the attribute value fields to translate.""" translatableContent: AttributeValueTranslatableContent } @@ -6735,11 +6172,7 @@ type AttributeValueTranslatableContent implements Node @doc(category: "Attribute """The ID of the attribute value translatable content.""" id: ID! - """ - The ID of the attribute value to translate. - - Added in Saleor 3.14. - """ + """The ID of the attribute value to translate.""" attributeValueId: ID! """Name of the attribute value to translate.""" @@ -6762,13 +6195,9 @@ type AttributeValueTranslatableContent implements Node @doc(category: "Attribute ): AttributeValueTranslation """Represents a value of an attribute.""" - attributeValue: AttributeValue @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + attributeValue: AttributeValue @deprecated(reason: "Get model fields from the root level queries.") - """ - Associated attribute that can be translated. - - Added in Saleor 3.9. - """ + """Associated attribute that can be translated.""" attribute: AttributeTranslatableContent } @@ -6779,11 +6208,7 @@ type AttributeTranslatableContent implements Node @doc(category: "Attributes") { """The ID of the attribute translatable content.""" id: ID! - """ - The ID of the attribute to translate. - - Added in Saleor 3.14. - """ + """The ID of the attribute to translate.""" attributeId: ID! """Name of the attribute to translate.""" @@ -6796,7 +6221,7 @@ type AttributeTranslatableContent implements Node @doc(category: "Attributes") { ): AttributeTranslation """Custom attribute of a product.""" - attribute: Attribute @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + attribute: Attribute @deprecated(reason: "Get model fields from the root level queries.") } """Represents attribute translations.""" @@ -6810,11 +6235,7 @@ type AttributeTranslation implements Node @doc(category: "Attributes") { """Translated attribute name.""" name: String! - """ - Represents the attribute fields to translate. - - Added in Saleor 3.14. - """ + """Represents the attribute fields to translate.""" translatableContent: AttributeTranslatableContent } @@ -6880,8 +6301,6 @@ enum VariantAttributeScope @doc(category: "Products") { """ Represents assigned attribute to variant with variant selection attached. - -Added in Saleor 3.1. """ type AssignedVariantAttribute @doc(category: "Attributes") { """Attribute assigned to variant.""" @@ -6925,12 +6344,8 @@ input AttributeFilterInput @doc(category: "Attributes") { inCategory: ID slugs: [String!] - """ - Specifies the channel by which the data should be filtered. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String + """Specifies the channel by which the data should be filtered.""" + channel: String @deprecated(reason: "Use root-level channel argument instead.") } input MetadataFilter { @@ -6941,13 +6356,7 @@ input MetadataFilter { value: String } -""" -Where filtering options. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Where filtering options.""" input AttributeWhereInput @doc(category: "Attributes") { metadata: [MetadataFilter!] ids: [ID!] @@ -6971,13 +6380,7 @@ input AttributeWhereInput @doc(category: "Attributes") { OR: [AttributeWhereInput!] } -""" -Define the filtering options for string fields. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Define the filtering options for string fields.""" input StringFilterInput { """The value equal to.""" eq: String @@ -7032,15 +6435,11 @@ type Category implements Node & ObjectWithMetadata @doc(category: "Products") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -7051,15 +6450,11 @@ type Category implements Node & ObjectWithMetadata @doc(category: "Products") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -7093,13 +6488,9 @@ type Category implements Node & ObjectWithMetadata @doc(category: "Products") { Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") - """ - The date and time when the category was last updated. - - Added in Saleor 3.17. - """ + """The date and time when the category was last updated.""" updatedAt: DateTime! """List of ancestors of the category.""" @@ -7125,27 +6516,13 @@ type Category implements Node & ObjectWithMetadata @doc(category: "Products") { List of products in the category. Requires the following permissions to include the unpublished items: MANAGE_ORDERS, MANAGE_DISCOUNTS, MANAGE_PRODUCTS. """ products( - """ - Filtering options for products. - - Added in Saleor 3.10. - """ + """Filtering options for products.""" filter: ProductFilterInput - """ - Filtering options for products. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Filtering options for products.""" where: ProductWhereInput - """ - Sort products. - - Added in Saleor 3.10. - """ + """Sort products.""" sortBy: ProductOrder """Slug of a channel for which the data should be returned.""" @@ -7196,8 +6573,6 @@ type Category implements Node & ObjectWithMetadata @doc(category: "Products") { """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. """ format: ThumbnailFormatEnum = ORIGINAL ): Image @@ -7239,32 +6614,16 @@ input ProductFilterInput @doc(category: "Products") { search: String metadata: [MetadataFilter!] - """ - Filter by the publication date. - - Added in Saleor 3.8. - """ + """Filter by the publication date.""" publishedFrom: DateTime - """ - Filter by availability for purchase. - - Added in Saleor 3.8. - """ + """Filter by availability for purchase.""" isAvailable: Boolean - """ - Filter by the date of availability for purchase. - - Added in Saleor 3.8. - """ + """Filter by the date of availability for purchase.""" availableFrom: DateTime - """ - Filter by visibility in product listings. - - Added in Saleor 3.8. - """ + """Filter by visibility in product listings.""" isVisibleInListing: Boolean price: PriceRangeInput @@ -7281,12 +6640,8 @@ input ProductFilterInput @doc(category: "Products") { hasPreorderedVariants: Boolean slugs: [String!] - """ - Specifies the channel by which the data should be filtered. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String + """Specifies the channel by which the data should be filtered.""" + channel: String @deprecated(reason: "Use root-level channel argument instead.") } input AttributeInput @doc(category: "Attributes") { @@ -7421,13 +6776,7 @@ input ProductWhereInput @doc(category: "Products") { OR: [ProductWhereInput!] } -""" -Define the filtering options for foreign key fields. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Define the filtering options for foreign key fields.""" input GlobalIDFilterInput { """The value equal to.""" eq: ID @@ -7436,13 +6785,7 @@ input GlobalIDFilterInput { oneOf: [ID!] } -""" -Define the filtering options for decimal fields. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Define the filtering options for decimal fields.""" input DecimalFilterInput { """The value equal to.""" eq: Decimal @@ -7470,13 +6813,7 @@ input DecimalRangeInput { lte: Decimal } -""" -Define the filtering options for date time fields. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Define the filtering options for date time fields.""" input DateTimeFilterInput { """The value equal to.""" eq: DateTime @@ -7492,12 +6829,8 @@ input ProductOrder @doc(category: "Products") { """Specifies the direction in which to sort products.""" direction: OrderDirection! - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String + """Specifies the channel in which to sort the data.""" + channel: String @deprecated(reason: "Use root-level channel argument instead.") """ Sort product by the selected attribute's values. @@ -7575,11 +6908,7 @@ enum ProductOrderField @doc(category: "Products") { """Sort products by rating.""" RATING - """ - Sort products by creation date. - - Added in Saleor 3.8. - """ + """Sort products by creation date.""" CREATED_AT } @@ -7592,7 +6921,6 @@ type Image { alt: String } -"""An enumeration.""" enum ThumbnailFormatEnum { ORIGINAL AVIF @@ -7613,6 +6941,13 @@ type CategoryTranslation implements Node @doc(category: "Products") { """Translated SEO description.""" seoDescription: String + """ + Translated category slug. + + Added in Saleor 3.21. + """ + slug: String + """Translated category name.""" name: String @@ -7628,13 +6963,9 @@ type CategoryTranslation implements Node @doc(category: "Products") { Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") - """ - Represents the category fields to translate. - - Added in Saleor 3.14. - """ + """Represents the category fields to translate.""" translatableContent: CategoryTranslatableContent } @@ -7645,11 +6976,7 @@ type CategoryTranslatableContent implements Node @doc(category: "Products") { """The ID of the category translatable content.""" id: ID! - """ - The ID of the category to translate. - - Added in Saleor 3.14. - """ + """The ID of the category to translate.""" categoryId: ID! """SEO title to translate.""" @@ -7658,6 +6985,13 @@ type CategoryTranslatableContent implements Node @doc(category: "Products") { """SEO description to translate.""" seoDescription: String + """ + Slug to translate. + + Added in Saleor 3.21. + """ + slug: String + """Name of the category translatable content.""" name: String! @@ -7673,7 +7007,7 @@ type CategoryTranslatableContent implements Node @doc(category: "Products") { Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") """Returns translated category fields for the given language code.""" translation( @@ -7682,7 +7016,7 @@ type CategoryTranslatableContent implements Node @doc(category: "Products") { ): CategoryTranslation """Represents a single category of products.""" - category: Category @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + category: Category @deprecated(reason: "Get model fields from the root level queries.") } """Represents a version of a product such as different size or color.""" @@ -7697,15 +7031,11 @@ type ProductVariant implements Node & ObjectWithMetadata @doc(category: "Product A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -7716,15 +7046,11 @@ type ProductVariant implements Node & ObjectWithMetadata @doc(category: "Product A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -7794,7 +7120,7 @@ type ProductVariant implements Node & ObjectWithMetadata @doc(category: "Product revenue(period: ReportingPeriod): TaxedMoney """List of images for the product variant.""" - images: [ProductImage!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `media` field instead.") + images: [ProductImage!] @deprecated(reason: "Use the `media` field instead.") """List of media for the product variant.""" media: [ProductMedia!] @@ -7823,12 +7149,8 @@ type ProductVariant implements Node & ObjectWithMetadata @doc(category: "Product """ address: AddressInput - """ - Two-letter ISO 3166-1 country code. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `address` argument instead. - """ - countryCode: CountryCode + """Two-letter ISO 3166-1 country code.""" + countryCode: CountryCode @deprecated(reason: "Use `address` argument instead.") ): [Stock!] """ @@ -7841,18 +7163,12 @@ type ProductVariant implements Node & ObjectWithMetadata @doc(category: "Product address: AddressInput """ - Two-letter ISO 3166-1 country code. When provided, the exact quantity from a warehouse operating in shipping zones that contain this country will be returned. Otherwise, it will return the maximum quantity from all shipping zones. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `address` argument instead. + Two-letter ISO 3166-1 country code. When provided, the exact quantity from a warehouse operating in shipping zones that contain this country will be returned. Otherwise, it will return the maximum quantity from all shipping zones. """ - countryCode: CountryCode + countryCode: CountryCode @deprecated(reason: "Use `address` argument instead.") ): Int - """ - Preorder data for product variant. - - Added in Saleor 3.1. - """ + """Preorder data for product variant.""" preorder: PreorderData """The date and time when the product variant was created.""" @@ -7861,11 +7177,7 @@ type ProductVariant implements Node & ObjectWithMetadata @doc(category: "Product """The date and time when the product variant was last updated.""" updatedAt: DateTime! - """ - External ID of this product. - - Added in Saleor 3.10. - """ + """External ID of this product.""" externalReference: String } @@ -7884,17 +7196,20 @@ type ProductVariantChannelListing implements Node @doc(category: "Products") { costPrice: Money """ - Gross margin percentage value. + Prior price of the variant used for discount calculations. - Requires one of the following permissions: MANAGE_PRODUCTS. + Added in Saleor 3.21. """ - margin: Int + priorPrice: Money """ - Preorder variant data. + Gross margin percentage value. - Added in Saleor 3.1. + Requires one of the following permissions: MANAGE_PRODUCTS. """ + margin: Int + + """Preorder variant data.""" preorderThreshold: PreorderThreshold } @@ -7915,8 +7230,15 @@ type VariantPricingInfo @doc(category: "Products") { """The discount amount if in sale (null otherwise).""" discount: TaxedMoney + """ + The discount amount compared to prior price. Null if product is not on sale or prior price was not provided in VariantChannelListing + + Added in Saleor 3.21. + """ + discountPrior: TaxedMoney + """The discount amount in the local currency.""" - discountLocalCurrency: TaxedMoney @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`.") + discountLocalCurrency: TaxedMoney @deprecated(reason: "Always returns `null`.") """The price, with any discount subtracted.""" price: TaxedMoney @@ -7924,8 +7246,15 @@ type VariantPricingInfo @doc(category: "Products") { """The price without any discount.""" priceUndiscounted: TaxedMoney + """ + The price prior to discount. + + Added in Saleor 3.21. + """ + pricePrior: TaxedMoney + """The discounted price in the local currency.""" - priceLocalCurrency: TaxedMoney @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`.") + priceLocalCurrency: TaxedMoney @deprecated(reason: "Always returns `null`.") } """ @@ -7984,9 +7313,9 @@ input AddressInput { phone: String """ - Address public metadata. + Address public metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.15. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] @@ -8044,8 +7373,6 @@ type ProductImage @doc(category: "Products") { """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. """ format: ThumbnailFormatEnum = ORIGINAL ): String! @@ -8056,49 +7383,33 @@ type ProductMedia implements Node & ObjectWithMetadata @doc(category: "Products" """The unique ID of the product media.""" id: ID! - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.12. - """ + """List of private metadata items. Requires staff permissions to access.""" privateMetadata: [MetadataItem!]! """ A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.12. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.12. """ privateMetafields(keys: [String!]): Metadata - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.12. - """ + """List of public metadata items. Can be accessed without permissions.""" metadata: [MetadataItem!]! """ A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.12. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.12. """ metafields(keys: [String!]): Metadata @@ -8123,21 +7434,14 @@ type ProductMedia implements Node & ObjectWithMetadata @doc(category: "Products" """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. """ format: ThumbnailFormatEnum = ORIGINAL ): String! - """ - Product id the media refers to. - - Added in Saleor 3.12. - """ + """Product id the media refers to.""" productId: ID } -"""An enumeration.""" enum ProductMediaType @doc(category: "Products") { IMAGE VIDEO @@ -8154,11 +7458,7 @@ type ProductVariantTranslation implements Node @doc(category: "Products") { """Translated product variant name.""" name: String! - """ - Represents the product variant fields to translate. - - Added in Saleor 3.14. - """ + """Represents the product variant fields to translate.""" translatableContent: ProductVariantTranslatableContent } @@ -8169,11 +7469,7 @@ type ProductVariantTranslatableContent implements Node @doc(category: "Products" """The ID of the product variant translatable content.""" id: ID! - """ - The ID of the product variant to translate. - - Added in Saleor 3.14. - """ + """The ID of the product variant to translate.""" productVariantId: ID! """Name of the product variant to translate.""" @@ -8186,7 +7482,7 @@ type ProductVariantTranslatableContent implements Node @doc(category: "Products" ): ProductVariantTranslation """Represents a version of a product such as different size or color.""" - productVariant: ProductVariant @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + productVariant: ProductVariant @deprecated(reason: "Get model fields from the root level queries.") """List of product variant attribute values that can be translated.""" attributeValues: [AttributeValueTranslatableContent!]! @@ -8204,15 +7500,11 @@ type DigitalContent implements Node & ObjectWithMetadata @doc(category: "Product A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -8223,15 +7515,11 @@ type DigitalContent implements Node & ObjectWithMetadata @doc(category: "Product A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -8341,14 +7629,17 @@ type ProductPricingInfo @doc(category: "Products") { """The discount amount if in sale (null otherwise).""" discount: TaxedMoney - """The discount amount in the local currency.""" - discountLocalCurrency: TaxedMoney @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`.") - """ - Determines whether displayed prices should include taxes. + The discount amount compared to prior price. Null if product is not on sale or prior price was not provided in VariantChannelListing - Added in Saleor 3.9. + Added in Saleor 3.21. """ + discountPrior: TaxedMoney + + """The discount amount in the local currency.""" + discountLocalCurrency: TaxedMoney @deprecated(reason: "Always returns `null`.") + + """Determines whether displayed prices should include taxes.""" displayGrossPrices: Boolean! """The discounted price range of the product variants.""" @@ -8357,10 +7648,17 @@ type ProductPricingInfo @doc(category: "Products") { """The undiscounted price range of the product variants.""" priceRangeUndiscounted: TaxedMoneyRange + """ + The prior price range of the product variants. + + Added in Saleor 3.21. + """ + priceRangePrior: TaxedMoneyRange + """ The discounted price range of the product variants in the local currency. """ - priceRangeLocalCurrency: TaxedMoneyRange @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `null`.") + priceRangeLocalCurrency: TaxedMoneyRange @deprecated(reason: "Always returns `null`.") } """Represents a range of monetary values.""" @@ -8376,13 +7674,9 @@ type TaxedMoneyRange { type ProductChannelListing implements Node @doc(category: "Products") { """The ID of the product channel listing.""" id: ID! - publicationDate: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date.") + publicationDate: Date @deprecated(reason: "Use the `publishedAt` field to fetch the publication date.") - """ - The product publication date time. - - Added in Saleor 3.3. - """ + """The product publication date time.""" publishedAt: DateTime """Indicates if the product is published in the channel.""" @@ -8393,13 +7687,9 @@ type ProductChannelListing implements Node @doc(category: "Products") { """Indicates product visibility in the channel listings.""" visibleInListings: Boolean! - availableForPurchase: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `availableForPurchaseAt` field to fetch the available for purchase date.") + availableForPurchase: Date @deprecated(reason: "Use the `availableForPurchaseAt` field to fetch the available for purchase date.") - """ - The product available for purchase date time. - - Added in Saleor 3.3. - """ + """The product available for purchase date time.""" availableForPurchaseAt: DateTime """The price of the cheapest variant (including discounts).""" @@ -8444,6 +7734,55 @@ type Margin @doc(category: "Products") { stop: Int } +type ProductVariantCountableConnection @doc(category: "Products") { + """Pagination data for this connection.""" + pageInfo: PageInfo! + edges: [ProductVariantCountableEdge!]! + + """A total count of items in the collection.""" + totalCount: Int +} + +type ProductVariantCountableEdge @doc(category: "Products") { + """The item at the end of the edge.""" + node: ProductVariant! + + """A cursor for use in pagination.""" + cursor: String! +} + +input ProductVariantFilterInput @doc(category: "Products") { + search: String + sku: [String!] + metadata: [MetadataFilter!] + isPreorder: Boolean + updatedAt: DateTimeRangeInput +} + +input ProductVariantWhereInput @doc(category: "Products") { + metadata: [MetadataFilter!] + ids: [ID!] + + """List of conditions that must be met.""" + AND: [ProductVariantWhereInput!] + + """A list of conditions of which at least one must be met.""" + OR: [ProductVariantWhereInput!] +} + +input ProductVariantSortingInput @doc(category: "Products") { + """Specifies the direction in which to sort productVariants.""" + direction: OrderDirection! + + """Sort productVariants by the selected field.""" + field: ProductVariantSortField! +} + +enum ProductVariantSortField @doc(category: "Products") { + """Sort products variants by last modified at.""" + LAST_MODIFIED_AT +} + input MediaSortingInput @doc(category: "Products") { """Specifies the direction in which to sort media.""" direction: OrderDirection! @@ -8469,15 +7808,11 @@ type Collection implements Node & ObjectWithMetadata @doc(category: "Products") A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -8488,15 +7823,11 @@ type Collection implements Node & ObjectWithMetadata @doc(category: "Products") A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -8529,20 +7860,14 @@ type Collection implements Node & ObjectWithMetadata @doc(category: "Products") Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") """List of products in this collection.""" products( """Filtering options for products.""" filter: ProductFilterInput - """ - Filtering options for products. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Filtering options for products.""" where: ProductWhereInput """Sort products.""" @@ -8574,8 +7899,6 @@ type Collection implements Node & ObjectWithMetadata @doc(category: "Products") """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. """ format: ThumbnailFormatEnum = ORIGINAL ): Image @@ -8608,6 +7931,13 @@ type CollectionTranslation implements Node @doc(category: "Products") { """Translated SEO description.""" seoDescription: String + """ + Translated collection slug. + + Added in Saleor 3.21. + """ + slug: String + """Translated collection name.""" name: String @@ -8623,13 +7953,9 @@ type CollectionTranslation implements Node @doc(category: "Products") { Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") - """ - Represents the collection fields to translate. - - Added in Saleor 3.14. - """ + """Represents the collection fields to translate.""" translatableContent: CollectionTranslatableContent } @@ -8640,11 +7966,7 @@ type CollectionTranslatableContent implements Node @doc(category: "Products") { """The ID of the collection translatable content.""" id: ID! - """ - The ID of the collection to translate. - - Added in Saleor 3.14. - """ + """The ID of the collection to translate.""" collectionId: ID! """SEO title to translate.""" @@ -8653,6 +7975,13 @@ type CollectionTranslatableContent implements Node @doc(category: "Products") { """SEO description to translate.""" seoDescription: String + """ + Slug to translate + + Added in Saleor 3.21. + """ + slug: String + """Collection's name to translate.""" name: String! @@ -8668,7 +7997,7 @@ type CollectionTranslatableContent implements Node @doc(category: "Products") { Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") """Returns translated collection fields for the given language code.""" translation( @@ -8677,20 +8006,16 @@ type CollectionTranslatableContent implements Node @doc(category: "Products") { ): CollectionTranslation """Represents a collection of products.""" - collection: Collection @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + collection: Collection @deprecated(reason: "Get model fields from the root level queries.") } """Represents collection channel listing.""" type CollectionChannelListing implements Node @doc(category: "Products") { """The ID of the collection channel listing.""" id: ID! - publicationDate: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date.") + publicationDate: Date @deprecated(reason: "Use the `publishedAt` field to fetch the publication date.") - """ - The collection publication date. - - Added in Saleor 3.3. - """ + """The collection publication date.""" publishedAt: DateTime """Indicates if the collection is published in the channel.""" @@ -8714,6 +8039,13 @@ type ProductTranslation implements Node @doc(category: "Products") { """Translated SEO description.""" seoDescription: String + """ + Translated product slug. + + Added in Saleor 3.21. + """ + slug: String + """Translated product name.""" name: String @@ -8729,13 +8061,9 @@ type ProductTranslation implements Node @doc(category: "Products") { Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") - """ - Represents the product fields to translate. - - Added in Saleor 3.14. - """ + """Represents the product fields to translate.""" translatableContent: ProductTranslatableContent } @@ -8746,11 +8074,7 @@ type ProductTranslatableContent implements Node @doc(category: "Products") { """The ID of the product translatable content.""" id: ID! - """ - The ID of the product to translate. - - Added in Saleor 3.14. - """ + """The ID of the product to translate.""" productId: ID! """SEO title to translate.""" @@ -8759,6 +8083,13 @@ type ProductTranslatableContent implements Node @doc(category: "Products") { """SEO description to translate.""" seoDescription: String + """ + Slug to translate. + + Added in Saleor 3.21. + """ + slug: String + """Product's name to translate.""" name: String! @@ -8774,7 +8105,7 @@ type ProductTranslatableContent implements Node @doc(category: "Products") { Rich text format. For reference see https://editorjs.io/ """ - descriptionJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `description` field instead.") + descriptionJson: JSONString @deprecated(reason: "Use the `description` field instead.") """Returns translated product fields for the given language code.""" translation( @@ -8783,7 +8114,7 @@ type ProductTranslatableContent implements Node @doc(category: "Products") { ): ProductTranslation """Represents an individual item for sale in the storefront.""" - product: Product @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + product: Product @deprecated(reason: "Get model fields from the root level queries.") """List of product attribute values that can be translated.""" attributeValues: [AttributeValueTranslatableContent!]! @@ -8872,11 +8203,7 @@ type PageTranslatableContent implements Node @doc(category: "Pages") { """The ID of the page translatable content.""" id: ID! - """ - The ID of the page to translate. - - Added in Saleor 3.14. - """ + """The ID of the page to translate.""" pageId: ID! """SEO title to translate.""" @@ -8885,6 +8212,13 @@ type PageTranslatableContent implements Node @doc(category: "Pages") { """SEO description to translate.""" seoDescription: String + """ + Slug to translate. + + Added in Saleor 3.21. + """ + slug: String + """Page title to translate.""" title: String! @@ -8900,7 +8234,7 @@ type PageTranslatableContent implements Node @doc(category: "Pages") { Rich text format. For reference see https://editorjs.io/ """ - contentJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `content` field instead.") + contentJson: JSONString @deprecated(reason: "Use the `content` field instead.") """Returns translated page fields for the given language code.""" translation( @@ -8911,7 +8245,7 @@ type PageTranslatableContent implements Node @doc(category: "Pages") { """ A static page that can be manually added by a shop operator through the dashboard. """ - page: Page @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + page: Page @deprecated(reason: "Get model fields from the root level queries.") """List of page content attribute values that can be translated.""" attributeValues: [AttributeValueTranslatableContent!]! @@ -8931,6 +8265,13 @@ type PageTranslation implements Node @doc(category: "Pages") { """Translated SEO description.""" seoDescription: String + """ + Translated page slug. + + Added in Saleor 3.21. + """ + slug: String + """Translated page title.""" title: String @@ -8946,13 +8287,9 @@ type PageTranslation implements Node @doc(category: "Pages") { Rich text format. For reference see https://editorjs.io/ """ - contentJson: JSONString @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `content` field instead.") + contentJson: JSONString @deprecated(reason: "Use the `content` field instead.") - """ - Represents the page fields to translate. - - Added in Saleor 3.14. - """ + """Represents the page fields to translate.""" translatableContent: PageTranslatableContent } @@ -8970,15 +8307,11 @@ type Page implements Node & ObjectWithMetadata @doc(category: "Pages") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -8989,15 +8322,11 @@ type Page implements Node & ObjectWithMetadata @doc(category: "Pages") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -9016,13 +8345,9 @@ type Page implements Node & ObjectWithMetadata @doc(category: "Pages") { Rich text format. For reference see https://editorjs.io/ """ content: JSONString - publicationDate: Date @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `publishedAt` field to fetch the publication date.") + publicationDate: Date @deprecated(reason: "Use the `publishedAt` field to fetch the publication date.") - """ - The page publication date. - - Added in Saleor 3.3. - """ + """The page publication date.""" publishedAt: DateTime """Determines if the page is published.""" @@ -9042,7 +8367,7 @@ type Page implements Node & ObjectWithMetadata @doc(category: "Pages") { Rich text format. For reference see https://editorjs.io/ """ - contentJson: JSONString! @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `content` field instead.") + contentJson: JSONString! @deprecated(reason: "Use the `content` field instead.") """Returns translated page fields for the given language code.""" translation( @@ -9068,15 +8393,11 @@ type PageType implements Node & ObjectWithMetadata @doc(category: "Pages") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -9087,15 +8408,11 @@ type PageType implements Node & ObjectWithMetadata @doc(category: "Pages") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -9149,11 +8466,7 @@ type VoucherTranslatableContent implements Node @doc(category: "Discounts") { """The ID of the voucher translatable content.""" id: ID! - """ - The ID of the voucher to translate. - - Added in Saleor 3.14. - """ + """The ID of the voucher to translate.""" voucherId: ID! """Voucher name to translate.""" @@ -9170,7 +8483,7 @@ type VoucherTranslatableContent implements Node @doc(category: "Discounts") { Requires one of the following permissions: MANAGE_DISCOUNTS. """ - voucher: Voucher @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + voucher: Voucher @deprecated(reason: "Get model fields from the root level queries.") } """Represents voucher translations.""" @@ -9184,11 +8497,7 @@ type VoucherTranslation implements Node @doc(category: "Discounts") { """Translated voucher name.""" name: String - """ - Represents the voucher fields to translate. - - Added in Saleor 3.14. - """ + """Represents the voucher fields to translate.""" translatableContent: VoucherTranslatableContent } @@ -9206,15 +8515,11 @@ type Voucher implements Node & ObjectWithMetadata @doc(category: "Discounts") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -9225,15 +8530,11 @@ type Voucher implements Node & ObjectWithMetadata @doc(category: "Discounts") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -9263,7 +8564,7 @@ type Voucher implements Node & ObjectWithMetadata @doc(category: "Discounts") { last: Int ): VoucherCodeCountableConnection - """The code of the voucher.This field will be removed in Saleor 4.0.""" + """The code of the voucher.""" code: String """The number of times a voucher can be used.""" @@ -9371,8 +8672,6 @@ type Voucher implements Node & ObjectWithMetadata @doc(category: "Discounts") { """ List of product variants this voucher applies to. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_DISCOUNTS. """ variants( @@ -9484,23 +8783,6 @@ type CollectionCountableEdge @doc(category: "Products") { cursor: String! } -type ProductVariantCountableConnection @doc(category: "Products") { - """Pagination data for this connection.""" - pageInfo: PageInfo! - edges: [ProductVariantCountableEdge!]! - - """A total count of items in the collection.""" - totalCount: Int -} - -type ProductVariantCountableEdge @doc(category: "Products") { - """The item at the end of the edge.""" - node: ProductVariant! - - """A cursor for use in pagination.""" - cursor: String! -} - enum DiscountValueTypeEnum @doc(category: "Discounts") { FIXED PERCENTAGE @@ -9537,11 +8819,7 @@ type MenuItemTranslatableContent implements Node @doc(category: "Menu") { """The ID of the menu item translatable content.""" id: ID! - """ - The ID of the menu item to translate. - - Added in Saleor 3.14. - """ + """The ID of the menu item to translate.""" menuItemId: ID! """Name of the menu item to translate.""" @@ -9556,7 +8834,7 @@ type MenuItemTranslatableContent implements Node @doc(category: "Menu") { """ Represents a single item of the related menu. Can store categories, collection or pages. """ - menuItem: MenuItem @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + menuItem: MenuItem @deprecated(reason: "Get model fields from the root level queries.") } """Represents menu item translations.""" @@ -9570,11 +8848,7 @@ type MenuItemTranslation implements Node @doc(category: "Menu") { """Translated menu item name.""" name: String! - """ - Represents the menu item fields to translate. - - Added in Saleor 3.14. - """ + """Represents the menu item fields to translate.""" translatableContent: MenuItemTranslatableContent } @@ -9592,15 +8866,11 @@ type MenuItem implements Node & ObjectWithMetadata @doc(category: "Menu") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -9611,15 +8881,11 @@ type MenuItem implements Node & ObjectWithMetadata @doc(category: "Menu") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -9675,15 +8941,11 @@ type Menu implements Node & ObjectWithMetadata @doc(category: "Menu") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -9694,15 +8956,11 @@ type Menu implements Node & ObjectWithMetadata @doc(category: "Menu") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -9718,8 +8976,6 @@ type Menu implements Node & ObjectWithMetadata @doc(category: "Menu") { """ Represents promotion's original translatable fields and related translations. - -Added in Saleor 3.17. """ type PromotionTranslatableContent implements Node @doc(category: "Discounts") { """ID of the promotion translatable content.""" @@ -9745,11 +9001,7 @@ type PromotionTranslatableContent implements Node @doc(category: "Discounts") { ): PromotionTranslation } -""" -Represents promotion translations. - -Added in Saleor 3.17. -""" +"""Represents promotion translations.""" type PromotionTranslation implements Node @doc(category: "Discounts") { """ID of the promotion translation.""" id: ID! @@ -9767,28 +9019,18 @@ type PromotionTranslation implements Node @doc(category: "Discounts") { """ description: JSONString - """ - Represents the promotion fields to translate. - - Added in Saleor 3.14. - """ + """Represents the promotion fields to translate.""" translatableContent: PromotionTranslatableContent } """ Represents promotion rule's original translatable fields and related translations. - -Added in Saleor 3.17. """ type PromotionRuleTranslatableContent implements Node @doc(category: "Discounts") { """ID of the promotion rule translatable content.""" id: ID! - """ - ID of the promotion rule to translate. - - Added in Saleor 3.14. - """ + """ID of the promotion rule to translate.""" promotionRuleId: ID! """Name of the promotion rule.""" @@ -9808,11 +9050,7 @@ type PromotionRuleTranslatableContent implements Node @doc(category: "Discounts" ): PromotionRuleTranslation } -""" -Represents promotion rule translations. - -Added in Saleor 3.17. -""" +"""Represents promotion rule translations.""" type PromotionRuleTranslation implements Node @doc(category: "Discounts") { """ID of the promotion rule translation.""" id: ID! @@ -9830,28 +9068,20 @@ type PromotionRuleTranslation implements Node @doc(category: "Discounts") { """ description: JSONString - """ - Represents the promotion rule fields to translate. - - Added in Saleor 3.14. - """ + """Represents the promotion rule fields to translate.""" translatableContent: PromotionRuleTranslatableContent } """ Represents sale's original translatable fields and related translations. -DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionTranslatableContent` instead. +DEPRECATED: this type will be removed. Use `PromotionTranslatableContent` instead. """ type SaleTranslatableContent implements Node @doc(category: "Discounts") { """The ID of the sale translatable content.""" id: ID! - """ - The ID of the sale to translate. - - Added in Saleor 3.14. - """ + """The ID of the sale to translate.""" saleId: ID! """Name of the sale to translate.""" @@ -9868,13 +9098,13 @@ type SaleTranslatableContent implements Node @doc(category: "Discounts") { Requires one of the following permissions: MANAGE_DISCOUNTS. """ - sale: Sale @deprecated(reason: "This field will be removed in Saleor 4.0. Get model fields from the root level queries.") + sale: Sale @deprecated(reason: "Get model fields from the root level queries.") } """ Represents sale translations. -DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionTranslation` instead. +DEPRECATED: this type will be removed. Use `PromotionTranslation` instead. """ type SaleTranslation implements Node @doc(category: "Discounts") { """The ID of the sale translation.""" @@ -9886,18 +9116,14 @@ type SaleTranslation implements Node @doc(category: "Discounts") { """Translated name of sale.""" name: String - """ - Represents the sale fields to translate. - - Added in Saleor 3.14. - """ + """Represents the sale fields to translate.""" translatableContent: SaleTranslatableContent } """ Sales allow creating discounts for categories, collections or products and are visible to all the customers. -DEPRECATED: this type will be removed in Saleor 4.0. Use `Promotion` type instead. +DEPRECATED: this type will be removed. Use `Promotion` type instead. """ type Sale implements Node & ObjectWithMetadata @doc(category: "Discounts") { """The ID of the sale.""" @@ -9910,15 +9136,11 @@ type Sale implements Node & ObjectWithMetadata @doc(category: "Discounts") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -9929,15 +9151,11 @@ type Sale implements Node & ObjectWithMetadata @doc(category: "Discounts") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -10027,8 +9245,6 @@ type Sale implements Node & ObjectWithMetadata @doc(category: "Discounts") { """ List of product variants this sale applies to. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_DISCOUNTS. """ variants( @@ -10077,7 +9293,7 @@ enum SaleType @doc(category: "Discounts") { """ Represents sale channel listing. -DEPRECATED: this type will be removed in Saleor 4.0. Use `PromotionRule` type instead. +DEPRECATED: this type will be removed. Use `PromotionRule` type instead. """ type SaleChannelListing implements Node @doc(category: "Discounts") { """The ID of the channel listing.""" @@ -10167,11 +9383,7 @@ input TaxClassFilterInput @doc(category: "Taxes") { countries: [CountryCode!] } -""" -Tax class rates grouped by country. - -Added in Saleor 3.9. -""" +"""Tax class rates grouped by country.""" type TaxCountryConfiguration @doc(category: "Taxes") { """A country for which tax class rates are grouped.""" country: CountryDisplay! @@ -10224,12 +9436,8 @@ type Shop implements ObjectWithMetadata { """List of available payment gateways.""" availablePaymentGateways( - """ - A currency for which gateways will be returned. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `channel` argument instead. - """ - currency: String + """A currency for which gateways will be returned.""" + currency: String @deprecated(reason: "Use `channel` argument instead.") """Slug of a channel for which the data should be returned.""" channel: String @@ -10250,20 +9458,14 @@ type Shop implements ObjectWithMetadata { """ List of all currencies supported by shop's channels. - Added in Saleor 3.1. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ channelCurrencies: [String!]! """List of countries available in the shop.""" countries( - """ - A language code to return the translation for. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - languageCode: LanguageCodeEnum + """A language code to return the translation for.""" + languageCode: LanguageCodeEnum @deprecated """Filtering options for countries""" filter: CountryFilterInput @@ -10307,18 +9509,10 @@ type Shop implements ObjectWithMetadata { """Header text.""" headerText: String - """ - Automatically approve all new fulfillments. - - Added in Saleor 3.1. - """ + """Automatically approve all new fulfillments.""" fulfillmentAutoApprove: Boolean! - """ - Allow to approve fulfillments which are unpaid. - - Added in Saleor 3.1. - """ + """Allow to approve fulfillments which are unpaid.""" fulfillmentAllowUnpaid: Boolean! """ @@ -10345,8 +9539,6 @@ type Shop implements ObjectWithMetadata { """ Default number of minutes stock will be reserved for anonymous checkout or null when stock reservation is disabled. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_SETTINGS. """ reserveStockDurationAnonymousUser: Int @@ -10354,8 +9546,6 @@ type Shop implements ObjectWithMetadata { """ Default number of minutes stock will be reserved for authenticated checkout or null when stock reservation is disabled. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_SETTINGS. """ reserveStockDurationAuthenticatedUser: Int @@ -10363,8 +9553,6 @@ type Shop implements ObjectWithMetadata { """ Default number of maximum line quantity in single checkout (per single checkout line). - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_SETTINGS. """ limitQuantityPerCheckout: Int @@ -10399,8 +9587,6 @@ type Shop implements ObjectWithMetadata { """ Determines if account confirmation by email is enabled. - Added in Saleor 3.14. - Requires one of the following permissions: MANAGE_SETTINGS. """ enableAccountConfirmationByEmail: Boolean @@ -10408,8 +9594,6 @@ type Shop implements ObjectWithMetadata { """ Determines if user can login without confirmation when `enableAccountConfirmation` is enabled. - Added in Saleor 3.15. - Requires one of the following permissions: MANAGE_SETTINGS. """ allowLoginWithoutConfirmation: Boolean @@ -10419,7 +9603,7 @@ type Shop implements ObjectWithMetadata { Requires one of the following permissions: AUTHENTICATED_STAFF_USER. """ - limits: LimitInfo! @deprecated(reason: "This field will be removed in Saleor 4.0.") + limits: LimitInfo! @deprecated """ Saleor API version. @@ -10428,11 +9612,7 @@ type Shop implements ObjectWithMetadata { """ version: String! - """ - Minor Saleor API version. - - Added in Saleor 3.5. - """ + """Minor Saleor API version.""" schemaVersion: String! """ @@ -10445,13 +9625,13 @@ type Shop implements ObjectWithMetadata { availableTaxApps: [App!]! """Include taxes in prices.""" - includeTaxesInPrices: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration.pricesEnteredWithTax` to determine whether prices are entered with tax.") + includeTaxesInPrices: Boolean! @deprecated(reason: "Use `Channel.taxConfiguration.pricesEnteredWithTax` to determine whether prices are entered with tax.") """Display prices with tax in store.""" - displayGrossPrices: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to determine whether to display gross or net prices.") + displayGrossPrices: Boolean! @deprecated(reason: "Use `Channel.taxConfiguration` to determine whether to display gross or net prices.") """Charge taxes on shipping.""" - chargeTaxesOnShipping: Boolean! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `ShippingMethodType.taxClass` to determine whether taxes are calculated for shipping methods; if a tax class is set, the taxes will be calculated, otherwise no tax rate will be applied.") + chargeTaxesOnShipping: Boolean! @deprecated(reason: "Use `ShippingMethodType.taxClass` to determine whether taxes are calculated for shipping methods; if a tax class is set, the taxes will be calculated, otherwise no tax rate will be applied.") } """ @@ -10552,15 +9732,11 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -10571,15 +9747,11 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -10598,24 +9770,20 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { """Determine if the user is active.""" isActive: Boolean! - """ - Determines if user has confirmed email. - - Added in Saleor 3.15. - """ + """Determines if user has confirmed email.""" isConfirmed: Boolean! """List of all user's addresses.""" addresses: [Address!]! """Returns the last open checkout of this user.""" - checkout: Checkout @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `checkoutTokens` field to fetch the user checkouts.") + checkout: Checkout @deprecated(reason: "Use the `checkoutTokens` field to fetch the user checkouts.") """Returns the checkout UUID's assigned to this user.""" checkoutTokens( """Slug of a channel for which the data should be returned.""" channel: String - ): [UUID!] @deprecated(reason: "This field will be removed in Saleor 4.0. Use `checkoutIds` instead.") + ): [UUID!] @deprecated(reason: "Use `checkoutIds` instead.") """Returns the checkout ID's assigned to this user.""" checkoutIds( @@ -10624,9 +9792,7 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { ): [ID!] """ - Returns checkouts assigned to this user. - - Added in Saleor 3.8. + Returns checkouts assigned to this user. The query will not initiate any external requests, including fetching external shipping methods, filtering available shipping methods, or performing external tax calculations. """ checkouts( """Slug of a channel for which the data should be returned.""" @@ -10676,7 +9842,7 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { note: String """ - List of user's orders. Requires one of the following permissions: MANAGE_STAFF, OWNER. + List of user's orders. The query will not initiate any external requests, including filtering available shipping methods, or performing external tax calculations. Requires one of the following permissions: MANAGE_STAFF, OWNER. """ orders( """Return the elements in the list that come before the specified cursor.""" @@ -10707,19 +9873,11 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { """ List of channels the user has access to. The sum of channels from all user groups. If at least one group has `restrictedAccessToChannels` set to False - all channels are returned. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ accessibleChannels: [Channel!] """ Determine if user have restricted access to channels. False if at least one user group has `restrictedAccessToChannels` set to False. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ restrictedAccessToChannels: Boolean! @@ -10732,8 +9890,6 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. """ format: ThumbnailFormatEnum = ORIGINAL ): Image @@ -10762,11 +9918,7 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { """The default billing address of the user.""" defaultBillingAddress: Address - """ - External ID of this user. - - Added in Saleor 3.10. - """ + """External ID of this user.""" externalReference: String """The date when the user last time log in to the system.""" @@ -10780,10 +9932,6 @@ type User implements Node & ObjectWithMetadata @doc(category: "Users") { """ Returns a list of user's stored payment methods that can be used in provided channel. The field returns a list of stored payment methods by payment apps. When `amount` is not provided, 0 will be used as default value. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ storedPaymentMethods( """Slug of a channel for which the data should be returned.""" @@ -10803,15 +9951,11 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -10822,28 +9966,20 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata """The date and time when the checkout was created.""" created: DateTime! - """ - Time of last modification of the given checkout. - - Added in Saleor 3.13. - """ + """Time of last modification of the given checkout.""" updatedAt: DateTime! - lastChange: DateTime! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `updatedAt` instead.") + lastChange: DateTime! @deprecated(reason: "Use `updatedAt` instead.") """ The user assigned to the checkout. Requires one of the following permissions: MANAGE_USERS, HANDLE_PAYMENTS, OWNER. @@ -10859,8 +9995,15 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { """The shipping address of the checkout.""" shippingAddress: Address + """ + The customer note for the checkout. + + Added in Saleor 3.21. + """ + customerNote: String! + """The note for the checkout.""" - note: String! + note: String! @deprecated(reason: "Use `customerNote` instead.") """ The total discount applied to the checkout. Note: Only discount created via voucher are included in this field. @@ -10894,7 +10037,7 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. """ - availableShippingMethods: [ShippingMethod!]! @webhookEventsInfo(asyncEvents: [], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT, CHECKOUT_FILTER_SHIPPING_METHODS]) @deprecated(reason: "This field will be removed in Saleor 4.0. Use `shippingMethods` instead.") + availableShippingMethods: [ShippingMethod!]! @webhookEventsInfo(asyncEvents: [], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT, CHECKOUT_FILTER_SHIPPING_METHODS]) @deprecated(reason: "Use `shippingMethods` instead.") """ Shipping methods that can be used with this checkout. @@ -10905,11 +10048,7 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { """ shippingMethods: [ShippingMethod!]! @webhookEventsInfo(asyncEvents: [], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT, CHECKOUT_FILTER_SHIPPING_METHODS]) - """ - Collection points that can be used for this order. - - Added in Saleor 3.1. - """ + """Collection points that can be used for this order.""" availableCollectionPoints: [Warehouse!]! """ @@ -10934,8 +10073,6 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { """ Date when oldest stock reservation for this checkout expires or null if no stock is reserved. - - Added in Saleor 3.1. """ stockReservationExpires: DateTime @@ -10959,13 +10096,11 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. """ - shippingMethod: ShippingMethod @webhookEventsInfo(asyncEvents: [], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT, CHECKOUT_FILTER_SHIPPING_METHODS]) @deprecated(reason: "This field will be removed in Saleor 4.0. Use `deliveryMethod` instead.") + shippingMethod: ShippingMethod @webhookEventsInfo(asyncEvents: [], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT, CHECKOUT_FILTER_SHIPPING_METHODS]) @deprecated(reason: "Use `deliveryMethod` instead.") """ The delivery method selected for this checkout. - Added in Saleor 3.1. - Triggers the following webhook events: - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. @@ -10980,11 +10115,7 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { """ subtotalPrice: TaxedMoney! @webhookEventsInfo(asyncEvents: [], syncEvents: [CHECKOUT_CALCULATE_TAXES]) - """ - Returns True if checkout has to be exempt from taxes. - - Added in Saleor 3.8. - """ + """Returns True if checkout has to be exempt from taxes.""" taxExemption: Boolean! """The checkout's token.""" @@ -11001,10 +10132,6 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { """ The difference between the paid and the checkout total amount. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Triggers the following webhook events: - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. """ @@ -11015,27 +10142,15 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { """ List of transactions for the checkout. Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS. - - Added in Saleor 3.4. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ transactions: [TransactionItem!] - """ - Determines whether displayed prices should include taxes. - - Added in Saleor 3.9. - """ + """Determines whether displayed prices should include taxes.""" displayGrossPrices: Boolean! """ The authorize status of the checkout. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Triggers the following webhook events: - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. """ @@ -11044,10 +10159,6 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { """ The charge status of the checkout. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Triggers the following webhook events: - CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired. """ @@ -11055,23 +10166,13 @@ type Checkout implements Node & ObjectWithMetadata @doc(category: "Checkout") { """ List of user's stored payment methods that can be used in this checkout session. It uses the channel that the checkout was created in. When `amount` is not provided, `checkout.total` will be used as a default value. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ storedPaymentMethods( """Amount that will be used to fetch stored payment methods.""" amount: PositiveDecimal ): [StoredPaymentMethod!] - """ - List of problems with the checkout. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """List of problems with the checkout.""" problems: [CheckoutProblem!] } @@ -11089,15 +10190,11 @@ type GiftCard implements Node & ObjectWithMetadata @doc(category: "Gift cards") A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -11108,15 +10205,11 @@ type GiftCard implements Node & ObjectWithMetadata @doc(category: "Gift cards") A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -11136,35 +10229,21 @@ type GiftCard implements Node & ObjectWithMetadata @doc(category: "Gift cards") """Date and time when gift card was created.""" created: DateTime! - """ - The user who bought or issued a gift card. - - Added in Saleor 3.1. - """ + """The user who bought or issued a gift card.""" createdBy: User - """ - The customer who used a gift card. - - Added in Saleor 3.1. - """ - usedBy: User @deprecated(reason: "This field will be removed in Saleor 4.0.") + """The customer who used a gift card.""" + usedBy: User @deprecated """ Email address of the user who bought or issued gift card. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_USERS, OWNER. """ createdByEmail: String - """ - Email address of the customer who used a gift card. - - Added in Saleor 3.1. - """ - usedByEmail: String @deprecated(reason: "This field will be removed in Saleor 4.0.") + """Email address of the customer who used a gift card.""" + usedByEmail: String @deprecated """Date and time when gift card was last used.""" lastUsedOn: DateTime @@ -11175,24 +10254,16 @@ type GiftCard implements Node & ObjectWithMetadata @doc(category: "Gift cards") """ App which created the gift card. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_APPS, OWNER. """ app: App - """ - Related gift card product. - - Added in Saleor 3.1. - """ + """Related gift card product.""" product: Product """ List of events associated with the gift card. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_GIFT_CARD. """ events( @@ -11203,37 +10274,27 @@ type GiftCard implements Node & ObjectWithMetadata @doc(category: "Gift cards") """ The gift card tag. - Added in Saleor 3.1. - Requires one of the following permissions: MANAGE_GIFT_CARD. """ tags: [GiftCardTag!]! - """ - Slug of the channel where the gift card was bought. - - Added in Saleor 3.1. - """ + """Slug of the channel where the gift card was bought.""" boughtInChannel: String isActive: Boolean! initialBalance: Money! currentBalance: Money! """The customer who bought a gift card.""" - user: User @deprecated(reason: "This field will be removed in Saleor 4.0. Use `createdBy` field instead.") + user: User @deprecated(reason: "Use `createdBy` field instead.") """End date of gift card.""" - endDate: DateTime @deprecated(reason: "This field will be removed in Saleor 4.0. Use `expiryDate` field instead.") + endDate: DateTime @deprecated(reason: "Use `expiryDate` field instead.") """Start date of gift card.""" - startDate: DateTime @deprecated(reason: "This field will be removed in Saleor 4.0.") + startDate: DateTime @deprecated } -""" -History log of the gift card. - -Added in Saleor 3.1. -""" +"""History log of the gift card.""" type GiftCardEvent implements Node @doc(category: "Gift cards") { """ID of the event associated with a gift card.""" id: ID! @@ -11282,7 +10343,6 @@ type GiftCardEvent implements Node @doc(category: "Gift cards") { oldExpiryDate: Date } -"""An enumeration.""" enum GiftCardEventsEnum @doc(category: "Gift cards") { ISSUED BOUGHT @@ -11317,11 +10377,7 @@ input GiftCardEventFilterInput @doc(category: "Gift cards") { orders: [ID!] } -""" -The gift card tag. - -Added in Saleor 3.1. -""" +"""The gift card tag.""" type GiftCardTag implements Node @doc(category: "Gift cards") { """ID of the tag associated with a gift card.""" id: ID! @@ -11335,49 +10391,33 @@ type CheckoutLine implements Node & ObjectWithMetadata @doc(category: "Checkout" """The ID of the checkout line.""" id: ID! - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.5. - """ + """List of private metadata items. Requires staff permissions to access.""" privateMetadata: [MetadataItem!]! """ A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.5. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.5. """ privateMetafields(keys: [String!]): Metadata - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.5. - """ + """List of public metadata items. Can be accessed without permissions.""" metadata: [MetadataItem!]! """ A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.5. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.5. """ metafields(keys: [String!]): Metadata @@ -11398,6 +10438,13 @@ type CheckoutLine implements Node & ObjectWithMetadata @doc(category: "Checkout" """The unit price of the checkout line, without discounts.""" undiscountedUnitPrice: Money! + """ + The unit price of the checkout line prior to promotion. + + Added in Saleor 3.21. + """ + priorUnitPrice: Money + """ The sum of the checkout line price, taxes and discounts. @@ -11409,16 +10456,17 @@ type CheckoutLine implements Node & ObjectWithMetadata @doc(category: "Checkout" """The sum of the checkout line price, without discounts.""" undiscountedTotalPrice: Money! - """Indicates whether the item need to be delivered.""" - requiresShipping: Boolean! - """ - List of problems with the checkout line. - - Added in Saleor 3.15. + The sum of the checkout line price prior to promotion. - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Added in Saleor 3.21. """ + priorTotalPrice: Money + + """Indicates whether the item need to be delivered.""" + requiresShipping: Boolean! + + """List of problems with the checkout line.""" problems: [CheckoutLineProblem!] """ @@ -11431,21 +10479,11 @@ type CheckoutLine implements Node & ObjectWithMetadata @doc(category: "Checkout" isGift: Boolean } -""" -Represents an problem in the checkout line. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents an problem in the checkout line.""" union CheckoutLineProblem = CheckoutLineProblemInsufficientStock | CheckoutLineProblemVariantNotAvailable """ Indicates insufficient stock for a given checkout line.Placing the order will not be possible until solving this problem. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type CheckoutLineProblemInsufficientStock @doc(category: "Checkout") { """Available quantity of a variant.""" @@ -11460,10 +10498,6 @@ type CheckoutLineProblemInsufficientStock @doc(category: "Checkout") { """ The variant assigned to the checkout line is not available.Placing the order will not be possible until solving this problem. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type CheckoutLineProblemVariantNotAvailable @doc(category: "Checkout") { """The line that has variant that is not available.""" @@ -11472,18 +10506,10 @@ type CheckoutLineProblemVariantNotAvailable @doc(category: "Checkout") { """ Represents a delivery method chosen for the checkout. `Warehouse` type is used when checkout is marked as "click and collect" and `ShippingMethod` otherwise. - -Added in Saleor 3.1. """ union DeliveryMethod = Warehouse | ShippingMethod -""" -Represents a payment transaction. - -Added in Saleor 3.4. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents a payment transaction.""" type TransactionItem implements Node & ObjectWithMetadata @doc(category: "Payments") { """The ID of the object.""" id: ID! @@ -11495,15 +10521,11 @@ type TransactionItem implements Node & ObjectWithMetadata @doc(category: "Paymen A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -11514,23 +10536,15 @@ type TransactionItem implements Node & ObjectWithMetadata @doc(category: "Paymen A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata - """ - The transaction token. - - Added in Saleor 3.14. - """ + """The transaction token.""" token: UUID! """Date and time at which payment transaction was created.""" @@ -11547,96 +10561,50 @@ type TransactionItem implements Node & ObjectWithMetadata @doc(category: "Paymen """Total amount authorized for this payment.""" authorizedAmount: Money! - """ - Total amount of ongoing authorization requests for the transaction. - - Added in Saleor 3.13. - """ + """Total amount of ongoing authorization requests for the transaction.""" authorizePendingAmount: Money! """Total amount refunded for this payment.""" refundedAmount: Money! - """ - Total amount of ongoing refund requests for the transaction. - - Added in Saleor 3.13. - """ + """Total amount of ongoing refund requests for the transaction.""" refundPendingAmount: Money! - """ - Total amount canceled for this payment. - - Added in Saleor 3.13. - """ + """Total amount canceled for this payment.""" canceledAmount: Money! - """ - Total amount of ongoing cancel requests for the transaction. - - Added in Saleor 3.13. - """ + """Total amount of ongoing cancel requests for the transaction.""" cancelPendingAmount: Money! """Total amount charged for this payment.""" chargedAmount: Money! - """ - Total amount of ongoing charge requests for the transaction. - - Added in Saleor 3.13. - """ + """Total amount of ongoing charge requests for the transaction.""" chargePendingAmount: Money! - """ - Name of the transaction. - - Added in Saleor 3.13. - """ + """Name of the transaction.""" name: String! - """ - Message related to the transaction. - - Added in Saleor 3.13. - """ + """Message related to the transaction.""" message: String! - """ - PSP reference of transaction. - - Added in Saleor 3.13. - """ + """PSP reference of transaction.""" pspReference: String! - """ - The related order. - - Added in Saleor 3.6. - """ + """The related order.""" order: Order - """ - The related checkout. - - Added in Saleor 3.14. - """ + """The related checkout.""" checkout: Checkout """List of all transaction's events.""" events: [TransactionEvent!]! - """ - User or App that created the transaction. - - Added in Saleor 3.13. - """ + """User or App that created the transaction.""" createdBy: UserOrApp """ The url that will allow to redirect user to payment provider page with transaction details. - - Added in Saleor 3.13. """ externalUrl: String! } @@ -11667,15 +10635,11 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -11686,15 +10650,11 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -11712,9 +10672,7 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """ user: User - """ - Google Analytics tracking client ID. This field will be removed in Saleor 4.0. - """ + """Google Analytics tracking client ID.""" trackingClientId: String! """ @@ -11755,11 +10713,7 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """Shipping methods related to this order.""" shippingMethods: [ShippingMethod!]! - """ - Collection points that can be used for this order. - - Added in Saleor 3.1. - """ + """Collection points that can be used for this order.""" availableCollectionPoints: [Warehouse!]! """ @@ -11785,31 +10739,17 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """User-friendly payment status.""" paymentStatusDisplay: String! - """ - The authorize status of the order. - - Added in Saleor 3.4. - """ + """The authorize status of the order.""" authorizeStatus: OrderAuthorizeStatusEnum! - """ - The charge status of the order. - - Added in Saleor 3.4. - """ + """The charge status of the order.""" chargeStatus: OrderChargeStatusEnum! - """ - Returns True if order has to be exempt from taxes. - - Added in Saleor 3.8. - """ + """Returns True if order has to be exempt from taxes.""" taxExemption: Boolean! """ List of transactions for the order. Requires one of the following permissions: MANAGE_ORDERS, HANDLE_PAYMENTS. - - Added in Saleor 3.4. """ transactions: [TransactionItem!]! @@ -11823,14 +10763,14 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { undiscountedTotal: TaxedMoney! """Shipping method for this order.""" - shippingMethod: ShippingMethod @deprecated(reason: "This field will be removed in Saleor 4.0. Use `deliveryMethod` instead.") + shippingMethod: ShippingMethod @deprecated(reason: "Use `deliveryMethod` instead.") """ Undiscounted total price of shipping. Added in Saleor 3.19. """ - undiscountedShippingPrice: Money + undiscountedShippingPrice: Money! """Total price of shipping.""" shippingPrice: TaxedMoney! @@ -11841,33 +10781,21 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """ Denormalized tax class assigned to the shipping method. - Added in Saleor 3.9. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ shippingTaxClass: TaxClass - """ - Denormalized name of the tax class assigned to the shipping method. - - Added in Saleor 3.9. - """ + """Denormalized name of the tax class assigned to the shipping method.""" shippingTaxClassName: String - """ - Denormalized public metadata of the shipping method's tax class. - - Added in Saleor 3.9. - """ + """Denormalized public metadata of the shipping method's tax class.""" shippingTaxClassMetadata: [MetadataItem!]! """ Denormalized private metadata of the shipping method's tax class. Requires staff permissions to access. - - Added in Saleor 3.9. """ shippingTaxClassPrivateMetadata: [MetadataItem!]! - token: String! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `id` instead.") + token: String! @deprecated(reason: "Use `id` instead.") """Voucher linked to the order.""" voucher: Voucher @@ -11906,20 +10834,12 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { totalAuthorized: Money! """Amount captured for the order.""" - totalCaptured: Money! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `totalCharged` instead.") + totalCaptured: Money! @deprecated(reason: "Use `totalCharged` instead.") - """ - Amount charged for the order. - - Added in Saleor 3.13. - """ + """Amount charged for the order.""" totalCharged: Money! - """ - Amount canceled for the order. - - Added in Saleor 3.13. - """ + """Amount canceled for the order.""" totalCanceled: Money! """ @@ -11940,25 +10860,21 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """Returns True, if order requires shipping.""" isShippingRequired: Boolean! - """ - The delivery method selected for this order. - - Added in Saleor 3.1. - """ + """The delivery method selected for this order.""" deliveryMethod: DeliveryMethod - languageCode: String! @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `languageCodeEnum` field to fetch the language code. ") + languageCode: String! @deprecated(reason: "Use the `languageCodeEnum` field to fetch the language code.") """Order language code.""" languageCodeEnum: LanguageCodeEnum! """Returns applied discount.""" - discount: Money @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `discounts` field instead.") + discount: Money @deprecated(reason: "Use the `discounts` field instead.") """Discount name.""" - discountName: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `discounts` field instead.") + discountName: String @deprecated(reason: "Use the `discounts` field instead.") """Translated discount name.""" - translatedDiscountName: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use the `discounts` field instead. ") + translatedDiscountName: String @deprecated(reason: "Use the `discounts` field instead.") """List of all discounts assigned to the order.""" discounts: [OrderDiscount!]! @@ -11966,34 +10882,18 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """List of errors that occurred during order validation.""" errors: [OrderError!]! - """ - Determines whether displayed prices should include taxes. - - Added in Saleor 3.9. - """ + """Determines whether displayed prices should include taxes.""" displayGrossPrices: Boolean! - """ - External ID of this order. - - Added in Saleor 3.10. - """ + """External ID of this order.""" externalReference: String - """ - ID of the checkout that the order was created from. - - Added in Saleor 3.11. - """ + """ID of the checkout that the order was created from.""" checkoutId: ID """ List of granted refunds. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_ORDERS. """ grantedRefunds: [OrderGrantedRefund!]! @@ -12001,30 +10901,16 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """ Total amount of granted refund. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_ORDERS. """ totalGrantedRefund: Money! - """ - Total refund amount for the order. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Total refund amount for the order.""" totalRefunded: Money! """ Total amount of ongoing refund requests for the order's transactions. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_ORDERS. """ totalRefundPending: Money! @@ -12032,10 +10918,6 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """ Total amount of ongoing authorize requests for the order's transactions. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_ORDERS. """ totalAuthorizePending: Money! @@ -12043,10 +10925,6 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """ Total amount of ongoing charge requests for the order's transactions. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_ORDERS. """ totalChargePending: Money! @@ -12054,10 +10932,6 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """ Total amount of ongoing cancel requests for the order's transactions. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_ORDERS. """ totalCancelPending: Money! @@ -12065,16 +10939,11 @@ type Order implements Node & ObjectWithMetadata @doc(category: "Orders") { """ The difference amount between granted refund and the amounts that are pending and refunded. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires one of the following permissions: MANAGE_ORDERS. """ totalRemainingGrant: Money! } -"""An enumeration.""" enum OrderStatus @doc(category: "Orders") { DRAFT UNCONFIRMED @@ -12099,15 +10968,11 @@ type Fulfillment implements Node & ObjectWithMetadata @doc(category: "Orders") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -12118,15 +10983,11 @@ type Fulfillment implements Node & ObjectWithMetadata @doc(category: "Orders") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -12151,22 +11012,13 @@ type Fulfillment implements Node & ObjectWithMetadata @doc(category: "Orders") { """Warehouse from fulfillment was fulfilled.""" warehouse: Warehouse - """ - Amount of refunded shipping price. - - Added in Saleor 3.14. - """ + """Amount of refunded shipping price.""" shippingRefundedAmount: Money - """ - Total refunded amount assigned to this fulfillment. - - Added in Saleor 3.14. - """ + """Total refunded amount assigned to this fulfillment.""" totalRefundedAmount: Money } -"""An enumeration.""" enum FulfillmentStatus @doc(category: "Orders") { FULFILLED REFUNDED @@ -12194,49 +11046,33 @@ type OrderLine implements Node & ObjectWithMetadata @doc(category: "Orders") { """ID of the order line.""" id: ID! - """ - List of private metadata items. Requires staff permissions to access. - - Added in Saleor 3.5. - """ + """List of private metadata items. Requires staff permissions to access.""" privateMetadata: [MetadataItem!]! """ A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.5. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.5. """ privateMetafields(keys: [String!]): Metadata - """ - List of public metadata items. Can be accessed without permissions. - - Added in Saleor 3.5. - """ + """List of public metadata items. Can be accessed without permissions.""" metadata: [MetadataItem!]! """ A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.5. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.5. """ metafields(keys: [String!]): Metadata @@ -12261,9 +11097,6 @@ type OrderLine implements Node & ObjectWithMetadata @doc(category: "Orders") { """Number of variant items fulfilled.""" quantityFulfilled: Int! - """Reason for any discounts applied on a product in the order.""" - unitDiscountReason: String - """Rate of tax applied on product variant.""" taxRate: Float! digitalContentUrl: DigitalContentUrl @@ -12275,37 +11108,47 @@ type OrderLine implements Node & ObjectWithMetadata @doc(category: "Orders") { """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.6. """ format: ThumbnailFormatEnum = ORIGINAL ): Image - """Price of the single item in the order line.""" + """ + Price of the single item in the order line with all the line-level discounts and order-level discount portions applied. + """ unitPrice: TaxedMoney! """ - Price of the single item in the order line without applied an order line discount. + Price of the single item in the order line without any discount applied. """ undiscountedUnitPrice: TaxedMoney! - """The discount applied to the single order line.""" + """ + Sum of the line-level discounts applied to the order line. Order-level discounts which affect the line are not visible in this field. For order-level discount portion (if any), please query `order.discounts` field. + """ unitDiscount: Money! - """Value of the discount. Can store fixed value or percent value""" + """ + Reason for line-level discounts applied on the order line. Order-level discounts which affect the line are not visible in this field. For order-level discount reason (if any), please query `order.discounts` field. + """ + unitDiscountReason: String + + """ + Value of the discount. Can store fixed value or percent value. This field shouldn't be used when multiple discounts affect the line. There is a limitation, that after running `checkoutComplete` mutation the field always stores fixed value. + """ unitDiscountValue: PositiveDecimal! + """ + Type of the discount: `fixed` or `percent`. This field shouldn't be used when multiple discounts affect the line. There is a limitation, that after running `checkoutComplete` mutation the field is always set to `fixed`. + """ + unitDiscountType: DiscountValueTypeEnum + """Price of the order line.""" totalPrice: TaxedMoney! """Price of the order line without discounts.""" undiscountedTotalPrice: TaxedMoney! - """ - Returns True, if the line unit price was overridden. - - Added in Saleor 3.14. - """ + """Returns True, if the line unit price was overridden.""" isPriceOverridden: Boolean """ @@ -12328,56 +11171,31 @@ type OrderLine implements Node & ObjectWithMetadata @doc(category: "Orders") { """ Denormalized sale ID, set when order line is created for a product variant that is on sale. - - Added in Saleor 3.14. """ saleId: ID - """ - A quantity of items remaining to be fulfilled. - - Added in Saleor 3.1. - """ + """A quantity of items remaining to be fulfilled.""" quantityToFulfill: Int! - """Type of the discount: fixed or percent""" - unitDiscountType: DiscountValueTypeEnum - """ Denormalized tax class of the product in this order line. - Added in Saleor 3.9. - Requires one of the following permissions: AUTHENTICATED_STAFF_USER, AUTHENTICATED_APP. """ taxClass: TaxClass - """ - Denormalized name of the tax class. - - Added in Saleor 3.9. - """ + """Denormalized name of the tax class.""" taxClassName: String - """ - Denormalized public metadata of the tax class. - - Added in Saleor 3.9. - """ + """Denormalized public metadata of the tax class.""" taxClassMetadata: [MetadataItem!]! """ Denormalized private metadata of the tax class. Requires staff permissions to access. - - Added in Saleor 3.9. """ taxClassPrivateMetadata: [MetadataItem!]! - """ - Voucher code that was used for this order line. - - Added in Saleor 3.14. - """ + """Voucher code that was used for this order line.""" voucherCode: String """ @@ -12388,6 +11206,13 @@ type OrderLine implements Node & ObjectWithMetadata @doc(category: "Orders") { Note: this API is currently in Feature Preview and can be subject to changes at later point. """ isGift: Boolean + + """ + List of applied discounts + + Added in Saleor 3.21. + """ + discounts: [OrderLineDiscount!] } """ @@ -12417,6 +11242,48 @@ type Allocation implements Node @doc(category: "Products") { warehouse: Warehouse! } +"""Represent the discount applied to order line.""" +type OrderLineDiscount @doc(category: "Orders") { + """The ID of discount applied.""" + id: ID! + + """The type of applied discount: Sale, Voucher or Manual.""" + type: OrderDiscountType! + + """The name of applied discount.""" + name: String + + """Translated name of the applied discount.""" + translatedName: String + + """Type of the discount: fixed or percent""" + valueType: DiscountValueTypeEnum! + + """Value of the discount. Can store fixed value or percent value""" + value: PositiveDecimal! + + """ + Explanation for the applied discount. + + Requires one of the following permissions: MANAGE_ORDERS. + """ + reason: String + + """The discount amount applied to the line item.""" + total: Money! + + """The discount amount applied to the single line unit.""" + unit: Money! +} + +enum OrderDiscountType @doc(category: "Discounts") { + SALE + VOUCHER + MANUAL + PROMOTION + ORDER_PROMOTION +} + enum OrderAction @doc(category: "Payments") { """Represents the capture action.""" CAPTURE @@ -12440,15 +11307,11 @@ type Invoice implements ObjectWithMetadata & Job & Node @doc(category: "Orders") A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -12459,15 +11322,11 @@ type Invoice implements ObjectWithMetadata & Job & Node @doc(category: "Orders") A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -12490,18 +11349,12 @@ type Invoice implements ObjectWithMetadata & Job & Node @doc(category: "Orders") number: String """URL to view an invoice.""" - externalUrl: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `url` field.This field will be removed in 4.0") + externalUrl: String @deprecated(reason: "Use `url` field.") - """ - URL to view/download an invoice. This can be an internal URL if the Invoicing Plugin was used or an external URL if it has been provided. - """ + """URL to view/download an invoice.""" url: String - """ - Order related to the invoice. - - Added in Saleor 3.10. - """ + """Order related to the invoice.""" order: Order } @@ -12519,7 +11372,6 @@ interface Job { message: String } -"""An enumeration.""" enum JobStatusEnum { PENDING SUCCESS @@ -12527,7 +11379,6 @@ enum JobStatusEnum { DELETED } -"""An enumeration.""" enum OrderOriginEnum @doc(category: "Orders") { CHECKOUT DRAFT @@ -12535,7 +11386,6 @@ enum OrderOriginEnum @doc(category: "Orders") { BULK_CREATE } -"""An enumeration.""" enum PaymentChargeStatusEnum @doc(category: "Payments") { NOT_CHARGED PENDING @@ -12608,15 +11458,11 @@ type Payment implements Node & ObjectWithMetadata @doc(category: "Payments") { A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -12627,15 +11473,11 @@ type Payment implements Node & ObjectWithMetadata @doc(category: "Payments") { A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -12710,18 +11552,10 @@ type Payment implements Node & ObjectWithMetadata @doc(category: "Payments") { """The details of the card used for this payment.""" creditCard: CreditCard - """ - Informs whether this is a partial payment. - - Added in Saleor 3.14. - """ + """Informs whether this is a partial payment.""" partial: Boolean! - """ - PSP reference of the payment. - - Added in Saleor 3.14. - """ + """PSP reference of the payment.""" pspReference: String } @@ -12755,7 +11589,6 @@ type Transaction implements Node @doc(category: "Payments") { amount: Money } -"""An enumeration.""" enum TransactionKind @doc(category: "Payments") { EXTERNAL AUTH @@ -12856,13 +11689,7 @@ type OrderEvent implements Node @doc(category: "Orders") { """The order which is related to this order.""" relatedOrder: Order - """ - The order event which is related to this event. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The order event which is related to this event.""" related: OrderEvent """The discount applied to the order.""" @@ -12880,6 +11707,7 @@ enum OrderEventsEnum @doc(category: "Orders") { REMOVED_PRODUCTS PLACED PLACED_FROM_DRAFT + PLACED_AUTOMATICALLY_FROM_PAID_CHECKOUT OVERSOLD_ITEMS CANCELED EXPIRED @@ -12925,7 +11753,6 @@ enum OrderEventsEnum @doc(category: "Orders") { OTHER } -"""An enumeration.""" enum OrderEventsEmailsEnum @doc(category: "Orders") { PAYMENT_CONFIRMATION CONFIRMED @@ -13003,16 +11830,14 @@ type OrderDiscount implements Node @doc(category: "Discounts") { reason: String """Returns amount of discount.""" - amount: Money! -} + amount: Money! @deprecated(reason: "Use `total` instead.") -"""An enumeration.""" -enum OrderDiscountType @doc(category: "Discounts") { - SALE - VOUCHER - MANUAL - PROMOTION - ORDER_PROMOTION + """ + The amount of discount applied to the order. + + Added in Saleor 3.21. + """ + total: Money! } type OrderError @doc(category: "Orders") { @@ -13040,7 +11865,6 @@ type OrderError @doc(category: "Orders") { addressType: AddressTypeEnum } -"""An enumeration.""" enum OrderErrorCode @doc(category: "Orders") { BILLING_ADDRESS_NOT_SET CANNOT_CANCEL_FULFILLMENT @@ -13078,21 +11902,15 @@ enum OrderErrorCode @doc(category: "Orders") { INVALID_VOUCHER_CODE NON_EDITABLE_GIFT_LINE NON_REMOVABLE_GIFT_LINE + MISSING_ADDRESS_DATA } -"""An enumeration.""" enum AddressTypeEnum { BILLING SHIPPING } -""" -The details of granted refund. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""The details of granted refund.""" type OrderGrantedRefund @doc(category: "Orders") { id: ID! @@ -13118,20 +11936,10 @@ type OrderGrantedRefund @doc(category: "Orders") { """ If true, the refunded amount includes the shipping price.If false, the refunded amount does not include the shipping price. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ shippingCostsIncluded: Boolean! - """ - Lines assigned to the granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Lines assigned to the granted refund.""" lines: [OrderGrantedRefundLine!] """ @@ -13156,13 +11964,7 @@ type OrderGrantedRefund @doc(category: "Orders") { transaction: TransactionItem } -""" -Represents granted refund line. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents granted refund line.""" type OrderGrantedRefundLine { id: ID! @@ -13199,53 +12001,27 @@ type TransactionEvent implements Node @doc(category: "Payments") { """Date and time at which a transaction event was created.""" createdAt: DateTime! - """ - PSP reference of transaction. - - Added in Saleor 3.13. - """ + """PSP reference of transaction.""" pspReference: String! - """ - Message related to the transaction's event. - - Added in Saleor 3.13. - """ + """Message related to the transaction's event.""" message: String! """ The url that will allow to redirect user to payment provider page with transaction details. - - Added in Saleor 3.13. """ externalUrl: String! - """ - The amount related to this event. - - Added in Saleor 3.13. - """ + """The amount related to this event.""" amount: Money! - """ - The type of action related to this event. - - Added in Saleor 3.13. - """ + """The type of action related to this event.""" type: TransactionEventTypeEnum - """ - User or App that created the transaction event. - - Added in Saleor 3.13. - """ + """User or App that created the transaction event.""" createdBy: UserOrApp - """ - Idempotency key assigned to the event. - - Added in Saleor 3.14. - """ + """Idempotency key assigned to the event.""" idempotencyKey: String } @@ -13344,10 +12120,6 @@ enum CheckoutChargeStatusEnum @doc(category: "Checkout") { """ Represents a payment method stored for user (tokenized) in payment gateway. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type StoredPaymentMethod @doc(category: "Payments") { """Stored payment method ID.""" @@ -13390,13 +12162,7 @@ enum TokenizedPaymentFlowEnum @doc(category: "Payments") { scalar JSON -""" -Represents an problem in the checkout. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents an problem in the checkout.""" union CheckoutProblem = CheckoutLineProblemInsufficientStock | CheckoutLineProblemVariantNotAvailable type CheckoutCountableConnection @doc(category: "Checkout") { @@ -13488,22 +12254,10 @@ type Group implements Node @doc(category: "Users") { """ userCanManage: Boolean! - """ - List of channels the group has access to. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """List of channels the group has access to.""" accessibleChannels: [Channel!] - """ - Determine if the group have restricted access to channels. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Determine if the group have restricted access to channels.""" restrictedAccessToChannels: Boolean! } @@ -13537,7 +12291,6 @@ type CustomerEvent implements Node @doc(category: "Users") { orderLine: OrderLine } -"""An enumeration.""" enum CustomerEventsEnum @doc(category: "Users") { ACCOUNT_CREATED ACCOUNT_ACTIVATED @@ -13572,8 +12325,6 @@ type PaymentSource @doc(category: "Payments") { """ List of public metadata items. - Added in Saleor 3.1. - Can be accessed without permissions. """ metadata: [MetadataItem!]! @@ -13614,7 +12365,6 @@ type GiftCardSettings @doc(category: "Gift cards") { expiryPeriod: TimePeriod } -"""An enumeration.""" enum GiftCardSettingsExpiryTypeEnum @doc(category: "Gift cards") { NEVER_EXPIRE EXPIRY_PERIOD @@ -13628,7 +12378,6 @@ type TimePeriod { type: TimePeriodTypeEnum! } -"""An enumeration.""" enum TimePeriodTypeEnum { DAY WEEK @@ -13665,11 +12414,7 @@ input CategoryFilterInput @doc(category: "Products") { ids: [ID!] slugs: [String!] - """ - Filter by when was the most recent update. - - Added in Saleor 3.17. - """ + """Filter by when was the most recent update.""" updatedAt: DateTimeRangeInput } @@ -13688,12 +12433,8 @@ input CategorySortingInput @doc(category: "Products") { """Specifies the direction in which to sort categories.""" direction: OrderDirection! - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String + """Specifies the channel in which to sort the data.""" + channel: String @deprecated(reason: "Use root-level channel argument instead.") """Sort categories by the selected field.""" field: CategorySortField! @@ -13717,12 +12458,8 @@ input CollectionFilterInput @doc(category: "Products") { ids: [ID!] slugs: [String!] - """ - Specifies the channel by which the data should be filtered. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String + """Specifies the channel by which the data should be filtered.""" + channel: String @deprecated(reason: "Use root-level channel argument instead.") } enum CollectionPublished @doc(category: "Products") { @@ -13745,12 +12482,8 @@ input CollectionSortingInput @doc(category: "Products") { """Specifies the direction in which to sort collections.""" direction: OrderDirection! - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String + """Specifies the channel in which to sort the data.""" + channel: String @deprecated(reason: "Use root-level channel argument instead.") """Sort collections by the selected field.""" field: CollectionSortField! @@ -13824,38 +12557,6 @@ enum ProductTypeSortField @doc(category: "Products") { SHIPPING_REQUIRED } -input ProductVariantFilterInput @doc(category: "Products") { - search: String - sku: [String!] - metadata: [MetadataFilter!] - isPreorder: Boolean - updatedAt: DateTimeRangeInput -} - -input ProductVariantWhereInput @doc(category: "Products") { - metadata: [MetadataFilter!] - ids: [ID!] - - """List of conditions that must be met.""" - AND: [ProductVariantWhereInput!] - - """A list of conditions of which at least one must be met.""" - OR: [ProductVariantWhereInput!] -} - -input ProductVariantSortingInput @doc(category: "Products") { - """Specifies the direction in which to sort productVariants.""" - direction: OrderDirection! - - """Sort productVariants by the selected field.""" - field: ProductVariantSortField! -} - -enum ProductVariantSortField @doc(category: "Products") { - """Sort products variants by last modified at.""" - LAST_MODIFIED_AT -} - type PaymentCountableConnection @doc(category: "Payments") { """Pagination data for this connection.""" pageInfo: PageInfo! @@ -13874,11 +12575,7 @@ type PaymentCountableEdge @doc(category: "Payments") { } input PaymentFilterInput @doc(category: "Payments") { - """ - Filter by ids. - - Added in Saleor 3.8. - """ + """Filter by ids.""" ids: [ID!] checkouts: [ID!] } @@ -13918,32 +12615,16 @@ enum PageSortField @doc(category: "Pages") { """Sort pages by visibility.""" VISIBILITY - """ - Sort pages by creation date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ + """Sort pages by creation date.""" CREATION_DATE - """ - Sort pages by publication date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ + """Sort pages by publication date.""" PUBLICATION_DATE - """ - Sort pages by publication date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ + """Sort pages by publication date.""" PUBLISHED_AT - """ - Sort pages by creation date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ + """Sort pages by creation date.""" CREATED_AT } @@ -14027,18 +12708,10 @@ enum OrderSortField @doc(category: "Orders") { """ RANK - """ - Sort orders by creation date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ + """Sort orders by creation date.""" CREATION_DATE - """ - Sort orders by creation date. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ + """Sort orders by creation date.""" CREATED_AT """Sort orders by last modified at.""" @@ -14186,11 +12859,7 @@ enum GiftCardSortField @doc(category: "Gift cards") { """Sort gift cards by current balance.""" CURRENT_BALANCE - """ - Sort gift cards by created at. - - Added in Saleor 3.8. - """ + """Sort gift cards by created at.""" CREATED_AT } @@ -14277,7 +12946,6 @@ type ConfigurationItem { label: String } -"""An enumeration.""" enum ConfigurationTypeFieldEnum { STRING MULTILINE @@ -14370,12 +13038,8 @@ input SaleSortingInput @doc(category: "Discounts") { """Specifies the direction in which to sort sales.""" direction: OrderDirection! - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String + """Specifies the channel in which to sort the data.""" + channel: String @deprecated(reason: "Use root-level channel argument instead.") """Sort sales by the selected field.""" field: SaleSortField! @@ -14445,23 +13109,15 @@ input VoucherSortingInput @doc(category: "Discounts") { """Specifies the direction in which to sort vouchers.""" direction: OrderDirection! - """ - Specifies the channel in which to sort the data. - - DEPRECATED: this field will be removed in Saleor 4.0. Use root-level channel argument instead. - """ - channel: String + """Specifies the channel in which to sort the data.""" + channel: String @deprecated(reason: "Use root-level channel argument instead.") """Sort vouchers by the selected field.""" field: VoucherSortField! } enum VoucherSortField { - """ - Sort vouchers by code. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ + """Sort vouchers by code.""" CODE """ @@ -14500,10 +13156,6 @@ enum VoucherSortField { """ Represents the promotion that allow creating discounts based on given conditions, and is visible to all the customers. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type Promotion implements Node & ObjectWithMetadata @doc(category: "Discounts") { id: ID! @@ -14515,15 +13167,11 @@ type Promotion implements Node & ObjectWithMetadata @doc(category: "Discounts") A single key from private metadata. Requires staff permissions to access. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ privateMetafield(key: String!): String """ Private metadata. Requires staff permissions to access. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ privateMetafields(keys: [String!]): Metadata @@ -14534,15 +13182,11 @@ type Promotion implements Node & ObjectWithMetadata @doc(category: "Discounts") A single key from public metadata. Tip: Use GraphQL aliases to fetch multiple keys. - - Added in Saleor 3.3. """ metafield(key: String!): String """ Public metadata. Use `keys` to control which fields you want to include. The default is to include everything. - - Added in Saleor 3.3. """ metafields(keys: [String!]): Metadata @@ -14586,7 +13230,6 @@ type Promotion implements Node & ObjectWithMetadata @doc(category: "Discounts") events: [PromotionEvent!] } -"""An enumeration.""" enum PromotionTypeEnum @doc(category: "Discounts") { CATALOGUE ORDER @@ -14594,10 +13237,6 @@ enum PromotionTypeEnum @doc(category: "Discounts") { """ Represents the promotion rule that specifies the conditions that must be met to apply the promotion discount. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type PromotionRule implements Node @doc(category: "Discounts") { id: ID! @@ -14685,13 +13324,11 @@ type PromotionRule implements Node @doc(category: "Discounts") { giftsLimit: Int } -"""An enumeration.""" enum RewardValueTypeEnum @doc(category: "Discounts") { FIXED PERCENTAGE } -"""An enumeration.""" enum RewardTypeEnum @doc(category: "Discounts") { SUBTOTAL_DISCOUNT GIFT @@ -14699,13 +13336,7 @@ enum RewardTypeEnum @doc(category: "Discounts") { union PromotionEvent = PromotionCreatedEvent | PromotionUpdatedEvent | PromotionStartedEvent | PromotionEndedEvent | PromotionRuleCreatedEvent | PromotionRuleUpdatedEvent | PromotionRuleDeletedEvent -""" -History log of the promotion created event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""History log of the promotion created event.""" type PromotionCreatedEvent implements Node & PromotionEventInterface @doc(category: "Discounts") { id: ID! @@ -14740,7 +13371,6 @@ interface PromotionEventInterface { createdBy: UserOrApp } -"""An enumeration.""" enum PromotionEventsEnum @doc(category: "Discounts") { PROMOTION_CREATED PROMOTION_UPDATED @@ -14751,13 +13381,7 @@ enum PromotionEventsEnum @doc(category: "Discounts") { RULE_DELETED } -""" -History log of the promotion updated event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""History log of the promotion updated event.""" type PromotionUpdatedEvent implements Node & PromotionEventInterface @doc(category: "Discounts") { id: ID! @@ -14775,13 +13399,7 @@ type PromotionUpdatedEvent implements Node & PromotionEventInterface @doc(catego createdBy: UserOrApp } -""" -History log of the promotion started event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""History log of the promotion started event.""" type PromotionStartedEvent implements Node & PromotionEventInterface @doc(category: "Discounts") { id: ID! @@ -14799,13 +13417,7 @@ type PromotionStartedEvent implements Node & PromotionEventInterface @doc(catego createdBy: UserOrApp } -""" -History log of the promotion ended event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""History log of the promotion ended event.""" type PromotionEndedEvent implements Node & PromotionEventInterface @doc(category: "Discounts") { id: ID! @@ -14823,13 +13435,7 @@ type PromotionEndedEvent implements Node & PromotionEventInterface @doc(category createdBy: UserOrApp } -""" -History log of the promotion rule created event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""History log of the promotion rule created event.""" type PromotionRuleCreatedEvent implements Node & PromotionEventInterface & PromotionRuleEventInterface @doc(category: "Discounts") { id: ID! @@ -14850,25 +13456,13 @@ type PromotionRuleCreatedEvent implements Node & PromotionEventInterface & Promo ruleId: String } -""" -History log of the promotion event related to rule. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""History log of the promotion event related to rule.""" interface PromotionRuleEventInterface { """The rule ID associated with the promotion event.""" ruleId: String } -""" -History log of the promotion rule created event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""History log of the promotion rule created event.""" type PromotionRuleUpdatedEvent implements Node & PromotionEventInterface & PromotionRuleEventInterface @doc(category: "Discounts") { id: ID! @@ -14889,13 +13483,7 @@ type PromotionRuleUpdatedEvent implements Node & PromotionEventInterface & Promo ruleId: String } -""" -History log of the promotion rule created event. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""History log of the promotion rule created event.""" type PromotionRuleDeletedEvent implements Node & PromotionEventInterface & PromotionRuleEventInterface @doc(category: "Discounts") { id: ID! @@ -15040,7 +13628,6 @@ type ExportEvent implements Node { message: String! } -"""An enumeration.""" enum ExportEventsEnum { EXPORT_PENDING EXPORT_SUCCESS @@ -15199,13 +13786,7 @@ type AppInstallation implements Node & Job @doc(category: "Apps") { """The URL address of manifest for the app installation.""" manifestUrl: String! - """ - App's brand data. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """App's brand data.""" brand: AppBrand } @@ -15392,11 +13973,7 @@ input CustomerFilterInput @doc(category: "Users") { search: String metadata: [MetadataFilter!] - """ - Filter by ids. - - Added in Saleor 3.8. - """ + """Filter by ids.""" ids: [ID!] updatedAt: DateTimeRangeInput } @@ -15525,11 +14102,7 @@ type Mutation { ): EventDeliveryRetry @doc(category: "Webhooks") """ - Performs a dry run of a webhook event. Supports a single event (the first, if multiple provided in the `query`). Requires permission relevant to processed event. - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Performs a dry run of a webhook event. Supports a single event (the first, if multiple provided in the `query`). Requires permission relevant to processed event. Requires one of the following permissions: AUTHENTICATED_STAFF_USER. """ @@ -15542,11 +14115,7 @@ type Mutation { ): WebhookDryRun @doc(category: "Webhooks") """ - Trigger a webhook event. Supports a single event (the first, if multiple provided in the `webhook.subscription_query`). Requires permission relevant to processed event. Successfully delivered webhook returns `delivery` with status='PENDING' and empty payload. - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Trigger a webhook event. Supports a single event (the first, if multiple provided in the `webhook.subscription_query`). Requires permission relevant to processed event. Successfully delivered webhook returns `delivery` with status='PENDING' and empty payload. Requires one of the following permissions: AUTHENTICATED_STAFF_USER. """ @@ -15574,11 +14143,7 @@ type Mutation { Requires one of the following permissions: MANAGE_PRODUCTS. """ updateWarehouse( - """ - External reference of a warehouse. - - Added in Saleor 3.16. - """ + """External reference of a warehouse.""" externalReference: String """ID of a warehouse to update.""" @@ -15625,9 +14190,7 @@ type Mutation { ): WarehouseShippingZoneUnassign @doc(category: "Products") """ - Create a tax class. - - Added in Saleor 3.9. + Create a tax class. Requires one of the following permissions: MANAGE_TAXES. """ @@ -15637,9 +14200,7 @@ type Mutation { ): TaxClassCreate @doc(category: "Taxes") """ - Delete a tax class. After deleting the tax class any products, product types or shipping methods using it are updated to use the default tax class. - - Added in Saleor 3.9. + Delete a tax class. After deleting the tax class any products, product types or shipping methods using it are updated to use the default tax class. Requires one of the following permissions: MANAGE_TAXES. """ @@ -15649,9 +14210,7 @@ type Mutation { ): TaxClassDelete @doc(category: "Taxes") """ - Update a tax class. - - Added in Saleor 3.9. + Update a tax class. Requires one of the following permissions: MANAGE_TAXES. """ @@ -15664,9 +14223,7 @@ type Mutation { ): TaxClassUpdate @doc(category: "Taxes") """ - Update tax configuration for a channel. - - Added in Saleor 3.9. + Update tax configuration for a channel. Requires one of the following permissions: MANAGE_TAXES. """ @@ -15679,9 +14236,7 @@ type Mutation { ): TaxConfigurationUpdate @doc(category: "Taxes") """ - Update tax class rates for a specific country. - - Added in Saleor 3.9. + Update tax class rates for a specific country. Requires one of the following permissions: MANAGE_TAXES. """ @@ -15696,9 +14251,7 @@ type Mutation { ): TaxCountryConfigurationUpdate @doc(category: "Taxes") """ - Remove all tax class rates for a specific country. - - Added in Saleor 3.9. + Remove all tax class rates for a specific country. Requires one of the following permissions: MANAGE_TAXES. """ @@ -15708,9 +14261,7 @@ type Mutation { ): TaxCountryConfigurationDelete @doc(category: "Taxes") """ - Exempt checkout or order from charging the taxes. When tax exemption is enabled, taxes won't be charged for the checkout or order. Taxes may still be calculated in cases when product prices are entered with the tax included and the net price needs to be known. - - Added in Saleor 3.8. + Exempt checkout or order from charging the taxes. When tax exemption is enabled, taxes won't be charged for the checkout or order. Taxes may still be calculated in cases when product prices are entered with the tax included and the net price needs to be known. Requires one of the following permissions: MANAGE_TAXES. """ @@ -15723,11 +14274,7 @@ type Mutation { ): TaxExemptionManage @doc(category: "Taxes") """ - Updates stocks for a given variant and warehouse. Variant and warehouse selectors have to be the same for all stock inputs. Is not allowed to use 'variantId' in one input and 'variantExternalReference' in another. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Updates stocks for a given variant and warehouse. Variant and warehouse selectors have to be the same for all stock inputs. Is not allowed to use 'variantId' in one input and 'variantExternalReference' in another. Requires one of the following permissions: MANAGE_PRODUCTS. @@ -15776,16 +14323,14 @@ type Mutation { ): StaffNotificationRecipientDelete @doc(category: "Users") """ - Updates site domain of the shop. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead. + Updates site domain of the shop. Requires one of the following permissions: MANAGE_SETTINGS. """ shopDomainUpdate( """Fields required to update site.""" input: SiteDomainInput - ): ShopDomainUpdate @doc(category: "Shop") @deprecated(reason: "\\n\\nDEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead.") + ): ShopDomainUpdate @doc(category: "Shop") @deprecated(reason: "Use `PUBLIC_URL` environment variable instead.") """ Updates shop settings. @@ -15805,7 +14350,7 @@ type Mutation { Requires one of the following permissions: MANAGE_SETTINGS. """ - shopFetchTaxRates: ShopFetchTaxRates @doc(category: "Shop") @deprecated(reason: "\\n\\nDEPRECATED: this mutation will be removed in Saleor 4.0.") + shopFetchTaxRates: ShopFetchTaxRates @doc(category: "Shop") @deprecated """ Creates/updates translations for shop settings. @@ -15838,7 +14383,7 @@ type Mutation { orderSettingsUpdate( """Fields required to update shop order settings.""" input: OrderSettingsUpdateInput! - ): OrderSettingsUpdate @doc(category: "Orders") @deprecated(reason: "\\n\\nDEPRECATED: this mutation will be removed in Saleor 4.0. Use `channelUpdate` mutation instead.") + ): OrderSettingsUpdate @doc(category: "Orders") @deprecated(reason: "Use `channelUpdate` mutation instead.") """ Update gift card settings. @@ -16005,9 +14550,7 @@ type Mutation { ): ProductAttributeAssign @doc(category: "Products") """ - Update attributes assigned to product variant for given product type. - - Added in Saleor 3.1. + Update attributes assigned to product variant for given product type. Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. """ @@ -16223,11 +14766,7 @@ type Mutation { Requires one of the following permissions: MANAGE_PRODUCTS. """ productDelete( - """ - External ID of a product to delete. - - Added in Saleor 3.10. - """ + """External ID of a product to delete.""" externalReference: String """ID of a product to delete.""" @@ -16235,11 +14774,7 @@ type Mutation { ): ProductDelete @doc(category: "Products") """ - Creates products. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Creates products. Requires one of the following permissions: MANAGE_PRODUCTS. """ @@ -16267,11 +14802,7 @@ type Mutation { Requires one of the following permissions: MANAGE_PRODUCTS. """ productUpdate( - """ - External ID of a product to update. - - Added in Saleor 3.10. - """ + """External ID of a product to update.""" externalReference: String """ID of a product to update.""" @@ -16282,11 +14813,7 @@ type Mutation { ): ProductUpdate @doc(category: "Products") """ - Creates/updates translations for products. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Creates/updates translations for products. Requires one of the following permissions: MANAGE_TRANSLATIONS. @@ -16537,21 +15064,13 @@ type Mutation { Requires one of the following permissions: MANAGE_PRODUCTS. """ productVariantDelete( - """ - External ID of a product variant to update. - - Added in Saleor 3.10. - """ + """External ID of a product variant to update.""" externalReference: String """ID of a product variant to delete.""" id: ID - """ - SKU of a product variant to delete. - - Added in Saleor 3.8. - """ + """SKU of a product variant to delete.""" sku: String ): ProductVariantDelete @doc(category: "Products") @@ -16561,13 +15080,7 @@ type Mutation { Requires one of the following permissions: MANAGE_PRODUCTS. """ productVariantBulkCreate( - """ - Policies of error handling. DEFAULT: REJECT_EVERYTHING - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Policies of error handling. DEFAULT: REJECT_EVERYTHING""" errorPolicy: ErrorPolicyEnum """ID of the product to create the variants for.""" @@ -16578,11 +15091,7 @@ type Mutation { ): ProductVariantBulkCreate @doc(category: "Products") """ - Update multiple product variants. - - Added in Saleor 3.11. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Update multiple product variants. Requires one of the following permissions: MANAGE_PRODUCTS. """ @@ -16606,11 +15115,7 @@ type Mutation { """List of product variant IDs to delete.""" ids: [ID!] - """ - List of product variant SKUs to delete. - - Added in Saleor 3.8. - """ + """List of product variant SKUs to delete.""" skus: [String!] ): ProductVariantBulkDelete @doc(category: "Products") @@ -16665,11 +15170,7 @@ type Mutation { Requires one of the following permissions: MANAGE_PRODUCTS. """ productVariantUpdate( - """ - External ID of a product variant to update. - - Added in Saleor 3.10. - """ + """External ID of a product variant to update.""" externalReference: String """ID of a product to update.""" @@ -16678,11 +15179,7 @@ type Mutation { """Fields required to update a product variant.""" input: ProductVariantInput! - """ - SKU of a product variant to update. - - Added in Saleor 3.8. - """ + """SKU of a product variant to update.""" sku: String ): ProductVariantUpdate @doc(category: "Products") @@ -16716,11 +15213,7 @@ type Mutation { ): ProductVariantTranslate @doc(category: "Products") """ - Creates/updates translations for products variants. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Creates/updates translations for products variants. Requires one of the following permissions: MANAGE_TRANSLATIONS. @@ -16750,11 +15243,7 @@ type Mutation { """ input: [ProductVariantChannelListingAddInput!]! - """ - SKU of a product variant to update. - - Added in Saleor 3.8. - """ + """SKU of a product variant to update.""" sku: String ): ProductVariantChannelListingUpdate @doc(category: "Products") @@ -16775,9 +15264,7 @@ type Mutation { ): ProductVariantReorderAttributeValues @doc(category: "Products") """ - Deactivates product variant preorder. It changes all preorder allocation into regular allocation. - - Added in Saleor 3.1. + Deactivates product variant preorder. It changes all preorder allocation into regular allocation. Requires one of the following permissions: MANAGE_PRODUCTS. """ @@ -16867,11 +15354,7 @@ type Mutation { ): PaymentCheckBalance @doc(category: "Payments") """ - Create transaction for checkout or order. - - Added in Saleor 3.4. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Create transaction for checkout or order. Requires one of the following permissions: HANDLE_PAYMENTS. """ @@ -16889,21 +15372,13 @@ type Mutation { """ Update transaction. - Added in Saleor 3.4. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. """ transactionUpdate( """The ID of the transaction. One of field id or token is required.""" id: ID - """ - The token of the transaction. One of field id or token is required. - - Added in Saleor 3.14. - """ + """The token of the transaction. One of field id or token is required.""" token: UUID """Input data required to create a new transaction object.""" @@ -16914,11 +15389,7 @@ type Mutation { ): TransactionUpdate @doc(category: "Payments") """ - Request an action for payment transaction. - - Added in Saleor 3.4. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Request an action for payment transaction. Requires one of the following permissions: HANDLE_PAYMENTS. """ @@ -16927,27 +15398,19 @@ type Mutation { actionType: TransactionActionEnum! """ - Transaction request amount. If empty for refund or capture, maximal possible amount will be used. + Transaction request amount. If empty, maximal possible amount will be used. """ amount: PositiveDecimal """The ID of the transaction. One of field id or token is required.""" id: ID - """ - The token of the transaction. One of field id or token is required. - - Added in Saleor 3.14. - """ + """The token of the transaction. One of field id or token is required.""" token: UUID ): TransactionRequestAction @doc(category: "Payments") """ - Request a refund for payment transaction based on granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Request a refund for payment transaction based on granted refund. Requires one of the following permissions: HANDLE_PAYMENTS. """ @@ -16969,11 +15432,12 @@ type Mutation { """ Report the event for the transaction. - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. + + Triggers the following webhook events: + - TRANSACTION_ITEM_METADATA_UPDATED (async): Optionally called when transaction's metadata was updated. + - CHECKOUT_FULLY_PAID (async): Optionally called when the checkout charge status changed to `FULL` or `OVERCHARGED`. + - ORDER_UPDATED (async): Optionally called when the transaction is related to the order and the order was updated. """ transactionEventReport( """ @@ -16994,7 +15458,9 @@ type Mutation { """The ID of the transaction. One of field id or token is required.""" id: ID - """The message related to the event.""" + """ + The message related to the event. The maximum length is 512 characters; any text exceeding this limit will be truncated. + """ message: String """PSP Reference of the event to report.""" @@ -17005,23 +15471,31 @@ type Mutation { """ time: DateTime + """The token of the transaction. One of field id or token is required.""" + token: UUID + """ - The token of the transaction. One of field id or token is required. + Fields required to update the transaction metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ - token: UUID + transactionMetadata: [MetadataInput!] + + """ + Fields required to update the transaction private metadata. + + Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ + transactionPrivateMetadata: [MetadataInput!] """Current status of the event to report.""" type: TransactionEventTypeEnum! - ): TransactionEventReport @doc(category: "Payments") + ): TransactionEventReport @doc(category: "Payments") @webhookEventsInfo(asyncEvents: [TRANSACTION_ITEM_METADATA_UPDATED, CHECKOUT_FULLY_PAID, ORDER_UPDATED], syncEvents: []) """ Initializes a payment gateway session. It triggers the webhook `PAYMENT_GATEWAY_INITIALIZE_SESSION`, to the requested `paymentGateways`. If `paymentGateways` is not provided, the webhook will be send to all subscribed payment gateways. There is a limit of 100 transaction items per checkout / order. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ paymentGatewayInitialize( """ @@ -17038,10 +15512,6 @@ type Mutation { """ Initializes a transaction session. It triggers the webhook `TRANSACTION_INITIALIZE_SESSION`, to the requested `paymentGateways`. There is a limit of 100 transaction items per checkout / order. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ transactionInitialize( """ @@ -17056,8 +15526,6 @@ type Mutation { """ The customer's IP address. If not provided Saleor will try to determine the customer's IP address on its own. The customer's IP address will be passed to the payment app. The IP should be in ipv4 or ipv6 format. The field can be used only by an app that has `HANDLE_PAYMENTS` permission. - - Added in Saleor 3.16. """ customerIpAddress: String @@ -17066,8 +15534,6 @@ type Mutation { """ The idempotency key assigned to the action. It will be passed to the payment app to discover potential duplicate actions. If not provided, the default one will be generated. If empty string provided, INVALID error code will be raised. - - Added in Saleor 3.14. """ idempotencyKey: String @@ -17076,17 +15542,11 @@ type Mutation { ): TransactionInitialize @doc(category: "Payments") """ - Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. """ transactionProcess( """ The customer's IP address. If not provided Saleor will try to determine the customer's IP address on its own. The customer's IP address will be passed to the payment app. The IP should be in ipv4 or ipv6 format. The field can be used only by an app that has `HANDLE_PAYMENTS` permission. - - Added in Saleor 3.16. """ customerIpAddress: String @@ -17100,18 +15560,12 @@ type Mutation { """ The token of the transaction to process. One of field id or token is required. - - Added in Saleor 3.14. """ token: UUID ): TransactionProcess @doc(category: "Payments") """ - Request to delete a stored payment method on payment provider side. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Request to delete a stored payment method on payment provider side. Requires one of the following permissions: AUTHENTICATED_USER. @@ -17127,11 +15581,7 @@ type Mutation { ): StoredPaymentMethodRequestDelete @doc(category: "Payments") @webhookEventsInfo(asyncEvents: [], syncEvents: [STORED_PAYMENT_METHOD_DELETE_REQUESTED]) """ - Initializes payment gateway for tokenizing payment method session. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Initializes payment gateway for tokenizing payment method session. Requires one of the following permissions: AUTHENTICATED_USER. @@ -17150,11 +15600,7 @@ type Mutation { ): PaymentGatewayInitializeTokenization @doc(category: "Payments") @webhookEventsInfo(asyncEvents: [], syncEvents: [PAYMENT_GATEWAY_INITIALIZE_TOKENIZATION_SESSION]) """ - Tokenize payment method. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Tokenize payment method. Requires one of the following permissions: AUTHENTICATED_USER. @@ -17178,11 +15624,7 @@ type Mutation { ): PaymentMethodInitializeTokenization @doc(category: "Payments") @webhookEventsInfo(asyncEvents: [], syncEvents: [PAYMENT_METHOD_INITIALIZE_TOKENIZATION_SESSION]) """ - Tokenize payment method. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Tokenize payment method. Requires one of the following permissions: AUTHENTICATED_USER. @@ -17398,11 +15840,7 @@ type Mutation { Requires one of the following permissions: MANAGE_ORDERS. """ draftOrderDelete( - """ - External ID of a product to delete. - - Added in Saleor 3.10. - """ + """External ID of a product to delete.""" externalReference: String """ID of a product to delete.""" @@ -17427,7 +15865,7 @@ type Mutation { draftOrderLinesBulkDelete( """List of order lines IDs to delete.""" ids: [ID!]! - ): DraftOrderLinesBulkDelete @doc(category: "Orders") @deprecated(reason: "This field will be removed in Saleor 4.0.") + ): DraftOrderLinesBulkDelete @doc(category: "Orders") @deprecated """ Updates a draft order. @@ -17435,11 +15873,7 @@ type Mutation { Requires one of the following permissions: MANAGE_ORDERS. """ draftOrderUpdate( - """ - External ID of a draft order to update. - - Added in Saleor 3.10. - """ + """External ID of a draft order to update.""" externalReference: String """ID of a draft order to update.""" @@ -17450,9 +15884,7 @@ type Mutation { ): DraftOrderUpdate @doc(category: "Orders") """ - Adds note to the order. - - DEPRECATED: this mutation will be removed in Saleor 4.0. + Adds note to the order. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -17462,7 +15894,7 @@ type Mutation { """Fields required to create a note for the order.""" input: OrderAddNoteInput! - ): OrderAddNote @doc(category: "Orders") @deprecated(reason: "This field will be removed in Saleor 4.0. Use `orderNoteAdd` instead.") + ): OrderAddNote @doc(category: "Orders") @deprecated(reason: "Use `orderNoteAdd` instead.") """ Cancel an order. @@ -17530,9 +15962,7 @@ type Mutation { ): FulfillmentCancel @doc(category: "Orders") """ - Approve existing fulfillment. - - Added in Saleor 3.1. + Approve existing fulfillment. Requires one of the following permissions: MANAGE_ORDERS. @@ -17593,11 +16023,7 @@ type Mutation { ): FulfillmentReturnProducts @doc(category: "Orders") """ - Adds granted refund to the order. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Adds granted refund to the order. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -17610,11 +16036,7 @@ type Mutation { ): OrderGrantRefundCreate @doc(category: "Orders") """ - Updates granted refund. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Updates granted refund. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -17722,11 +16144,7 @@ type Mutation { ): OrderLineDiscountRemove @doc(category: "Orders") """ - Adds note to the order. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Adds note to the order. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -17739,11 +16157,7 @@ type Mutation { ): OrderNoteAdd @doc(category: "Orders") """ - Updates note of an order. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Updates note of an order. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -17787,11 +16201,7 @@ type Mutation { Requires one of the following permissions: MANAGE_ORDERS. """ orderUpdate( - """ - External ID of an order to update. - - Added in Saleor 3.10. - """ + """External ID of an order to update.""" externalReference: String """ID of an order to update.""" @@ -17835,11 +16245,7 @@ type Mutation { ): OrderBulkCancel @doc(category: "Orders") """ - Creates multiple orders. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Creates multiple orders. Requires one of the following permissions: MANAGE_ORDERS_IMPORT. """ @@ -17879,7 +16285,9 @@ type Mutation { ): DeletePrivateMetadata """ - Updates metadata of an object. To use it, you need to have access to the modified object. + Updates metadata of an object.Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. """ updateMetadata( """ID or token (for Order and Checkout) of an object to update.""" @@ -17890,7 +16298,9 @@ type Mutation { ): UpdateMetadata """ - Updates private metadata of an object. To use it, you need to be an authenticated staff user or an app and have access to the modified object. + Updates private metadata of an object. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. """ updatePrivateMetadata( """ID or token (for Order and Checkout) of an object to update.""" @@ -18166,9 +16576,7 @@ type Mutation { ): GiftCardCreate @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_CREATED, NOTIFY_USER], syncEvents: []) """ - Delete gift card. - - Added in Saleor 3.1. + Delete gift card. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -18210,9 +16618,7 @@ type Mutation { ): GiftCardUpdate @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_UPDATED], syncEvents: []) """ - Resend a gift card. - - Added in Saleor 3.1. + Resend a gift card. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -18225,9 +16631,7 @@ type Mutation { ): GiftCardResend @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [NOTIFY_USER], syncEvents: []) """ - Adds note to the gift card. - - Added in Saleor 3.1. + Adds note to the gift card. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -18243,9 +16647,7 @@ type Mutation { ): GiftCardAddNote @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_UPDATED], syncEvents: []) """ - Create gift cards. - - Added in Saleor 3.1. + Create gift cards. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -18259,9 +16661,7 @@ type Mutation { ): GiftCardBulkCreate @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_CREATED, NOTIFY_USER], syncEvents: []) """ - Delete gift cards. - - Added in Saleor 3.1. + Delete gift cards. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -18274,9 +16674,7 @@ type Mutation { ): GiftCardBulkDelete @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_DELETED], syncEvents: []) """ - Activate gift cards. - - Added in Saleor 3.1. + Activate gift cards. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -18289,9 +16687,7 @@ type Mutation { ): GiftCardBulkActivate @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_STATUS_CHANGED], syncEvents: []) """ - Deactivate gift cards. - - Added in Saleor 3.1. + Deactivate gift cards. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -18321,8 +16717,6 @@ type Mutation { """ Trigger sending a notification with the notify plugin method. Serializes nodes provided as ids parameter and includes this data in the notification payload. - - Added in Saleor 3.1. """ externalNotificationTrigger( """ @@ -18335,14 +16729,10 @@ type Mutation { """The ID of notification plugin.""" pluginId: String - ): ExternalNotificationTrigger @deprecated(reason: "\\n\\nDEPRECATED: this mutation will be removed in Saleor 4.0.") + ): ExternalNotificationTrigger @deprecated """ - Creates a new promotion. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Creates a new promotion. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18356,11 +16746,7 @@ type Mutation { ): PromotionCreate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [PROMOTION_CREATED, PROMOTION_STARTED], syncEvents: []) """ - Updates an existing promotion. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Updates an existing promotion. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18378,11 +16764,7 @@ type Mutation { ): PromotionUpdate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [PROMOTION_UPDATED, PROMOTION_STARTED, PROMOTION_ENDED], syncEvents: []) """ - Deletes a promotion. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Deletes a promotion. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18395,11 +16777,7 @@ type Mutation { ): PromotionDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [PROMOTION_DELETED], syncEvents: []) """ - Creates a new promotion rule. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Creates a new promotion rule. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18412,11 +16790,7 @@ type Mutation { ): PromotionRuleCreate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [PROMOTION_RULE_CREATED], syncEvents: []) """ - Updates an existing promotion rule. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Updates an existing promotion rule. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18432,11 +16806,7 @@ type Mutation { ): PromotionRuleUpdate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [PROMOTION_RULE_UPDATED], syncEvents: []) """ - Deletes a promotion rule. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Deletes a promotion rule. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18449,9 +16819,7 @@ type Mutation { ): PromotionRuleDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [PROMOTION_RULE_DELETED], syncEvents: []) """ - Creates/updates translations for a promotion. - - Added in Saleor 3.17. + Creates/updates translations for a promotion. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -18467,9 +16835,7 @@ type Mutation { ): PromotionTranslate @doc(category: "Discounts") """ - Creates/updates translations for a promotion rule. - - Added in Saleor 3.17. + Creates/updates translations for a promotion rule. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -18485,11 +16851,7 @@ type Mutation { ): PromotionRuleTranslate @doc(category: "Discounts") """ - Deletes promotions. - - Added in Saleor 3.17. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Deletes promotions. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18502,9 +16864,7 @@ type Mutation { ): PromotionBulkDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [PROMOTION_DELETED], syncEvents: []) """ - Creates a new sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionCreate` mutation instead. + Creates a new sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18514,12 +16874,10 @@ type Mutation { saleCreate( """Fields required to create a sale.""" input: SaleInput! - ): SaleCreate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_CREATED], syncEvents: []) + ): SaleCreate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_CREATED], syncEvents: []) @deprecated(reason: "Use `promotionCreate` mutation instead.") """ - Deletes a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionDelete` mutation instead. + Deletes a sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18529,7 +16887,7 @@ type Mutation { saleDelete( """ID of a sale to delete.""" id: ID! - ): SaleDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_DELETED], syncEvents: []) + ): SaleDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_DELETED], syncEvents: []) @deprecated(reason: "Use `promotionDelete` mutation instead.") """ Deletes sales. @@ -18545,9 +16903,7 @@ type Mutation { ): SaleBulkDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_DELETED], syncEvents: []) """ - Updates a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionUpdate` mutation instead. + Updates a sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18561,12 +16917,10 @@ type Mutation { """Fields required to update a sale.""" input: SaleInput! - ): SaleUpdate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED, SALE_TOGGLE], syncEvents: []) + ): SaleUpdate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED, SALE_TOGGLE], syncEvents: []) @deprecated(reason: "Use `promotionUpdate` mutation instead.") """ - Adds products, categories, collections to a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` mutation instead. + Adds products, categories, collections to a sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18579,12 +16933,10 @@ type Mutation { """Fields required to modify catalogue IDs of sale.""" input: CatalogueInput! - ): SaleAddCatalogues @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED], syncEvents: []) + ): SaleAddCatalogues @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED], syncEvents: []) @deprecated(reason: "Use `promotionRuleCreate` and `promotionRuleUpdate` mutations instead.") """ - Removes products, categories, collections from a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleUpdate` or `promotionRuleDelete` mutations instead. + Removes products, categories, collections from a sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -18597,12 +16949,10 @@ type Mutation { """Fields required to modify catalogue IDs of sale.""" input: CatalogueInput! - ): SaleRemoveCatalogues @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED], syncEvents: []) + ): SaleRemoveCatalogues @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED], syncEvents: []) @deprecated(reason: "Use `promotionRuleUpdate` and `promotionRuleDelete` mutations instead.") """ - Creates/updates translations for a sale. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PromotionTranslate` mutation instead. + Creates/updates translations for a sale. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -18615,12 +16965,10 @@ type Mutation { """Translation language code.""" languageCode: LanguageCodeEnum! - ): SaleTranslate @doc(category: "Discounts") + ): SaleTranslate @doc(category: "Discounts") @deprecated(reason: "Use `promotionTranslate` mutation instead.") """ - Manage sale's availability in channels. - - DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` or `promotionRuleUpdate` mutations instead. + Manage sale's availability in channels. Requires one of the following permissions: MANAGE_DISCOUNTS. """ @@ -18630,7 +16978,7 @@ type Mutation { """Fields required to update sale channel listings.""" input: SaleChannelListingInput! - ): SaleChannelListingUpdate @doc(category: "Discounts") + ): SaleChannelListingUpdate @doc(category: "Discounts") @deprecated(reason: "Use `promotionRuleUpdate` mutation instead.") """ Creates a new voucher. @@ -18783,9 +17131,7 @@ type Mutation { ): ExportProducts @doc(category: "Products") @webhookEventsInfo(asyncEvents: [NOTIFY_USER, PRODUCT_EXPORT_COMPLETED], syncEvents: []) """ - Export gift cards to csv file. - - Added in Saleor 3.1. + Export gift cards to csv file. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -18832,29 +17178,17 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutAddPromoCode( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """Gift card code or voucher code.""" promoCode: String! - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutAddPromoCode @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) """ @@ -18867,32 +17201,23 @@ type Mutation { """The billing address of the checkout.""" billingAddress: AddressInput! - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """ - Checkout token. + Indicates whether the billing address should be saved to the user’s address book upon checkout completion. If not provided, the default behavior is to save the address. - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. + Added in Saleor 3.21. """ - token: UUID + saveAddress: Boolean = true - """ - The rules for changing validation for received billing address data. - - Added in Saleor 3.5. - """ + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") + + """The rules for changing validation for received billing address data.""" validationRules: CheckoutAddressValidationRules ): CheckoutBillingAddressUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) @@ -18912,24 +17237,16 @@ type Mutation { - ORDER_CONFIRMED (async): Optionally triggered when newly created order are automatically marked as confirmed. """ checkoutComplete( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """ - Fields required to update the checkout metadata. + Fields required to update the checkout metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] @@ -18941,19 +17258,11 @@ type Mutation { """ redirectUrl: String - """ - Determines whether to store the payment source for future usage. - - DEPRECATED: this field will be removed in Saleor 4.0. Use checkoutPaymentCreate for this action. - """ - storeSource: Boolean = false + """Determines whether to store the payment source for future usage.""" + storeSource: Boolean = false @deprecated(reason: "Use checkoutPaymentCreate for this action.") - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutComplete @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [ORDER_CREATED, NOTIFY_USER, NOTIFY_USER, ORDER_UPDATED, ORDER_PAID, ORDER_FULLY_PAID, ORDER_CONFIRMED], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT, CHECKOUT_FILTER_SHIPPING_METHODS, CHECKOUT_CALCULATE_TAXES]) """ @@ -18969,13 +17278,7 @@ type Mutation { input: CheckoutCreateInput! ): CheckoutCreate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_CREATED], syncEvents: []) - """ - Create new checkout from existing order. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Create new checkout from existing order.""" checkoutCreateFromOrder( """ID of a order that will be used to create the checkout.""" id: ID! @@ -18990,31 +17293,19 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutCustomerAttach( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") """ ID of customer to attach to checkout. Requires IMPERSONATE_USER permission when customerId is different than the logged-in user. """ customerId: ID - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutCustomerAttach @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) """ @@ -19026,28 +17317,32 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutCustomerDetach( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutCustomerDetach @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) + """ + Updates customer note in the existing checkout object. + + Added in Saleor 3.21. + + Triggers the following webhook events: + - CHECKOUT_UPDATED (async): A checkout was updated. + """ + checkoutCustomerNoteUpdate( + """New customer note content.""" + customerNote: String! + + """The checkout's ID.""" + id: ID! + ): CheckoutCustomerNoteUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) + """ Updates email address in the existing checkout object. @@ -19055,29 +17350,17 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutEmailUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") """email.""" email: String! - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutEmailUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) """ @@ -19087,30 +17370,18 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutLineDelete( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """ID of the checkout line to delete.""" lineId: ID - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutLineDelete @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) @deprecated(reason: "This field will be removed in Saleor 4.0. Use `checkoutLinesDelete` instead.") + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") + ): CheckoutLineDelete @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) @deprecated(reason: "Use `checkoutLinesDelete` instead.") """ Deletes checkout lines. @@ -19119,22 +17390,14 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutLinesDelete( - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """A list of checkout lines.""" linesIds: [ID!]! - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutLinesDelete @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) """ @@ -19144,18 +17407,10 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutLinesAdd( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """ @@ -19163,12 +17418,8 @@ type Mutation { """ lines: [CheckoutLineInput!]! - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutLinesAdd @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) """ @@ -19178,18 +17429,10 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutLinesUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """ @@ -19197,12 +17440,8 @@ type Mutation { """ lines: [CheckoutLineUpdateInput!]! - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutLinesUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) """ @@ -19212,18 +17451,10 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutRemovePromoCode( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """Gift card code or voucher code.""" @@ -19232,39 +17463,23 @@ type Mutation { """Gift card or voucher ID.""" promoCodeId: ID - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutRemovePromoCode @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) """Create a new payment for given checkout.""" checkoutPaymentCreate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """Data required to create a new payment.""" input: PaymentInput! - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutPaymentCreate @doc(category: "Checkout") """ @@ -19274,35 +17489,26 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutShippingAddressUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") + + """The checkout's ID.""" + id: ID """ - The checkout's ID. + Indicates whether the shipping address should be saved to the user’s address book upon checkout completion. If not provided, the default behavior is to save the address. - Added in Saleor 3.4. + Added in Saleor 3.21. """ - id: ID + saveAddress: Boolean = true """The mailing address to where the checkout will be shipped.""" shippingAddress: AddressInput! - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") - """ - The rules for changing validation for received shipping address data. - - Added in Saleor 3.5. - """ + """The rules for changing validation for received shipping address data.""" validationRules: CheckoutAddressValidationRules ): CheckoutShippingAddressUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) @@ -19314,36 +17520,22 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutShippingMethodUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """Shipping method.""" shippingMethodId: ID - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID - ): CheckoutShippingMethodUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT]) @deprecated(reason: "This field will be removed in Saleor 4.0. Use `checkoutDeliveryMethodUpdate` instead.") + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") + ): CheckoutShippingMethodUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT]) @deprecated(reason: "Use `checkoutDeliveryMethodUpdate` instead.") """ Updates the delivery method (shipping method or pick up point) of the checkout. Updates the checkout shipping_address for click and collect delivery for a warehouse address. - Added in Saleor 3.1. - Triggers the following webhook events: - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout delivery method with the external one. - CHECKOUT_UPDATED (async): A checkout was updated. @@ -19352,19 +17544,11 @@ type Mutation { """Delivery Method ID (`Warehouse` ID or `ShippingMethod` ID).""" deliveryMethodId: ID - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutDeliveryMethodUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT]) """ @@ -19374,36 +17558,22 @@ type Mutation { - CHECKOUT_UPDATED (async): A checkout was updated. """ checkoutLanguageCodeUpdate( - """ - The ID of the checkout. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - checkoutId: ID + """The ID of the checkout.""" + checkoutId: ID @deprecated(reason: "Use `id` instead.") - """ - The checkout's ID. - - Added in Saleor 3.4. - """ + """The checkout's ID.""" id: ID """New language code.""" languageCode: LanguageCodeEnum! - """ - Checkout token. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `id` instead. - """ - token: UUID + """Checkout token.""" + token: UUID @deprecated(reason: "Use `id` instead.") ): CheckoutLanguageCodeUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) """ Create new order from existing checkout. Requires the following permissions: AUTHENTICATED_APP and HANDLE_CHECKOUTS. - Added in Saleor 3.2. - Triggers the following webhook events: - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. @@ -19421,16 +17591,16 @@ type Mutation { id: ID! """ - Fields required to update the checkout metadata. + Fields required to update the checkout metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the checkout private metadata. + Fields required to update the checkout private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] @@ -19516,9 +17686,7 @@ type Mutation { ): ChannelDeactivate @doc(category: "Channels") @webhookEventsInfo(asyncEvents: [CHANNEL_STATUS_CHANGED], syncEvents: []) """ - Reorder the warehouses of a channel. - - Added in Saleor 3.7. + Reorder the warehouses of a channel. Requires one of the following permissions: MANAGE_CHANNELS. """ @@ -19550,11 +17718,7 @@ type Mutation { - ATTRIBUTE_DELETED (async): An attribute was deleted. """ attributeDelete( - """ - External ID of an attribute to delete. - - Added in Saleor 3.10. - """ + """External ID of an attribute to delete.""" externalReference: String """ID of an attribute to delete.""" @@ -19570,11 +17734,7 @@ type Mutation { - ATTRIBUTE_UPDATED (async): An attribute was updated. """ attributeUpdate( - """ - External ID of an attribute to update. - - Added in Saleor 3.10. - """ + """External ID of an attribute to update.""" externalReference: String """ID of an attribute to update.""" @@ -19587,10 +17747,6 @@ type Mutation { """ Creates attributes. - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Triggers the following webhook events: - ATTRIBUTE_CREATED (async): An attribute was created. """ @@ -19605,10 +17761,6 @@ type Mutation { """ Updates attributes. - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - Triggers the following webhook events: - ATTRIBUTE_UPDATED (async): An attribute was updated. Optionally called when new attribute value was created or deleted. - ATTRIBUTE_VALUE_CREATED (async): Called optionally when an attribute value was created. @@ -19639,11 +17791,7 @@ type Mutation { ): AttributeTranslate @doc(category: "Attributes") """ - Creates/updates translations for attributes. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Creates/updates translations for attributes. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -19709,11 +17857,7 @@ type Mutation { - ATTRIBUTE_UPDATED (async): An attribute was updated. """ attributeValueDelete( - """ - External ID of a value to delete. - - Added in Saleor 3.10. - """ + """External ID of a value to delete.""" externalReference: String """ID of a value to delete.""" @@ -19730,11 +17874,7 @@ type Mutation { - ATTRIBUTE_UPDATED (async): An attribute was updated. """ attributeValueUpdate( - """ - External ID of an AttributeValue to update. - - Added in Saleor 3.10. - """ + """External ID of an AttributeValue to update.""" externalReference: String """ID of an AttributeValue to update.""" @@ -19745,11 +17885,7 @@ type Mutation { ): AttributeValueUpdate @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_VALUE_UPDATED, ATTRIBUTE_UPDATED], syncEvents: []) """ - Creates/updates translations for attributes values. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Creates/updates translations for attributes values. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -19930,12 +18066,22 @@ type Mutation { id: ID! ): AppDeactivate @doc(category: "Apps") @webhookEventsInfo(asyncEvents: [APP_STATUS_CHANGED], syncEvents: []) + """ + Re-enable sync webhooks for provided app. Can be used to manually re-enable sync webhooks for the app before the cooldown period ends. + + Added in Saleor 3.21. + + Requires one of the following permissions: MANAGE_APPS. + """ + appReenableSyncWebhooks( + """The app ID to re-enable sync webhooks for.""" + appId: ID! + ): AppReenableSyncWebhooks @doc(category: "Apps") + """Create JWT token.""" tokenCreate( """ The audience that will be included to JWT tokens with prefix `custom:`. - - Added in Saleor 3.8. """ audience: String @@ -20027,7 +18173,7 @@ type Mutation { """ requestPasswordReset( """ - Slug of a channel which will be used for notify user. Optional when only one channel exists. + Slug of a channel which will be used to notify the user. It is needed for customers, if not provided, the notification may not happen. Please note that mutation will not fail if the channel is not provided. """ channel: String @@ -20041,11 +18187,7 @@ type Mutation { ): RequestPasswordReset @doc(category: "Users") @webhookEventsInfo(asyncEvents: [NOTIFY_USER, ACCOUNT_SET_PASSWORD_REQUESTED, STAFF_SET_PASSWORD_REQUESTED], syncEvents: []) """ - Sends a notification confirmation. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Sends a notification confirmation. Requires one of the following permissions: AUTHENTICATED_USER. @@ -20376,11 +18518,7 @@ type Mutation { - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. """ customerUpdate( - """ - External ID of a customer to update. - - Added in Saleor 3.10. - """ + """External ID of a customer to update.""" externalReference: String """ID of a customer to update.""" @@ -20399,11 +18537,7 @@ type Mutation { - CUSTOMER_DELETED (async): A customer account was deleted. """ customerDelete( - """ - External ID of a customer to update. - - Added in Saleor 3.10. - """ + """External ID of a customer to update.""" externalReference: String """ID of a customer to delete.""" @@ -20424,11 +18558,7 @@ type Mutation { ): CustomerBulkDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_DELETED], syncEvents: []) """ - Updates customers. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. + Updates customers. Requires one of the following permissions: MANAGE_USERS. @@ -20580,7 +18710,7 @@ Creates a new webhook subscription. Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. """ type WebhookCreate @doc(category: "Webhooks") { - webhookErrors: [WebhookError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + webhookErrors: [WebhookError!]! @deprecated(reason: "Use `errors` field instead.") errors: [WebhookError!]! webhook: Webhook } @@ -20598,7 +18728,6 @@ type WebhookError @doc(category: "Webhooks") { code: WebhookErrorCode! } -"""An enumeration.""" enum WebhookErrorCode @doc(category: "Webhooks") { GRAPHQL_ERROR INVALID @@ -20621,12 +18750,8 @@ input WebhookCreateInput @doc(category: "Webhooks") { """The url to receive the payload.""" targetUrl: String - """ - The events that webhook wants to subscribe. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead. - """ - events: [WebhookEventTypeEnum!] + """The events that webhook wants to subscribe.""" + events: [WebhookEventTypeEnum!] @deprecated(reason: "Use `asyncEvents` or `syncEvents` instead.") """The asynchronous events that webhook wants to subscribe.""" asyncEvents: [WebhookEventTypeAsyncEnum!] @@ -20640,26 +18765,14 @@ input WebhookCreateInput @doc(category: "Webhooks") { """Determine if webhook will be set active or not.""" isActive: Boolean - """ - The secret key used to create a hash signature with each payload. - - DEPRECATED: this field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. - """ - secretKey: String + """The secret key used to create a hash signature with each payload.""" + secretKey: String @deprecated(reason: "As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS.") - """ - Subscription query used to define a webhook payload. - - Added in Saleor 3.2. - """ + """Subscription query used to define a webhook payload.""" query: String """ Custom headers, which will be added to HTTP request. There is a limitation of 5 headers per webhook and 998 characters per header.Only `X-*`, `Authorization*`, and `BrokerProperties` keys are allowed. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ customHeaders: JSONString } @@ -20670,7 +18783,7 @@ Delete a webhook. Before the deletion, the webhook is deactivated to pause any d Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. """ type WebhookDelete @doc(category: "Webhooks") { - webhookErrors: [WebhookError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + webhookErrors: [WebhookError!]! @deprecated(reason: "Use `errors` field instead.") errors: [WebhookError!]! webhook: Webhook } @@ -20681,7 +18794,7 @@ Updates a webhook subscription. Requires one of the following permissions: MANAGE_APPS, AUTHENTICATED_APP. """ type WebhookUpdate @doc(category: "Webhooks") { - webhookErrors: [WebhookError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + webhookErrors: [WebhookError!]! @deprecated(reason: "Use `errors` field instead.") errors: [WebhookError!]! webhook: Webhook } @@ -20693,12 +18806,8 @@ input WebhookUpdateInput @doc(category: "Webhooks") { """The url to receive the payload.""" targetUrl: String - """ - The events that webhook wants to subscribe. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `asyncEvents` or `syncEvents` instead. - """ - events: [WebhookEventTypeEnum!] + """The events that webhook wants to subscribe.""" + events: [WebhookEventTypeEnum!] @deprecated(reason: "Use `asyncEvents` or `syncEvents` instead.") """The asynchronous events that webhook wants to subscribe.""" asyncEvents: [WebhookEventTypeAsyncEnum!] @@ -20712,26 +18821,14 @@ input WebhookUpdateInput @doc(category: "Webhooks") { """Determine if webhook will be set active or not.""" isActive: Boolean - """ - Use to create a hash signature with each payload. - - DEPRECATED: this field will be removed in Saleor 4.0. As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS. - """ - secretKey: String + """Use to create a hash signature with each payload.""" + secretKey: String @deprecated(reason: "As of Saleor 3.5, webhook payloads default to signing using a verifiable JWS.") - """ - Subscription query used to define a webhook payload. - - Added in Saleor 3.2. - """ + """Subscription query used to define a webhook payload.""" query: String """ Custom headers, which will be added to HTTP request. There is a limitation of 5 headers per webhook and 998 characters per header.Only `X-*`, `Authorization*`, and `BrokerProperties` keys are allowed. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ customHeaders: JSONString } @@ -20748,11 +18845,7 @@ type EventDeliveryRetry @doc(category: "Webhooks") { } """ -Performs a dry run of a webhook event. Supports a single event (the first, if multiple provided in the `query`). Requires permission relevant to processed event. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Performs a dry run of a webhook event. Supports a single event (the first, if multiple provided in the `query`). Requires permission relevant to processed event. Requires one of the following permissions: AUTHENTICATED_STAFF_USER. """ @@ -20775,7 +18868,6 @@ type WebhookDryRunError @doc(category: "Webhooks") { code: WebhookDryRunErrorCode! } -"""An enumeration.""" enum WebhookDryRunErrorCode @doc(category: "Webhooks") { GRAPHQL_ERROR NOT_FOUND @@ -20789,11 +18881,7 @@ enum WebhookDryRunErrorCode @doc(category: "Webhooks") { } """ -Trigger a webhook event. Supports a single event (the first, if multiple provided in the `webhook.subscription_query`). Requires permission relevant to processed event. Successfully delivered webhook returns `delivery` with status='PENDING' and empty payload. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Trigger a webhook event. Supports a single event (the first, if multiple provided in the `webhook.subscription_query`). Requires permission relevant to processed event. Successfully delivered webhook returns `delivery` with status='PENDING' and empty payload. Requires one of the following permissions: AUTHENTICATED_STAFF_USER. """ @@ -20815,7 +18903,6 @@ type WebhookTriggerError @doc(category: "Webhooks") { code: WebhookTriggerErrorCode! } -"""An enumeration.""" enum WebhookTriggerErrorCode @doc(category: "Webhooks") { GRAPHQL_ERROR NOT_FOUND @@ -20835,7 +18922,7 @@ Creates new warehouse. Requires one of the following permissions: MANAGE_PRODUCTS. """ type WarehouseCreate @doc(category: "Products") { - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + warehouseErrors: [WarehouseError!]! @deprecated(reason: "Use `errors` field instead.") errors: [WarehouseError!]! warehouse: Warehouse } @@ -20856,7 +18943,6 @@ type WarehouseError @doc(category: "Products") { shippingZones: [ID!] } -"""An enumeration.""" enum WarehouseErrorCode @doc(category: "Products") { ALREADY_EXISTS GRAPHQL_ERROR @@ -20873,11 +18959,7 @@ input WarehouseCreateInput @doc(category: "Products") { """The email address of the warehouse.""" email: String - """ - External ID of the warehouse. - - Added in Saleor 3.10. - """ + """External ID of the warehouse.""" externalReference: String """Warehouse name.""" @@ -20886,12 +18968,8 @@ input WarehouseCreateInput @doc(category: "Products") { """Address of the warehouse.""" address: AddressInput! - """ - Shipping zones supported by the warehouse. - - DEPRECATED: this field will be removed in Saleor 4.0. Providing the zone ids will raise a ValidationError. - """ - shippingZones: [ID!] + """Shipping zones supported by the warehouse.""" + shippingZones: [ID!] @deprecated(reason: "Providing the zone ids will raise a ValidationError.") } """ @@ -20900,7 +18978,7 @@ Updates given warehouse. Requires one of the following permissions: MANAGE_PRODUCTS. """ type WarehouseUpdate @doc(category: "Products") { - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + warehouseErrors: [WarehouseError!]! @deprecated(reason: "Use `errors` field instead.") errors: [WarehouseError!]! warehouse: Warehouse } @@ -20912,11 +18990,7 @@ input WarehouseUpdateInput @doc(category: "Products") { """The email address of the warehouse.""" email: String - """ - External ID of the warehouse. - - Added in Saleor 3.10. - """ + """External ID of the warehouse.""" externalReference: String """Warehouse name.""" @@ -20925,18 +18999,10 @@ input WarehouseUpdateInput @doc(category: "Products") { """Address of the warehouse.""" address: AddressInput - """ - Click and collect options: local, all or disabled. - - Added in Saleor 3.1. - """ + """Click and collect options: local, all or disabled.""" clickAndCollectOption: WarehouseClickAndCollectOptionEnum - """ - Visibility of warehouse stocks. - - Added in Saleor 3.1. - """ + """Visibility of warehouse stocks.""" isPrivate: Boolean } @@ -20946,7 +19012,7 @@ Deletes selected warehouse. Requires one of the following permissions: MANAGE_PRODUCTS. """ type WarehouseDelete @doc(category: "Products") { - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + warehouseErrors: [WarehouseError!]! @deprecated(reason: "Use `errors` field instead.") errors: [WarehouseError!]! warehouse: Warehouse } @@ -20957,7 +19023,7 @@ Add shipping zone to given warehouse. Requires one of the following permissions: MANAGE_PRODUCTS. """ type WarehouseShippingZoneAssign @doc(category: "Products") { - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + warehouseErrors: [WarehouseError!]! @deprecated(reason: "Use `errors` field instead.") errors: [WarehouseError!]! warehouse: Warehouse } @@ -20968,15 +19034,13 @@ Remove shipping zone from given warehouse. Requires one of the following permissions: MANAGE_PRODUCTS. """ type WarehouseShippingZoneUnassign @doc(category: "Products") { - warehouseErrors: [WarehouseError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + warehouseErrors: [WarehouseError!]! @deprecated(reason: "Use `errors` field instead.") errors: [WarehouseError!]! warehouse: Warehouse } """ -Create a tax class. - -Added in Saleor 3.9. +Create a tax class. Requires one of the following permissions: MANAGE_TAXES. """ @@ -21001,7 +19065,6 @@ type TaxClassCreateError @doc(category: "Taxes") { countryCodes: [String!]! } -"""An enumeration.""" enum TaxClassCreateErrorCode @doc(category: "Taxes") { GRAPHQL_ERROR INVALID @@ -21027,9 +19090,7 @@ input CountryRateInput @doc(category: "Taxes") { } """ -Delete a tax class. After deleting the tax class any products, product types or shipping methods using it are updated to use the default tax class. - -Added in Saleor 3.9. +Delete a tax class. After deleting the tax class any products, product types or shipping methods using it are updated to use the default tax class. Requires one of the following permissions: MANAGE_TAXES. """ @@ -21051,7 +19112,6 @@ type TaxClassDeleteError @doc(category: "Taxes") { code: TaxClassDeleteErrorCode! } -"""An enumeration.""" enum TaxClassDeleteErrorCode @doc(category: "Taxes") { GRAPHQL_ERROR INVALID @@ -21059,9 +19119,7 @@ enum TaxClassDeleteErrorCode @doc(category: "Taxes") { } """ -Update a tax class. - -Added in Saleor 3.9. +Update a tax class. Requires one of the following permissions: MANAGE_TAXES. """ @@ -21086,7 +19144,6 @@ type TaxClassUpdateError @doc(category: "Taxes") { countryCodes: [String!]! } -"""An enumeration.""" enum TaxClassUpdateErrorCode @doc(category: "Taxes") { DUPLICATED_INPUT_ITEM GRAPHQL_ERROR @@ -21120,9 +19177,7 @@ input CountryRateUpdateInput @doc(category: "Taxes") { } """ -Update tax configuration for a channel. - -Added in Saleor 3.9. +Update tax configuration for a channel. Requires one of the following permissions: MANAGE_TAXES. """ @@ -21147,7 +19202,6 @@ type TaxConfigurationUpdateError @doc(category: "Taxes") { countryCodes: [String!]! } -"""An enumeration.""" enum TaxConfigurationUpdateErrorCode @doc(category: "Taxes") { DUPLICATED_INPUT_ITEM GRAPHQL_ERROR @@ -21178,6 +19232,13 @@ input TaxConfigurationUpdateInput @doc(category: "Taxes") { """List of country codes for which to remove the tax configuration.""" removeCountriesConfiguration: [CountryCode!] + """ + Determines whether to use weighted tax for shipping. When set to true, the tax rate for shipping will be calculated based on the weighted average of tax rates from the order or checkout lines. Default value is `False`.Can be used only with `taxCalculationStrategy` set to `FLAT_RATES`. + + Added in Saleor 3.21. + """ + useWeightedTaxForShipping: Boolean + """ The tax app `App.identifier` that will be used to calculate the taxes for the given channel. Empty value for `TAX_APP` set as `taxCalculationStrategy` means that Saleor will iterate over all installed tax apps. If multiple tax apps exist with provided tax app id use the `App` with newest `created` date. It's possible to set plugin by using prefix `plugin:` with `PLUGIN_ID` e.g. with Avalara `plugin:mirumee.taxes.avalara`.Will become mandatory in 4.0 for `TAX_APP` `taxCalculationStrategy`. @@ -21209,12 +19270,17 @@ input TaxConfigurationPerCountryInput @doc(category: "Taxes") { Added in Saleor 3.19. """ taxAppId: String + + """ + Determines whether to use weighted tax for shipping. When set to true, the tax rate for shipping will be calculated based on the weighted average of tax rates from the order or checkout lines. Default value is `False`.Can be used only with `taxCalculationStrategy` set to `FLAT_RATES`. + + Added in Saleor 3.21. + """ + useWeightedTaxForShipping: Boolean } """ -Update tax class rates for a specific country. - -Added in Saleor 3.9. +Update tax class rates for a specific country. Requires one of the following permissions: MANAGE_TAXES. """ @@ -21240,7 +19306,6 @@ type TaxCountryConfigurationUpdateError @doc(category: "Taxes") { taxClassIds: [String!]! } -"""An enumeration.""" enum TaxCountryConfigurationUpdateErrorCode @doc(category: "Taxes") { GRAPHQL_ERROR INVALID @@ -21258,9 +19323,7 @@ input TaxClassRateInput @doc(category: "Taxes") { } """ -Remove all tax class rates for a specific country. - -Added in Saleor 3.9. +Remove all tax class rates for a specific country. Requires one of the following permissions: MANAGE_TAXES. """ @@ -21283,7 +19346,6 @@ type TaxCountryConfigurationDeleteError @doc(category: "Taxes") { code: TaxCountryConfigurationDeleteErrorCode! } -"""An enumeration.""" enum TaxCountryConfigurationDeleteErrorCode @doc(category: "Taxes") { GRAPHQL_ERROR INVALID @@ -21291,9 +19353,7 @@ enum TaxCountryConfigurationDeleteErrorCode @doc(category: "Taxes") { } """ -Exempt checkout or order from charging the taxes. When tax exemption is enabled, taxes won't be charged for the checkout or order. Taxes may still be calculated in cases when product prices are entered with the tax included and the net price needs to be known. - -Added in Saleor 3.8. +Exempt checkout or order from charging the taxes. When tax exemption is enabled, taxes won't be charged for the checkout or order. Taxes may still be calculated in cases when product prices are entered with the tax included and the net price needs to be known. Requires one of the following permissions: MANAGE_TAXES. """ @@ -21317,7 +19377,6 @@ type TaxExemptionManageError @doc(category: "Taxes") { code: TaxExemptionManageErrorCode! } -"""An enumeration.""" enum TaxExemptionManageErrorCode @doc(category: "Taxes") { GRAPHQL_ERROR INVALID @@ -21326,11 +19385,7 @@ enum TaxExemptionManageErrorCode @doc(category: "Taxes") { } """ -Updates stocks for a given variant and warehouse. Variant and warehouse selectors have to be the same for all stock inputs. Is not allowed to use 'variantId' in one input and 'variantExternalReference' in another. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Updates stocks for a given variant and warehouse. Variant and warehouse selectors have to be the same for all stock inputs. Is not allowed to use 'variantId' in one input and 'variantExternalReference' in another. Requires one of the following permissions: MANAGE_PRODUCTS. @@ -21367,7 +19422,6 @@ type StockBulkUpdateError @doc(category: "Products") { code: StockBulkUpdateErrorCode! } -"""An enumeration.""" enum StockBulkUpdateErrorCode @doc(category: "Products") { GRAPHQL_ERROR INVALID @@ -21411,7 +19465,7 @@ Creates a new staff notification recipient. Requires one of the following permissions: MANAGE_SETTINGS. """ type StaffNotificationRecipientCreate @doc(category: "Users") { - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shopErrors: [ShopError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShopError!]! staffNotificationRecipient: StaffNotificationRecipient } @@ -21429,7 +19483,6 @@ type ShopError @doc(category: "Shop") { code: ShopErrorCode! } -"""An enumeration.""" enum ShopErrorCode { ALREADY_EXISTS CANNOT_FETCH_TAX_RATES @@ -21457,7 +19510,7 @@ Updates a staff notification recipient. Requires one of the following permissions: MANAGE_SETTINGS. """ type StaffNotificationRecipientUpdate @doc(category: "Users") { - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shopErrors: [ShopError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShopError!]! staffNotificationRecipient: StaffNotificationRecipient } @@ -21468,22 +19521,20 @@ Delete staff notification recipient. Requires one of the following permissions: MANAGE_SETTINGS. """ type StaffNotificationRecipientDelete @doc(category: "Users") { - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shopErrors: [ShopError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShopError!]! staffNotificationRecipient: StaffNotificationRecipient } """ -Updates site domain of the shop. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PUBLIC_URL` environment variable instead. +Updates site domain of the shop. Requires one of the following permissions: MANAGE_SETTINGS. """ type ShopDomainUpdate @doc(category: "Shop") { """Updated shop.""" shop: Shop - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shopErrors: [ShopError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShopError!]! } @@ -21506,7 +19557,7 @@ Triggers the following webhook events: type ShopSettingsUpdate @doc(category: "Shop") @webhookEventsInfo(asyncEvents: [SHOP_METADATA_UPDATED], syncEvents: []) { """Updated shop.""" shop: Shop - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shopErrors: [ShopError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShopError!]! } @@ -21528,18 +19579,10 @@ input ShopSettingsInput { """Enable automatic fulfillment for all digital products.""" automaticFulfillmentDigitalProducts: Boolean - """ - Enable automatic approval of all new fulfillments. - - Added in Saleor 3.1. - """ + """Enable automatic approval of all new fulfillments.""" fulfillmentAutoApprove: Boolean - """ - Enable ability to approve fulfillments which are unpaid. - - Added in Saleor 3.1. - """ + """Enable ability to approve fulfillments which are unpaid.""" fulfillmentAllowUnpaid: Boolean """Default number of max downloads per digital content URL.""" @@ -21559,73 +19602,47 @@ input ShopSettingsInput { """ Default number of minutes stock will be reserved for anonymous checkout. Enter 0 or null to disable. - - Added in Saleor 3.1. """ reserveStockDurationAnonymousUser: Int """ Default number of minutes stock will be reserved for authenticated checkout. Enter 0 or null to disable. - - Added in Saleor 3.1. """ reserveStockDurationAuthenticatedUser: Int """ Default number of maximum line quantity in single checkout. Minimum possible value is 1, default value is 50. - - Added in Saleor 3.1. """ limitQuantityPerCheckout: Int - """ - Enable automatic account confirmation by email. - - Added in Saleor 3.14. - """ + """Enable automatic account confirmation by email.""" enableAccountConfirmationByEmail: Boolean - """ - Enable possibility to login without account confirmation. - - Added in Saleor 3.15. - """ + """Enable possibility to login without account confirmation.""" allowLoginWithoutConfirmation: Boolean """ - Shop public metadata. + Shop public metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.15. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Shop private metadata. + Shop private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.15. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - Include taxes in prices. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `taxConfigurationUpdate` mutation to configure this setting per channel or country. - """ - includeTaxesInPrices: Boolean + """Include taxes in prices.""" + includeTaxesInPrices: Boolean @deprecated(reason: "Use `taxConfigurationUpdate` mutation to configure this setting per channel or country.") - """ - Display prices with tax in store. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `taxConfigurationUpdate` mutation to configure this setting per channel or country. - """ - displayGrossPrices: Boolean + """Display prices with tax in store.""" + displayGrossPrices: Boolean @deprecated(reason: "Use `taxConfigurationUpdate` mutation to configure this setting per channel or country.") - """ - Charge taxes on shipping. - - DEPRECATED: this field will be removed in Saleor 4.0. To enable taxes for a shipping method, assign a tax class to the shipping method with `shippingPriceCreate` or `shippingPriceUpdate` mutations. - """ - chargeTaxesOnShipping: Boolean + """Charge taxes on shipping.""" + chargeTaxesOnShipping: Boolean @deprecated(reason: "To enable taxes for a shipping method, assign a tax class to the shipping method with `shippingPriceCreate` or `shippingPriceUpdate` mutations.") } """ @@ -21636,7 +19653,7 @@ Requires one of the following permissions: MANAGE_SETTINGS. type ShopFetchTaxRates @doc(category: "Shop") { """Updated shop.""" shop: Shop - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shopErrors: [ShopError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShopError!]! } @@ -21648,7 +19665,7 @@ Requires one of the following permissions: MANAGE_TRANSLATIONS. type ShopSettingsTranslate @doc(category: "Shop") { """Updated shop settings.""" shop: Shop - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! } @@ -21665,12 +19682,12 @@ type TranslationError { code: TranslationErrorCode! } -"""An enumeration.""" enum TranslationErrorCode { GRAPHQL_ERROR INVALID NOT_FOUND REQUIRED + UNIQUE } input ShopSettingsTranslationInput { @@ -21686,7 +19703,7 @@ Requires one of the following permissions: MANAGE_SETTINGS. type ShopAddressUpdate @doc(category: "Shop") { """Updated shop.""" shop: Shop - shopErrors: [ShopError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shopErrors: [ShopError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShopError!]! } @@ -21698,7 +19715,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderSettingsUpdate @doc(category: "Orders") { """Order settings.""" orderSettings: OrderSettings - orderSettingsErrors: [OrderSettingsError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderSettingsErrors: [OrderSettingsError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderSettingsError!]! } @@ -21715,7 +19732,6 @@ type OrderSettingsError @doc(category: "Orders") { code: OrderSettingsErrorCode! } -"""An enumeration.""" enum OrderSettingsErrorCode @doc(category: "Orders") { INVALID } @@ -21756,7 +19772,6 @@ type GiftCardSettingsError @doc(category: "Gift cards") { code: GiftCardSettingsErrorCode! } -"""An enumeration.""" enum GiftCardSettingsErrorCode @doc(category: "Gift cards") { INVALID REQUIRED @@ -21787,7 +19802,7 @@ Requires one of the following permissions: MANAGE_SHIPPING. type ShippingMethodChannelListingUpdate @doc(category: "Shipping") { """An updated shipping method instance.""" shippingMethod: ShippingMethodType - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! } @@ -21810,7 +19825,6 @@ type ShippingError @doc(category: "Shipping") { channels: [ID!] } -"""An enumeration.""" enum ShippingErrorCode @doc(category: "Shipping") { ALREADY_EXISTS GRAPHQL_ERROR @@ -21853,7 +19867,7 @@ type ShippingPriceCreate @doc(category: "Shipping") { """A shipping zone to which the shipping method belongs.""" shippingZone: ShippingZone shippingMethod: ShippingMethodType - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! } @@ -21918,7 +19932,7 @@ type ShippingPriceDelete @doc(category: "Shipping") { """A shipping zone to which the shipping method belongs.""" shippingZone: ShippingZone - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! } @@ -21930,7 +19944,7 @@ Requires one of the following permissions: MANAGE_SHIPPING. type ShippingPriceBulkDelete @doc(category: "Shipping") { """Returns how many objects were affected.""" count: Int! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! } @@ -21943,7 +19957,7 @@ type ShippingPriceUpdate @doc(category: "Shipping") { """A shipping zone to which the shipping method belongs.""" shippingZone: ShippingZone shippingMethod: ShippingMethodType - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! } @@ -21953,7 +19967,7 @@ Creates/updates translations for a shipping method. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type ShippingPriceTranslate @doc(category: "Shipping") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! shippingMethod: ShippingMethodType } @@ -21977,7 +19991,7 @@ Requires one of the following permissions: MANAGE_SHIPPING. type ShippingPriceExcludeProducts @doc(category: "Shipping") { """A shipping method with new list of excluded products.""" shippingMethod: ShippingMethodType - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! } @@ -21994,7 +20008,7 @@ Requires one of the following permissions: MANAGE_SHIPPING. type ShippingPriceRemoveProductFromExclude @doc(category: "Shipping") { """A shipping method with new list of excluded products.""" shippingMethod: ShippingMethodType - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! } @@ -22004,7 +20018,7 @@ Creates a new shipping zone. Requires one of the following permissions: MANAGE_SHIPPING. """ type ShippingZoneCreate @doc(category: "Shipping") { - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! shippingZone: ShippingZone } @@ -22037,7 +20051,7 @@ Deletes a shipping zone. Requires one of the following permissions: MANAGE_SHIPPING. """ type ShippingZoneDelete @doc(category: "Shipping") { - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! shippingZone: ShippingZone } @@ -22050,7 +20064,7 @@ Requires one of the following permissions: MANAGE_SHIPPING. type ShippingZoneBulkDelete @doc(category: "Shipping") { """Returns how many objects were affected.""" count: Int! - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! } @@ -22060,7 +20074,7 @@ Updates a new shipping zone. Requires one of the following permissions: MANAGE_SHIPPING. """ type ShippingZoneUpdate @doc(category: "Shipping") { - shippingErrors: [ShippingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + shippingErrors: [ShippingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ShippingError!]! shippingZone: ShippingZone } @@ -22101,7 +20115,7 @@ Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. type ProductAttributeAssign @doc(category: "Products") { """The updated product type.""" productType: ProductType - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -22124,7 +20138,6 @@ type ProductError @doc(category: "Products") { values: [ID!] } -"""An enumeration.""" enum ProductErrorCode @doc(category: "Products") { ALREADY_EXISTS ATTRIBUTE_ALREADY_ASSIGNED @@ -22157,8 +20170,6 @@ input ProductAttributeAssignInput @doc(category: "Products") { """ Whether attribute is allowed in variant selection. Allowed types are: ['dropdown', 'boolean', 'swatch', 'numeric']. - - Added in Saleor 3.1. """ variantSelection: Boolean } @@ -22169,16 +20180,14 @@ enum ProductAttributeType @doc(category: "Products") { } """ -Update attributes assigned to product variant for given product type. - -Added in Saleor 3.1. +Update attributes assigned to product variant for given product type. Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. """ type ProductAttributeAssignmentUpdate @doc(category: "Products") { """The updated product type.""" productType: ProductType - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -22188,8 +20197,6 @@ input ProductAttributeAssignmentUpdateInput @doc(category: "Products") { """ Whether attribute is allowed in variant selection. Allowed types are: ['dropdown', 'boolean', 'swatch', 'numeric']. - - Added in Saleor 3.1. """ variantSelection: Boolean! } @@ -22202,7 +20209,7 @@ Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. type ProductAttributeUnassign @doc(category: "Products") { """The updated product type.""" productType: ProductType - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -22212,7 +20219,7 @@ Creates a new category. Requires one of the following permissions: MANAGE_PRODUCTS. """ type CategoryCreate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! category: Category } @@ -22241,16 +20248,16 @@ input CategoryInput @doc(category: "Products") { backgroundImageAlt: String """ - Fields required to update the category metadata. + Fields required to update the category metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the category private metadata. + Fields required to update the category private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] } @@ -22274,7 +20281,7 @@ Deletes a category. Requires one of the following permissions: MANAGE_PRODUCTS. """ type CategoryDelete @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! category: Category } @@ -22287,7 +20294,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type CategoryBulkDelete @doc(category: "Products") { """Returns how many objects were affected.""" count: Int! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -22297,7 +20304,7 @@ Updates a category. Requires one of the following permissions: MANAGE_PRODUCTS. """ type CategoryUpdate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! category: Category } @@ -22308,12 +20315,13 @@ Creates/updates translations for a category. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type CategoryTranslate @doc(category: "Products") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! category: Category } input TranslationInput { + slug: String seoTitle: String seoDescription: String name: String @@ -22334,7 +20342,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type CollectionAddProducts @doc(category: "Products") { """Collection to which products will be added.""" collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + collectionErrors: [CollectionError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CollectionError!]! } @@ -22354,7 +20362,6 @@ type CollectionError @doc(category: "Products") { code: CollectionErrorCode! } -"""An enumeration.""" enum CollectionErrorCode @doc(category: "Products") { DUPLICATED_INPUT_ITEM GRAPHQL_ERROR @@ -22371,7 +20378,7 @@ Creates a new collection. Requires one of the following permissions: MANAGE_PRODUCTS. """ type CollectionCreate @doc(category: "Products") { - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + collectionErrors: [CollectionError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CollectionError!]! collection: Collection } @@ -22402,24 +20409,20 @@ input CollectionCreateInput @doc(category: "Products") { """Search engine optimization fields.""" seo: SeoInput - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - publicationDate: Date + """Publication date. ISO 8601 standard.""" + publicationDate: Date @deprecated """ - Fields required to update the collection metadata. + Fields required to update the collection metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the collection private metadata. + Fields required to update the collection private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] @@ -22433,7 +20436,7 @@ Deletes a collection. Requires one of the following permissions: MANAGE_PRODUCTS. """ type CollectionDelete @doc(category: "Products") { - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + collectionErrors: [CollectionError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CollectionError!]! collection: Collection } @@ -22446,7 +20449,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type CollectionReorderProducts @doc(category: "Products") { """Collection from which products are reordered.""" collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + collectionErrors: [CollectionError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CollectionError!]! } @@ -22468,7 +20471,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type CollectionBulkDelete @doc(category: "Products") { """Returns how many objects were affected.""" count: Int! - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + collectionErrors: [CollectionError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CollectionError!]! } @@ -22480,7 +20483,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type CollectionRemoveProducts @doc(category: "Products") { """Collection from which products will be removed.""" collection: Collection - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + collectionErrors: [CollectionError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CollectionError!]! } @@ -22490,7 +20493,7 @@ Updates a collection. Requires one of the following permissions: MANAGE_PRODUCTS. """ type CollectionUpdate @doc(category: "Products") { - collectionErrors: [CollectionError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + collectionErrors: [CollectionError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CollectionError!]! collection: Collection } @@ -22521,24 +20524,20 @@ input CollectionInput @doc(category: "Products") { """Search engine optimization fields.""" seo: SeoInput - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - publicationDate: Date + """Publication date. ISO 8601 standard.""" + publicationDate: Date @deprecated """ - Fields required to update the collection metadata. + Fields required to update the collection metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the collection private metadata. + Fields required to update the collection private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] } @@ -22549,7 +20548,7 @@ Creates/updates translations for a collection. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type CollectionTranslate @doc(category: "Products") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! collection: Collection } @@ -22562,7 +20561,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type CollectionChannelListingUpdate @doc(category: "Products") { """An updated collection instance.""" collection: Collection - collectionChannelListingErrors: [CollectionChannelListingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + collectionChannelListingErrors: [CollectionChannelListingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CollectionChannelListingError!]! } @@ -22603,18 +20602,10 @@ input PublishableChannelListingInput @doc(category: "Products") { """Determines if object is visible to customers.""" isPublished: Boolean - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - """ - publicationDate: Date + """Publication date. ISO 8601 standard.""" + publicationDate: Date @deprecated(reason: "Use `publishedAt` field instead.") - """ - Publication date time. ISO 8601 standard. - - Added in Saleor 3.3. - """ + """Publication date time. ISO 8601 standard.""" publishedAt: DateTime } @@ -22624,7 +20615,7 @@ Creates a new product. Requires one of the following permissions: MANAGE_PRODUCTS. """ type ProductCreate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! product: Product } @@ -22636,12 +20627,8 @@ input ProductCreateInput @doc(category: "Products") { """ID of the product's category.""" category: ID - """ - Determine if taxes are being charged for the product. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. - """ - chargeTaxes: Boolean + """Determine if taxes are being charged for the product.""" + chargeTaxes: Boolean @deprecated(reason: "Use `Channel.taxConfiguration` to configure whether tax collection is enabled.") """List of IDs of collections that the product belongs to.""" collections: [ID!] @@ -22664,12 +20651,8 @@ input ProductCreateInput @doc(category: "Products") { """ taxClass: ID - """ - Tax rate for enabled tax gateway. - - DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. - """ - taxCode: String + """Tax rate for enabled tax gateway.""" + taxCode: String @deprecated(reason: "Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned.") """Search engine optimization fields.""" seo: SeoInput @@ -22681,24 +20664,20 @@ input ProductCreateInput @doc(category: "Products") { rating: Float """ - Fields required to update the product metadata. + Fields required to update the product metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the product private metadata. + Fields required to update the product private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - External ID of this product. - - Added in Saleor 3.10. - """ + """External ID of this product.""" externalReference: String """ID of the type that product belongs to.""" @@ -22709,44 +20688,24 @@ input AttributeValueInput @doc(category: "Attributes") { """ID of the selected attribute.""" id: ID - """ - External ID of this attribute. - - Added in Saleor 3.14. - """ + """External ID of this attribute.""" externalReference: String """ - The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. This field will be removed in Saleor 4.0. + The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. """ - values: [String!] + values: [String!] @deprecated - """ - Attribute value ID or external reference. - - Added in Saleor 3.9. - """ + """Attribute value ID or external reference.""" dropdown: AttributeValueSelectableTypeInput - """ - Attribute value ID or external reference. - - Added in Saleor 3.9. - """ + """Attribute value ID or external reference.""" swatch: AttributeValueSelectableTypeInput - """ - List of attribute value IDs or external references. - - Added in Saleor 3.9. - """ + """List of attribute value IDs or external references.""" multiselect: [AttributeValueSelectableTypeInput!] - """ - Numeric value of an attribute. - - Added in Saleor 3.9. - """ + """Numeric value of an attribute.""" numeric: String """URL of the file attribute. Every time, a new value is created.""" @@ -22780,18 +20739,12 @@ Represents attribute value. 2. If externalReference is provided, then attribute value will be resolved by external reference. 3. If value is provided, then attribute value will be resolved by value. If this attribute value doesn't exist, then it will be created. 4. If externalReference and value is provided then new attribute value will be created. - -Added in Saleor 3.9. """ input AttributeValueSelectableTypeInput @doc(category: "Attributes") { """ID of an attribute value.""" id: ID - """ - External reference of an attribute value. - - Added in Saleor 3.14. - """ + """External reference of an attribute value.""" externalReference: String """ @@ -22806,17 +20759,13 @@ Deletes a product. Requires one of the following permissions: MANAGE_PRODUCTS. """ type ProductDelete @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! product: Product } """ -Creates products. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Creates products. Requires one of the following permissions: MANAGE_PRODUCTS. """ @@ -22862,7 +20811,6 @@ type ProductBulkCreateError @doc(category: "Products") { channels: [ID!] } -"""An enumeration.""" enum ProductBulkCreateErrorCode @doc(category: "Products") { ATTRIBUTE_ALREADY_ASSIGNED ATTRIBUTE_CANNOT_BE_ASSIGNED @@ -22888,12 +20836,8 @@ input ProductBulkCreateInput @doc(category: "Products") { """ID of the product's category.""" category: ID - """ - Determine if taxes are being charged for the product. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. - """ - chargeTaxes: Boolean + """Determine if taxes are being charged for the product.""" + chargeTaxes: Boolean @deprecated(reason: "Use `Channel.taxConfiguration` to configure whether tax collection is enabled.") """List of IDs of collections that the product belongs to.""" collections: [ID!] @@ -22916,12 +20860,8 @@ input ProductBulkCreateInput @doc(category: "Products") { """ taxClass: ID - """ - Tax rate for enabled tax gateway. - - DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. - """ - taxCode: String + """Tax rate for enabled tax gateway.""" + taxCode: String @deprecated(reason: "Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned.") """Search engine optimization fields.""" seo: SeoInput @@ -22932,10 +20872,18 @@ input ProductBulkCreateInput @doc(category: "Products") { """Defines the product rating value.""" rating: Float - """Fields required to update the product metadata.""" + """ + Fields required to update the product metadata. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ metadata: [MetadataInput!] - """Fields required to update the product private metadata.""" + """ + Fields required to update the product private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ privateMetadata: [MetadataInput!] """External ID of this product.""" @@ -23009,39 +20957,29 @@ input ProductVariantBulkCreateInput @doc(category: "Products") { """Weight of the Product Variant.""" weight: WeightScalar - """ - Determines if variant is in preorder. - - Added in Saleor 3.1. - """ + """Determines if variant is in preorder.""" preorder: PreorderSettingsInput """ Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - - Added in Saleor 3.1. """ quantityLimitPerCustomer: Int """ - Fields required to update the product variant metadata. + Fields required to update the product variant metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the product variant private metadata. + Fields required to update the product variant private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - External ID of this product variant. - - Added in Saleor 3.10. - """ + """External ID of this product variant.""" externalReference: String """Stocks of a product available for sale.""" @@ -23055,79 +20993,39 @@ input BulkAttributeValueInput @doc(category: "Products") { """ID of the selected attribute.""" id: ID - """ - External ID of this attribute. - - Added in Saleor 3.14. - """ + """External ID of this attribute.""" externalReference: String """ - The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created.This field will be removed in Saleor 4.0. + The value or slug of an attribute to resolve. If the passed value is non-existent, it will be created. """ - values: [String!] + values: [String!] @deprecated - """ - Attribute value ID. - - Added in Saleor 3.12. - """ + """Attribute value ID.""" dropdown: AttributeValueSelectableTypeInput - """ - Attribute value ID. - - Added in Saleor 3.12. - """ + """Attribute value ID.""" swatch: AttributeValueSelectableTypeInput - """ - List of attribute value IDs. - - Added in Saleor 3.12. - """ + """List of attribute value IDs.""" multiselect: [AttributeValueSelectableTypeInput!] - """ - Numeric value of an attribute. - - Added in Saleor 3.12. - """ + """Numeric value of an attribute.""" numeric: String - """ - URL of the file attribute. Every time, a new value is created. - - Added in Saleor 3.12. - """ + """URL of the file attribute. Every time, a new value is created.""" file: String - """ - File content type. - - Added in Saleor 3.12. - """ + """File content type.""" contentType: String - """ - List of entity IDs that will be used as references. - - Added in Saleor 3.12. - """ + """List of entity IDs that will be used as references.""" references: [ID!] - """ - Text content in JSON format. - - Added in Saleor 3.12. - """ + """Text content in JSON format.""" richText: JSONString - """ - Plain text content. - - Added in Saleor 3.12. - """ + """Plain text content.""" plainText: String """ @@ -23135,18 +21033,10 @@ input BulkAttributeValueInput @doc(category: "Products") { """ boolean: Boolean - """ - Represents the date value of the attribute value. - - Added in Saleor 3.12. - """ + """Represents the date value of the attribute value.""" date: Date - """ - Represents the date/time value of the attribute value. - - Added in Saleor 3.12. - """ + """Represents the date/time value of the attribute value.""" dateTime: DateTime } @@ -23177,10 +21067,13 @@ input ProductVariantChannelListingAddInput @doc(category: "Products") { costPrice: PositiveDecimal """ - The threshold for preorder variant in channel. + Previous price of the variant in channel. Useful for providing promotion information required by customer protection laws such as EU Omnibus directive. - Added in Saleor 3.1. + Added in Saleor 3.21. """ + priorPrice: PositiveDecimal + + """The threshold for preorder variant in channel.""" preorderThreshold: Int } @@ -23192,7 +21085,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductBulkDelete @doc(category: "Products") { """Returns how many objects were affected.""" count: Int! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23202,7 +21095,7 @@ Updates an existing product. Requires one of the following permissions: MANAGE_PRODUCTS. """ type ProductUpdate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! product: Product } @@ -23214,12 +21107,8 @@ input ProductInput @doc(category: "Products") { """ID of the product's category.""" category: ID - """ - Determine if taxes are being charged for the product. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `Channel.taxConfiguration` to configure whether tax collection is enabled. - """ - chargeTaxes: Boolean + """Determine if taxes are being charged for the product.""" + chargeTaxes: Boolean @deprecated(reason: "Use `Channel.taxConfiguration` to configure whether tax collection is enabled.") """List of IDs of collections that the product belongs to.""" collections: [ID!] @@ -23242,12 +21131,8 @@ input ProductInput @doc(category: "Products") { """ taxClass: ID - """ - Tax rate for enabled tax gateway. - - DEPRECATED: this field will be removed in Saleor 4.0. Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. - """ - taxCode: String + """Tax rate for enabled tax gateway.""" + taxCode: String @deprecated(reason: "Use tax classes to control the tax calculation for a product. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned.") """Search engine optimization fields.""" seo: SeoInput @@ -23259,33 +21144,25 @@ input ProductInput @doc(category: "Products") { rating: Float """ - Fields required to update the product metadata. + Fields required to update the product metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the product private metadata. + Fields required to update the product private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - External ID of this product. - - Added in Saleor 3.10. - """ + """External ID of this product.""" externalReference: String } """ -Creates/updates translations for products. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Creates/updates translations for products. Requires one of the following permissions: MANAGE_TRANSLATIONS. @@ -23323,7 +21200,6 @@ type ProductBulkTranslateError { code: ProductTranslateErrorCode! } -"""An enumeration.""" enum ProductTranslateErrorCode @doc(category: "Products") { GRAPHQL_ERROR INVALID @@ -23351,7 +21227,7 @@ Creates/updates translations for a product. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type ProductTranslate @doc(category: "Products") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! product: Product } @@ -23364,7 +21240,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductChannelListingUpdate @doc(category: "Products") { """An updated product instance.""" product: Product - productChannelListingErrors: [ProductChannelListingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productChannelListingErrors: [ProductChannelListingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductChannelListingError!]! } @@ -23408,18 +21284,10 @@ input ProductChannelListingAddInput @doc(category: "Products") { """Determines if object is visible to customers.""" isPublished: Boolean - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - """ - publicationDate: Date + """Publication date. ISO 8601 standard.""" + publicationDate: Date @deprecated(reason: "Use `publishedAt` field instead.") - """ - Publication date time. ISO 8601 standard. - - Added in Saleor 3.3. - """ + """Publication date time. ISO 8601 standard.""" publishedAt: DateTime """ @@ -23433,16 +21301,12 @@ input ProductChannelListingAddInput @doc(category: "Products") { isAvailableForPurchase: Boolean """ - A start date from which a product will be available for purchase. When not set and isAvailable is set to True, the current day is assumed. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `availableForPurchaseAt` field instead. + A start date from which a product will be available for purchase. When not set and isAvailable is set to True, the current day is assumed. """ - availableForPurchaseDate: Date + availableForPurchaseDate: Date @deprecated(reason: "Use `availableForPurchaseAt` field instead.") """ A start date time from which a product will be available for purchase. When not set and `isAvailable` is set to True, the current day is assumed. - - Added in Saleor 3.3. """ availableForPurchaseAt: DateTime @@ -23461,7 +21325,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductMediaCreate @doc(category: "Products") { product: Product media: ProductMedia - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23486,7 +21350,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. """ type ProductVariantReorder @doc(category: "Products") { product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23508,7 +21372,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductMediaDelete @doc(category: "Products") { product: Product media: ProductMedia - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23520,7 +21384,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductMediaBulkDelete @doc(category: "Products") { """Returns how many objects were affected.""" count: Int! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23532,7 +21396,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductMediaReorder @doc(category: "Products") { product: Product media: [ProductMedia!] - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23544,7 +21408,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductMediaUpdate @doc(category: "Products") { product: Product media: ProductMedia - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23559,7 +21423,7 @@ Creates a new product type. Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. """ type ProductTypeCreate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! productType: ProductType } @@ -23596,12 +21460,8 @@ input ProductTypeInput @doc(category: "Products") { """Weight of the ProductType items.""" weight: WeightScalar - """ - Tax rate for enabled tax gateway. - - DEPRECATED: this field will be removed in Saleor 4.0.. Use tax classes to control the tax calculation for a product type. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned. - """ - taxCode: String + """Tax rate for enabled tax gateway.""" + taxCode: String @deprecated(reason: "Use tax classes to control the tax calculation for a product type. If taxCode is provided, Saleor will try to find a tax class with given code (codes are stored in metadata) and assign it. If no tax class is found, it would be created and assigned.") """ ID of a tax class to assign to this product type. All products of this product type would use this tax class, unless it's overridden in the `Product` type. @@ -23615,7 +21475,7 @@ Deletes a product type. Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. """ type ProductTypeDelete @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! productType: ProductType } @@ -23628,7 +21488,7 @@ Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. type ProductTypeBulkDelete @doc(category: "Products") { """Returns how many objects were affected.""" count: Int! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23638,7 +21498,7 @@ Updates an existing product type. Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. """ type ProductTypeUpdate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! productType: ProductType } @@ -23651,7 +21511,7 @@ Requires one of the following permissions: MANAGE_PRODUCT_TYPES_AND_ATTRIBUTES. type ProductTypeReorderAttributes @doc(category: "Products") { """Product type from which attributes are reordered.""" productType: ProductType - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23663,7 +21523,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductReorderAttributeValues @doc(category: "Products") { """Product from which attribute values are reordered.""" product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23675,7 +21535,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type DigitalContentCreate @doc(category: "Products") { variant: ProductVariant content: DigitalContent - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23697,16 +21557,16 @@ input DigitalContentUploadInput @doc(category: "Products") { automaticFulfillment: Boolean """ - Fields required to update the digital content metadata. + Fields required to update the digital content metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the digital content private metadata. + Fields required to update the digital content private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] @@ -23721,7 +21581,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. """ type DigitalContentDelete @doc(category: "Products") { variant: ProductVariant - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23733,7 +21593,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type DigitalContentUpdate @doc(category: "Products") { variant: ProductVariant content: DigitalContent - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -23755,16 +21615,16 @@ input DigitalContentInput @doc(category: "Products") { automaticFulfillment: Boolean """ - Fields required to update the digital content metadata. + Fields required to update the digital content metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the digital content private metadata. + Fields required to update the digital content private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] } @@ -23775,7 +21635,7 @@ Generate new URL to digital content. Requires one of the following permissions: MANAGE_PRODUCTS. """ type DigitalContentUrlCreate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! digitalContentUrl: DigitalContentUrl } @@ -23791,7 +21651,7 @@ Creates a new variant for a product. Requires one of the following permissions: MANAGE_PRODUCTS. """ type ProductVariantCreate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! productVariant: ProductVariant } @@ -23814,39 +21674,29 @@ input ProductVariantCreateInput @doc(category: "Products") { """Weight of the Product Variant.""" weight: WeightScalar - """ - Determines if variant is in preorder. - - Added in Saleor 3.1. - """ + """Determines if variant is in preorder.""" preorder: PreorderSettingsInput """ Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - - Added in Saleor 3.1. """ quantityLimitPerCustomer: Int """ - Fields required to update the product variant metadata. + Fields required to update the product variant metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the product variant private metadata. + Fields required to update the product variant private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - External ID of this product variant. - - Added in Saleor 3.10. - """ + """External ID of this product variant.""" externalReference: String """Product ID of which type is the variant.""" @@ -23862,7 +21712,7 @@ Deletes a product variant. Requires one of the following permissions: MANAGE_PRODUCTS. """ type ProductVariantDelete @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! productVariant: ProductVariant } @@ -23876,16 +21726,12 @@ type ProductVariantBulkCreate @doc(category: "Products") { """Returns how many objects were created.""" count: Int! - """List of the created variants.This field will be removed in Saleor 4.0.""" + """List of the created variants.""" productVariants: [ProductVariant!]! - """ - List of the created variants. - - Added in Saleor 3.11. - """ + """List of the created variants.""" results: [ProductVariantBulkResult!]! - bulkProductErrors: [BulkProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + bulkProductErrors: [BulkProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [BulkProductError!]! } @@ -23911,8 +21757,6 @@ type ProductVariantBulkError @doc(category: "Products") { """ Path to field that caused the error. A value of `null` indicates that the error isn't associated with a particular field. - - Added in Saleor 3.14. """ path: String @@ -23925,25 +21769,16 @@ type ProductVariantBulkError @doc(category: "Products") { """List of warehouse IDs which causes the error.""" warehouses: [ID!] - """ - List of stocks IDs which causes the error. - - Added in Saleor 3.12. - """ + """List of stocks IDs which causes the error.""" stocks: [ID!] - """ - List of channel IDs which causes the error. - - Added in Saleor 3.12. - """ + """List of channel IDs which causes the error.""" channels: [ID!] """List of channel listings IDs which causes the error.""" channelListings: [ID!] } -"""An enumeration.""" enum ProductVariantBulkErrorCode @doc(category: "Products") { ATTRIBUTE_ALREADY_ASSIGNED ATTRIBUTE_CANNOT_BE_ASSIGNED @@ -23989,11 +21824,7 @@ type BulkProductError @doc(category: "Products") { } """ -Update multiple product variants. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Update multiple product variants. Requires one of the following permissions: MANAGE_PRODUCTS. """ @@ -24006,11 +21837,7 @@ type ProductVariantBulkUpdate @doc(category: "Products") { errors: [ProductVariantBulkError!]! } -""" -Input fields to update product variants. - -Added in Saleor 3.11. -""" +"""Input fields to update product variants.""" input ProductVariantBulkUpdateInput @doc(category: "Products") { """List of attributes specific to this variant.""" attributes: [BulkAttributeValueInput!] @@ -24029,57 +21856,35 @@ input ProductVariantBulkUpdateInput @doc(category: "Products") { """Weight of the Product Variant.""" weight: WeightScalar - """ - Determines if variant is in preorder. - - Added in Saleor 3.1. - """ + """Determines if variant is in preorder.""" preorder: PreorderSettingsInput """ Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - - Added in Saleor 3.1. """ quantityLimitPerCustomer: Int """ - Fields required to update the product variant metadata. + Fields required to update the product variant metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the product variant private metadata. + Fields required to update the product variant private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - External ID of this product variant. - - Added in Saleor 3.10. - """ + """External ID of this product variant.""" externalReference: String - """ - Stocks input. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Stocks input.""" stocks: ProductVariantStocksUpdateInput - """ - Channel listings input. - - Added in Saleor 3.12. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Channel listings input.""" channelListings: ProductVariantChannelListingUpdateInput """ID of the product variant to update.""" @@ -24126,6 +21931,9 @@ input ChannelListingUpdateInput @doc(category: "Products") { """Cost price of the variant in channel.""" costPrice: PositiveDecimal + """Price of the variant before discount.""" + priorPrice: PositiveDecimal + """The threshold for preorder variant in channel.""" preorderThreshold: Int } @@ -24138,7 +21946,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductVariantBulkDelete @doc(category: "Products") { """Returns how many objects were affected.""" count: Int! - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -24150,7 +21958,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductVariantStocksCreate @doc(category: "Products") { """Updated product variant.""" productVariant: ProductVariant - bulkStockErrors: [BulkStockError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + bulkStockErrors: [BulkStockError!]! @deprecated(reason: "Use `errors` field instead.") errors: [BulkStockError!]! } @@ -24184,7 +21992,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductVariantStocksDelete @doc(category: "Products") { """Updated product variant.""" productVariant: ProductVariant - stockErrors: [StockError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + stockErrors: [StockError!]! @deprecated(reason: "Use `errors` field instead.") errors: [StockError!]! } @@ -24201,7 +22009,6 @@ type StockError @doc(category: "Products") { code: StockErrorCode! } -"""An enumeration.""" enum StockErrorCode @doc(category: "Products") { ALREADY_EXISTS GRAPHQL_ERROR @@ -24219,7 +22026,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductVariantStocksUpdate @doc(category: "Products") { """Updated product variant.""" productVariant: ProductVariant - bulkStockErrors: [BulkStockError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + bulkStockErrors: [BulkStockError!]! @deprecated(reason: "Use `errors` field instead.") errors: [BulkStockError!]! } @@ -24229,7 +22036,7 @@ Updates an existing variant for product. Requires one of the following permissions: MANAGE_PRODUCTS. """ type ProductVariantUpdate @doc(category: "Products") { - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! productVariant: ProductVariant } @@ -24252,39 +22059,29 @@ input ProductVariantInput @doc(category: "Products") { """Weight of the Product Variant.""" weight: WeightScalar - """ - Determines if variant is in preorder. - - Added in Saleor 3.1. - """ + """Determines if variant is in preorder.""" preorder: PreorderSettingsInput """ Determines maximum quantity of `ProductVariant`,that can be bought in a single checkout. - - Added in Saleor 3.1. """ quantityLimitPerCustomer: Int """ - Fields required to update the product variant metadata. + Fields required to update the product variant metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the product variant private metadata. + Fields required to update the product variant private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - External ID of this product variant. - - Added in Saleor 3.10. - """ + """External ID of this product variant.""" externalReference: String } @@ -24295,7 +22092,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. """ type ProductVariantSetDefault @doc(category: "Products") { product: Product - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -24305,7 +22102,7 @@ Creates/updates translations for a product variant. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type ProductVariantTranslate @doc(category: "Products") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! productVariant: ProductVariant } @@ -24315,11 +22112,7 @@ input NameTranslationInput { } """ -Creates/updates translations for products variants. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Creates/updates translations for products variants. Requires one of the following permissions: MANAGE_TRANSLATIONS. @@ -24357,7 +22150,6 @@ type ProductVariantBulkTranslateError { code: ProductVariantTranslateErrorCode! } -"""An enumeration.""" enum ProductVariantTranslateErrorCode @doc(category: "Products") { GRAPHQL_ERROR INVALID @@ -24387,7 +22179,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductVariantChannelListingUpdate @doc(category: "Products") { """An updated product variant instance.""" variant: ProductVariant - productChannelListingErrors: [ProductChannelListingError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productChannelListingErrors: [ProductChannelListingError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductChannelListingError!]! } @@ -24399,14 +22191,12 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type ProductVariantReorderAttributeValues @doc(category: "Products") { """Product variant from which attribute values are reordered.""" productVariant: ProductVariant - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } """ -Deactivates product variant preorder. It changes all preorder allocation into regular allocation. - -Added in Saleor 3.1. +Deactivates product variant preorder. It changes all preorder allocation into regular allocation. Requires one of the following permissions: MANAGE_PRODUCTS. """ @@ -24424,7 +22214,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type VariantMediaAssign @doc(category: "Products") { productVariant: ProductVariant media: ProductMedia - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -24436,7 +22226,7 @@ Requires one of the following permissions: MANAGE_PRODUCTS. type VariantMediaUnassign @doc(category: "Products") { productVariant: ProductVariant media: ProductMedia - productErrors: [ProductError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + productErrors: [ProductError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ProductError!]! } @@ -24448,7 +22238,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type PaymentCapture @doc(category: "Payments") { """Updated payment.""" payment: Payment - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + paymentErrors: [PaymentError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PaymentError!]! } @@ -24468,7 +22258,6 @@ type PaymentError @doc(category: "Payments") { variants: [ID!] } -"""An enumeration.""" enum PaymentErrorCode @doc(category: "Payments") { BILLING_ADDRESS_NOT_SET GRAPHQL_ERROR @@ -24498,7 +22287,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type PaymentRefund @doc(category: "Payments") { """Updated payment.""" payment: Payment - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + paymentErrors: [PaymentError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PaymentError!]! } @@ -24510,7 +22299,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type PaymentVoid @doc(category: "Payments") { """Updated payment.""" payment: Payment - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + paymentErrors: [PaymentError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PaymentError!]! } @@ -24518,7 +22307,7 @@ type PaymentVoid @doc(category: "Payments") { type PaymentInitialize @doc(category: "Payments") { """Payment that was initialized.""" initializedPayment: PaymentInitialized - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + paymentErrors: [PaymentError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PaymentError!]! } @@ -24540,7 +22329,7 @@ type PaymentInitialized @doc(category: "Payments") { type PaymentCheckBalance @doc(category: "Payments") { """Response from the gateway.""" data: JSONString - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + paymentErrors: [PaymentError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PaymentError!]! } @@ -24580,11 +22369,7 @@ input MoneyInput { } """ -Create transaction for checkout or order. - -Added in Saleor 3.4. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Create transaction for checkout or order. Requires one of the following permissions: HANDLE_PAYMENTS. """ @@ -24606,7 +22391,6 @@ type TransactionCreateError @doc(category: "Payments") { code: TransactionCreateErrorCode! } -"""An enumeration.""" enum TransactionCreateErrorCode @doc(category: "Payments") { INVALID GRAPHQL_ERROR @@ -24617,25 +22401,13 @@ enum TransactionCreateErrorCode @doc(category: "Payments") { } input TransactionCreateInput @doc(category: "Payments") { - """ - Payment name of the transaction. - - Added in Saleor 3.13. - """ + """Payment name of the transaction.""" name: String - """ - The message of the transaction. - - Added in Saleor 3.13. - """ + """The message of the transaction.""" message: String - """ - PSP Reference of the transaction. - - Added in Saleor 3.13. - """ + """PSP Reference of the transaction.""" pspReference: String """List of all possible actions for the transaction""" @@ -24650,50 +22422,40 @@ input TransactionCreateInput @doc(category: "Payments") { """Amount refunded by this transaction.""" amountRefunded: MoneyInput + """Amount canceled by this transaction.""" + amountCanceled: MoneyInput + """ - Amount canceled by this transaction. + Payment public metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.13. + Warning: never store sensitive information, including financial data such as credit card details. """ - amountCanceled: MoneyInput - - """Payment public metadata.""" metadata: [MetadataInput!] - """Payment private metadata.""" + """ + Payment private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ privateMetadata: [MetadataInput!] """ The url that will allow to redirect user to payment provider page with transaction event details. - - Added in Saleor 3.13. """ externalUrl: String } input TransactionEventInput @doc(category: "Payments") { - """ - PSP Reference related to this action. - - Added in Saleor 3.13. - """ + """PSP Reference related to this action.""" pspReference: String - """ - The message related to the event. - - Added in Saleor 3.13. - """ + """The message related to the event.""" message: String } """ Update transaction. -Added in Saleor 3.4. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. """ type TransactionUpdate @doc(category: "Payments") { @@ -24714,7 +22476,6 @@ type TransactionUpdateError @doc(category: "Payments") { code: TransactionUpdateErrorCode! } -"""An enumeration.""" enum TransactionUpdateErrorCode @doc(category: "Payments") { INVALID GRAPHQL_ERROR @@ -24725,25 +22486,13 @@ enum TransactionUpdateErrorCode @doc(category: "Payments") { } input TransactionUpdateInput @doc(category: "Payments") { - """ - Payment name of the transaction. - - Added in Saleor 3.13. - """ + """Payment name of the transaction.""" name: String - """ - The message of the transaction. - - Added in Saleor 3.13. - """ + """The message of the transaction.""" message: String - """ - PSP Reference of the transaction. - - Added in Saleor 3.13. - """ + """PSP Reference of the transaction.""" pspReference: String """List of all possible actions for the transaction""" @@ -24758,33 +22507,31 @@ input TransactionUpdateInput @doc(category: "Payments") { """Amount refunded by this transaction.""" amountRefunded: MoneyInput + """Amount canceled by this transaction.""" + amountCanceled: MoneyInput + """ - Amount canceled by this transaction. + Payment public metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.13. + Warning: never store sensitive information, including financial data such as credit card details. """ - amountCanceled: MoneyInput - - """Payment public metadata.""" metadata: [MetadataInput!] - """Payment private metadata.""" + """ + Payment private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ privateMetadata: [MetadataInput!] """ The url that will allow to redirect user to payment provider page with transaction event details. - - Added in Saleor 3.13. """ externalUrl: String } """ -Request an action for payment transaction. - -Added in Saleor 3.4. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Request an action for payment transaction. Requires one of the following permissions: HANDLE_PAYMENTS. """ @@ -24806,7 +22553,6 @@ type TransactionRequestActionError @doc(category: "Payments") { code: TransactionRequestActionErrorCode! } -"""An enumeration.""" enum TransactionRequestActionErrorCode @doc(category: "Payments") { INVALID GRAPHQL_ERROR @@ -24815,11 +22561,7 @@ enum TransactionRequestActionErrorCode @doc(category: "Payments") { } """ -Request a refund for payment transaction based on granted refund. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Request a refund for payment transaction based on granted refund. Requires one of the following permissions: HANDLE_PAYMENTS. """ @@ -24841,7 +22583,6 @@ type TransactionRequestRefundForGrantedRefundError @doc(category: "Payments") { code: TransactionRequestRefundForGrantedRefundErrorCode! } -"""An enumeration.""" enum TransactionRequestRefundForGrantedRefundErrorCode @doc(category: "Payments") { INVALID GRAPHQL_ERROR @@ -24855,13 +22596,14 @@ enum TransactionRequestRefundForGrantedRefundErrorCode @doc(category: "Payments" """ Report the event for the transaction. -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - Requires the following permissions: OWNER and HANDLE_PAYMENTS for apps, HANDLE_PAYMENTS for staff users. Staff user cannot update a transaction that is owned by the app. + +Triggers the following webhook events: +- TRANSACTION_ITEM_METADATA_UPDATED (async): Optionally called when transaction's metadata was updated. +- CHECKOUT_FULLY_PAID (async): Optionally called when the checkout charge status changed to `FULL` or `OVERCHARGED`. +- ORDER_UPDATED (async): Optionally called when the transaction is related to the order and the order was updated. """ -type TransactionEventReport @doc(category: "Payments") { +type TransactionEventReport @doc(category: "Payments") @webhookEventsInfo(asyncEvents: [TRANSACTION_ITEM_METADATA_UPDATED, CHECKOUT_FULLY_PAID, ORDER_UPDATED], syncEvents: []) { """Defines if the reported event hasn't been processed earlier.""" alreadyProcessed: Boolean @@ -24888,7 +22630,6 @@ type TransactionEventReportError @doc(category: "Payments") { code: TransactionEventReportErrorCode! } -"""An enumeration.""" enum TransactionEventReportErrorCode @doc(category: "Payments") { INVALID GRAPHQL_ERROR @@ -24900,10 +22641,6 @@ enum TransactionEventReportErrorCode @doc(category: "Payments") { """ Initializes a payment gateway session. It triggers the webhook `PAYMENT_GATEWAY_INITIALIZE_SESSION`, to the requested `paymentGateways`. If `paymentGateways` is not provided, the webhook will be send to all subscribed payment gateways. There is a limit of 100 transaction items per checkout / order. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type PaymentGatewayInitialize @doc(category: "Payments") { """List of payment gateway configurations.""" @@ -24933,7 +22670,6 @@ type PaymentGatewayConfigError @doc(category: "Payments") { code: PaymentGatewayConfigErrorCode! } -"""An enumeration.""" enum PaymentGatewayConfigErrorCode @doc(category: "Payments") { GRAPHQL_ERROR INVALID @@ -24953,7 +22689,6 @@ type PaymentGatewayInitializeError @doc(category: "Payments") { code: PaymentGatewayInitializeErrorCode! } -"""An enumeration.""" enum PaymentGatewayInitializeErrorCode @doc(category: "Payments") { GRAPHQL_ERROR INVALID @@ -24970,10 +22705,6 @@ input PaymentGatewayToInitialize @doc(category: "Payments") { """ Initializes a transaction session. It triggers the webhook `TRANSACTION_INITIALIZE_SESSION`, to the requested `paymentGateways`. There is a limit of 100 transaction items per checkout / order. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type TransactionInitialize @doc(category: "Payments") { """The initialized transaction.""" @@ -25000,7 +22731,6 @@ type TransactionInitializeError @doc(category: "Payments") { code: TransactionInitializeErrorCode! } -"""An enumeration.""" enum TransactionInitializeErrorCode @doc(category: "Payments") { GRAPHQL_ERROR INVALID @@ -25010,11 +22740,7 @@ enum TransactionInitializeErrorCode @doc(category: "Payments") { } """ -Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Processes a transaction session. It triggers the webhook `TRANSACTION_PROCESS_SESSION`, to the assigned `paymentGateways`. """ type TransactionProcess @doc(category: "Payments") { """The processed transaction.""" @@ -25041,7 +22767,6 @@ type TransactionProcessError @doc(category: "Payments") { code: TransactionProcessErrorCode! } -"""An enumeration.""" enum TransactionProcessErrorCode @doc(category: "Payments") { GRAPHQL_ERROR INVALID @@ -25053,11 +22778,7 @@ enum TransactionProcessErrorCode @doc(category: "Payments") { } """ -Request to delete a stored payment method on payment provider side. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Request to delete a stored payment method on payment provider side. Requires one of the following permissions: AUTHENTICATED_USER. @@ -25098,7 +22819,6 @@ type PaymentMethodRequestDeleteError @doc(category: "Payments") { code: StoredPaymentMethodRequestDeleteErrorCode! } -"""An enumeration.""" enum StoredPaymentMethodRequestDeleteErrorCode @doc(category: "Payments") { GRAPHQL_ERROR INVALID @@ -25108,11 +22828,7 @@ enum StoredPaymentMethodRequestDeleteErrorCode @doc(category: "Payments") { } """ -Initializes payment gateway for tokenizing payment method session. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Initializes payment gateway for tokenizing payment method session. Requires one of the following permissions: AUTHENTICATED_USER. @@ -25155,7 +22871,6 @@ type PaymentGatewayInitializeTokenizationError @doc(category: "Payments") { code: PaymentGatewayInitializeTokenizationErrorCode! } -"""An enumeration.""" enum PaymentGatewayInitializeTokenizationErrorCode @doc(category: "Payments") { GRAPHQL_ERROR INVALID @@ -25165,11 +22880,7 @@ enum PaymentGatewayInitializeTokenizationErrorCode @doc(category: "Payments") { } """ -Tokenize payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Tokenize payment method. Requires one of the following permissions: AUTHENTICATED_USER. @@ -25219,7 +22930,6 @@ type PaymentMethodInitializeTokenizationError @doc(category: "Payments") { code: PaymentMethodInitializeTokenizationErrorCode! } -"""An enumeration.""" enum PaymentMethodInitializeTokenizationErrorCode @doc(category: "Payments") { GRAPHQL_ERROR INVALID @@ -25229,11 +22939,7 @@ enum PaymentMethodInitializeTokenizationErrorCode @doc(category: "Payments") { } """ -Tokenize payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Tokenize payment method. Requires one of the following permissions: AUTHENTICATED_USER. @@ -25265,7 +22971,6 @@ type PaymentMethodProcessTokenizationError @doc(category: "Payments") { code: PaymentMethodProcessTokenizationErrorCode! } -"""An enumeration.""" enum PaymentMethodProcessTokenizationErrorCode @doc(category: "Payments") { GRAPHQL_ERROR INVALID @@ -25280,7 +22985,7 @@ Creates a new page. Requires one of the following permissions: MANAGE_PAGES. """ type PageCreate @doc(category: "Pages") { - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! page: Page } @@ -25304,7 +23009,6 @@ type PageError @doc(category: "Pages") { values: [ID!] } -"""An enumeration.""" enum PageErrorCode @doc(category: "Pages") { GRAPHQL_ERROR INVALID @@ -25335,18 +23039,10 @@ input PageCreateInput @doc(category: "Pages") { """Determines if page is visible in the storefront.""" isPublished: Boolean - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - """ - publicationDate: String + """Publication date. ISO 8601 standard.""" + publicationDate: String @deprecated(reason: "Use `publishedAt` field instead.") - """ - Publication date time. ISO 8601 standard. - - Added in Saleor 3.3. - """ + """Publication date time. ISO 8601 standard.""" publishedAt: DateTime """Search engine optimization fields.""" @@ -25362,7 +23058,7 @@ Deletes a page. Requires one of the following permissions: MANAGE_PAGES. """ type PageDelete @doc(category: "Pages") { - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! page: Page } @@ -25375,7 +23071,7 @@ Requires one of the following permissions: MANAGE_PAGES. type PageBulkDelete @doc(category: "Pages") { """Returns how many objects were affected.""" count: Int! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! } @@ -25387,7 +23083,7 @@ Requires one of the following permissions: MANAGE_PAGES. type PageBulkPublish @doc(category: "Pages") { """Returns how many objects were affected.""" count: Int! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! } @@ -25397,7 +23093,7 @@ Updates an existing page. Requires one of the following permissions: MANAGE_PAGES. """ type PageUpdate @doc(category: "Pages") { - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! page: Page } @@ -25422,18 +23118,10 @@ input PageInput @doc(category: "Pages") { """Determines if page is visible in the storefront.""" isPublished: Boolean - """ - Publication date. ISO 8601 standard. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `publishedAt` field instead. - """ - publicationDate: String + """Publication date. ISO 8601 standard.""" + publicationDate: String @deprecated(reason: "Use `publishedAt` field instead.") - """ - Publication date time. ISO 8601 standard. - - Added in Saleor 3.3. - """ + """Publication date time. ISO 8601 standard.""" publishedAt: DateTime """Search engine optimization fields.""" @@ -25446,12 +23134,13 @@ Creates/updates translations for a page. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type PageTranslate @doc(category: "Pages") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! page: PageTranslatableContent } input PageTranslationInput { + slug: String seoTitle: String seoDescription: String title: String @@ -25470,7 +23159,7 @@ Create a new page type. Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. """ type PageTypeCreate @doc(category: "Pages") { - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! pageType: PageType } @@ -25492,7 +23181,7 @@ Update page type. Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. """ type PageTypeUpdate @doc(category: "Pages") { - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! pageType: PageType } @@ -25517,7 +23206,7 @@ Delete a page type. Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. """ type PageTypeDelete @doc(category: "Pages") { - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! pageType: PageType } @@ -25530,7 +23219,7 @@ Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. type PageTypeBulkDelete @doc(category: "Pages") { """Returns how many objects were affected.""" count: Int! - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! } @@ -25542,7 +23231,7 @@ Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. type PageAttributeAssign @doc(category: "Pages") { """The updated page type.""" pageType: PageType - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! } @@ -25554,7 +23243,7 @@ Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. type PageAttributeUnassign @doc(category: "Pages") { """The updated page type.""" pageType: PageType - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! } @@ -25566,7 +23255,7 @@ Requires one of the following permissions: MANAGE_PAGE_TYPES_AND_ATTRIBUTES. type PageTypeReorderAttributes @doc(category: "Pages") { """Page type from which attributes are reordered.""" pageType: PageType - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! } @@ -25578,7 +23267,7 @@ Requires one of the following permissions: MANAGE_PAGES. type PageReorderAttributeValues @doc(category: "Pages") { """Page from which attribute values are reordered.""" page: Page - pageErrors: [PageError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pageErrors: [PageError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PageError!]! } @@ -25590,7 +23279,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type DraftOrderComplete @doc(category: "Orders") { """Completed order.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25600,7 +23289,7 @@ Creates a new draft order. Requires one of the following permissions: MANAGE_ORDERS. """ type DraftOrderCreate @doc(category: "Orders") { - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! order: Order } @@ -25609,6 +23298,13 @@ input DraftOrderCreateInput @doc(category: "Orders") { """Billing address of the customer.""" billingAddress: AddressInput + """ + Indicates whether the billing address should be saved to the user’s address book upon draft order completion. Can only be set when a billing address is provided. If not specified along with the address, the default behavior is to not save the address. + + Added in Saleor 3.21. + """ + saveBillingAddress: Boolean + """Customer associated with the draft order.""" user: ID @@ -25616,11 +23312,18 @@ input DraftOrderCreateInput @doc(category: "Orders") { userEmail: String """Discount amount for the order.""" - discount: PositiveDecimal + discount: PositiveDecimal @deprecated(reason: "Providing a value for the field has no effect. Use `orderDiscountAdd` mutation instead.") """Shipping address of the customer.""" shippingAddress: AddressInput + """ + Indicates whether the shipping address should be saved to the user’s address book upon draft order completion.Can only be set when a shipping address is provided. If not specified along with the address, the default behavior is to not save the address. + + Added in Saleor 3.21. + """ + saveShippingAddress: Boolean + """ID of a selected shipping method.""" shippingMethod: ID @@ -25645,12 +23348,33 @@ input DraftOrderCreateInput @doc(category: "Orders") { """ redirectUrl: String + """External ID of this order.""" + externalReference: String + """ - External ID of this order. + Order public metadata. - Added in Saleor 3.10. + Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. """ - externalReference: String + metadata: [MetadataInput!] + + """ + Order private metadata. + + Added in Saleor 3.21. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ + privateMetadata: [MetadataInput!] + + """ + Order language code. + + Added in Saleor 3.21. + """ + languageCode: LanguageCodeEnum """Variant line input consisting of variant ID and quantity of products.""" lines: [OrderLineCreateInput!] @@ -25664,18 +23388,12 @@ input OrderLineCreateInput @doc(category: "Orders") { variantId: ID! """ - Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. - - Added in Saleor 3.6. + Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. """ forceNewLine: Boolean = false """ Custom price of the item.When the line with the same variant will be provided multiple times, the last price will be used. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ price: PositiveDecimal } @@ -25686,7 +23404,7 @@ Deletes a draft order. Requires one of the following permissions: MANAGE_ORDERS. """ type DraftOrderDelete @doc(category: "Orders") { - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! order: Order } @@ -25699,7 +23417,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type DraftOrderBulkDelete @doc(category: "Orders") { """Returns how many objects were affected.""" count: Int! - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25711,7 +23429,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type DraftOrderLinesBulkDelete @doc(category: "Orders") { """Returns how many objects were affected.""" count: Int! - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25721,7 +23439,7 @@ Updates a draft order. Requires one of the following permissions: MANAGE_ORDERS. """ type DraftOrderUpdate @doc(category: "Orders") { - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! order: Order } @@ -25730,6 +23448,13 @@ input DraftOrderInput @doc(category: "Orders") { """Billing address of the customer.""" billingAddress: AddressInput + """ + Indicates whether the billing address should be saved to the user’s address book upon draft order completion. Can only be set when a billing address is provided. If not specified along with the address, the default behavior is to not save the address. + + Added in Saleor 3.21. + """ + saveBillingAddress: Boolean + """Customer associated with the draft order.""" user: ID @@ -25737,11 +23462,18 @@ input DraftOrderInput @doc(category: "Orders") { userEmail: String """Discount amount for the order.""" - discount: PositiveDecimal + discount: PositiveDecimal @deprecated(reason: "Providing a value for the field has no effect. Use `orderDiscountAdd` mutation instead.") """Shipping address of the customer.""" shippingAddress: AddressInput + """ + Indicates whether the shipping address should be saved to the user’s address book upon draft order completion.Can only be set when a shipping address is provided. If not specified along with the address, the default behavior is to not save the address. + + Added in Saleor 3.21. + """ + saveShippingAddress: Boolean + """ID of a selected shipping method.""" shippingMethod: ID @@ -25766,18 +23498,37 @@ input DraftOrderInput @doc(category: "Orders") { """ redirectUrl: String + """External ID of this order.""" + externalReference: String + """ - External ID of this order. + Order public metadata. + + Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.10. + Warning: never store sensitive information, including financial data such as credit card details. """ - externalReference: String + metadata: [MetadataInput!] + + """ + Order private metadata. + + Added in Saleor 3.21. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ + privateMetadata: [MetadataInput!] + + """ + Order language code. + + Added in Saleor 3.21. + """ + languageCode: LanguageCodeEnum } """ -Adds note to the order. - -DEPRECATED: this mutation will be removed in Saleor 4.0. +Adds note to the order. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -25787,16 +23538,12 @@ type OrderAddNote @doc(category: "Orders") { """Order note created.""" event: OrderEvent - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } input OrderAddNoteInput @doc(category: "Orders") { - """ - Note message. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ + """Note message.""" message: String! } @@ -25808,7 +23555,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderCancel @doc(category: "Orders") { """Canceled order.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25820,7 +23567,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderCapture @doc(category: "Orders") { """Captured order.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25831,7 +23578,7 @@ Requires one of the following permissions: MANAGE_ORDERS. """ type OrderConfirm @doc(category: "Orders") { order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25852,7 +23599,7 @@ type OrderFulfill @doc(category: "Orders") @webhookEventsInfo(asyncEvents: [FULF """Fulfilled order.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25866,11 +23613,7 @@ input OrderFulfillInput @doc(category: "Orders") { """If true, then allow proceed fulfillment when stock is exceeded.""" allowStockToBeExceeded: Boolean = false - """ - Fulfillment tracking number. - - Added in Saleor 3.6. - """ + """Fulfillment tracking number.""" trackingNumber: String } @@ -25901,7 +23644,7 @@ type FulfillmentCancel @doc(category: "Orders") { """Order which fulfillment was cancelled.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25913,9 +23656,7 @@ input FulfillmentCancelInput @doc(category: "Orders") { } """ -Approve existing fulfillment. - -Added in Saleor 3.1. +Approve existing fulfillment. Requires one of the following permissions: MANAGE_ORDERS. @@ -25928,7 +23669,7 @@ type FulfillmentApprove @doc(category: "Orders") @webhookEventsInfo(asyncEvents: """Order which fulfillment was approved.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25946,7 +23687,7 @@ type FulfillmentUpdateTracking @doc(category: "Orders") @webhookEventsInfo(async """Order for which fulfillment was updated.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -25969,7 +23710,7 @@ type FulfillmentRefundProducts @doc(category: "Orders") { """Order which fulfillment was refunded.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26022,7 +23763,7 @@ type FulfillmentReturnProducts @doc(category: "Orders") { """A draft order which was created for products with replace flag.""" replaceOrder: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26068,11 +23809,7 @@ input OrderReturnFulfillmentLineInput @doc(category: "Orders") { } """ -Adds granted refund to the order. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Adds granted refund to the order. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -26097,17 +23834,10 @@ type OrderGrantRefundCreateError @doc(category: "Orders") { """The error code.""" code: OrderGrantRefundCreateErrorCode! - """ - List of lines which cause the error. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """List of lines which cause the error.""" lines: [OrderGrantRefundCreateLineError!] } -"""An enumeration.""" enum OrderGrantRefundCreateErrorCode @doc(category: "Orders") { GRAPHQL_ERROR NOT_FOUND @@ -26133,7 +23863,6 @@ type OrderGrantRefundCreateLineError { lineId: ID! } -"""An enumeration.""" enum OrderGrantRefundCreateLineErrorCode { GRAPHQL_ERROR NOT_FOUND @@ -26149,32 +23878,20 @@ input OrderGrantRefundCreateInput @doc(category: "Orders") { """Reason of the granted refund.""" reason: String - """ - Lines to assign to granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Lines to assign to granted refund.""" lines: [OrderGrantRefundCreateLineInput!] - """ - Determine if granted refund should include shipping costs. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Determine if granted refund should include shipping costs.""" grantRefundForShipping: Boolean """ - The ID of the transaction item related to the granted refund. If `amount` provided in the input, the transaction.chargedAmount needs to be equal or greater than provided `amount`.If `amount` is not provided in the input and calculated automatically by Saleor, the `min(calculatedAmount, transaction.chargedAmount)` will be used.Field will be required starting from Saleor 3.21. + The ID of the transaction item related to the granted refund. If `amount` provided in the input, the transaction.chargedAmount needs to be equal or greater than provided `amount`.If `amount` is not provided in the input and calculated automatically by Saleor, the `min(calculatedAmount, transaction.chargedAmount)` will be used. Field required starting from Saleor 3.21. Added in Saleor 3.20. Note: this API is currently in Feature Preview and can be subject to changes at later point. """ - transactionId: ID + transactionId: ID! } input OrderGrantRefundCreateLineInput @doc(category: "Orders") { @@ -26189,11 +23906,7 @@ input OrderGrantRefundCreateLineInput @doc(category: "Orders") { } """ -Updates granted refund. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Updates granted refund. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -26218,26 +23931,13 @@ type OrderGrantRefundUpdateError @doc(category: "Orders") { """The error code.""" code: OrderGrantRefundUpdateErrorCode! - """ - List of lines to add which cause the error. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """List of lines to add which cause the error.""" addLines: [OrderGrantRefundUpdateLineError!] - """ - List of lines to remove which cause the error. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """List of lines to remove which cause the error.""" removeLines: [OrderGrantRefundUpdateLineError!] } -"""An enumeration.""" enum OrderGrantRefundUpdateErrorCode @doc(category: "Orders") { GRAPHQL_ERROR NOT_FOUND @@ -26263,7 +23963,6 @@ type OrderGrantRefundUpdateLineError { lineId: ID! } -"""An enumeration.""" enum OrderGrantRefundUpdateLineErrorCode { GRAPHQL_ERROR NOT_FOUND @@ -26279,31 +23978,13 @@ input OrderGrantRefundUpdateInput @doc(category: "Orders") { """Reason of the granted refund.""" reason: String - """ - Lines to assign to granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Lines to assign to granted refund.""" addLines: [OrderGrantRefundUpdateLineAddInput!] - """ - Lines to remove from granted refund. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Lines to remove from granted refund.""" removeLines: [ID!] - """ - Determine if granted refund should include shipping costs. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Determine if granted refund should include shipping costs.""" grantRefundForShipping: Boolean """ @@ -26338,7 +24019,7 @@ type OrderLinesCreate @doc(category: "Orders") { """List of added order lines.""" orderLines: [OrderLine!] - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26353,7 +24034,7 @@ type OrderLineDelete @doc(category: "Orders") { """An order line that was deleted.""" orderLine: OrderLine - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26365,7 +24046,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderLineUpdate @doc(category: "Orders") { """Related order.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! orderLine: OrderLine } @@ -26383,7 +24064,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderDiscountAdd @doc(category: "Orders") { """Order which has been discounted.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26406,7 +24087,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderDiscountUpdate @doc(category: "Orders") { """Order which has been discounted.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26418,7 +24099,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderDiscountDelete @doc(category: "Orders") { """Order which has removed discount.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26433,7 +24114,7 @@ type OrderLineDiscountUpdate @doc(category: "Orders") { """Order which is related to the discounted line.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26448,16 +24129,12 @@ type OrderLineDiscountRemove @doc(category: "Orders") { """Order which is related to line which has removed discount.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } """ -Adds note to the order. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Adds note to the order. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -26483,7 +24160,6 @@ type OrderNoteAddError @doc(category: "Orders") { code: OrderNoteAddErrorCode } -"""An enumeration.""" enum OrderNoteAddErrorCode @doc(category: "Orders") { GRAPHQL_ERROR REQUIRED @@ -26495,11 +24171,7 @@ input OrderNoteInput @doc(category: "Orders") { } """ -Updates note of an order. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Updates note of an order. Requires one of the following permissions: MANAGE_ORDERS. """ @@ -26525,7 +24197,6 @@ type OrderNoteUpdateError @doc(category: "Orders") { code: OrderNoteUpdateErrorCode } -"""An enumeration.""" enum OrderNoteUpdateErrorCode @doc(category: "Orders") { GRAPHQL_ERROR NOT_FOUND @@ -26540,7 +24211,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderMarkAsPaid @doc(category: "Orders") { """Order marked as paid.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26552,7 +24223,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderRefund @doc(category: "Orders") { """A refunded order.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26562,7 +24233,7 @@ Updates an order. Requires one of the following permissions: MANAGE_ORDERS. """ type OrderUpdate @doc(category: "Orders") { - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! order: Order } @@ -26577,12 +24248,33 @@ input OrderUpdateInput @doc(category: "Orders") { """Shipping address of the customer.""" shippingAddress: AddressInput + """External ID of this order.""" + externalReference: String + """ - External ID of this order. + Order public metadata. - Added in Saleor 3.10. + Added in Saleor 3.21.Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. """ - externalReference: String + metadata: [MetadataInput!] + + """ + Order private metadata. + + Added in Saleor 3.21.Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ + privateMetadata: [MetadataInput!] + + """ + Order language code. + + Added in Saleor 3.21. + """ + languageCode: LanguageCodeEnum } """ @@ -26593,7 +24285,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderUpdateShipping @doc(category: "Orders") { """Order with updated shipping method.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26612,7 +24304,7 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderVoid @doc(category: "Orders") { """A voided order.""" order: Order - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } @@ -26624,16 +24316,12 @@ Requires one of the following permissions: MANAGE_ORDERS. type OrderBulkCancel @doc(category: "Orders") { """Returns how many objects were affected.""" count: Int! - orderErrors: [OrderError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + orderErrors: [OrderError!]! @deprecated(reason: "Use `errors` field instead.") errors: [OrderError!]! } """ -Creates multiple orders. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Creates multiple orders. Requires one of the following permissions: MANAGE_ORDERS_IMPORT. """ @@ -26667,7 +24355,6 @@ type OrderBulkCreateError @doc(category: "Orders") { code: OrderBulkCreateErrorCode } -"""An enumeration.""" enum OrderBulkCreateErrorCode { GRAPHQL_ERROR REQUIRED @@ -26714,10 +24401,18 @@ input OrderBulkCreateInput @doc(category: "Orders") { """Currency code.""" currency: String! - """Metadata of the order.""" + """ + Metadata of the order. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ metadata: [MetadataInput!] - """Private metadata of the order.""" + """ + Private metadata of the order. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ privateMetadata: [MetadataInput!] """Note about customer.""" @@ -26816,6 +24511,13 @@ input OrderBulkCreateOrderLineInput @doc(category: "Orders") { """The name of the product.""" productName: String + """ + The SKU of the product. + + Added in Saleor 3.18. + """ + productSku: String + """Translation of the product variant name.""" translatedVariantName: String @@ -26840,13 +24542,42 @@ input OrderBulkCreateOrderLineInput @doc(category: "Orders") { """Price of the order line excluding applied discount.""" undiscountedTotalPrice: TaxedMoneyInput! + """ + Reason of the discount on order line. + + Added in Saleor 3.19. + """ + unitDiscountReason: String + + """ + Type of the discount: fixed or percent + + Added in Saleor 3.19. + """ + unitDiscountType: DiscountValueTypeEnum + + """ + Value of the discount. Can store fixed value or percent value + + Added in Saleor 3.19. + """ + unitDiscountValue: PositiveDecimal + """The ID of the warehouse, where the line will be allocated.""" warehouse: ID! - """Metadata of the order line.""" + """ + Metadata of the order line. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ metadata: [MetadataInput!] - """Private metadata of the order line.""" + """ + Private metadata of the order line. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ privateMetadata: [MetadataInput!] """Tax rate of the order line.""" @@ -26858,10 +24589,18 @@ input OrderBulkCreateOrderLineInput @doc(category: "Orders") { """The name of the tax class.""" taxClassName: String - """Metadata of the tax class.""" + """ + Metadata of the tax class. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ taxClassMetadata: [MetadataInput!] - """Private metadata of the tax class.""" + """ + Private metadata of the tax class. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ taxClassPrivateMetadata: [MetadataInput!] } @@ -26898,10 +24637,18 @@ input OrderBulkCreateDeliveryMethodInput @doc(category: "Orders") { """The name of the tax class.""" shippingTaxClassName: String - """Metadata of the tax class.""" + """ + Metadata of the tax class. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ shippingTaxClassMetadata: [MetadataInput!] - """Private metadata of the tax class.""" + """ + Private metadata of the tax class. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ shippingTaxClassPrivateMetadata: [MetadataInput!] } @@ -26943,10 +24690,18 @@ input OrderBulkCreateInvoiceInput @doc(category: "Orders") { """URL of the invoice to download.""" url: String - """Metadata of the invoice.""" + """ + Metadata of the invoice. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ metadata: [MetadataInput!] - """Private metadata of the invoice.""" + """ + Private metadata of the invoice. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ privateMetadata: [MetadataInput!] } @@ -26967,7 +24722,7 @@ enum StockUpdatePolicyEnum { Delete metadata of an object. To use it, you need to have access to the modified object. """ type DeleteMetadata { - metadataErrors: [MetadataError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + metadataErrors: [MetadataError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MetadataError!]! item: ObjectWithMetadata } @@ -26985,7 +24740,6 @@ type MetadataError { code: MetadataErrorCode! } -"""An enumeration.""" enum MetadataErrorCode { GRAPHQL_ERROR INVALID @@ -26998,25 +24752,29 @@ enum MetadataErrorCode { Delete object's private metadata. To use it, you need to be an authenticated staff user or an app and have access to the modified object. """ type DeletePrivateMetadata { - metadataErrors: [MetadataError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + metadataErrors: [MetadataError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MetadataError!]! item: ObjectWithMetadata } """ -Updates metadata of an object. To use it, you need to have access to the modified object. +Updates metadata of an object.Requires permissions to modify and to read the metadata of the object it's attached to. + +Warning: never store sensitive information, including financial data such as credit card details. """ type UpdateMetadata { - metadataErrors: [MetadataError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + metadataErrors: [MetadataError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MetadataError!]! item: ObjectWithMetadata } """ -Updates private metadata of an object. To use it, you need to be an authenticated staff user or an app and have access to the modified object. +Updates private metadata of an object. Requires permissions to modify and to read the metadata of the object it's attached to. + +Warning: never store sensitive information, including financial data such as credit card details. """ type UpdatePrivateMetadata { - metadataErrors: [MetadataError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + metadataErrors: [MetadataError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MetadataError!]! item: ObjectWithMetadata } @@ -27029,7 +24787,7 @@ Requires one of the following permissions: MANAGE_MENUS, MANAGE_SETTINGS. type AssignNavigation @doc(category: "Menu") { """Assigned navigation menu.""" menu: Menu - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! } @@ -27046,7 +24804,6 @@ type MenuError @doc(category: "Menu") { code: MenuErrorCode! } -"""An enumeration.""" enum MenuErrorCode { CANNOT_ASSIGN_NODE GRAPHQL_ERROR @@ -27076,7 +24833,7 @@ Triggers the following webhook events: - MENU_CREATED (async): A menu was created. """ type MenuCreate @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_CREATED], syncEvents: []) { - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! menu: Menu } @@ -27118,7 +24875,7 @@ Triggers the following webhook events: - MENU_DELETED (async): A menu was deleted. """ type MenuDelete @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_DELETED], syncEvents: []) { - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! menu: Menu } @@ -27134,7 +24891,7 @@ Triggers the following webhook events: type MenuBulkDelete @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_DELETED], syncEvents: []) { """Returns how many objects were affected.""" count: Int! - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! } @@ -27147,7 +24904,7 @@ Triggers the following webhook events: - MENU_UPDATED (async): A menu was updated. """ type MenuUpdate @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_UPDATED], syncEvents: []) { - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! menu: Menu } @@ -27169,7 +24926,7 @@ Triggers the following webhook events: - MENU_ITEM_CREATED (async): A menu item was created. """ type MenuItemCreate @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_ITEM_CREATED], syncEvents: []) { - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! menuItem: MenuItem } @@ -27206,7 +24963,7 @@ Triggers the following webhook events: - MENU_ITEM_DELETED (async): A menu item was deleted. """ type MenuItemDelete @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_ITEM_DELETED], syncEvents: []) { - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! menuItem: MenuItem } @@ -27222,7 +24979,7 @@ Triggers the following webhook events: type MenuItemBulkDelete @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_ITEM_DELETED], syncEvents: []) { """Returns how many objects were affected.""" count: Int! - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! } @@ -27235,7 +24992,7 @@ Triggers the following webhook events: - MENU_ITEM_UPDATED (async): A menu item was updated. """ type MenuItemUpdate @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_ITEM_UPDATED], syncEvents: []) { - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! menuItem: MenuItem } @@ -27246,7 +25003,7 @@ Creates/updates translations for a menu item. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type MenuItemTranslate @doc(category: "Menu") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! menuItem: MenuItem } @@ -27262,7 +25019,7 @@ Triggers the following webhook events: type MenuItemMove @doc(category: "Menu") @webhookEventsInfo(asyncEvents: [MENU_ITEM_UPDATED], syncEvents: []) { """Assigned menu to move within.""" menu: Menu - menuErrors: [MenuError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + menuErrors: [MenuError!]! @deprecated(reason: "Use `errors` field instead.") errors: [MenuError!]! } @@ -27290,7 +25047,7 @@ Triggers the following webhook events: type InvoiceRequest @doc(category: "Orders") @webhookEventsInfo(asyncEvents: [INVOICE_REQUESTED], syncEvents: []) { """Order related to an invoice.""" order: Order - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + invoiceErrors: [InvoiceError!]! @deprecated(reason: "Use `errors` field instead.") errors: [InvoiceError!]! invoice: Invoice } @@ -27308,7 +25065,6 @@ type InvoiceError @doc(category: "Orders") { code: InvoiceErrorCode! } -"""An enumeration.""" enum InvoiceErrorCode @doc(category: "Orders") { REQUIRED NOT_READY @@ -27329,7 +25085,7 @@ Triggers the following webhook events: - INVOICE_DELETED (async): An invoice was requested to delete. """ type InvoiceRequestDelete @doc(category: "Orders") @webhookEventsInfo(asyncEvents: [INVOICE_DELETED], syncEvents: []) { - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + invoiceErrors: [InvoiceError!]! @deprecated(reason: "Use `errors` field instead.") errors: [InvoiceError!]! invoice: Invoice } @@ -27340,7 +25096,7 @@ Creates a ready to send invoice. Requires one of the following permissions: MANAGE_ORDERS. """ type InvoiceCreate @doc(category: "Orders") { - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + invoiceErrors: [InvoiceError!]! @deprecated(reason: "Use `errors` field instead.") errors: [InvoiceError!]! invoice: Invoice } @@ -27353,16 +25109,16 @@ input InvoiceCreateInput @doc(category: "Orders") { url: String! """ - Fields required to update the invoice metadata. + Fields required to update the invoice metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the invoice private metadata. + Fields required to update the invoice private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] } @@ -27373,7 +25129,7 @@ Deletes an invoice. Requires one of the following permissions: MANAGE_ORDERS. """ type InvoiceDelete @doc(category: "Orders") { - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + invoiceErrors: [InvoiceError!]! @deprecated(reason: "Use `errors` field instead.") errors: [InvoiceError!]! invoice: Invoice } @@ -27384,7 +25140,7 @@ Updates an invoice. Requires one of the following permissions: MANAGE_ORDERS. """ type InvoiceUpdate @doc(category: "Orders") { - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + invoiceErrors: [InvoiceError!]! @deprecated(reason: "Use `errors` field instead.") errors: [InvoiceError!]! invoice: Invoice } @@ -27397,16 +25153,16 @@ input UpdateInvoiceInput @doc(category: "Orders") { url: String """ - Fields required to update the invoice metadata. + Fields required to update the invoice metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the invoice private metadata. + Fields required to update the invoice private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] } @@ -27421,7 +25177,7 @@ Triggers the following webhook events: - NOTIFY_USER (async): A notification for invoice send """ type InvoiceSendNotification @doc(category: "Orders") @webhookEventsInfo(asyncEvents: [INVOICE_SENT, NOTIFY_USER], syncEvents: []) { - invoiceErrors: [InvoiceError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + invoiceErrors: [InvoiceError!]! @deprecated(reason: "Use `errors` field instead.") errors: [InvoiceError!]! invoice: Invoice } @@ -27437,7 +25193,7 @@ Triggers the following webhook events: type GiftCardActivate @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_STATUS_CHANGED], syncEvents: []) { """Activated gift card.""" giftCard: GiftCard - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + giftCardErrors: [GiftCardError!]! @deprecated(reason: "Use `errors` field instead.") errors: [GiftCardError!]! } @@ -27457,7 +25213,6 @@ type GiftCardError @doc(category: "Gift cards") { tags: [String!] } -"""An enumeration.""" enum GiftCardErrorCode @doc(category: "Gift cards") { ALREADY_EXISTS GRAPHQL_ERROR @@ -27479,39 +25234,41 @@ Triggers the following webhook events: - NOTIFY_USER (async): A notification for created gift card. """ type GiftCardCreate @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_CREATED, NOTIFY_USER], syncEvents: []) { - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + giftCardErrors: [GiftCardError!]! @deprecated(reason: "Use `errors` field instead.") errors: [GiftCardError!]! giftCard: GiftCard } input GiftCardCreateInput @doc(category: "Gift cards") { - """ - The gift card tags to add. - - Added in Saleor 3.1. - """ + """The gift card tags to add.""" addTags: [String!] - """ - The gift card expiry date. - - Added in Saleor 3.1. - """ + """The gift card expiry date.""" expiryDate: Date """ - Start date of the gift card in ISO 8601 format. + Gift Card public metadata. + + Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. - DEPRECATED: this field will be removed in Saleor 4.0. + Warning: never store sensitive information, including financial data such as credit card details. """ - startDate: Date + metadata: [MetadataInput!] """ - End date of the gift card in ISO 8601 format. + Gift Card private metadata. + + Added in Saleor 3.21. Requires permissions to modify and to read the metadata of the object it's attached to. - DEPRECATED: this field will be removed in Saleor 4.0. Use `expiryDate` from `expirySettings` instead. + Warning: never store sensitive information, including financial data such as credit card details. """ - endDate: Date + privateMetadata: [MetadataInput!] + + """Start date of the gift card in ISO 8601 format.""" + startDate: Date @deprecated + + """End date of the gift card in ISO 8601 format.""" + endDate: Date @deprecated(reason: "Use `expiryDate` from `expirySettings` instead.") """Balance of the gift card.""" balance: PriceInput! @@ -27519,32 +25276,16 @@ input GiftCardCreateInput @doc(category: "Gift cards") { """Email of the customer to whom gift card will be sent.""" userEmail: String - """ - Slug of a channel from which the email should be sent. - - Added in Saleor 3.1. - """ + """Slug of a channel from which the email should be sent.""" channel: String - """ - Determine if gift card is active. - - Added in Saleor 3.1. - """ + """Determine if gift card is active.""" isActive: Boolean! - """ - Code to use the gift card. - - DEPRECATED: this field will be removed in Saleor 4.0. The code is now auto generated. - """ - code: String + """Code to use the gift card.""" + code: String @deprecated(reason: "The code is now auto generated.") - """ - The gift card note from the staff member. - - Added in Saleor 3.1. - """ + """The gift card note from the staff member.""" note: String } @@ -27557,9 +25298,7 @@ input PriceInput { } """ -Delete gift card. - -Added in Saleor 3.1. +Delete gift card. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -27567,7 +25306,7 @@ Triggers the following webhook events: - GIFT_CARD_DELETED (async): A gift card was deleted. """ type GiftCardDelete @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_DELETED], syncEvents: []) { - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + giftCardErrors: [GiftCardError!]! @deprecated(reason: "Use `errors` field instead.") errors: [GiftCardError!]! giftCard: GiftCard } @@ -27583,7 +25322,7 @@ Triggers the following webhook events: type GiftCardDeactivate @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_STATUS_CHANGED], syncEvents: []) { """Deactivated gift card.""" giftCard: GiftCard - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + giftCardErrors: [GiftCardError!]! @deprecated(reason: "Use `errors` field instead.") errors: [GiftCardError!]! } @@ -27596,59 +25335,51 @@ Triggers the following webhook events: - GIFT_CARD_UPDATED (async): A gift card was updated. """ type GiftCardUpdate @doc(category: "Gift cards") @webhookEventsInfo(asyncEvents: [GIFT_CARD_UPDATED], syncEvents: []) { - giftCardErrors: [GiftCardError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + giftCardErrors: [GiftCardError!]! @deprecated(reason: "Use `errors` field instead.") errors: [GiftCardError!]! giftCard: GiftCard } input GiftCardUpdateInput @doc(category: "Gift cards") { - """ - The gift card tags to add. - - Added in Saleor 3.1. - """ + """The gift card tags to add.""" addTags: [String!] - """ - The gift card expiry date. - - Added in Saleor 3.1. - """ + """The gift card expiry date.""" expiryDate: Date """ - Start date of the gift card in ISO 8601 format. + Gift Card public metadata. - DEPRECATED: this field will be removed in Saleor 4.0. - """ - startDate: Date - - """ - End date of the gift card in ISO 8601 format. + Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. - DEPRECATED: this field will be removed in Saleor 4.0. Use `expiryDate` from `expirySettings` instead. + Warning: never store sensitive information, including financial data such as credit card details. """ - endDate: Date + metadata: [MetadataInput!] """ - The gift card tags to remove. + Gift Card private metadata. - Added in Saleor 3.1. + Added in Saleor 3.21. Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. """ + privateMetadata: [MetadataInput!] + + """Start date of the gift card in ISO 8601 format.""" + startDate: Date @deprecated + + """End date of the gift card in ISO 8601 format.""" + endDate: Date @deprecated(reason: "Use `expiryDate` from `expirySettings` instead.") + + """The gift card tags to remove.""" removeTags: [String!] - """ - The gift card balance amount. - - Added in Saleor 3.1. - """ + """The gift card balance amount.""" balanceAmount: PositiveDecimal } """ -Resend a gift card. - -Added in Saleor 3.1. +Resend a gift card. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -27673,9 +25404,7 @@ input GiftCardResendInput @doc(category: "Gift cards") { } """ -Adds note to the gift card. - -Added in Saleor 3.1. +Adds note to the gift card. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -27697,9 +25426,7 @@ input GiftCardAddNoteInput @doc(category: "Gift cards") { } """ -Create gift cards. - -Added in Saleor 3.1. +Create gift cards. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -27734,9 +25461,7 @@ input GiftCardBulkCreateInput @doc(category: "Gift cards") { } """ -Delete gift cards. - -Added in Saleor 3.1. +Delete gift cards. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -27750,9 +25475,7 @@ type GiftCardBulkDelete @doc(category: "Gift cards") @webhookEventsInfo(asyncEve } """ -Activate gift cards. - -Added in Saleor 3.1. +Activate gift cards. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -27766,9 +25489,7 @@ type GiftCardBulkActivate @doc(category: "Gift cards") @webhookEventsInfo(asyncE } """ -Deactivate gift cards. - -Added in Saleor 3.1. +Deactivate gift cards. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -27788,7 +25509,7 @@ Requires one of the following permissions: MANAGE_PLUGINS. """ type PluginUpdate { plugin: Plugin - pluginsErrors: [PluginError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + pluginsErrors: [PluginError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PluginError!]! } @@ -27805,7 +25526,6 @@ type PluginError { code: PluginErrorCode! } -"""An enumeration.""" enum PluginErrorCode { GRAPHQL_ERROR INVALID @@ -27833,8 +25553,6 @@ input ConfigurationItemInput { """ Trigger sending a notification with the notify plugin method. Serializes nodes provided as ids parameter and includes this data in the notification payload. - -Added in Saleor 3.1. """ type ExternalNotificationTrigger { errors: [ExternalNotificationError!]! @@ -27853,7 +25571,6 @@ type ExternalNotificationError { code: ExternalNotificationErrorCodes! } -"""An enumeration.""" enum ExternalNotificationErrorCodes { REQUIRED INVALID_MODEL_TYPE @@ -27879,11 +25596,7 @@ input ExternalNotificationTriggerInput { } """ -Creates a new promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Creates a new promotion. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -27924,7 +25637,6 @@ type PromotionCreateError { giftsLimitExceedBy: Int } -"""An enumeration.""" enum PromotionCreateErrorCode { GRAPHQL_ERROR NOT_FOUND @@ -28061,11 +25773,7 @@ input DiscountedObjectWhereInput @doc(category: "Discounts") { } """ -Updates an existing promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Updates an existing promotion. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28092,7 +25800,6 @@ type PromotionUpdateError { code: PromotionUpdateErrorCode! } -"""An enumeration.""" enum PromotionUpdateErrorCode { GRAPHQL_ERROR NOT_FOUND @@ -28115,11 +25822,7 @@ input PromotionUpdateInput { } """ -Deletes a promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Deletes a promotion. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28144,18 +25847,13 @@ type PromotionDeleteError { code: PromotionDeleteErrorCode! } -"""An enumeration.""" enum PromotionDeleteErrorCode { GRAPHQL_ERROR NOT_FOUND } """ -Creates a new promotion rule. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Creates a new promotion rule. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28192,7 +25890,6 @@ type PromotionRuleCreateError { giftsLimitExceedBy: Int } -"""An enumeration.""" enum PromotionRuleCreateErrorCode { GRAPHQL_ERROR NOT_FOUND @@ -28263,11 +25960,7 @@ input PromotionRuleCreateInput { } """ -Updates an existing promotion rule. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Updates an existing promotion rule. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28301,7 +25994,6 @@ type PromotionRuleUpdateError { giftsLimitExceedBy: Int } -"""An enumeration.""" enum PromotionRuleUpdateErrorCode { GRAPHQL_ERROR NOT_FOUND @@ -28381,11 +26073,7 @@ input PromotionRuleUpdateInput { } """ -Deletes a promotion rule. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Deletes a promotion rule. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28410,16 +26098,13 @@ type PromotionRuleDeleteError { code: PromotionRuleDeleteErrorCode! } -"""An enumeration.""" enum PromotionRuleDeleteErrorCode { GRAPHQL_ERROR NOT_FOUND } """ -Creates/updates translations for a promotion. - -Added in Saleor 3.17. +Creates/updates translations for a promotion. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -28440,9 +26125,7 @@ input PromotionTranslationInput { } """ -Creates/updates translations for a promotion rule. - -Added in Saleor 3.17. +Creates/updates translations for a promotion rule. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -28463,11 +26146,7 @@ input PromotionRuleTranslationInput { } """ -Deletes promotions. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Deletes promotions. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28506,7 +26185,6 @@ type DiscountError @doc(category: "Discounts") { voucherCodes: [String!] } -"""An enumeration.""" enum DiscountErrorCode @doc(category: "Discounts") { ALREADY_EXISTS GRAPHQL_ERROR @@ -28520,9 +26198,7 @@ enum DiscountErrorCode @doc(category: "Discounts") { } """ -Creates a new sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionCreate` mutation instead. +Creates a new sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28530,7 +26206,7 @@ Triggers the following webhook events: - SALE_CREATED (async): A sale was created. """ type SaleCreate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_CREATED], syncEvents: []) { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! sale: Sale } @@ -28563,9 +26239,7 @@ input SaleInput @doc(category: "Discounts") { } """ -Deletes a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionDelete` mutation instead. +Deletes a sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28573,7 +26247,7 @@ Triggers the following webhook events: - SALE_DELETED (async): A sale was deleted. """ type SaleDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_DELETED], syncEvents: []) { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! sale: Sale } @@ -28589,14 +26263,12 @@ Triggers the following webhook events: type SaleBulkDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_DELETED], syncEvents: []) { """Returns how many objects were affected.""" count: Int! - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! } """ -Updates a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionUpdate` mutation instead. +Updates a sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28605,15 +26277,13 @@ Triggers the following webhook events: - SALE_TOGGLE (async): Optionally triggered when a sale is started or stopped. """ type SaleUpdate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED, SALE_TOGGLE], syncEvents: []) { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! sale: Sale } """ -Adds products, categories, collections to a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` mutation instead. +Adds products, categories, collections to a sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28623,7 +26293,7 @@ Triggers the following webhook events: type SaleAddCatalogues @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED], syncEvents: []) { """Sale of which catalogue IDs will be modified.""" sale: Sale - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! } @@ -28637,18 +26307,12 @@ input CatalogueInput @doc(category: "Discounts") { """Collections related to the discount.""" collections: [ID!] - """ - Product variant related to the discount. - - Added in Saleor 3.1. - """ + """Product variant related to the discount.""" variants: [ID!] } """ -Removes products, categories, collections from a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleUpdate` or `promotionRuleDelete` mutations instead. +Removes products, categories, collections from a sale. Requires one of the following permissions: MANAGE_DISCOUNTS. @@ -28658,34 +26322,30 @@ Triggers the following webhook events: type SaleRemoveCatalogues @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [SALE_UPDATED], syncEvents: []) { """Sale of which catalogue IDs will be modified.""" sale: Sale - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! } """ -Creates/updates translations for a sale. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `PromotionTranslate` mutation instead. +Creates/updates translations for a sale. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type SaleTranslate @doc(category: "Discounts") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! sale: Sale } """ -Manage sale's availability in channels. - -DEPRECATED: this mutation will be removed in Saleor 4.0. Use `promotionRuleCreate` or `promotionRuleUpdate` mutations instead. +Manage sale's availability in channels. Requires one of the following permissions: MANAGE_DISCOUNTS. """ type SaleChannelListingUpdate @doc(category: "Discounts") { """An updated sale instance.""" sale: Sale - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! } @@ -28715,7 +26375,7 @@ Triggers the following webhook events: - VOUCHER_CODES_CREATED (async): A voucher codes were created. """ type VoucherCreate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [VOUCHER_CREATED, VOUCHER_CODES_CREATED], syncEvents: []) { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! voucher: Voucher } @@ -28727,10 +26387,8 @@ input VoucherInput @doc(category: "Discounts") { """Voucher name.""" name: String - """ - Code to use the voucher. This field will be removed in Saleor 4.0. Use `addCodes` instead. - """ - code: String + """Code to use the voucher.""" + code: String @deprecated(reason: "Use `addCodes` instead.") """ List of codes to add. @@ -28753,11 +26411,7 @@ input VoucherInput @doc(category: "Discounts") { """Products discounted by the voucher.""" products: [ID!] - """ - Variants discounted by the voucher. - - Added in Saleor 3.1. - """ + """Variants discounted by the voucher.""" variants: [ID!] """Collections discounted by the voucher.""" @@ -28805,7 +26459,7 @@ Triggers the following webhook events: - VOUCHER_DELETED (async): A voucher was deleted. """ type VoucherDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [VOUCHER_DELETED], syncEvents: []) { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! voucher: Voucher } @@ -28821,7 +26475,7 @@ Triggers the following webhook events: type VoucherBulkDelete @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [VOUCHER_DELETED], syncEvents: []) { """Returns how many objects were affected.""" count: Int! - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! } @@ -28835,7 +26489,7 @@ Triggers the following webhook events: - VOUCHER_CODES_CREATED (async): A voucher code was created. """ type VoucherUpdate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [VOUCHER_UPDATED, VOUCHER_CODES_CREATED], syncEvents: []) { - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! voucher: Voucher } @@ -28851,7 +26505,7 @@ Triggers the following webhook events: type VoucherAddCatalogues @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [VOUCHER_UPDATED], syncEvents: []) { """Voucher of which catalogue IDs will be modified.""" voucher: Voucher - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! } @@ -28866,7 +26520,7 @@ Triggers the following webhook events: type VoucherRemoveCatalogues @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [VOUCHER_UPDATED], syncEvents: []) { """Voucher of which catalogue IDs will be modified.""" voucher: Voucher - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! } @@ -28876,7 +26530,7 @@ Creates/updates translations for a voucher. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type VoucherTranslate @doc(category: "Discounts") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! voucher: Voucher } @@ -28892,7 +26546,7 @@ Triggers the following webhook events: type VoucherChannelListingUpdate @doc(category: "Discounts") @webhookEventsInfo(asyncEvents: [VOUCHER_UPDATED], syncEvents: []) { """An updated voucher instance.""" voucher: Voucher - discountErrors: [DiscountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + discountErrors: [DiscountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [DiscountError!]! } @@ -28947,7 +26601,6 @@ type VoucherCodeBulkDeleteError @doc(category: "Discounts") { voucherCodes: [ID!] } -"""An enumeration.""" enum VoucherCodeBulkDeleteErrorCode @doc(category: "Discounts") { GRAPHQL_ERROR NOT_FOUND @@ -28968,7 +26621,7 @@ type ExportProducts @doc(category: "Products") @webhookEventsInfo(asyncEvents: [ The newly created export file job which is responsible for export data. """ exportFile: ExportFile - exportErrors: [ExportError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + exportErrors: [ExportError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ExportError!]! } @@ -28985,7 +26638,6 @@ type ExportError { code: ExportErrorCode! } -"""An enumeration.""" enum ExportErrorCode { GRAPHQL_ERROR INVALID @@ -29050,16 +26702,13 @@ enum ProductFieldEnum @doc(category: "Products") { VARIANT_MEDIA } -"""An enumeration.""" enum FileTypesEnum { CSV XLSX } """ -Export gift cards to csv file. - -Added in Saleor 3.1. +Export gift cards to csv file. Requires one of the following permissions: MANAGE_GIFT_CARD. @@ -29129,7 +26778,7 @@ Requires one of the following permissions: AUTHENTICATED_APP, AUTHENTICATED_STAF """ type FileUpload { uploadedFile: File - uploadErrors: [UploadError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + uploadErrors: [UploadError!]! @deprecated(reason: "Use `errors` field instead.") errors: [UploadError!]! } @@ -29146,7 +26795,6 @@ type UploadError { code: UploadErrorCode! } -"""An enumeration.""" enum UploadErrorCode { GRAPHQL_ERROR } @@ -29160,7 +26808,7 @@ Triggers the following webhook events: type CheckoutAddPromoCode @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """The checkout with the added gift card or voucher.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29186,7 +26834,6 @@ type CheckoutError @doc(category: "Checkout") { addressType: AddressTypeEnum } -"""An enumeration.""" enum CheckoutErrorCode @doc(category: "Checkout") { BILLING_ADDRESS_NOT_SET CHECKOUT_NOT_FULLY_PAID @@ -29219,6 +26866,7 @@ enum CheckoutErrorCode @doc(category: "Checkout") { NON_EDITABLE_GIFT_LINE NON_REMOVABLE_GIFT_LINE SHIPPING_CHANGE_FORBIDDEN + MISSING_ADDRESS_DATA } """ @@ -29230,7 +26878,7 @@ Triggers the following webhook events: type CheckoutBillingAddressUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29277,7 +26925,7 @@ type CheckoutComplete @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: """Confirmation data used to process additional authorization steps.""" confirmationData: JSONString - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29293,8 +26941,8 @@ type CheckoutCreate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [ """ Whether the checkout was created or the current active one was returned. Refer to checkoutLinesAdd and checkoutLinesUpdate to merge a cart with an active checkout. """ - created: Boolean @deprecated(reason: "This field will be removed in Saleor 4.0. Always returns `true`.") - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + created: Boolean @deprecated(reason: "Always returns `true`.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! checkout: Checkout } @@ -29311,11 +26959,25 @@ input CheckoutCreateInput @doc(category: "Checkout") { """The customer's email address.""" email: String + """ + Indicates whether the shipping address should be saved to the user’s address book upon checkout completion.Can only be set when a shipping address is provided. If not specified along with the address, the default behavior is to save the address. + + Added in Saleor 3.21. + """ + saveShippingAddress: Boolean + """ The mailing address to where the checkout will be shipped. Note: the address will be ignored if the checkout doesn't contain shippable items. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. """ shippingAddress: AddressInput + """ + Indicates whether the billing address should be saved to the user’s address book upon checkout completion. Can only be set when a billing address is provided. If not specified along with the address, the default behavior is to save the address. + + Added in Saleor 3.21. + """ + saveBillingAddress: Boolean + """ Billing address of the customer. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. """ @@ -29324,12 +26986,28 @@ input CheckoutCreateInput @doc(category: "Checkout") { """Checkout language code.""" languageCode: LanguageCodeEnum + """The checkout validation rules that can be changed.""" + validationRules: CheckoutValidationRules + """ - The checkout validation rules that can be changed. + Checkout public metadata. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. - Added in Saleor 3.5. + Added in Saleor 3.21. """ - validationRules: CheckoutValidationRules + metadata: [MetadataInput!] + + """ + Checkout private metadata. Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_CHECKOUTS + + Requires permissions to modify and to read the metadata of the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + + Added in Saleor 3.21. + """ + privateMetadata: [MetadataInput!] } input CheckoutLineInput @doc(category: "Checkout") { @@ -29341,22 +27019,18 @@ input CheckoutLineInput @doc(category: "Checkout") { """ Custom price of the item. Can be set only by apps with `HANDLE_CHECKOUTS` permission. When the line with the same variant will be provided multiple times, the last price will be used. - - Added in Saleor 3.1. """ price: PositiveDecimal """ - Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. - - Added in Saleor 3.6. + Flag that allow force splitting the same variant into multiple lines by skipping the matching logic. """ forceNewLine: Boolean = false """ - Fields required to update the object's metadata. + Fields required to update the object's metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.8. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] } @@ -29373,13 +27047,7 @@ input CheckoutValidationRules @doc(category: "Checkout") { billingAddress: CheckoutAddressValidationRules } -""" -Create new checkout from existing order. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Create new checkout from existing order.""" type CheckoutCreateFromOrder @doc(category: "Checkout") { """Variants that were not attached to the checkout.""" unavailableVariants: [CheckoutCreateFromOrderUnavailableVariant!] @@ -29403,7 +27071,6 @@ type CheckoutCreateFromOrderUnavailableVariant @doc(category: "Checkout") { lineId: ID! } -"""An enumeration.""" enum CheckoutCreateFromOrderUnavailableVariantErrorCode @doc(category: "Checkout") { NOT_FOUND PRODUCT_UNAVAILABLE_FOR_PURCHASE @@ -29426,7 +27093,6 @@ type CheckoutCreateFromOrderError @doc(category: "Checkout") { code: CheckoutCreateFromOrderErrorCode! } -"""An enumeration.""" enum CheckoutCreateFromOrderErrorCode @doc(category: "Checkout") { GRAPHQL_ERROR INVALID @@ -29446,7 +27112,7 @@ Triggers the following webhook events: type CheckoutCustomerAttach @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29461,7 +27127,22 @@ Triggers the following webhook events: type CheckoutCustomerDetach @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") + errors: [CheckoutError!]! +} + +""" +Updates customer note in the existing checkout object. + +Added in Saleor 3.21. + +Triggers the following webhook events: +- CHECKOUT_UPDATED (async): A checkout was updated. +""" +type CheckoutCustomerNoteUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { + """An updated checkout.""" + checkout: Checkout + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29474,7 +27155,7 @@ Triggers the following webhook events: type CheckoutEmailUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29487,7 +27168,7 @@ Triggers the following webhook events: type CheckoutLineDelete @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29512,7 +27193,7 @@ Triggers the following webhook events: type CheckoutLinesAdd @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29525,17 +27206,13 @@ Triggers the following webhook events: type CheckoutLinesUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } input CheckoutLineUpdateInput @doc(category: "Checkout") { - """ - ID of the product variant. - - DEPRECATED: this field will be removed in Saleor 4.0. Use `lineId` instead. - """ - variantId: ID + """ID of the product variant.""" + variantId: ID @deprecated(reason: "Use `lineId` instead.") """ The number of items purchased. Optional for apps, required for any other users. @@ -29544,17 +27221,20 @@ input CheckoutLineUpdateInput @doc(category: "Checkout") { """ Custom price of the item. Can be set only by apps with `HANDLE_CHECKOUTS` permission. When the line with the same variant will be provided multiple times, the last price will be used. - - Added in Saleor 3.1. """ price: PositiveDecimal + """ID of the line.""" + lineId: ID + """ - ID of the line. + Checkout line public metadata. Will add and update keys. To delete keys use deleteMetadata mutation. + + Added in Saleor 3.21. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.6. + Warning: never store sensitive information, including financial data such as credit card details. """ - lineId: ID + metadata: [MetadataInput!] } """ @@ -29566,7 +27246,7 @@ Triggers the following webhook events: type CheckoutRemovePromoCode @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """The checkout with the removed gift card or voucher.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29577,7 +27257,7 @@ type CheckoutPaymentCreate @doc(category: "Checkout") { """A newly created payment.""" payment: Payment - paymentErrors: [PaymentError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + paymentErrors: [PaymentError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PaymentError!]! } @@ -29600,17 +27280,13 @@ input PaymentInput @doc(category: "Payments") { """ returnUrl: String - """ - Payment store type. - - Added in Saleor 3.1. - """ + """Payment store type.""" storePaymentMethod: StorePaymentMethodEnum = NONE """ - User public metadata. + User public metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.1. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] } @@ -29640,7 +27316,7 @@ Triggers the following webhook events: type CheckoutShippingAddressUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } @@ -29654,15 +27330,13 @@ Triggers the following webhook events: type CheckoutShippingMethodUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: [SHIPPING_LIST_METHODS_FOR_CHECKOUT]) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } """ Updates the delivery method (shipping method or pick up point) of the checkout. Updates the checkout shipping_address for click and collect delivery for a warehouse address. -Added in Saleor 3.1. - Triggers the following webhook events: - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Triggered when updating the checkout delivery method with the external one. - CHECKOUT_UPDATED (async): A checkout was updated. @@ -29682,15 +27356,13 @@ Triggers the following webhook events: type CheckoutLanguageCodeUpdate @doc(category: "Checkout") @webhookEventsInfo(asyncEvents: [CHECKOUT_UPDATED], syncEvents: []) { """An updated checkout.""" checkout: Checkout - checkoutErrors: [CheckoutError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + checkoutErrors: [CheckoutError!]! @deprecated(reason: "Use `errors` field instead.") errors: [CheckoutError!]! } """ Create new order from existing checkout. Requires the following permissions: AUTHENTICATED_APP and HANDLE_CHECKOUTS. -Added in Saleor 3.2. - Triggers the following webhook events: - SHIPPING_LIST_METHODS_FOR_CHECKOUT (sync): Optionally triggered when cached external shipping methods are invalid. - CHECKOUT_FILTER_SHIPPING_METHODS (sync): Optionally triggered when cached filtered shipping methods are invalid. @@ -29728,7 +27400,6 @@ type OrderCreateFromCheckoutError @doc(category: "Orders") { lines: [ID!] } -"""An enumeration.""" enum OrderCreateFromCheckoutErrorCode @doc(category: "Orders") { GRAPHQL_ERROR CHECKOUT_NOT_FOUND @@ -29755,7 +27426,7 @@ Triggers the following webhook events: - CHANNEL_CREATED (async): A channel was created. """ type ChannelCreate @doc(category: "Channels") @webhookEventsInfo(asyncEvents: [CHANNEL_CREATED], syncEvents: []) { - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + channelErrors: [ChannelError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ChannelError!]! channel: Channel } @@ -29779,7 +27450,6 @@ type ChannelError @doc(category: "Channels") { warehouses: [ID!] } -"""An enumeration.""" enum ChannelErrorCode @doc(category: "Channels") { ALREADY_EXISTS GRAPHQL_ERROR @@ -29796,60 +27466,36 @@ input ChannelCreateInput @doc(category: "Channels") { """Determine if channel will be set active or not.""" isActive: Boolean - """ - The channel stock settings. - - Added in Saleor 3.7. - """ + """The channel stock settings.""" stockSettings: StockSettingsInput """List of shipping zones to assign to the channel.""" addShippingZones: [ID!] - """ - List of warehouses to assign to the channel. - - Added in Saleor 3.5. - """ + """List of warehouses to assign to the channel.""" addWarehouses: [ID!] - """ - The channel order settings - - Added in Saleor 3.12. - """ + """The channel order settings""" orderSettings: OrderSettingsInput """ - Channel public metadata. + Channel public metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.15. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Channel private metadata. + Channel private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.15. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - The channel checkout settings - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The channel checkout settings""" checkoutSettings: CheckoutSettingsInput - """ - The channel payment settings - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The channel payment settings""" paymentSettings: PaymentSettingsInput """Name of the channel.""" @@ -29863,8 +27509,6 @@ input ChannelCreateInput @doc(category: "Channels") { """ Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. - - Added in Saleor 3.1. """ defaultCountry: CountryCode! } @@ -29889,19 +27533,11 @@ input OrderSettingsInput @doc(category: "Orders") { """ Expiration time in minutes. Default null - means do not expire any orders. Enter 0 or null to disable. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ expireOrdersAfter: Minute """ The time in days after expired orders will be deleted.Allowed range is from 1 to 120. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ deleteExpiredOrdersAfter: Day @@ -29909,19 +27545,11 @@ input OrderSettingsInput @doc(category: "Orders") { Determine what strategy will be used to mark the order as paid. Based on the chosen option, the proper object will be created and attached to the order when it's manually marked as paid. `PAYMENT_FLOW` - [default option] creates the `Payment` object. `TRANSACTION_FLOW` - creates the `TransactionItem` object. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ markAsPaidStrategy: MarkAsPaidStrategyEnum """ Determine if it is possible to place unpaid order by calling `checkoutComplete` mutation. - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ allowUnpaidOrders: Boolean @@ -29935,26 +27563,44 @@ input OrderSettingsInput @doc(category: "Orders") { Note: this API is currently in Feature Preview and can be subject to changes at later point. """ includeDraftOrderInVoucherUsage: Boolean + + """ + Time in hours after which the draft order line price will be refreshed. Default value is 24 hours. Enter 0 or null to disable. + + Added in Saleor 3.21. + + Note: this API is currently in Feature Preview and can be subject to changes at later point. + """ + draftOrderLinePriceFreezePeriod: Hour + + """ + This flag only affects orders created from checkout and applies specifically to vouchers of the types: `SPECIFIC_PRODUCT` and `ENTIRE_ORDER` with `applyOncePerOrder` enabled. + - When legacy propagation is enabled, discounts from these vouchers are represented as `OrderDiscount` objects, attached to the order and returned in the `Order.discounts` field. Additionally, percentage-based vouchers are converted to fixed-value discounts. + - When legacy propagation is disabled, discounts are represented as `OrderLineDiscount` objects, attached to individual lines and returned in the `OrderLine.discounts` field. In this case, percentage-based vouchers retain their original type. + In future releases, `OrderLineDiscount` will become the default behavior, and this flag will be deprecated and removed. + + Added in Saleor 3.21. + """ + useLegacyLineDiscountPropagation: Boolean } input CheckoutSettingsInput @doc(category: "Checkout") { """ - Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. - - Added in Saleor 3.15. + Default `true`. Determines if the checkout mutations should use legacy error flow. In legacy flow, all mutations can raise an exception unrelated to the requested action - (e.g. out-of-stock exception when updating checkoutShippingAddress.) If `false`, the errors will be aggregated in `checkout.problems` field. Some of the `problems` can block the finalizing checkout process. The legacy flow will be removed in Saleor 4.0. The flow with `checkout.problems` will be the default one. + """ + useLegacyErrorFlow: Boolean @deprecated + + """ + Default `false`. Determines if the paid checkouts should be automatically completed. This setting applies only to checkouts where payment was processed through transactions.When enabled, the checkout will be automatically completed once the checkout `charge_status` reaches `FULL`. This occurs when the total sum of charged and authorized transaction amounts equals or exceeds the checkout's total amount. - DEPRECATED: this field will be removed in Saleor 4.0. + Added in Saleor 3.20. """ - useLegacyErrorFlow: Boolean + automaticallyCompleteFullyPaidCheckouts: Boolean } input PaymentSettingsInput @doc(category: "Payments") { """ Determine the transaction flow strategy to be used. Include the selected option in the payload sent to the payment app, as a requested action for the transaction. - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ defaultTransactionFlowStrategy: TransactionFlowStrategyEnum } @@ -29972,7 +27618,7 @@ Triggers the following webhook events: - CHANNEL_METADATA_UPDATED (async): Optionally triggered when public or private metadata is updated. """ type ChannelUpdate @doc(category: "Channels") @webhookEventsInfo(asyncEvents: [CHANNEL_UPDATED, CHANNEL_METADATA_UPDATED], syncEvents: []) { - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + channelErrors: [ChannelError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ChannelError!]! channel: Channel } @@ -29981,60 +27627,36 @@ input ChannelUpdateInput @doc(category: "Channels") { """Determine if channel will be set active or not.""" isActive: Boolean - """ - The channel stock settings. - - Added in Saleor 3.7. - """ + """The channel stock settings.""" stockSettings: StockSettingsInput """List of shipping zones to assign to the channel.""" addShippingZones: [ID!] - """ - List of warehouses to assign to the channel. - - Added in Saleor 3.5. - """ + """List of warehouses to assign to the channel.""" addWarehouses: [ID!] - """ - The channel order settings - - Added in Saleor 3.12. - """ + """The channel order settings""" orderSettings: OrderSettingsInput """ - Channel public metadata. + Channel public metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.15. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Channel private metadata. + Channel private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.15. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] - """ - The channel checkout settings - - Added in Saleor 3.15. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The channel checkout settings""" checkoutSettings: CheckoutSettingsInput - """ - The channel payment settings - - Added in Saleor 3.16. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The channel payment settings""" paymentSettings: PaymentSettingsInput """Name of the channel.""" @@ -30045,19 +27667,13 @@ input ChannelUpdateInput @doc(category: "Channels") { """ Default country for the channel. Default country can be used in checkout to determine the stock quantities or calculate taxes when the country was not explicitly provided. - - Added in Saleor 3.1. """ defaultCountry: CountryCode """List of shipping zones to unassign from the channel.""" removeShippingZones: [ID!] - """ - List of warehouses to unassign from the channel. - - Added in Saleor 3.5. - """ + """List of warehouses to unassign from the channel.""" removeWarehouses: [ID!] } @@ -30070,13 +27686,15 @@ Triggers the following webhook events: - CHANNEL_DELETED (async): A channel was deleted. """ type ChannelDelete @doc(category: "Channels") @webhookEventsInfo(asyncEvents: [CHANNEL_DELETED], syncEvents: []) { - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + channelErrors: [ChannelError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ChannelError!]! channel: Channel } input ChannelDeleteInput @doc(category: "Channels") { - """ID of channel to migrate orders from origin channel.""" + """ + ID of a channel to migrate orders from the origin channel. Target channel has to have the same currency as the origin. + """ channelId: ID! } @@ -30091,7 +27709,7 @@ Triggers the following webhook events: type ChannelActivate @doc(category: "Channels") @webhookEventsInfo(asyncEvents: [CHANNEL_STATUS_CHANGED], syncEvents: []) { """Activated channel.""" channel: Channel - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + channelErrors: [ChannelError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ChannelError!]! } @@ -30106,14 +27724,12 @@ Triggers the following webhook events: type ChannelDeactivate @doc(category: "Channels") @webhookEventsInfo(asyncEvents: [CHANNEL_STATUS_CHANGED], syncEvents: []) { """Deactivated channel.""" channel: Channel - channelErrors: [ChannelError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + channelErrors: [ChannelError!]! @deprecated(reason: "Use `errors` field instead.") errors: [ChannelError!]! } """ -Reorder the warehouses of a channel. - -Added in Saleor 3.7. +Reorder the warehouses of a channel. Requires one of the following permissions: MANAGE_CHANNELS. """ @@ -30131,7 +27747,7 @@ Triggers the following webhook events: """ type AttributeCreate @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_CREATED], syncEvents: []) { attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! } @@ -30148,7 +27764,6 @@ type AttributeError @doc(category: "Attributes") { code: AttributeErrorCode! } -"""An enumeration.""" enum AttributeErrorCode @doc(category: "Attributes") { ALREADY_EXISTS GRAPHQL_ERROR @@ -30194,35 +27809,21 @@ input AttributeCreateInput @doc(category: "Attributes") { """Whether the attribute should be visible or not in storefront.""" visibleInStorefront: Boolean - """ - Whether the attribute can be filtered in storefront. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - filterableInStorefront: Boolean + """Whether the attribute can be filtered in storefront.""" + filterableInStorefront: Boolean @deprecated """Whether the attribute can be filtered in dashboard.""" filterableInDashboard: Boolean """ The position of the attribute in the storefront navigation (0 by default). - - DEPRECATED: this field will be removed in Saleor 4.0. """ - storefrontSearchPosition: Int + storefrontSearchPosition: Int @deprecated - """ - Whether the attribute can be displayed in the admin product list. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - availableInGrid: Boolean + """Whether the attribute can be displayed in the admin product list.""" + availableInGrid: Boolean @deprecated - """ - External ID of this attribute. - - Added in Saleor 3.10. - """ + """External ID of this attribute.""" externalReference: String } @@ -30236,17 +27837,13 @@ input AttributeValueCreateInput @doc(category: "Attributes") { Represents the text of the attribute value, includes formatting. Rich text format. For reference see https://editorjs.io/ - - DEPRECATED: this field will be removed in Saleor 4.0.The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. """ - richText: JSONString + richText: JSONString @deprecated(reason: "The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute.") """ Represents the text of the attribute value, plain text without formatting. - - DEPRECATED: this field will be removed in Saleor 4.0.The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. """ - plainText: String + plainText: String @deprecated(reason: "The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute.") """URL of the file attribute. Every time, a new value is created.""" fileUrl: String @@ -30254,11 +27851,7 @@ input AttributeValueCreateInput @doc(category: "Attributes") { """File content type.""" contentType: String - """ - External ID of this attribute value. - - Added in Saleor 3.10. - """ + """External ID of this attribute value.""" externalReference: String """Name of a value displayed in the interface.""" @@ -30274,7 +27867,7 @@ Triggers the following webhook events: - ATTRIBUTE_DELETED (async): An attribute was deleted. """ type AttributeDelete @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_DELETED], syncEvents: []) { - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! attribute: Attribute } @@ -30289,7 +27882,7 @@ Triggers the following webhook events: """ type AttributeUpdate @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_UPDATED], syncEvents: []) { attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! } @@ -30323,35 +27916,21 @@ input AttributeUpdateInput @doc(category: "Attributes") { """Whether the attribute should be visible or not in storefront.""" visibleInStorefront: Boolean - """ - Whether the attribute can be filtered in storefront. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - filterableInStorefront: Boolean + """Whether the attribute can be filtered in storefront.""" + filterableInStorefront: Boolean @deprecated """Whether the attribute can be filtered in dashboard.""" filterableInDashboard: Boolean """ The position of the attribute in the storefront navigation (0 by default). - - DEPRECATED: this field will be removed in Saleor 4.0. """ - storefrontSearchPosition: Int + storefrontSearchPosition: Int @deprecated - """ - Whether the attribute can be displayed in the admin product list. - - DEPRECATED: this field will be removed in Saleor 4.0. - """ - availableInGrid: Boolean + """Whether the attribute can be displayed in the admin product list.""" + availableInGrid: Boolean @deprecated - """ - External ID of this product. - - Added in Saleor 3.10. - """ + """External ID of this product.""" externalReference: String } @@ -30365,17 +27944,13 @@ input AttributeValueUpdateInput @doc(category: "Attributes") { Represents the text of the attribute value, includes formatting. Rich text format. For reference see https://editorjs.io/ - - DEPRECATED: this field will be removed in Saleor 4.0.The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. """ - richText: JSONString + richText: JSONString @deprecated(reason: "The rich text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute.") """ Represents the text of the attribute value, plain text without formatting. - - DEPRECATED: this field will be removed in Saleor 4.0.The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute. """ - plainText: String + plainText: String @deprecated(reason: "The plain text attribute hasn't got predefined value, so can be specified only from instance that supports the given attribute.") """URL of the file attribute. Every time, a new value is created.""" fileUrl: String @@ -30383,11 +27958,7 @@ input AttributeValueUpdateInput @doc(category: "Attributes") { """File content type.""" contentType: String - """ - External ID of this attribute value. - - Added in Saleor 3.10. - """ + """External ID of this attribute value.""" externalReference: String """Name of a value displayed in the interface.""" @@ -30397,10 +27968,6 @@ input AttributeValueUpdateInput @doc(category: "Attributes") { """ Creates attributes. -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - Triggers the following webhook events: - ATTRIBUTE_CREATED (async): An attribute was created. """ @@ -30434,7 +28001,6 @@ type AttributeBulkCreateError @doc(category: "Attributes") { code: AttributeBulkCreateErrorCode! } -"""An enumeration.""" enum AttributeBulkCreateErrorCode @doc(category: "Attributes") { ALREADY_EXISTS BLANK @@ -30450,10 +28016,6 @@ enum AttributeBulkCreateErrorCode @doc(category: "Attributes") { """ Updates attributes. -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. - Triggers the following webhook events: - ATTRIBUTE_UPDATED (async): An attribute was updated. Optionally called when new attribute value was created or deleted. - ATTRIBUTE_VALUE_CREATED (async): Called optionally when an attribute value was created. @@ -30489,7 +28051,6 @@ type AttributeBulkUpdateError @doc(category: "Attributes") { code: AttributeBulkUpdateErrorCode! } -"""An enumeration.""" enum AttributeBulkUpdateErrorCode { ALREADY_EXISTS BLANK @@ -30519,17 +28080,13 @@ Creates/updates translations for an attribute. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type AttributeTranslate @doc(category: "Attributes") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! attribute: Attribute } """ -Creates/updates translations for attributes. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Creates/updates translations for attributes. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -30563,7 +28120,6 @@ type AttributeBulkTranslateError { code: AttributeTranslateErrorCode! } -"""An enumeration.""" enum AttributeTranslateErrorCode @doc(category: "Attributes") { GRAPHQL_ERROR INVALID @@ -30596,7 +28152,7 @@ Triggers the following webhook events: type AttributeBulkDelete @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_DELETED], syncEvents: []) { """Returns how many objects were affected.""" count: Int! - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! } @@ -30612,7 +28168,7 @@ Triggers the following webhook events: type AttributeValueBulkDelete @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_VALUE_DELETED, ATTRIBUTE_UPDATED], syncEvents: []) { """Returns how many objects were affected.""" count: Int! - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! } @@ -30628,7 +28184,7 @@ Triggers the following webhook events: type AttributeValueCreate @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_VALUE_CREATED, ATTRIBUTE_UPDATED], syncEvents: []) { """The updated attribute.""" attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! attributeValue: AttributeValue } @@ -30645,7 +28201,7 @@ Triggers the following webhook events: type AttributeValueDelete @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_VALUE_DELETED, ATTRIBUTE_UPDATED], syncEvents: []) { """The updated attribute.""" attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! attributeValue: AttributeValue } @@ -30662,17 +28218,13 @@ Triggers the following webhook events: type AttributeValueUpdate @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_VALUE_UPDATED, ATTRIBUTE_UPDATED], syncEvents: []) { """The updated attribute.""" attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! attributeValue: AttributeValue } """ -Creates/updates translations for attributes values. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Creates/updates translations for attributes values. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ @@ -30706,7 +28258,6 @@ type AttributeValueBulkTranslateError { code: AttributeValueTranslateErrorCode! } -"""An enumeration.""" enum AttributeValueTranslateErrorCode @doc(category: "Attributes") { GRAPHQL_ERROR INVALID @@ -30748,7 +28299,7 @@ Creates/updates translations for an attribute value. Requires one of the following permissions: MANAGE_TRANSLATIONS. """ type AttributeValueTranslate @doc(category: "Attributes") { - translationErrors: [TranslationError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + translationErrors: [TranslationError!]! @deprecated(reason: "Use `errors` field instead.") errors: [TranslationError!]! attributeValue: AttributeValue } @@ -30765,7 +28316,7 @@ Triggers the following webhook events: type AttributeReorderValues @doc(category: "Attributes") @webhookEventsInfo(asyncEvents: [ATTRIBUTE_VALUE_UPDATED, ATTRIBUTE_UPDATED], syncEvents: []) { """Attribute from which values are reordered.""" attribute: Attribute - attributeErrors: [AttributeError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + attributeErrors: [AttributeError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AttributeError!]! } @@ -30778,7 +28329,7 @@ Triggers the following webhook events: type AppCreate @doc(category: "Apps") @webhookEventsInfo(asyncEvents: [APP_INSTALLED], syncEvents: []) { """The newly created authentication token.""" authToken: String - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! app: App } @@ -30799,7 +28350,6 @@ type AppError @doc(category: "Apps") { permissions: [PermissionEnum!] } -"""An enumeration.""" enum AppErrorCode @doc(category: "Apps") { FORBIDDEN GRAPHQL_ERROR @@ -30842,7 +28392,7 @@ Triggers the following webhook events: - APP_UPDATED (async): An app was updated. """ type AppUpdate @doc(category: "Apps") @webhookEventsInfo(asyncEvents: [APP_UPDATED], syncEvents: []) { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! app: App } @@ -30856,7 +28406,7 @@ Triggers the following webhook events: - APP_DELETED (async): An app was deleted. """ type AppDelete @doc(category: "Apps") @webhookEventsInfo(asyncEvents: [APP_DELETED], syncEvents: []) { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! app: App } @@ -30869,7 +28419,7 @@ Requires one of the following permissions: MANAGE_APPS. type AppTokenCreate @doc(category: "Apps") { """The newly created authentication token.""" authToken: String - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! appToken: AppToken } @@ -30888,7 +28438,7 @@ Deletes an authentication token assigned to app. Requires one of the following permissions: MANAGE_APPS. """ type AppTokenDelete @doc(category: "Apps") { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! appToken: AppToken } @@ -30897,7 +28447,7 @@ type AppTokenDelete @doc(category: "Apps") { type AppTokenVerify @doc(category: "Apps") { """Determine if token is valid or not.""" valid: Boolean! - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! } @@ -30905,7 +28455,7 @@ type AppTokenVerify @doc(category: "Apps") { Install new app by using app manifest. Requires the following permissions: AUTHENTICATED_STAFF_USER and MANAGE_APPS. """ type AppInstall @doc(category: "Apps") { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! appInstallation: AppInstallation } @@ -30933,7 +28483,7 @@ Triggers the following webhook events: - APP_INSTALLED (async): An app was installed. """ type AppRetryInstall @doc(category: "Apps") @webhookEventsInfo(asyncEvents: [APP_INSTALLED], syncEvents: []) { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! appInstallation: AppInstallation } @@ -30944,7 +28494,7 @@ Delete failed installation. Requires one of the following permissions: MANAGE_APPS. """ type AppDeleteFailedInstallation @doc(category: "Apps") { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! appInstallation: AppInstallation } @@ -30957,7 +28507,7 @@ Requires one of the following permissions: MANAGE_APPS. type AppFetchManifest @doc(category: "Apps") { """The validated manifest.""" manifest: Manifest - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! } @@ -30982,15 +28532,15 @@ type Manifest @doc(category: "Apps") { appUrl: String """URL to iframe with the configuration for the app.""" - configurationUrl: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `appUrl` instead.") + configurationUrl: String @deprecated(reason: "Use `appUrl` instead.") """ - Endpoint used during process of app installation, [see installing an app.](https://docs.saleor.io/docs/3.x/developer/extending/apps/installing-apps#installing-an-app) + Endpoint used during process of app installation, [see installing an app.](https://docs.saleor.io/developer/extending/apps/installing-apps#installing-an-app) """ tokenTargetUrl: String """Description of the data privacy defined for this app.""" - dataPrivacy: String @deprecated(reason: "This field will be removed in Saleor 4.0. Use `dataPrivacyUrl` instead.") + dataPrivacy: String @deprecated(reason: "Use `dataPrivacyUrl` instead.") """URL to the full privacy policy.""" dataPrivacyUrl: String @@ -31002,49 +28552,23 @@ type Manifest @doc(category: "Apps") { supportUrl: String """ - List of extensions that will be mounted in Saleor's dashboard. For details, please [see the extension section.](https://docs.saleor.io/docs/3.x/developer/extending/apps/extending-dashboard-with-apps#key-concepts) + List of extensions that will be mounted in Saleor's dashboard. For details, please [see the extension section.](https://docs.saleor.io/developer/extending/apps/extending-dashboard-with-apps#key-concepts) """ extensions: [AppManifestExtension!]! - """ - List of the app's webhooks. - - Added in Saleor 3.5. - """ + """List of the app's webhooks.""" webhooks: [AppManifestWebhook!]! - """ - The audience that will be included in all JWT tokens for the app. - - Added in Saleor 3.8. - """ + """The audience that will be included in all JWT tokens for the app.""" audience: String - """ - Determines the app's required Saleor version as semver range. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Determines the app's required Saleor version as semver range.""" requiredSaleorVersion: AppManifestRequiredSaleorVersion - """ - The App's author name. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """The App's author name.""" author: String - """ - App's brand data. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """App's brand data.""" brand: AppManifestBrand } @@ -31083,58 +28607,22 @@ type AppManifestWebhook @doc(category: "Apps") { } type AppManifestRequiredSaleorVersion @doc(category: "Apps") { - """ - Required Saleor version as semver range. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Required Saleor version as semver range.""" constraint: String! - """ - Informs if the Saleor version matches the required one. - - Added in Saleor 3.13. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Informs if the Saleor version matches the required one.""" satisfied: Boolean! } -""" -Represents the app's manifest brand data. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents the app's manifest brand data.""" type AppManifestBrand @doc(category: "Apps") { - """ - App's logos details. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """App's logos details.""" logo: AppManifestBrandLogo! } -""" -Represents the app's manifest brand data. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Represents the app's manifest brand data.""" type AppManifestBrandLogo @doc(category: "Apps") { - """ - Data URL with a base64 encoded logo image. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Data URL with a base64 encoded logo image.""" default( """ Desired longest side the image in pixels. Defaults to 4096. Images are never cropped. Pass 0 to retrieve the original size (not recommended). @@ -31143,10 +28631,6 @@ type AppManifestBrandLogo @doc(category: "Apps") { """ The format of the image. When not provided, format of the original image will be used. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ format: IconThumbnailFormatEnum = ORIGINAL ): String! @@ -31161,7 +28645,7 @@ Triggers the following webhook events: - APP_STATUS_CHANGED (async): An app was activated. """ type AppActivate @doc(category: "Apps") @webhookEventsInfo(asyncEvents: [APP_STATUS_CHANGED], syncEvents: []) { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! app: App } @@ -31175,11 +28659,25 @@ Triggers the following webhook events: - APP_STATUS_CHANGED (async): An app was deactivated. """ type AppDeactivate @doc(category: "Apps") @webhookEventsInfo(asyncEvents: [APP_STATUS_CHANGED], syncEvents: []) { - appErrors: [AppError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AppError!]! app: App } +""" +Re-enable sync webhooks for provided app. Can be used to manually re-enable sync webhooks for the app before the cooldown period ends. + +Added in Saleor 3.21. + +Requires one of the following permissions: MANAGE_APPS. +""" +type AppReenableSyncWebhooks @doc(category: "Apps") { + """App for which sync webhooks were re-enabled.""" + app: App + appErrors: [AppError!]! @deprecated(reason: "Use `errors` field instead.") + errors: [AppError!]! +} + """Create JWT token.""" type CreateToken @doc(category: "Authentication") { """JWT token, required to authenticate.""" @@ -31193,7 +28691,7 @@ type CreateToken @doc(category: "Authentication") { """A user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31214,7 +28712,6 @@ type AccountError @doc(category: "Users") { addressType: AddressTypeEnum } -"""An enumeration.""" enum AccountErrorCode @doc(category: "Users") { ACTIVATE_OWN_ACCOUNT ACTIVATE_SUPERUSER_ACCOUNT @@ -31263,7 +28760,7 @@ type RefreshToken @doc(category: "Authentication") { """A user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31277,7 +28774,7 @@ type VerifyToken @doc(category: "Authentication") { """JWT payload.""" payload: GenericScalar - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31294,7 +28791,7 @@ Deactivate all JWT tokens of the currently authenticated user. Requires one of the following permissions: AUTHENTICATED_USER. """ type DeactivateAllUserTokens @doc(category: "Authentication") { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31302,7 +28799,7 @@ type DeactivateAllUserTokens @doc(category: "Authentication") { type ExternalAuthenticationUrl @doc(category: "Authentication") { """The data returned by authentication plugin.""" authenticationData: JSONString - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31319,7 +28816,7 @@ type ExternalObtainAccessTokens @doc(category: "Authentication") { """A user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31336,7 +28833,7 @@ type ExternalRefresh @doc(category: "Authentication") { """A user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31344,7 +28841,7 @@ type ExternalRefresh @doc(category: "Authentication") { type ExternalLogout @doc(category: "Authentication") { """The data returned by authentication plugin.""" logoutData: JSONString - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31358,7 +28855,7 @@ type ExternalVerify @doc(category: "Authentication") { """External data.""" verifyData: JSONString - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31371,16 +28868,12 @@ Triggers the following webhook events: - STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. """ type RequestPasswordReset @doc(category: "Users") @webhookEventsInfo(asyncEvents: [NOTIFY_USER, ACCOUNT_SET_PASSWORD_REQUESTED, STAFF_SET_PASSWORD_REQUESTED], syncEvents: []) { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } """ -Sends a notification confirmation. - -Added in Saleor 3.15. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Sends a notification confirmation. Requires one of the following permissions: AUTHENTICATED_USER. @@ -31405,7 +28898,6 @@ type SendConfirmationEmailError @doc(category: "Users") { code: SendConfirmationEmailErrorCode! } -"""An enumeration.""" enum SendConfirmationEmailErrorCode @doc(category: "Users") { INVALID ACCOUNT_CONFIRMED @@ -31422,7 +28914,7 @@ Triggers the following webhook events: type ConfirmAccount @doc(category: "Users") @webhookEventsInfo(asyncEvents: [ACCOUNT_CONFIRMED], syncEvents: []) { """An activated user account.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31441,7 +28933,7 @@ type SetPassword @doc(category: "Users") { """A user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31453,7 +28945,7 @@ Requires one of the following permissions: AUTHENTICATED_USER. type PasswordChange @doc(category: "Users") { """A user instance with a new password.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31469,7 +28961,7 @@ Triggers the following webhook events: type RequestEmailChange @doc(category: "Users") @webhookEventsInfo(asyncEvents: [NOTIFY_USER, ACCOUNT_CHANGE_EMAIL_REQUESTED], syncEvents: []) { """A user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31486,7 +28978,7 @@ Triggers the following webhook events: type ConfirmEmailChange @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_UPDATED, NOTIFY_USER, ACCOUNT_EMAIL_CHANGED], syncEvents: []) { """A user instance with a new email.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31502,7 +28994,7 @@ Triggers the following webhook events: type AccountAddressCreate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_UPDATED, ADDRESS_CREATED], syncEvents: []) { """A user instance for which the address was created.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! address: Address } @@ -31516,7 +29008,7 @@ Triggers the following webhook events: type AccountAddressUpdate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [ADDRESS_UPDATED], syncEvents: []) { """A user object for which the address was edited.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! address: Address } @@ -31530,7 +29022,7 @@ Triggers the following webhook events: type AccountAddressDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [ADDRESS_DELETED], syncEvents: []) { """A user instance for which the address was deleted.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! address: Address } @@ -31546,7 +29038,7 @@ Triggers the following webhook events: type AccountSetDefaultAddress @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_UPDATED], syncEvents: []) { """An updated user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31561,7 +29053,7 @@ Triggers the following webhook events: type AccountRegister @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_CREATED, NOTIFY_USER, ACCOUNT_CONFIRMATION_REQUESTED], syncEvents: []) { """Informs whether users need to confirm their email address.""" requiresConfirmation: Boolean - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! user: User } @@ -31588,7 +29080,11 @@ input AccountRegisterInput @doc(category: "Users") { """ redirectUrl: String - """User public metadata.""" + """ + User public metadata. Can be read by any API client authorized to read the object it's attached to. + + Warning: never store sensitive information, including financial data such as credit card details. + """ metadata: [MetadataInput!] """ @@ -31607,7 +29103,7 @@ Triggers the following webhook events: - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. """ type AccountUpdate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_UPDATED, CUSTOMER_METADATA_UPDATED], syncEvents: []) { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! user: User } @@ -31630,9 +29126,9 @@ input AccountInput @doc(category: "Users") { defaultShippingAddress: AddressInput """ - Fields required to update the user metadata. + Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] } @@ -31647,7 +29143,7 @@ Triggers the following webhook events: - ACCOUNT_DELETE_REQUESTED (async): An account delete requested. """ type AccountRequestDeletion @doc(category: "Users") @webhookEventsInfo(asyncEvents: [NOTIFY_USER, ACCOUNT_DELETE_REQUESTED], syncEvents: []) { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31660,7 +29156,7 @@ Triggers the following webhook events: - ACCOUNT_DELETED (async): Account was deleted. """ type AccountDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [ACCOUNT_DELETED], syncEvents: []) { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! user: User } @@ -31676,7 +29172,7 @@ Triggers the following webhook events: type AddressCreate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [ADDRESS_CREATED], syncEvents: []) { """A user instance for which the address was created.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! address: Address } @@ -31692,7 +29188,7 @@ Triggers the following webhook events: type AddressUpdate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [ADDRESS_UPDATED], syncEvents: []) { """A user object for which the address was edited.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! address: Address } @@ -31708,7 +29204,7 @@ Triggers the following webhook events: type AddressDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [ADDRESS_DELETED], syncEvents: []) { """A user instance for which the address was deleted.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! address: Address } @@ -31724,7 +29220,7 @@ Triggers the following webhook events: type AddressSetDefault @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_UPDATED], syncEvents: []) { """An updated user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -31740,7 +29236,7 @@ Triggers the following webhook events: - ACCOUNT_SET_PASSWORD_REQUESTED (async): Setting a new password for the account is requested. """ type CustomerCreate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_CREATED, CUSTOMER_METADATA_UPDATED, NOTIFY_USER, ACCOUNT_SET_PASSWORD_REQUESTED], syncEvents: []) { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! user: User } @@ -31768,39 +29264,27 @@ input UserCreateInput @doc(category: "Users") { note: String """ - Fields required to update the user metadata. + Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the user private metadata. + Fields required to update the user private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] """User language code.""" languageCode: LanguageCodeEnum - """ - External ID of the customer. - - Added in Saleor 3.10. - """ + """External ID of the customer.""" externalReference: String - """ - User account is confirmed. - - Added in Saleor 3.15. - - DEPRECATED: this field will be removed in Saleor 4.0. - - The user will be always set as unconfirmed. The confirmation will take place when the user sets the password. - """ - isConfirmed: Boolean + """User account is confirmed.""" + isConfirmed: Boolean @deprecated(reason: "The user will be always set as unconfirmed. The confirmation will take place when the user sets the password.") """ URL of a view where users should be redirected to set the password. URL in RFC 1808 format. @@ -31823,7 +29307,7 @@ Triggers the following webhook events: - CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated. """ type CustomerUpdate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_UPDATED, CUSTOMER_METADATA_UPDATED], syncEvents: []) { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! user: User } @@ -31851,34 +29335,26 @@ input CustomerInput @doc(category: "Users") { note: String """ - Fields required to update the user metadata. + Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the user private metadata. + Fields required to update the user private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] """User language code.""" languageCode: LanguageCodeEnum - """ - External ID of the customer. - - Added in Saleor 3.10. - """ + """External ID of the customer.""" externalReference: String - """ - User account is confirmed. - - Added in Saleor 3.15. - """ + """User account is confirmed.""" isConfirmed: Boolean } @@ -31891,7 +29367,7 @@ Triggers the following webhook events: - CUSTOMER_DELETED (async): A customer account was deleted. """ type CustomerDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_DELETED], syncEvents: []) { - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! user: User } @@ -31907,16 +29383,12 @@ Triggers the following webhook events: type CustomerBulkDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [CUSTOMER_DELETED], syncEvents: []) { """Returns how many objects were affected.""" count: Int! - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } """ -Updates customers. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Updates customers. Requires one of the following permissions: MANAGE_USERS. @@ -31954,7 +29426,6 @@ type CustomerBulkUpdateError @doc(category: "Users") { code: CustomerBulkUpdateErrorCode! } -"""An enumeration.""" enum CustomerBulkUpdateErrorCode @doc(category: "Users") { BLANK DUPLICATED_INPUT_ITEM @@ -31988,7 +29459,7 @@ Triggers the following webhook events: - STAFF_SET_PASSWORD_REQUESTED (async): Setting a new password for the staff account is requested. """ type StaffCreate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [STAFF_CREATED, NOTIFY_USER, STAFF_SET_PASSWORD_REQUESTED], syncEvents: []) { - staffErrors: [StaffError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + staffErrors: [StaffError!]! @deprecated(reason: "Use `errors` field instead.") errors: [StaffError!]! user: User } @@ -32036,16 +29507,16 @@ input StaffCreateInput @doc(category: "Users") { note: String """ - Fields required to update the user metadata. + Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the user private metadata. + Fields required to update the user private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] @@ -32067,7 +29538,7 @@ Triggers the following webhook events: - STAFF_UPDATED (async): A staff account was updated. """ type StaffUpdate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [STAFF_UPDATED], syncEvents: []) { - staffErrors: [StaffError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + staffErrors: [StaffError!]! @deprecated(reason: "Use `errors` field instead.") errors: [StaffError!]! user: User } @@ -32090,16 +29561,16 @@ input StaffUpdateInput @doc(category: "Users") { note: String """ - Fields required to update the user metadata. + Fields required to update the user metadata. Can be read by any API client authorized to read the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ metadata: [MetadataInput!] """ - Fields required to update the user private metadata. + Fields required to update the user private metadata. Requires permissions to modify and to read the metadata of the object it's attached to. - Added in Saleor 3.14. + Warning: never store sensitive information, including financial data such as credit card details. """ privateMetadata: [MetadataInput!] @@ -32119,7 +29590,7 @@ Triggers the following webhook events: - STAFF_DELETED (async): A staff account was deleted. """ type StaffDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [STAFF_DELETED], syncEvents: []) { - staffErrors: [StaffError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + staffErrors: [StaffError!]! @deprecated(reason: "Use `errors` field instead.") errors: [StaffError!]! user: User } @@ -32135,7 +29606,7 @@ Triggers the following webhook events: type StaffBulkDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [STAFF_DELETED], syncEvents: []) { """Returns how many objects were affected.""" count: Int! - staffErrors: [StaffError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + staffErrors: [StaffError!]! @deprecated(reason: "Use `errors` field instead.") errors: [StaffError!]! } @@ -32147,7 +29618,7 @@ Requires one of the following permissions: AUTHENTICATED_STAFF_USER. type UserAvatarUpdate @doc(category: "Users") { """An updated user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -32159,7 +29630,7 @@ Requires one of the following permissions: AUTHENTICATED_STAFF_USER. type UserAvatarDelete @doc(category: "Users") { """An updated user instance.""" user: User - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -32171,7 +29642,7 @@ Requires one of the following permissions: MANAGE_USERS. type UserBulkSetActive @doc(category: "Users") { """Returns how many objects were affected.""" count: Int! - accountErrors: [AccountError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + accountErrors: [AccountError!]! @deprecated(reason: "Use `errors` field instead.") errors: [AccountError!]! } @@ -32184,7 +29655,7 @@ Triggers the following webhook events: - PERMISSION_GROUP_CREATED (async) """ type PermissionGroupCreate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [PERMISSION_GROUP_CREATED], syncEvents: []) { - permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PermissionGroupError!]! group: Group } @@ -32211,7 +29682,6 @@ type PermissionGroupError @doc(category: "Users") { channels: [ID!] } -"""An enumeration.""" enum PermissionGroupErrorCode @doc(category: "Users") { REQUIRED UNIQUE @@ -32231,13 +29701,7 @@ input PermissionGroupCreateInput @doc(category: "Users") { """List of users to assign to this group.""" addUsers: [ID!] - """ - List of channels to assign to this group. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """List of channels to assign to this group.""" addChannels: [ID!] """Group name.""" @@ -32245,10 +29709,6 @@ input PermissionGroupCreateInput @doc(category: "Users") { """ Determine if the group has restricted access to channels. DEFAULT: False - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ restrictedAccessToChannels: Boolean = false } @@ -32262,7 +29722,7 @@ Triggers the following webhook events: - PERMISSION_GROUP_UPDATED (async) """ type PermissionGroupUpdate @doc(category: "Users") @webhookEventsInfo(asyncEvents: [PERMISSION_GROUP_UPDATED], syncEvents: []) { - permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PermissionGroupError!]! group: Group } @@ -32274,13 +29734,7 @@ input PermissionGroupUpdateInput @doc(category: "Users") { """List of users to assign to this group.""" addUsers: [ID!] - """ - List of channels to assign to this group. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """List of channels to assign to this group.""" addChannels: [ID!] """Group name.""" @@ -32292,22 +29746,10 @@ input PermissionGroupUpdateInput @doc(category: "Users") { """List of users to unassign from this group.""" removeUsers: [ID!] - """ - List of channels to unassign from this group. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """List of channels to unassign from this group.""" removeChannels: [ID!] - """ - Determine if the group has restricted access to channels. - - Added in Saleor 3.14. - - Note: this API is currently in Feature Preview and can be subject to changes at later point. - """ + """Determine if the group has restricted access to channels.""" restrictedAccessToChannels: Boolean } @@ -32320,17 +29762,13 @@ Triggers the following webhook events: - PERMISSION_GROUP_DELETED (async) """ type PermissionGroupDelete @doc(category: "Users") @webhookEventsInfo(asyncEvents: [PERMISSION_GROUP_DELETED], syncEvents: []) { - permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "This field will be removed in Saleor 4.0. Use `errors` field instead.") + permissionGroupErrors: [PermissionGroupError!]! @deprecated(reason: "Use `errors` field instead.") errors: [PermissionGroupError!]! group: Group } type Subscription @doc(category: "Miscellaneous") { - """ - Look up subscription event. - - Added in Saleor 3.2. - """ + """Look up subscription event.""" event: Event """ @@ -32342,10 +29780,10 @@ type Subscription @doc(category: "Miscellaneous") { """ draftOrderCreated( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): DraftOrderCreated + ): DraftOrderCreated @doc(category: "Orders") """ Event sent when draft order is updated. @@ -32356,10 +29794,10 @@ type Subscription @doc(category: "Miscellaneous") { """ draftOrderUpdated( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): DraftOrderUpdated + ): DraftOrderUpdated @doc(category: "Orders") """ Event sent when draft order is deleted. @@ -32370,10 +29808,10 @@ type Subscription @doc(category: "Miscellaneous") { """ draftOrderDeleted( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): DraftOrderDeleted + ): DraftOrderDeleted @doc(category: "Orders") """ Event sent when new order is created. @@ -32384,10 +29822,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderCreated( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderCreated + ): OrderCreated @doc(category: "Orders") """ Event sent when order is updated. @@ -32398,10 +29836,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderUpdated( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderUpdated + ): OrderUpdated @doc(category: "Orders") """ Event sent when order is confirmed. @@ -32412,10 +29850,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderConfirmed( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderConfirmed + ): OrderConfirmed @doc(category: "Orders") """ Payment has been made. The order may be partially or fully paid. @@ -32426,10 +29864,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderPaid( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderPaid + ): OrderPaid @doc(category: "Orders") """ Event sent when order is fully paid. @@ -32440,10 +29878,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderFullyPaid( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderFullyPaid + ): OrderFullyPaid @doc(category: "Orders") """ The order received a refund. The order may be partially or fully refunded. @@ -32454,10 +29892,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderRefunded( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderRefunded + ): OrderRefunded @doc(category: "Orders") """ The order is fully refunded. @@ -32468,10 +29906,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderFullyRefunded( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderFullyRefunded + ): OrderFullyRefunded @doc(category: "Orders") """ Event sent when order is fulfilled. @@ -32482,10 +29920,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderFulfilled( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderFulfilled + ): OrderFulfilled @doc(category: "Orders") """ Event sent when order is cancelled. @@ -32496,10 +29934,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderCancelled( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderCancelled + ): OrderCancelled @doc(category: "Orders") """ Event sent when order becomes expired. @@ -32510,10 +29948,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderExpired( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderExpired + ): OrderExpired @doc(category: "Orders") """ Event sent when order metadata is updated. @@ -32524,10 +29962,10 @@ type Subscription @doc(category: "Miscellaneous") { """ orderMetadataUpdated( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderMetadataUpdated + ): OrderMetadataUpdated @doc(category: "Orders") """ Event sent when orders are imported. @@ -32538,10 +29976,66 @@ type Subscription @doc(category: "Miscellaneous") { """ orderBulkCreated( """ - List of channel slugs. The event will be sent only if the order belongs to one of the provided channels. If the channel slug list is empty, orders that belong to any channel will be sent. Maximally 500 items. + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. + """ + channels: [String!] + ): OrderBulkCreated @doc(category: "Orders") + + """ + Event sent when new checkout is created. + + Added in Saleor 3.21. + + Note: this API is currently in Feature Preview and can be subject to changes at later point. + """ + checkoutCreated( + """ + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. """ channels: [String!] - ): OrderBulkCreated + ): CheckoutCreated @doc(category: "Checkout") + + """ + Event sent when checkout is updated. + + Added in Saleor 3.21. + + Note: this API is currently in Feature Preview and can be subject to changes at later point. + """ + checkoutUpdated( + """ + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. + """ + channels: [String!] + ): CheckoutUpdated @doc(category: "Checkout") + + """ + Event sent when checkout is fully-paid. + + Added in Saleor 3.21. + + Note: this API is currently in Feature Preview and can be subject to changes at later point. + """ + checkoutFullyPaid( + """ + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. + """ + channels: [String!] + ): CheckoutFullyPaid @doc(category: "Checkout") + + """ + Event sent when checkout metadata is updated. + + Added in Saleor 3.21. + + Note: this API is currently in Feature Preview and can be subject to changes at later point. + """ + checkoutMetadataUpdated( + """ + List of channel slugs. The event will be sent only if the object belongs to one of the provided channels. If the channel slug list is empty, objects that belong to any channel will be sent. Maximally 500 items. + """ + channels: [String!] + ): CheckoutMetadataUpdated @doc(category: "Checkout") } interface Event { @@ -32560,11 +30054,7 @@ interface Event { union IssuingPrincipal = App | User -""" -Event sent when new draft order is created. - -Added in Saleor 3.2. -""" +"""Event sent when new draft order is created.""" type DraftOrderCreated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32582,11 +30072,7 @@ type DraftOrderCreated implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when draft order is updated. - -Added in Saleor 3.2. -""" +"""Event sent when draft order is updated.""" type DraftOrderUpdated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32604,11 +30090,7 @@ type DraftOrderUpdated implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when draft order is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when draft order is deleted.""" type DraftOrderDeleted implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32626,11 +30108,7 @@ type DraftOrderDeleted implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when new order is created. - -Added in Saleor 3.2. -""" +"""Event sent when new order is created.""" type OrderCreated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32648,11 +30126,7 @@ type OrderCreated implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when order is updated. - -Added in Saleor 3.2. -""" +"""Event sent when order is updated.""" type OrderUpdated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32670,11 +30144,7 @@ type OrderUpdated implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when order is confirmed. - -Added in Saleor 3.2. -""" +"""Event sent when order is confirmed.""" type OrderConfirmed implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32692,13 +30162,7 @@ type OrderConfirmed implements Event @doc(category: "Orders") { order: Order } -""" -Payment has been made. The order may be partially or fully paid. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Payment has been made. The order may be partially or fully paid.""" type OrderPaid implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32716,11 +30180,7 @@ type OrderPaid implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when order is fully paid. - -Added in Saleor 3.2. -""" +"""Event sent when order is fully paid.""" type OrderFullyPaid implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32740,10 +30200,6 @@ type OrderFullyPaid implements Event @doc(category: "Orders") { """ The order received a refund. The order may be partially or fully refunded. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type OrderRefunded implements Event @doc(category: "Orders") { """Time of the event.""" @@ -32762,13 +30218,7 @@ type OrderRefunded implements Event @doc(category: "Orders") { order: Order } -""" -The order is fully refunded. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""The order is fully refunded.""" type OrderFullyRefunded implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32786,11 +30236,7 @@ type OrderFullyRefunded implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when order is fulfilled. - -Added in Saleor 3.2. -""" +"""Event sent when order is fulfilled.""" type OrderFulfilled implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32808,11 +30254,7 @@ type OrderFulfilled implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when order is canceled. - -Added in Saleor 3.2. -""" +"""Event sent when order is canceled.""" type OrderCancelled implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32830,13 +30272,7 @@ type OrderCancelled implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when order becomes expired. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when order becomes expired.""" type OrderExpired implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32854,11 +30290,7 @@ type OrderExpired implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when order metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when order metadata is updated.""" type OrderMetadataUpdated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32876,13 +30308,7 @@ type OrderMetadataUpdated implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when orders are imported. - -Added in Saleor 3.14. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when orders are imported.""" type OrderBulkCreated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -32900,7 +30326,80 @@ type OrderBulkCreated implements Event @doc(category: "Orders") { orders: [Order!] } -"""An enumeration.""" +"""Event sent when new checkout is created.""" +type CheckoutCreated implements Event @doc(category: "Checkout") { + """Time of the event.""" + issuedAt: DateTime + + """Saleor version that triggered the event.""" + version: String + + """The user or application that triggered the event.""" + issuingPrincipal: IssuingPrincipal + + """The application receiving the webhook.""" + recipient: App + + """The checkout the event relates to.""" + checkout: Checkout +} + +"""Event sent when checkout is updated.""" +type CheckoutUpdated implements Event @doc(category: "Checkout") { + """Time of the event.""" + issuedAt: DateTime + + """Saleor version that triggered the event.""" + version: String + + """The user or application that triggered the event.""" + issuingPrincipal: IssuingPrincipal + + """The application receiving the webhook.""" + recipient: App + + """The checkout the event relates to.""" + checkout: Checkout +} + +""" +Event sent when checkout is fully paid with transactions. The checkout is considered as fully paid when the checkout `charge_status` is `FULL` or `OVERCHARGED`. The event is not sent when the checkout authorization flow strategy is used. +""" +type CheckoutFullyPaid implements Event @doc(category: "Checkout") { + """Time of the event.""" + issuedAt: DateTime + + """Saleor version that triggered the event.""" + version: String + + """The user or application that triggered the event.""" + issuingPrincipal: IssuingPrincipal + + """The application receiving the webhook.""" + recipient: App + + """The checkout the event relates to.""" + checkout: Checkout +} + +"""Event sent when checkout metadata is updated.""" +type CheckoutMetadataUpdated implements Event @doc(category: "Checkout") { + """Time of the event.""" + issuedAt: DateTime + + """Saleor version that triggered the event.""" + version: String + + """The user or application that triggered the event.""" + issuingPrincipal: IssuingPrincipal + + """The application receiving the webhook.""" + recipient: App + + """The checkout the event relates to.""" + checkout: Checkout +} + enum DistanceUnitsEnum { MM CM @@ -32912,7 +30411,6 @@ enum DistanceUnitsEnum { INCH } -"""An enumeration.""" enum AreaUnitsEnum { SQ_MM SQ_CM @@ -32924,7 +30422,6 @@ enum AreaUnitsEnum { SQ_INCH } -"""An enumeration.""" enum VolumeUnitsEnum { CUBIC_MILLIMETER CUBIC_CENTIMETER @@ -32943,8 +30440,6 @@ enum VolumeUnitsEnum { """ Event sent when account confirmation requested. This event is always sent. enableAccountConfirmationByEmail flag set to True is not required. - -Added in Saleor 3.15. """ type AccountConfirmationRequested implements Event @doc(category: "Users") { """Time of the event.""" @@ -32975,11 +30470,7 @@ type AccountConfirmationRequested implements Event @doc(category: "Users") { shop: Shop } -""" -Event sent when account change email is requested. - -Added in Saleor 3.15. -""" +"""Event sent when account change email is requested.""" type AccountChangeEmailRequested implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33012,11 +30503,7 @@ type AccountChangeEmailRequested implements Event @doc(category: "Users") { newEmail: String } -""" -Event sent when account email is changed. - -Added in Saleor 3.15. -""" +"""Event sent when account email is changed.""" type AccountEmailChanged implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33049,11 +30536,7 @@ type AccountEmailChanged implements Event @doc(category: "Users") { newEmail: String } -""" -Event sent when setting a new password is requested. - -Added in Saleor 3.15. -""" +"""Event sent when setting a new password is requested.""" type AccountSetPasswordRequested implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33083,11 +30566,7 @@ type AccountSetPasswordRequested implements Event @doc(category: "Users") { shop: Shop } -""" -Event sent when account is confirmed. - -Added in Saleor 3.15. -""" +"""Event sent when account is confirmed.""" type AccountConfirmed implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33117,11 +30596,7 @@ type AccountConfirmed implements Event @doc(category: "Users") { shop: Shop } -""" -Event sent when account delete is requested. - -Added in Saleor 3.15. -""" +"""Event sent when account delete is requested.""" type AccountDeleteRequested implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33151,11 +30626,7 @@ type AccountDeleteRequested implements Event @doc(category: "Users") { shop: Shop } -""" -Event sent when account is deleted. - -Added in Saleor 3.15. -""" +"""Event sent when account is deleted.""" type AccountDeleted implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33185,11 +30656,7 @@ type AccountDeleted implements Event @doc(category: "Users") { shop: Shop } -""" -Event sent when new address is created. - -Added in Saleor 3.5. -""" +"""Event sent when new address is created.""" type AddressCreated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33207,11 +30674,7 @@ type AddressCreated implements Event @doc(category: "Users") { address: Address } -""" -Event sent when address is updated. - -Added in Saleor 3.5. -""" +"""Event sent when address is updated.""" type AddressUpdated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33229,11 +30692,7 @@ type AddressUpdated implements Event @doc(category: "Users") { address: Address } -""" -Event sent when address is deleted. - -Added in Saleor 3.5. -""" +"""Event sent when address is deleted.""" type AddressDeleted implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -33251,11 +30710,7 @@ type AddressDeleted implements Event @doc(category: "Users") { address: Address } -""" -Event sent when new app is installed. - -Added in Saleor 3.4. -""" +"""Event sent when new app is installed.""" type AppInstalled implements Event @doc(category: "Apps") { """Time of the event.""" issuedAt: DateTime @@ -33273,11 +30728,7 @@ type AppInstalled implements Event @doc(category: "Apps") { app: App } -""" -Event sent when app is updated. - -Added in Saleor 3.4. -""" +"""Event sent when app is updated.""" type AppUpdated implements Event @doc(category: "Apps") { """Time of the event.""" issuedAt: DateTime @@ -33295,11 +30746,7 @@ type AppUpdated implements Event @doc(category: "Apps") { app: App } -""" -Event sent when app is deleted. - -Added in Saleor 3.4. -""" +"""Event sent when app is deleted.""" type AppDeleted implements Event @doc(category: "Apps") { """Time of the event.""" issuedAt: DateTime @@ -33317,11 +30764,7 @@ type AppDeleted implements Event @doc(category: "Apps") { app: App } -""" -Event sent when app status has changed. - -Added in Saleor 3.4. -""" +"""Event sent when app status has changed.""" type AppStatusChanged implements Event @doc(category: "Apps") { """Time of the event.""" issuedAt: DateTime @@ -33339,11 +30782,7 @@ type AppStatusChanged implements Event @doc(category: "Apps") { app: App } -""" -Event sent when new attribute is created. - -Added in Saleor 3.5. -""" +"""Event sent when new attribute is created.""" type AttributeCreated implements Event @doc(category: "Attributes") { """Time of the event.""" issuedAt: DateTime @@ -33361,11 +30800,7 @@ type AttributeCreated implements Event @doc(category: "Attributes") { attribute: Attribute } -""" -Event sent when attribute is updated. - -Added in Saleor 3.5. -""" +"""Event sent when attribute is updated.""" type AttributeUpdated implements Event @doc(category: "Attributes") { """Time of the event.""" issuedAt: DateTime @@ -33383,11 +30818,7 @@ type AttributeUpdated implements Event @doc(category: "Attributes") { attribute: Attribute } -""" -Event sent when attribute is deleted. - -Added in Saleor 3.5. -""" +"""Event sent when attribute is deleted.""" type AttributeDeleted implements Event @doc(category: "Attributes") { """Time of the event.""" issuedAt: DateTime @@ -33405,11 +30836,7 @@ type AttributeDeleted implements Event @doc(category: "Attributes") { attribute: Attribute } -""" -Event sent when new attribute value is created. - -Added in Saleor 3.5. -""" +"""Event sent when new attribute value is created.""" type AttributeValueCreated implements Event @doc(category: "Attributes") { """Time of the event.""" issuedAt: DateTime @@ -33427,11 +30854,7 @@ type AttributeValueCreated implements Event @doc(category: "Attributes") { attributeValue: AttributeValue } -""" -Event sent when attribute value is updated. - -Added in Saleor 3.5. -""" +"""Event sent when attribute value is updated.""" type AttributeValueUpdated implements Event @doc(category: "Attributes") { """Time of the event.""" issuedAt: DateTime @@ -33449,11 +30872,7 @@ type AttributeValueUpdated implements Event @doc(category: "Attributes") { attributeValue: AttributeValue } -""" -Event sent when attribute value is deleted. - -Added in Saleor 3.5. -""" +"""Event sent when attribute value is deleted.""" type AttributeValueDeleted implements Event @doc(category: "Attributes") { """Time of the event.""" issuedAt: DateTime @@ -33471,11 +30890,7 @@ type AttributeValueDeleted implements Event @doc(category: "Attributes") { attributeValue: AttributeValue } -""" -Event sent when new category is created. - -Added in Saleor 3.2. -""" +"""Event sent when new category is created.""" type CategoryCreated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -33493,11 +30908,7 @@ type CategoryCreated implements Event @doc(category: "Products") { category: Category } -""" -Event sent when category is updated. - -Added in Saleor 3.2. -""" +"""Event sent when category is updated.""" type CategoryUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -33515,11 +30926,7 @@ type CategoryUpdated implements Event @doc(category: "Products") { category: Category } -""" -Event sent when category is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when category is deleted.""" type CategoryDeleted implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -33537,11 +30944,7 @@ type CategoryDeleted implements Event @doc(category: "Products") { category: Category } -""" -Event sent when new channel is created. - -Added in Saleor 3.2. -""" +"""Event sent when new channel is created.""" type ChannelCreated implements Event @doc(category: "Channels") { """Time of the event.""" issuedAt: DateTime @@ -33559,11 +30962,7 @@ type ChannelCreated implements Event @doc(category: "Channels") { channel: Channel } -""" -Event sent when channel is updated. - -Added in Saleor 3.2. -""" +"""Event sent when channel is updated.""" type ChannelUpdated implements Event @doc(category: "Channels") { """Time of the event.""" issuedAt: DateTime @@ -33581,11 +30980,7 @@ type ChannelUpdated implements Event @doc(category: "Channels") { channel: Channel } -""" -Event sent when channel is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when channel is deleted.""" type ChannelDeleted implements Event @doc(category: "Channels") { """Time of the event.""" issuedAt: DateTime @@ -33603,11 +30998,7 @@ type ChannelDeleted implements Event @doc(category: "Channels") { channel: Channel } -""" -Event sent when channel status has changed. - -Added in Saleor 3.2. -""" +"""Event sent when channel status has changed.""" type ChannelStatusChanged implements Event @doc(category: "Channels") { """Time of the event.""" issuedAt: DateTime @@ -33625,11 +31016,7 @@ type ChannelStatusChanged implements Event @doc(category: "Channels") { channel: Channel } -""" -Event sent when channel metadata is updated. - -Added in Saleor 3.15. -""" +"""Event sent when channel metadata is updated.""" type ChannelMetadataUpdated implements Event @doc(category: "Channels") { """Time of the event.""" issuedAt: DateTime @@ -33647,11 +31034,7 @@ type ChannelMetadataUpdated implements Event @doc(category: "Channels") { channel: Channel } -""" -Event sent when new gift card is created. - -Added in Saleor 3.2. -""" +"""Event sent when new gift card is created.""" type GiftCardCreated implements Event @doc(category: "Gift cards") { """Time of the event.""" issuedAt: DateTime @@ -33669,11 +31052,7 @@ type GiftCardCreated implements Event @doc(category: "Gift cards") { giftCard: GiftCard } -""" -Event sent when gift card is updated. - -Added in Saleor 3.2. -""" +"""Event sent when gift card is updated.""" type GiftCardUpdated implements Event @doc(category: "Gift cards") { """Time of the event.""" issuedAt: DateTime @@ -33691,11 +31070,7 @@ type GiftCardUpdated implements Event @doc(category: "Gift cards") { giftCard: GiftCard } -""" -Event sent when gift card is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when gift card is deleted.""" type GiftCardDeleted implements Event @doc(category: "Gift cards") { """Time of the event.""" issuedAt: DateTime @@ -33713,13 +31088,7 @@ type GiftCardDeleted implements Event @doc(category: "Gift cards") { giftCard: GiftCard } -""" -Event sent when gift card is e-mailed. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when gift card is e-mailed.""" type GiftCardSent implements Event @doc(category: "Gift cards") { """Time of the event.""" issuedAt: DateTime @@ -33743,11 +31112,7 @@ type GiftCardSent implements Event @doc(category: "Gift cards") { sentToEmail: String } -""" -Event sent when gift card status has changed. - -Added in Saleor 3.2. -""" +"""Event sent when gift card status has changed.""" type GiftCardStatusChanged implements Event @doc(category: "Gift cards") { """Time of the event.""" issuedAt: DateTime @@ -33765,11 +31130,7 @@ type GiftCardStatusChanged implements Event @doc(category: "Gift cards") { giftCard: GiftCard } -""" -Event sent when gift card metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when gift card metadata is updated.""" type GiftCardMetadataUpdated implements Event @doc(category: "Gift cards") { """Time of the event.""" issuedAt: DateTime @@ -33787,11 +31148,7 @@ type GiftCardMetadataUpdated implements Event @doc(category: "Gift cards") { giftCard: GiftCard } -""" -Event sent when gift card export is completed. - -Added in Saleor 3.16. -""" +"""Event sent when gift card export is completed.""" type GiftCardExportCompleted implements Event @doc(category: "Gift cards") { """Time of the event.""" issuedAt: DateTime @@ -33809,11 +31166,7 @@ type GiftCardExportCompleted implements Event @doc(category: "Gift cards") { export: ExportFile } -""" -Event sent when new menu is created. - -Added in Saleor 3.4. -""" +"""Event sent when new menu is created.""" type MenuCreated implements Event @doc(category: "Menu") { """Time of the event.""" issuedAt: DateTime @@ -33834,11 +31187,7 @@ type MenuCreated implements Event @doc(category: "Menu") { ): Menu } -""" -Event sent when menu is updated. - -Added in Saleor 3.4. -""" +"""Event sent when menu is updated.""" type MenuUpdated implements Event @doc(category: "Menu") { """Time of the event.""" issuedAt: DateTime @@ -33859,11 +31208,7 @@ type MenuUpdated implements Event @doc(category: "Menu") { ): Menu } -""" -Event sent when menu is deleted. - -Added in Saleor 3.4. -""" +"""Event sent when menu is deleted.""" type MenuDeleted implements Event @doc(category: "Menu") { """Time of the event.""" issuedAt: DateTime @@ -33884,11 +31229,7 @@ type MenuDeleted implements Event @doc(category: "Menu") { ): Menu } -""" -Event sent when new menu item is created. - -Added in Saleor 3.4. -""" +"""Event sent when new menu item is created.""" type MenuItemCreated implements Event @doc(category: "Menu") { """Time of the event.""" issuedAt: DateTime @@ -33909,11 +31250,7 @@ type MenuItemCreated implements Event @doc(category: "Menu") { ): MenuItem } -""" -Event sent when menu item is updated. - -Added in Saleor 3.4. -""" +"""Event sent when menu item is updated.""" type MenuItemUpdated implements Event @doc(category: "Menu") { """Time of the event.""" issuedAt: DateTime @@ -33934,11 +31271,7 @@ type MenuItemUpdated implements Event @doc(category: "Menu") { ): MenuItem } -""" -Event sent when menu item is deleted. - -Added in Saleor 3.4. -""" +"""Event sent when menu item is deleted.""" type MenuItemDeleted implements Event @doc(category: "Menu") { """Time of the event.""" issuedAt: DateTime @@ -33959,11 +31292,7 @@ type MenuItemDeleted implements Event @doc(category: "Menu") { ): MenuItem } -""" -Event sent when new product is created. - -Added in Saleor 3.2. -""" +"""Event sent when new product is created.""" type ProductCreated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -33987,11 +31316,7 @@ type ProductCreated implements Event @doc(category: "Products") { category: Category } -""" -Event sent when product is updated. - -Added in Saleor 3.2. -""" +"""Event sent when product is updated.""" type ProductUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34015,11 +31340,7 @@ type ProductUpdated implements Event @doc(category: "Products") { category: Category } -""" -Event sent when product is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when product is deleted.""" type ProductDeleted implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34043,11 +31364,7 @@ type ProductDeleted implements Event @doc(category: "Products") { category: Category } -""" -Event sent when product metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when product metadata is updated.""" type ProductMetadataUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34071,11 +31388,7 @@ type ProductMetadataUpdated implements Event @doc(category: "Products") { category: Category } -""" -Event sent when product export is completed. - -Added in Saleor 3.16. -""" +"""Event sent when product export is completed.""" type ProductExportCompleted implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34093,11 +31406,7 @@ type ProductExportCompleted implements Event @doc(category: "Products") { export: ExportFile } -""" -Event sent when new product media is created. - -Added in Saleor 3.12. -""" +"""Event sent when new product media is created.""" type ProductMediaCreated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34115,11 +31424,7 @@ type ProductMediaCreated implements Event @doc(category: "Products") { productMedia: ProductMedia } -""" -Event sent when product media is updated. - -Added in Saleor 3.12. -""" +"""Event sent when product media is updated.""" type ProductMediaUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34137,11 +31442,7 @@ type ProductMediaUpdated implements Event @doc(category: "Products") { productMedia: ProductMedia } -""" -Event sent when product media is deleted. - -Added in Saleor 3.12. -""" +"""Event sent when product media is deleted.""" type ProductMediaDeleted implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34159,11 +31460,7 @@ type ProductMediaDeleted implements Event @doc(category: "Products") { productMedia: ProductMedia } -""" -Event sent when new product variant is created. - -Added in Saleor 3.2. -""" +"""Event sent when new product variant is created.""" type ProductVariantCreated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34184,11 +31481,7 @@ type ProductVariantCreated implements Event @doc(category: "Products") { ): ProductVariant } -""" -Event sent when product variant is updated. - -Added in Saleor 3.2. -""" +"""Event sent when product variant is updated.""" type ProductVariantUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34209,11 +31502,7 @@ type ProductVariantUpdated implements Event @doc(category: "Products") { ): ProductVariant } -""" -Event sent when product variant is out of stock. - -Added in Saleor 3.2. -""" +"""Event sent when product variant is out of stock.""" type ProductVariantOutOfStock implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34237,11 +31526,7 @@ type ProductVariantOutOfStock implements Event @doc(category: "Products") { warehouse: Warehouse } -""" -Event sent when product variant is back in stock. - -Added in Saleor 3.2. -""" +"""Event sent when product variant is back in stock.""" type ProductVariantBackInStock implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34265,13 +31550,7 @@ type ProductVariantBackInStock implements Event @doc(category: "Products") { warehouse: Warehouse } -""" -Event sent when product variant stock is updated. - -Added in Saleor 3.11. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when product variant stock is updated.""" type ProductVariantStockUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34295,11 +31574,7 @@ type ProductVariantStockUpdated implements Event @doc(category: "Products") { warehouse: Warehouse } -""" -Event sent when product variant is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when product variant is deleted.""" type ProductVariantDeleted implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34320,11 +31595,7 @@ type ProductVariantDeleted implements Event @doc(category: "Products") { ): ProductVariant } -""" -Event sent when product variant metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when product variant metadata is updated.""" type ProductVariantMetadataUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34348,9 +31619,7 @@ type ProductVariantMetadataUpdated implements Event @doc(category: "Products") { """ Event sent when new sale is created. -Added in Saleor 3.2. - -DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionCreated` event instead. +DEPRECATED: this event will be removed. Use `PromotionCreated` event instead. """ type SaleCreated implements Event @doc(category: "Discounts") { """Time of the event.""" @@ -34375,9 +31644,7 @@ type SaleCreated implements Event @doc(category: "Discounts") { """ Event sent when sale is updated. -Added in Saleor 3.2. - -DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionUpdated` event instead. +DEPRECATED: this event will be removed. Use `PromotionUpdated` event instead. """ type SaleUpdated implements Event @doc(category: "Discounts") { """Time of the event.""" @@ -34402,9 +31669,7 @@ type SaleUpdated implements Event @doc(category: "Discounts") { """ Event sent when sale is deleted. -Added in Saleor 3.2. - -DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionDeleted` event instead. +DEPRECATED: this event will be removed. Use `PromotionDeleted` event instead. """ type SaleDeleted implements Event @doc(category: "Discounts") { """Time of the event.""" @@ -34429,9 +31694,7 @@ type SaleDeleted implements Event @doc(category: "Discounts") { """ The event informs about the start or end of the sale. -Added in Saleor 3.5. - -DEPRECATED: this event will be removed in Saleor 4.0. Use `PromotionStarted` and `PromotionEnded` events instead. +DEPRECATED: this event will be removed. Use `PromotionStarted` and `PromotionEnded` events instead. """ type SaleToggle implements Event @doc(category: "Discounts") { """Time of the event.""" @@ -34446,24 +31709,14 @@ type SaleToggle implements Event @doc(category: "Discounts") { """The application receiving the webhook.""" recipient: App - """ - The sale the event relates to. - - Added in Saleor 3.5. - """ + """The sale the event relates to.""" sale( """Slug of a channel for which the data should be returned.""" channel: String ): Sale } -""" -Event sent when new promotion is created. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when new promotion is created.""" type PromotionCreated implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -34481,13 +31734,7 @@ type PromotionCreated implements Event @doc(category: "Discounts") { promotion: Promotion } -""" -Event sent when promotion is updated. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when promotion is updated.""" type PromotionUpdated implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -34505,13 +31752,7 @@ type PromotionUpdated implements Event @doc(category: "Discounts") { promotion: Promotion } -""" -Event sent when promotion is deleted. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when promotion is deleted.""" type PromotionDeleted implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -34529,13 +31770,7 @@ type PromotionDeleted implements Event @doc(category: "Discounts") { promotion: Promotion } -""" -The event informs about the start of the promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""The event informs about the start of the promotion.""" type PromotionStarted implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -34553,13 +31788,7 @@ type PromotionStarted implements Event @doc(category: "Discounts") { promotion: Promotion } -""" -The event informs about the end of the promotion. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""The event informs about the end of the promotion.""" type PromotionEnded implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -34577,13 +31806,7 @@ type PromotionEnded implements Event @doc(category: "Discounts") { promotion: Promotion } -""" -Event sent when new promotion rule is created. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when new promotion rule is created.""" type PromotionRuleCreated implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -34601,13 +31824,7 @@ type PromotionRuleCreated implements Event @doc(category: "Discounts") { promotionRule: PromotionRule } -""" -Event sent when new promotion rule is updated. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when new promotion rule is updated.""" type PromotionRuleUpdated implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -34625,13 +31842,7 @@ type PromotionRuleUpdated implements Event @doc(category: "Discounts") { promotionRule: PromotionRule } -""" -Event sent when new promotion rule is deleted. - -Added in Saleor 3.17. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when new promotion rule is deleted.""" type PromotionRuleDeleted implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -34649,11 +31860,7 @@ type PromotionRuleDeleted implements Event @doc(category: "Discounts") { promotionRule: PromotionRule } -""" -Event sent when invoice is requested. - -Added in Saleor 3.2. -""" +"""Event sent when invoice is requested.""" type InvoiceRequested implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -34670,19 +31877,11 @@ type InvoiceRequested implements Event @doc(category: "Orders") { """The invoice the event relates to.""" invoice: Invoice - """ - Order related to the invoice. - - Added in Saleor 3.10. - """ + """Order related to the invoice.""" order: Order! } -""" -Event sent when invoice is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when invoice is deleted.""" type InvoiceDeleted implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -34699,19 +31898,11 @@ type InvoiceDeleted implements Event @doc(category: "Orders") { """The invoice the event relates to.""" invoice: Invoice - """ - Order related to the invoice. - - Added in Saleor 3.10. - """ + """Order related to the invoice.""" order: Order } -""" -Event sent when invoice is sent. - -Added in Saleor 3.2. -""" +"""Event sent when invoice is sent.""" type InvoiceSent implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -34728,19 +31919,11 @@ type InvoiceSent implements Event @doc(category: "Orders") { """The invoice the event relates to.""" invoice: Invoice - """ - Order related to the invoice. - - Added in Saleor 3.10. - """ + """Order related to the invoice.""" order: Order } -""" -Event sent when new fulfillment is created. - -Added in Saleor 3.4. -""" +"""Event sent when new fulfillment is created.""" type FulfillmentCreated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -34760,19 +31943,11 @@ type FulfillmentCreated implements Event @doc(category: "Orders") { """The order the fulfillment belongs to.""" order: Order - """ - If true, the app should send a notification to the customer. - - Added in Saleor 3.16. - """ + """If true, the app should send a notification to the customer.""" notifyCustomer: Boolean! } -""" -Event sent when the tracking number is updated. - -Added in Saleor 3.16. -""" +"""Event sent when the tracking number is updated.""" type FulfillmentTrackingNumberUpdated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -34793,11 +31968,7 @@ type FulfillmentTrackingNumberUpdated implements Event @doc(category: "Orders") order: Order } -""" -Event sent when fulfillment is canceled. - -Added in Saleor 3.4. -""" +"""Event sent when fulfillment is canceled.""" type FulfillmentCanceled implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -34818,11 +31989,7 @@ type FulfillmentCanceled implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when fulfillment is approved. - -Added in Saleor 3.7. -""" +"""Event sent when fulfillment is approved.""" type FulfillmentApproved implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -34842,19 +32009,11 @@ type FulfillmentApproved implements Event @doc(category: "Orders") { """The order the fulfillment belongs to.""" order: Order - """ - If true, send a notification to the customer. - - Added in Saleor 3.16. - """ + """If true, send a notification to the customer.""" notifyCustomer: Boolean! } -""" -Event sent when fulfillment metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when fulfillment metadata is updated.""" type FulfillmentMetadataUpdated implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -34875,11 +32034,7 @@ type FulfillmentMetadataUpdated implements Event @doc(category: "Orders") { order: Order } -""" -Event sent when new customer user is created. - -Added in Saleor 3.2. -""" +"""Event sent when new customer user is created.""" type CustomerCreated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -34897,11 +32052,7 @@ type CustomerCreated implements Event @doc(category: "Users") { user: User } -""" -Event sent when customer user is updated. - -Added in Saleor 3.2. -""" +"""Event sent when customer user is updated.""" type CustomerUpdated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -34919,11 +32070,7 @@ type CustomerUpdated implements Event @doc(category: "Users") { user: User } -""" -Event sent when customer user metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when customer user metadata is updated.""" type CustomerMetadataUpdated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -34941,11 +32088,7 @@ type CustomerMetadataUpdated implements Event @doc(category: "Users") { user: User } -""" -Event sent when new collection is created. - -Added in Saleor 3.2. -""" +"""Event sent when new collection is created.""" type CollectionCreated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34966,11 +32109,7 @@ type CollectionCreated implements Event @doc(category: "Products") { ): Collection } -""" -Event sent when collection is updated. - -Added in Saleor 3.2. -""" +"""Event sent when collection is updated.""" type CollectionUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -34991,11 +32130,7 @@ type CollectionUpdated implements Event @doc(category: "Products") { ): Collection } -""" -Event sent when collection is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when collection is deleted.""" type CollectionDeleted implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -35016,11 +32151,7 @@ type CollectionDeleted implements Event @doc(category: "Products") { ): Collection } -""" -Event sent when collection metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when collection metadata is updated.""" type CollectionMetadataUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -35041,101 +32172,7 @@ type CollectionMetadataUpdated implements Event @doc(category: "Products") { ): Collection } -""" -Event sent when new checkout is created. - -Added in Saleor 3.2. -""" -type CheckoutCreated implements Event @doc(category: "Checkout") { - """Time of the event.""" - issuedAt: DateTime - - """Saleor version that triggered the event.""" - version: String - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The checkout the event relates to.""" - checkout: Checkout -} - -""" -Event sent when checkout is updated. - -Added in Saleor 3.2. -""" -type CheckoutUpdated implements Event @doc(category: "Checkout") { - """Time of the event.""" - issuedAt: DateTime - - """Saleor version that triggered the event.""" - version: String - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The checkout the event relates to.""" - checkout: Checkout -} - -""" -Event sent when checkout is fully paid with transactions. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" -type CheckoutFullyPaid implements Event @doc(category: "Checkout") { - """Time of the event.""" - issuedAt: DateTime - - """Saleor version that triggered the event.""" - version: String - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The checkout the event relates to.""" - checkout: Checkout -} - -""" -Event sent when checkout metadata is updated. - -Added in Saleor 3.8. -""" -type CheckoutMetadataUpdated implements Event @doc(category: "Checkout") { - """Time of the event.""" - issuedAt: DateTime - - """Saleor version that triggered the event.""" - version: String - - """The user or application that triggered the event.""" - issuingPrincipal: IssuingPrincipal - - """The application receiving the webhook.""" - recipient: App - - """The checkout the event relates to.""" - checkout: Checkout -} - -""" -Event sent when new page is created. - -Added in Saleor 3.2. -""" +"""Event sent when new page is created.""" type PageCreated implements Event @doc(category: "Pages") { """Time of the event.""" issuedAt: DateTime @@ -35153,11 +32190,7 @@ type PageCreated implements Event @doc(category: "Pages") { page: Page } -""" -Event sent when page is updated. - -Added in Saleor 3.2. -""" +"""Event sent when page is updated.""" type PageUpdated implements Event @doc(category: "Pages") { """Time of the event.""" issuedAt: DateTime @@ -35175,11 +32208,7 @@ type PageUpdated implements Event @doc(category: "Pages") { page: Page } -""" -Event sent when page is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when page is deleted.""" type PageDeleted implements Event @doc(category: "Pages") { """Time of the event.""" issuedAt: DateTime @@ -35197,11 +32226,7 @@ type PageDeleted implements Event @doc(category: "Pages") { page: Page } -""" -Event sent when new page type is created. - -Added in Saleor 3.5. -""" +"""Event sent when new page type is created.""" type PageTypeCreated implements Event @doc(category: "Pages") { """Time of the event.""" issuedAt: DateTime @@ -35219,11 +32244,7 @@ type PageTypeCreated implements Event @doc(category: "Pages") { pageType: PageType } -""" -Event sent when page type is updated. - -Added in Saleor 3.5. -""" +"""Event sent when page type is updated.""" type PageTypeUpdated implements Event @doc(category: "Pages") { """Time of the event.""" issuedAt: DateTime @@ -35241,11 +32262,7 @@ type PageTypeUpdated implements Event @doc(category: "Pages") { pageType: PageType } -""" -Event sent when page type is deleted. - -Added in Saleor 3.5. -""" +"""Event sent when page type is deleted.""" type PageTypeDeleted implements Event @doc(category: "Pages") { """Time of the event.""" issuedAt: DateTime @@ -35263,11 +32280,7 @@ type PageTypeDeleted implements Event @doc(category: "Pages") { pageType: PageType } -""" -Event sent when new permission group is created. - -Added in Saleor 3.6. -""" +"""Event sent when new permission group is created.""" type PermissionGroupCreated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -35285,11 +32298,7 @@ type PermissionGroupCreated implements Event @doc(category: "Users") { permissionGroup: Group } -""" -Event sent when permission group is updated. - -Added in Saleor 3.6. -""" +"""Event sent when permission group is updated.""" type PermissionGroupUpdated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -35307,11 +32316,7 @@ type PermissionGroupUpdated implements Event @doc(category: "Users") { permissionGroup: Group } -""" -Event sent when permission group is deleted. - -Added in Saleor 3.6. -""" +"""Event sent when permission group is deleted.""" type PermissionGroupDeleted implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -35329,11 +32334,7 @@ type PermissionGroupDeleted implements Event @doc(category: "Users") { permissionGroup: Group } -""" -Event sent when new shipping price is created. - -Added in Saleor 3.2. -""" +"""Event sent when new shipping price is created.""" type ShippingPriceCreated implements Event @doc(category: "Shipping") { """Time of the event.""" issuedAt: DateTime @@ -35360,11 +32361,7 @@ type ShippingPriceCreated implements Event @doc(category: "Shipping") { ): ShippingZone } -""" -Event sent when shipping price is updated. - -Added in Saleor 3.2. -""" +"""Event sent when shipping price is updated.""" type ShippingPriceUpdated implements Event @doc(category: "Shipping") { """Time of the event.""" issuedAt: DateTime @@ -35391,11 +32388,7 @@ type ShippingPriceUpdated implements Event @doc(category: "Shipping") { ): ShippingZone } -""" -Event sent when shipping price is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when shipping price is deleted.""" type ShippingPriceDeleted implements Event @doc(category: "Shipping") { """Time of the event.""" issuedAt: DateTime @@ -35422,11 +32415,7 @@ type ShippingPriceDeleted implements Event @doc(category: "Shipping") { ): ShippingZone } -""" -Event sent when new shipping zone is created. - -Added in Saleor 3.2. -""" +"""Event sent when new shipping zone is created.""" type ShippingZoneCreated implements Event @doc(category: "Shipping") { """Time of the event.""" issuedAt: DateTime @@ -35447,11 +32436,7 @@ type ShippingZoneCreated implements Event @doc(category: "Shipping") { ): ShippingZone } -""" -Event sent when shipping zone is updated. - -Added in Saleor 3.2. -""" +"""Event sent when shipping zone is updated.""" type ShippingZoneUpdated implements Event @doc(category: "Shipping") { """Time of the event.""" issuedAt: DateTime @@ -35472,11 +32457,7 @@ type ShippingZoneUpdated implements Event @doc(category: "Shipping") { ): ShippingZone } -""" -Event sent when shipping zone is deleted. - -Added in Saleor 3.2. -""" +"""Event sent when shipping zone is deleted.""" type ShippingZoneDeleted implements Event @doc(category: "Shipping") { """Time of the event.""" issuedAt: DateTime @@ -35497,11 +32478,7 @@ type ShippingZoneDeleted implements Event @doc(category: "Shipping") { ): ShippingZone } -""" -Event sent when shipping zone metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when shipping zone metadata is updated.""" type ShippingZoneMetadataUpdated implements Event @doc(category: "Shipping") { """Time of the event.""" issuedAt: DateTime @@ -35522,11 +32499,7 @@ type ShippingZoneMetadataUpdated implements Event @doc(category: "Shipping") { ): ShippingZone } -""" -Event sent when shop metadata is updated. - -Added in Saleor 3.15. -""" +"""Event sent when shop metadata is updated.""" type ShopMetadataUpdated implements Event { """Time of the event.""" issuedAt: DateTime @@ -35544,11 +32517,7 @@ type ShopMetadataUpdated implements Event { shop: Shop } -""" -Event sent when new staff user is created. - -Added in Saleor 3.5. -""" +"""Event sent when new staff user is created.""" type StaffCreated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -35566,11 +32535,7 @@ type StaffCreated implements Event @doc(category: "Users") { user: User } -""" -Event sent when staff user is updated. - -Added in Saleor 3.5. -""" +"""Event sent when staff user is updated.""" type StaffUpdated implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -35588,11 +32553,7 @@ type StaffUpdated implements Event @doc(category: "Users") { user: User } -""" -Event sent when staff user is deleted. - -Added in Saleor 3.5. -""" +"""Event sent when staff user is deleted.""" type StaffDeleted implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -35610,11 +32571,7 @@ type StaffDeleted implements Event @doc(category: "Users") { user: User } -""" -Event sent when setting a new password for staff is requested. - -Added in Saleor 3.15. -""" +"""Event sent when setting a new password for staff is requested.""" type StaffSetPasswordRequested implements Event @doc(category: "Users") { """Time of the event.""" issuedAt: DateTime @@ -35644,11 +32601,7 @@ type StaffSetPasswordRequested implements Event @doc(category: "Users") { shop: Shop } -""" -Event sent when transaction item metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when transaction item metadata is updated.""" type TransactionItemMetadataUpdated implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -35666,11 +32619,7 @@ type TransactionItemMetadataUpdated implements Event @doc(category: "Payments") transaction: TransactionItem } -""" -Event sent when new translation is created. - -Added in Saleor 3.2. -""" +"""Event sent when new translation is created.""" type TranslationCreated implements Event @doc(category: "Miscellaneous") { """Time of the event.""" issuedAt: DateTime @@ -35690,11 +32639,7 @@ type TranslationCreated implements Event @doc(category: "Miscellaneous") { union TranslationTypes = ProductTranslation | CollectionTranslation | CategoryTranslation | AttributeTranslation | AttributeValueTranslation | ProductVariantTranslation | PageTranslation | ShippingMethodTranslation | VoucherTranslation | MenuItemTranslation | PromotionTranslation | PromotionRuleTranslation | SaleTranslation -""" -Event sent when translation is updated. - -Added in Saleor 3.2. -""" +"""Event sent when translation is updated.""" type TranslationUpdated implements Event @doc(category: "Miscellaneous") { """Time of the event.""" issuedAt: DateTime @@ -35712,11 +32657,7 @@ type TranslationUpdated implements Event @doc(category: "Miscellaneous") { translation: TranslationTypes } -""" -Event sent when new voucher is created. - -Added in Saleor 3.4. -""" +"""Event sent when new voucher is created.""" type VoucherCreated implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -35737,11 +32678,7 @@ type VoucherCreated implements Event @doc(category: "Discounts") { ): Voucher } -""" -Event sent when voucher is updated. - -Added in Saleor 3.4. -""" +"""Event sent when voucher is updated.""" type VoucherUpdated implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -35762,11 +32699,7 @@ type VoucherUpdated implements Event @doc(category: "Discounts") { ): Voucher } -""" -Event sent when voucher is deleted. - -Added in Saleor 3.4. -""" +"""Event sent when voucher is deleted.""" type VoucherDeleted implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -35831,11 +32764,7 @@ type VoucherCodesDeleted implements Event { voucherCodes: [VoucherCode!] } -""" -Event sent when voucher metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when voucher metadata is updated.""" type VoucherMetadataUpdated implements Event @doc(category: "Discounts") { """Time of the event.""" issuedAt: DateTime @@ -35878,11 +32807,7 @@ type VoucherCodeExportCompleted implements Event @doc(category: "Discounts") { export: ExportFile } -""" -Event sent when new warehouse is created. - -Added in Saleor 3.4. -""" +"""Event sent when new warehouse is created.""" type WarehouseCreated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -35900,11 +32825,7 @@ type WarehouseCreated implements Event @doc(category: "Products") { warehouse: Warehouse } -""" -Event sent when warehouse is updated. - -Added in Saleor 3.4. -""" +"""Event sent when warehouse is updated.""" type WarehouseUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -35922,11 +32843,7 @@ type WarehouseUpdated implements Event @doc(category: "Products") { warehouse: Warehouse } -""" -Event sent when warehouse is deleted. - -Added in Saleor 3.4. -""" +"""Event sent when warehouse is deleted.""" type WarehouseDeleted implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -35944,11 +32861,7 @@ type WarehouseDeleted implements Event @doc(category: "Products") { warehouse: Warehouse } -""" -Event sent when warehouse metadata is updated. - -Added in Saleor 3.8. -""" +"""Event sent when warehouse metadata is updated.""" type WarehouseMetadataUpdated implements Event @doc(category: "Products") { """Time of the event.""" issuedAt: DateTime @@ -35966,11 +32879,7 @@ type WarehouseMetadataUpdated implements Event @doc(category: "Products") { warehouse: Warehouse } -""" -Event sent when thumbnail is created. - -Added in Saleor 3.12. -""" +"""Event sent when thumbnail is created.""" type ThumbnailCreated implements Event @doc(category: "Miscellaneous") { """Time of the event.""" issuedAt: DateTime @@ -35984,40 +32893,20 @@ type ThumbnailCreated implements Event @doc(category: "Miscellaneous") { """The application receiving the webhook.""" recipient: App - """ - Thumbnail id. - - Added in Saleor 3.12. - """ + """Thumbnail id.""" id: ID - """ - Thumbnail url. - - Added in Saleor 3.12. - """ + """Thumbnail url.""" url: String - """ - Object the thumbnail refers to. - - Added in Saleor 3.12. - """ + """Object the thumbnail refers to.""" objectId: ID - """ - Original media url. - - Added in Saleor 3.12. - """ + """Original media url.""" mediaUrl: String } -""" -Authorize payment. - -Added in Saleor 3.6. -""" +"""Authorize payment.""" type PaymentAuthorize implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36035,11 +32924,7 @@ type PaymentAuthorize implements Event @doc(category: "Payments") { payment: Payment } -""" -Capture payment. - -Added in Saleor 3.6. -""" +"""Capture payment.""" type PaymentCaptureEvent implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36057,11 +32942,7 @@ type PaymentCaptureEvent implements Event @doc(category: "Payments") { payment: Payment } -""" -Refund payment. - -Added in Saleor 3.6. -""" +"""Refund payment.""" type PaymentRefundEvent implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36079,11 +32960,7 @@ type PaymentRefundEvent implements Event @doc(category: "Payments") { payment: Payment } -""" -Void payment. - -Added in Saleor 3.6. -""" +"""Void payment.""" type PaymentVoidEvent implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36101,11 +32978,7 @@ type PaymentVoidEvent implements Event @doc(category: "Payments") { payment: Payment } -""" -Confirm payment. - -Added in Saleor 3.6. -""" +"""Confirm payment.""" type PaymentConfirmEvent implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36123,11 +32996,7 @@ type PaymentConfirmEvent implements Event @doc(category: "Payments") { payment: Payment } -""" -Process payment. - -Added in Saleor 3.6. -""" +"""Process payment.""" type PaymentProcessEvent implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36145,11 +33014,7 @@ type PaymentProcessEvent implements Event @doc(category: "Payments") { payment: Payment } -""" -List payment gateways. - -Added in Saleor 3.6. -""" +"""List payment gateways.""" type PaymentListGateways implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36167,13 +33032,7 @@ type PaymentListGateways implements Event @doc(category: "Payments") { checkout: Checkout } -""" -Event sent when transaction cancelation is requested. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when transaction cancelation is requested.""" type TransactionCancelationRequested implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36198,24 +33057,14 @@ type TransactionAction @doc(category: "Payments") { """Determines the action type.""" actionType: TransactionActionEnum! - """Transaction request amount. Null when action type is VOID.""" - amount: PositiveDecimal + """Transaction request amount.""" + amount: PositiveDecimal! - """ - Currency code. - - Added in Saleor 3.16. - """ + """Currency code.""" currency: String! } -""" -Event sent when transaction charge is requested. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when transaction charge is requested.""" type TransactionChargeRequested implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36236,13 +33085,7 @@ type TransactionChargeRequested implements Event @doc(category: "Payments") { action: TransactionAction! } -""" -Event sent when transaction refund is requested. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when transaction refund is requested.""" type TransactionRefundRequested implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36265,18 +33108,12 @@ type TransactionRefundRequested implements Event @doc(category: "Payments") { """ Granted refund related to refund request. - Added in Saleor 3.15. - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ grantedRefund: OrderGrantedRefund } -""" -Filter shipping methods for order. - -Added in Saleor 3.6. -""" +"""Filter shipping methods for order.""" type OrderFilterShippingMethods implements Event @doc(category: "Orders") { """Time of the event.""" issuedAt: DateTime @@ -36293,19 +33130,11 @@ type OrderFilterShippingMethods implements Event @doc(category: "Orders") { """The order the event relates to.""" order: Order - """ - Shipping methods that can be used with this checkout. - - Added in Saleor 3.6. - """ + """Shipping methods that can be used with this checkout.""" shippingMethods: [ShippingMethod!] } -""" -Filter shipping methods for checkout. - -Added in Saleor 3.6. -""" +"""Filter shipping methods for checkout.""" type CheckoutFilterShippingMethods implements Event @doc(category: "Checkout") { """Time of the event.""" issuedAt: DateTime @@ -36322,19 +33151,11 @@ type CheckoutFilterShippingMethods implements Event @doc(category: "Checkout") { """The checkout the event relates to.""" checkout: Checkout - """ - Shipping methods that can be used with this checkout. - - Added in Saleor 3.6. - """ + """Shipping methods that can be used with this checkout.""" shippingMethods: [ShippingMethod!] } -""" -List shipping methods for checkout. - -Added in Saleor 3.6. -""" +"""List shipping methods for checkout.""" type ShippingListMethodsForCheckout implements Event @doc(category: "Checkout") { """Time of the event.""" issuedAt: DateTime @@ -36351,19 +33172,11 @@ type ShippingListMethodsForCheckout implements Event @doc(category: "Checkout") """The checkout the event relates to.""" checkout: Checkout - """ - Shipping methods that can be used with this checkout. - - Added in Saleor 3.6. - """ + """Shipping methods that can be used with this checkout.""" shippingMethods: [ShippingMethod!] } -""" -Synchronous webhook for calculating checkout/order taxes. - -Added in Saleor 3.7. -""" +"""Synchronous webhook for calculating checkout/order taxes.""" type CalculateTaxes implements Event @doc(category: "Taxes") { """Time of the event.""" issuedAt: DateTime @@ -36460,13 +33273,7 @@ type TaxableObjectLine @doc(category: "Taxes") { union TaxSourceLine = CheckoutLine | OrderLine -""" -Event sent when user wants to initialize the payment gateway. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when user wants to initialize the payment gateway.""" type PaymentGatewayInitializeSession implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36492,13 +33299,7 @@ type PaymentGatewayInitializeSession implements Event @doc(category: "Payments") union OrderOrCheckout = Checkout | Order -""" -Event sent when user starts processing the payment. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when user starts processing the payment.""" type TransactionInitializeSession implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36526,19 +33327,13 @@ type TransactionInitializeSession implements Event @doc(category: "Payments") { """ The customer's IP address. If not provided as a parameter in the mutation, Saleor will try to determine the customer's IP address on its own. - - Added in Saleor 3.16. """ customerIpAddress: String """Action to proceed for the transaction""" action: TransactionProcessAction! - """ - Idempotency key assigned to the transaction initialize. - - Added in Saleor 3.14. - """ + """Idempotency key assigned to the transaction initialize.""" idempotencyKey: String! } @@ -36551,13 +33346,7 @@ type TransactionProcessAction @doc(category: "Payments") { actionType: TransactionFlowStrategyEnum! } -""" -Event sent when user has additional payment action to process. - -Added in Saleor 3.13. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when user has additional payment action to process.""" type TransactionProcessSession implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36585,8 +33374,6 @@ type TransactionProcessSession implements Event @doc(category: "Payments") { """ The customer's IP address. If not provided as a parameter in the mutation, Saleor will try to determine the customer's IP address on its own. - - Added in Saleor 3.16. """ customerIpAddress: String @@ -36597,8 +33384,6 @@ type TransactionProcessSession implements Event @doc(category: "Payments") { """ List payment methods stored for the user by payment gateway. -Added in Saleor 3.15. - Note: this API is currently in Feature Preview and can be subject to changes at later point. """ type ListStoredPaymentMethods implements Event @doc(category: "Payments") { @@ -36623,13 +33408,7 @@ type ListStoredPaymentMethods implements Event @doc(category: "Payments") { channel: Channel! } -""" -Event sent when user requests to delete a payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when user requests to delete a payment method.""" type StoredPaymentMethodDeleteRequested implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36658,11 +33437,7 @@ type StoredPaymentMethodDeleteRequested implements Event @doc(category: "Payment } """ -Event sent to initialize a new session in payment gateway to store the payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. +Event sent to initialize a new session in payment gateway to store the payment method. """ type PaymentGatewayInitializeTokenizationSession implements Event @doc(category: "Payments") { """Time of the event.""" @@ -36687,13 +33462,7 @@ type PaymentGatewayInitializeTokenizationSession implements Event @doc(category: data: JSON } -""" -Event sent when user requests a tokenization of payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when user requests a tokenization of payment method.""" type PaymentMethodInitializeTokenizationSession implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime @@ -36720,13 +33489,7 @@ type PaymentMethodInitializeTokenizationSession implements Event @doc(category: paymentFlowToSupport: TokenizedPaymentFlowEnum! } -""" -Event sent when user continues a tokenization of payment method. - -Added in Saleor 3.16. - -Note: this API is currently in Feature Preview and can be subject to changes at later point. -""" +"""Event sent when user continues a tokenization of payment method.""" type PaymentMethodProcessTokenizationSession implements Event @doc(category: "Payments") { """Time of the event.""" issuedAt: DateTime diff --git a/graphql/subscriptions/order-filter-shipping-methods.graphql b/graphql/subscriptions/order-filter-shipping-methods.graphql new file mode 100644 index 00000000..b291ca14 --- /dev/null +++ b/graphql/subscriptions/order-filter-shipping-methods.graphql @@ -0,0 +1,5 @@ +subscription OrderFilterShippingMethodsSubscription { + event { + ...OrderFilterShippingMethodsPayload + } +} diff --git a/next.config.js b/next.config.js deleted file mode 100644 index 3dd7ef15..00000000 --- a/next.config.js +++ /dev/null @@ -1,4 +0,0 @@ -/** @type {import('next').NextConfig} */ -module.exports = { - reactStrictMode: true, -}; diff --git a/next.config.ts b/next.config.ts new file mode 100644 index 00000000..5ff973fd --- /dev/null +++ b/next.config.ts @@ -0,0 +1,7 @@ +import { NextConfig } from "next"; + +const config: NextConfig = { + reactStrictMode: true, +}; + +export default config; diff --git a/package.json b/package.json index 609ac639..86e38e83 100644 --- a/package.json +++ b/package.json @@ -3,41 +3,50 @@ "version": "1.0.0", "private": true, "license": "(BSD-3-Clause AND CC-BY-4.0)", + "type": "module", "scripts": { "dev": "NODE_OPTIONS='--inspect' next dev", "build": "next build", "start": "next start", "lint": "next lint", - "fetch-schema": "curl https://raw.githubusercontent.com/saleor/saleor/${npm_package_saleor_schemaVersion}/saleor/graphql/schema.graphql > graphql/schema.graphql", - "generate": "graphql-codegen", + "fetch-schema": "curl https://raw.githubusercontent.com/saleor/saleor/${npm_package_config_saleor_schemaVersion}/saleor/graphql/schema.graphql > graphql/schema.graphql", "test": "vitest", - "check-types": "tsc --noEmit" + "check-types": "tsc --noEmit", + "generate": "pnpm run /generate:.*/", + "generate:app-graphql-types": "graphql-codegen", + "generate:app-webhooks-types": "tsx ./scripts/generate-app-webhooks-types.ts" }, - "saleor": { - "schemaVersion": "3.20" + "config": { + "saleor": { + "schemaVersion": "3.21" + } }, "engines": { "npm": ">=10.0.0 <11.0.0", "node": ">=22.0.0 <23.0.0", - "pnpm": ">=9.0.0 <10.0.0" + "pnpm": ">=10.0.0 <11.0.0" }, "dependencies": { "@saleor/app-sdk": "1.0.0", "@saleor/macaw-ui": "1.1.10", "@urql/exchange-auth": "^1.0.0", - "@vitejs/plugin-react": "4.2.1", - "graphql": "^16.8.1", - "graphql-tag": "^2.12.6", - "jsdom": "^20.0.3", "next": "15.1.7", "react": "18.3.1", "react-dom": "18.3.1", - "urql": "^4.0.2", - "vite": "5.2.10", - "vitest": "1.5.2" + "urql": "^4.0.2" }, - "packageManager": "pnpm@9.12.3", + "packageManager": "pnpm@10.12.1", "devDependencies": { + "@vitejs/plugin-react": "4.2.1", + "graphql": "^16.8.1", + "graphql-tag": "^2.12.6", + "jsdom": "^20.0.3", + "vite": "5.2.10", + "vitest": "1.5.2", + "vite-tsconfig-paths": "5.1.4", + "tsx": "4.20.3", + "json-schema-to-typescript": "^15.0.4", + "@graphql-codegen/add": "3.2.0", "@graphql-codegen/cli": "3.3.1", "@graphql-codegen/introspection": "3.0.1", "@graphql-codegen/schema-ast": "^3.0.1", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 4d5f99f4..46d81764 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -10,28 +10,16 @@ importers: dependencies: '@saleor/app-sdk': specifier: 1.0.0 - version: 1.0.0(graphql@16.8.1)(next@15.1.7(@babel/core@7.24.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + version: 1.0.0(graphql@16.8.1)(next@15.1.7(@babel/core@7.23.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@saleor/macaw-ui': specifier: 1.1.10 version: 1.1.10(@types/react-dom@18.2.10)(@types/react@18.2.25)(@vanilla-extract/css@1.14.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@urql/exchange-auth': specifier: ^1.0.0 version: 1.0.0(graphql@16.8.1) - '@vitejs/plugin-react': - specifier: 4.2.1 - version: 4.2.1(vite@5.2.10(@types/node@18.18.3)) - graphql: - specifier: ^16.8.1 - version: 16.8.1 - graphql-tag: - specifier: ^2.12.6 - version: 2.12.6(graphql@16.8.1) - jsdom: - specifier: ^20.0.3 - version: 20.0.3 next: specifier: 15.1.7 - version: 15.1.7(@babel/core@7.24.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + version: 15.1.7(@babel/core@7.23.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) react: specifier: 18.3.1 version: 18.3.1 @@ -41,16 +29,13 @@ importers: urql: specifier: ^4.0.2 version: 4.0.5(graphql@16.8.1)(react@18.3.1) - vite: - specifier: 5.2.10 - version: 5.2.10(@types/node@18.18.3) - vitest: - specifier: 1.5.2 - version: 1.5.2(@types/node@18.18.3)(jsdom@20.0.3) devDependencies: + '@graphql-codegen/add': + specifier: 3.2.0 + version: 3.2.0(graphql@16.8.1) '@graphql-codegen/cli': specifier: 3.3.1 - version: 3.3.1(@babel/core@7.24.0)(@types/node@18.18.3)(enquirer@2.4.1)(graphql@16.8.1) + version: 3.3.1(@babel/core@7.23.0)(@types/node@18.18.3)(enquirer@2.4.1)(graphql@16.8.1) '@graphql-codegen/introspection': specifier: 3.0.1 version: 3.0.1(graphql@16.8.1) @@ -87,6 +72,9 @@ importers: '@types/react-dom': specifier: ^18.2.4 version: 18.2.10 + '@vitejs/plugin-react': + specifier: 4.2.1 + version: 4.2.1(vite@5.2.10(@types/node@18.18.3)) eslint: specifier: 8.31.0 version: 8.31.0 @@ -99,12 +87,36 @@ importers: eslint-plugin-simple-import-sort: specifier: 12.1.1 version: 12.1.1(eslint@8.31.0) + graphql: + specifier: ^16.8.1 + version: 16.8.1 + graphql-tag: + specifier: ^2.12.6 + version: 2.12.6(graphql@16.8.1) + jsdom: + specifier: ^20.0.3 + version: 20.0.3 + json-schema-to-typescript: + specifier: ^15.0.4 + version: 15.0.4 prettier: specifier: ^2.8.2 version: 2.8.8 + tsx: + specifier: 4.20.3 + version: 4.20.3 typescript: specifier: 5.0.4 version: 5.0.4 + vite: + specifier: 5.2.10 + version: 5.2.10(@types/node@18.18.3) + vite-tsconfig-paths: + specifier: 5.1.4 + version: 5.1.4(typescript@5.0.4)(vite@5.2.10(@types/node@18.18.3)) + vitest: + specifier: 1.5.2 + version: 1.5.2(@types/node@18.18.3)(jsdom@20.0.3) packages: @@ -124,6 +136,10 @@ packages: resolution: {integrity: sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg==} engines: {node: '>=6.0.0'} + '@apidevtools/json-schema-ref-parser@11.9.3': + resolution: {integrity: sha512-60vepv88RwcJtSHrD6MjIL6Ta3SOYbgfnkHb+ppAVK+o9mXprRtulx7VlRl3lN3bbvysAfCS7WMVfhUYemB0IQ==} + engines: {node: '>= 16'} + '@ardatan/relay-compiler@12.0.0': resolution: {integrity: sha512-9anThAaj1dQr6IGmzBMcfzOQKTa5artjuPmw8NYK/fiGEMjADbSguBY2FMDykt+QhilR3wc9VA/3yVju7JHg7Q==} hasBin: true @@ -573,138 +589,288 @@ packages: cpu: [ppc64] os: [aix] + '@esbuild/aix-ppc64@0.25.5': + resolution: {integrity: sha512-9o3TMmpmftaCMepOdA5k/yDw8SfInyzWWTjYTFCX3kPSDJMROQTb8jg+h9Cnwnmm1vOzvxN7gIfB5V2ewpjtGA==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [aix] + '@esbuild/android-arm64@0.20.2': resolution: {integrity: sha512-mRzjLacRtl/tWU0SvD8lUEwb61yP9cqQo6noDZP/O8VkwafSYwZ4yWy24kan8jE/IMERpYncRt2dw438LP3Xmg==} engines: {node: '>=12'} cpu: [arm64] os: [android] + '@esbuild/android-arm64@0.25.5': + resolution: {integrity: sha512-VGzGhj4lJO+TVGV1v8ntCZWJktV7SGCs3Pn1GRWI1SBFtRALoomm8k5E9Pmwg3HOAal2VDc2F9+PM/rEY6oIDg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [android] + '@esbuild/android-arm@0.20.2': resolution: {integrity: sha512-t98Ra6pw2VaDhqNWO2Oph2LXbz/EJcnLmKLGBJwEwXX/JAN83Fym1rU8l0JUWK6HkIbWONCSSatf4sf2NBRx/w==} engines: {node: '>=12'} cpu: [arm] os: [android] + '@esbuild/android-arm@0.25.5': + resolution: {integrity: sha512-AdJKSPeEHgi7/ZhuIPtcQKr5RQdo6OO2IL87JkianiMYMPbCtot9fxPbrMiBADOWWm3T2si9stAiVsGbTQFkbA==} + engines: {node: '>=18'} + cpu: [arm] + os: [android] + '@esbuild/android-x64@0.20.2': resolution: {integrity: sha512-btzExgV+/lMGDDa194CcUQm53ncxzeBrWJcncOBxuC6ndBkKxnHdFJn86mCIgTELsooUmwUm9FkhSp5HYu00Rg==} engines: {node: '>=12'} cpu: [x64] os: [android] + '@esbuild/android-x64@0.25.5': + resolution: {integrity: sha512-D2GyJT1kjvO//drbRT3Hib9XPwQeWd9vZoBJn+bu/lVsOZ13cqNdDeqIF/xQ5/VmWvMduP6AmXvylO/PIc2isw==} + engines: {node: '>=18'} + cpu: [x64] + os: [android] + '@esbuild/darwin-arm64@0.20.2': resolution: {integrity: sha512-4J6IRT+10J3aJH3l1yzEg9y3wkTDgDk7TSDFX+wKFiWjqWp/iCfLIYzGyasx9l0SAFPT1HwSCR+0w/h1ES/MjA==} engines: {node: '>=12'} cpu: [arm64] os: [darwin] + '@esbuild/darwin-arm64@0.25.5': + resolution: {integrity: sha512-GtaBgammVvdF7aPIgH2jxMDdivezgFu6iKpmT+48+F8Hhg5J/sfnDieg0aeG/jfSvkYQU2/pceFPDKlqZzwnfQ==} + engines: {node: '>=18'} + cpu: [arm64] + os: [darwin] + '@esbuild/darwin-x64@0.20.2': resolution: {integrity: sha512-tBcXp9KNphnNH0dfhv8KYkZhjc+H3XBkF5DKtswJblV7KlT9EI2+jeA8DgBjp908WEuYll6pF+UStUCfEpdysA==} engines: {node: '>=12'} cpu: [x64] os: [darwin] + '@esbuild/darwin-x64@0.25.5': + resolution: {integrity: sha512-1iT4FVL0dJ76/q1wd7XDsXrSW+oLoquptvh4CLR4kITDtqi2e/xwXwdCVH8hVHU43wgJdsq7Gxuzcs6Iq/7bxQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [darwin] + '@esbuild/freebsd-arm64@0.20.2': resolution: {integrity: sha512-d3qI41G4SuLiCGCFGUrKsSeTXyWG6yem1KcGZVS+3FYlYhtNoNgYrWcvkOoaqMhwXSMrZRl69ArHsGJ9mYdbbw==} engines: {node: '>=12'} cpu: [arm64] os: [freebsd] + '@esbuild/freebsd-arm64@0.25.5': + resolution: {integrity: sha512-nk4tGP3JThz4La38Uy/gzyXtpkPW8zSAmoUhK9xKKXdBCzKODMc2adkB2+8om9BDYugz+uGV7sLmpTYzvmz6Sw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [freebsd] + '@esbuild/freebsd-x64@0.20.2': resolution: {integrity: sha512-d+DipyvHRuqEeM5zDivKV1KuXn9WeRX6vqSqIDgwIfPQtwMP4jaDsQsDncjTDDsExT4lR/91OLjRo8bmC1e+Cw==} engines: {node: '>=12'} cpu: [x64] os: [freebsd] + '@esbuild/freebsd-x64@0.25.5': + resolution: {integrity: sha512-PrikaNjiXdR2laW6OIjlbeuCPrPaAl0IwPIaRv+SMV8CiM8i2LqVUHFC1+8eORgWyY7yhQY+2U2fA55mBzReaw==} + engines: {node: '>=18'} + cpu: [x64] + os: [freebsd] + '@esbuild/linux-arm64@0.20.2': resolution: {integrity: sha512-9pb6rBjGvTFNira2FLIWqDk/uaf42sSyLE8j1rnUpuzsODBq7FvpwHYZxQ/It/8b+QOS1RYfqgGFNLRI+qlq2A==} engines: {node: '>=12'} cpu: [arm64] os: [linux] + '@esbuild/linux-arm64@0.25.5': + resolution: {integrity: sha512-Z9kfb1v6ZlGbWj8EJk9T6czVEjjq2ntSYLY2cw6pAZl4oKtfgQuS4HOq41M/BcoLPzrUbNd+R4BXFyH//nHxVg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [linux] + '@esbuild/linux-arm@0.20.2': resolution: {integrity: sha512-VhLPeR8HTMPccbuWWcEUD1Az68TqaTYyj6nfE4QByZIQEQVWBB8vup8PpR7y1QHL3CpcF6xd5WVBU/+SBEvGTg==} engines: {node: '>=12'} cpu: [arm] os: [linux] + '@esbuild/linux-arm@0.25.5': + resolution: {integrity: sha512-cPzojwW2okgh7ZlRpcBEtsX7WBuqbLrNXqLU89GxWbNt6uIg78ET82qifUy3W6OVww6ZWobWub5oqZOVtwolfw==} + engines: {node: '>=18'} + cpu: [arm] + os: [linux] + '@esbuild/linux-ia32@0.20.2': resolution: {integrity: sha512-o10utieEkNPFDZFQm9CoP7Tvb33UutoJqg3qKf1PWVeeJhJw0Q347PxMvBgVVFgouYLGIhFYG0UGdBumROyiig==} engines: {node: '>=12'} cpu: [ia32] os: [linux] + '@esbuild/linux-ia32@0.25.5': + resolution: {integrity: sha512-sQ7l00M8bSv36GLV95BVAdhJ2QsIbCuCjh/uYrWiMQSUuV+LpXwIqhgJDcvMTj+VsQmqAHL2yYaasENvJ7CDKA==} + engines: {node: '>=18'} + cpu: [ia32] + os: [linux] + '@esbuild/linux-loong64@0.20.2': resolution: {integrity: sha512-PR7sp6R/UC4CFVomVINKJ80pMFlfDfMQMYynX7t1tNTeivQ6XdX5r2XovMmha/VjR1YN/HgHWsVcTRIMkymrgQ==} engines: {node: '>=12'} cpu: [loong64] os: [linux] + '@esbuild/linux-loong64@0.25.5': + resolution: {integrity: sha512-0ur7ae16hDUC4OL5iEnDb0tZHDxYmuQyhKhsPBV8f99f6Z9KQM02g33f93rNH5A30agMS46u2HP6qTdEt6Q1kg==} + engines: {node: '>=18'} + cpu: [loong64] + os: [linux] + '@esbuild/linux-mips64el@0.20.2': resolution: {integrity: sha512-4BlTqeutE/KnOiTG5Y6Sb/Hw6hsBOZapOVF6njAESHInhlQAghVVZL1ZpIctBOoTFbQyGW+LsVYZ8lSSB3wkjA==} engines: {node: '>=12'} cpu: [mips64el] os: [linux] + '@esbuild/linux-mips64el@0.25.5': + resolution: {integrity: sha512-kB/66P1OsHO5zLz0i6X0RxlQ+3cu0mkxS3TKFvkb5lin6uwZ/ttOkP3Z8lfR9mJOBk14ZwZ9182SIIWFGNmqmg==} + engines: {node: '>=18'} + cpu: [mips64el] + os: [linux] + '@esbuild/linux-ppc64@0.20.2': resolution: {integrity: sha512-rD3KsaDprDcfajSKdn25ooz5J5/fWBylaaXkuotBDGnMnDP1Uv5DLAN/45qfnf3JDYyJv/ytGHQaziHUdyzaAg==} engines: {node: '>=12'} cpu: [ppc64] os: [linux] + '@esbuild/linux-ppc64@0.25.5': + resolution: {integrity: sha512-UZCmJ7r9X2fe2D6jBmkLBMQetXPXIsZjQJCjgwpVDz+YMcS6oFR27alkgGv3Oqkv07bxdvw7fyB71/olceJhkQ==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [linux] + '@esbuild/linux-riscv64@0.20.2': resolution: {integrity: sha512-snwmBKacKmwTMmhLlz/3aH1Q9T8v45bKYGE3j26TsaOVtjIag4wLfWSiZykXzXuE1kbCE+zJRmwp+ZbIHinnVg==} engines: {node: '>=12'} cpu: [riscv64] os: [linux] + '@esbuild/linux-riscv64@0.25.5': + resolution: {integrity: sha512-kTxwu4mLyeOlsVIFPfQo+fQJAV9mh24xL+y+Bm6ej067sYANjyEw1dNHmvoqxJUCMnkBdKpvOn0Ahql6+4VyeA==} + engines: {node: '>=18'} + cpu: [riscv64] + os: [linux] + '@esbuild/linux-s390x@0.20.2': resolution: {integrity: sha512-wcWISOobRWNm3cezm5HOZcYz1sKoHLd8VL1dl309DiixxVFoFe/o8HnwuIwn6sXre88Nwj+VwZUvJf4AFxkyrQ==} engines: {node: '>=12'} cpu: [s390x] os: [linux] + '@esbuild/linux-s390x@0.25.5': + resolution: {integrity: sha512-K2dSKTKfmdh78uJ3NcWFiqyRrimfdinS5ErLSn3vluHNeHVnBAFWC8a4X5N+7FgVE1EjXS1QDZbpqZBjfrqMTQ==} + engines: {node: '>=18'} + cpu: [s390x] + os: [linux] + '@esbuild/linux-x64@0.20.2': resolution: {integrity: sha512-1MdwI6OOTsfQfek8sLwgyjOXAu+wKhLEoaOLTjbijk6E2WONYpH9ZU2mNtR+lZ2B4uwr+usqGuVfFT9tMtGvGw==} engines: {node: '>=12'} cpu: [x64] os: [linux] + '@esbuild/linux-x64@0.25.5': + resolution: {integrity: sha512-uhj8N2obKTE6pSZ+aMUbqq+1nXxNjZIIjCjGLfsWvVpy7gKCOL6rsY1MhRh9zLtUtAI7vpgLMK6DxjO8Qm9lJw==} + engines: {node: '>=18'} + cpu: [x64] + os: [linux] + + '@esbuild/netbsd-arm64@0.25.5': + resolution: {integrity: sha512-pwHtMP9viAy1oHPvgxtOv+OkduK5ugofNTVDilIzBLpoWAM16r7b/mxBvfpuQDpRQFMfuVr5aLcn4yveGvBZvw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [netbsd] + '@esbuild/netbsd-x64@0.20.2': resolution: {integrity: sha512-K8/DhBxcVQkzYc43yJXDSyjlFeHQJBiowJ0uVL6Tor3jGQfSGHNNJcWxNbOI8v5k82prYqzPuwkzHt3J1T1iZQ==} engines: {node: '>=12'} cpu: [x64] os: [netbsd] + '@esbuild/netbsd-x64@0.25.5': + resolution: {integrity: sha512-WOb5fKrvVTRMfWFNCroYWWklbnXH0Q5rZppjq0vQIdlsQKuw6mdSihwSo4RV/YdQ5UCKKvBy7/0ZZYLBZKIbwQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [netbsd] + + '@esbuild/openbsd-arm64@0.25.5': + resolution: {integrity: sha512-7A208+uQKgTxHd0G0uqZO8UjK2R0DDb4fDmERtARjSHWxqMTye4Erz4zZafx7Di9Cv+lNHYuncAkiGFySoD+Mw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] + '@esbuild/openbsd-x64@0.20.2': resolution: {integrity: sha512-eMpKlV0SThJmmJgiVyN9jTPJ2VBPquf6Kt/nAoo6DgHAoN57K15ZghiHaMvqjCye/uU4X5u3YSMgVBI1h3vKrQ==} engines: {node: '>=12'} cpu: [x64] os: [openbsd] + '@esbuild/openbsd-x64@0.25.5': + resolution: {integrity: sha512-G4hE405ErTWraiZ8UiSoesH8DaCsMm0Cay4fsFWOOUcz8b8rC6uCvnagr+gnioEjWn0wC+o1/TAHt+It+MpIMg==} + engines: {node: '>=18'} + cpu: [x64] + os: [openbsd] + '@esbuild/sunos-x64@0.20.2': resolution: {integrity: sha512-2UyFtRC6cXLyejf/YEld4Hajo7UHILetzE1vsRcGL3earZEW77JxrFjH4Ez2qaTiEfMgAXxfAZCm1fvM/G/o8w==} engines: {node: '>=12'} cpu: [x64] os: [sunos] + '@esbuild/sunos-x64@0.25.5': + resolution: {integrity: sha512-l+azKShMy7FxzY0Rj4RCt5VD/q8mG/e+mDivgspo+yL8zW7qEwctQ6YqKX34DTEleFAvCIUviCFX1SDZRSyMQA==} + engines: {node: '>=18'} + cpu: [x64] + os: [sunos] + '@esbuild/win32-arm64@0.20.2': resolution: {integrity: sha512-GRibxoawM9ZCnDxnP3usoUDO9vUkpAxIIZ6GQI+IlVmr5kP3zUq+l17xELTHMWTWzjxa2guPNyrpq1GWmPvcGQ==} engines: {node: '>=12'} cpu: [arm64] os: [win32] + '@esbuild/win32-arm64@0.25.5': + resolution: {integrity: sha512-O2S7SNZzdcFG7eFKgvwUEZ2VG9D/sn/eIiz8XRZ1Q/DO5a3s76Xv0mdBzVM5j5R639lXQmPmSo0iRpHqUUrsxw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [win32] + '@esbuild/win32-ia32@0.20.2': resolution: {integrity: sha512-HfLOfn9YWmkSKRQqovpnITazdtquEW8/SoHW7pWpuEeguaZI4QnCRW6b+oZTztdBnZOS2hqJ6im/D5cPzBTTlQ==} engines: {node: '>=12'} cpu: [ia32] os: [win32] + '@esbuild/win32-ia32@0.25.5': + resolution: {integrity: sha512-onOJ02pqs9h1iMJ1PQphR+VZv8qBMQ77Klcsqv9CNW2w6yLqoURLcgERAIurY6QE63bbLuqgP9ATqajFLK5AMQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [win32] + '@esbuild/win32-x64@0.20.2': resolution: {integrity: sha512-N49X4lJX27+l9jbLKSqZ6bKNjzQvHaT8IIFUy+YIqmXQdjYCToGWwOItDrfby14c78aDd5NHQl29xingXfCdLQ==} engines: {node: '>=12'} cpu: [x64] os: [win32] + '@esbuild/win32-x64@0.25.5': + resolution: {integrity: sha512-TXv6YnJ8ZMVdX+SXWVBo/0p8LTcrUYngpWjvm91TMjjBQii7Oz11Lw5lbDV5Y0TzuhSJHwiH4hEtC1I42mMS0g==} + engines: {node: '>=18'} + cpu: [x64] + os: [win32] + '@eslint-community/eslint-utils@4.4.0': resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -730,6 +896,11 @@ packages: '@floating-ui/utils@0.1.6': resolution: {integrity: sha512-OfX7E2oUDYxtBvsuS4e/jSn4Q9Qb6DzgeYtsAdkPZ47znpoNsMgZw0+tVijiv3uGNR6dgNlty6r9rzIzHjtd/A==} + '@graphql-codegen/add@3.2.0': + resolution: {integrity: sha512-8hyr5XvTDGnpiT4nH2yH8PP4SWtUEIUdkFaZbkpkFkU0Ud9dplvSviOCdxdArffZ1FHy0XYLTMa2it+UJOtszg==} + peerDependencies: + graphql: ^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0 + '@graphql-codegen/cli@3.3.1': resolution: {integrity: sha512-4Es8Y9zFeT0Zx2qRL7L3qXDbbqvXK6aID+8v8lP6gaYD+uWx3Jd4Hsq5vxwVBR+6flm0BW/C85Qm0cvmT7O6LA==} hasBin: true @@ -1062,6 +1233,9 @@ packages: '@jridgewell/trace-mapping@0.3.19': resolution: {integrity: sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==} + '@jsdevtools/ono@7.1.3': + resolution: {integrity: sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==} + '@manypkg/find-root@1.1.0': resolution: {integrity: sha512-mki5uBvhHzO8kYYix/WRy2WX8S3B5wdVSc9D6KcU5lQNglP2yt58/VfLuAK49glRXChosY8ap2oJ1qgma3GUVA==} @@ -1766,6 +1940,9 @@ packages: '@types/json5@0.0.29': resolution: {integrity: sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==} + '@types/lodash@4.17.17': + resolution: {integrity: sha512-RRVJ+J3J+WmyOTqnz3PiBLA501eKwXl2noseKOrNo/6+XEHjTAxO4xHvxQB6QuNm+s4WRbn6rSiap8+EA+ykFQ==} + '@types/node@12.20.55': resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} @@ -2457,6 +2634,11 @@ packages: engines: {node: '>=12'} hasBin: true + esbuild@0.25.5: + resolution: {integrity: sha512-P8OtKZRv/5J5hhz0cUAdu/cLuPIKXpQl1R9pZtvmHWQvrAUVd0UNIPT4IB4W3rNOqVO0rlqHmCIbSwxh/c9yUQ==} + engines: {node: '>=18'} + hasBin: true + escalade@3.1.1: resolution: {integrity: sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==} engines: {node: '>=6'} @@ -2662,6 +2844,14 @@ packages: fbjs@3.0.5: resolution: {integrity: sha512-ztsSx77JBtkuMrEypfhgc3cI0+0h+svqeie7xHbh1k/IKdcydnvadp/mUaGgjAOXQmQSxsqgaRhS3q9fy+1kxg==} + fdir@6.4.6: + resolution: {integrity: sha512-hiFoqpyZcfNm1yc4u8oWCf9A2c4D3QjCrks3zmoVKVxpQRzmPNar1hUJcBG2RQHvEVGDN+Jm81ZheVLAQMK6+w==} + peerDependencies: + picomatch: ^3 || ^4 + peerDependenciesMeta: + picomatch: + optional: true + figures@3.2.0: resolution: {integrity: sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg==} engines: {node: '>=8'} @@ -2748,6 +2938,9 @@ packages: resolution: {integrity: sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==} engines: {node: '>= 0.4'} + get-tsconfig@4.10.1: + resolution: {integrity: sha512-auHyJ4AgMz7vgS8Hp3N6HXSmlMdUyhSUrfBF16w153rxtLIEOE+HGqaBppczZvnHLqQJfiHotCYpNhl0lUROFQ==} + get-tsconfig@4.7.2: resolution: {integrity: sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A==} @@ -2783,6 +2976,9 @@ packages: resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} engines: {node: '>=10'} + globrex@0.1.2: + resolution: {integrity: sha512-uHJgbwAMwNFf5mLst7IWLNg14x1CkeqglJb/K3doi4dw6q2IvAAmM/Y81kevy83wP+Sst+nutFTYOGg3d1lsxg==} + gopd@1.0.1: resolution: {integrity: sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==} @@ -3146,6 +3342,11 @@ packages: json-parse-even-better-errors@2.3.1: resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==} + json-schema-to-typescript@15.0.4: + resolution: {integrity: sha512-Su9oK8DR4xCmDsLlyvadkXzX6+GGXJpbhwoLtOGArAG61dvbW4YQmSEno2y66ahpIdmLMg6YUf/QHLgiwvkrHQ==} + engines: {node: '>=16.0.0'} + hasBin: true + json-schema-traverse@0.4.1: resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} @@ -3569,6 +3770,10 @@ packages: resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} engines: {node: '>=8.6'} + picomatch@4.0.2: + resolution: {integrity: sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg==} + engines: {node: '>=12'} + pify@4.0.1: resolution: {integrity: sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==} engines: {node: '>=6'} @@ -3593,6 +3798,11 @@ packages: engines: {node: '>=10.13.0'} hasBin: true + prettier@3.5.3: + resolution: {integrity: sha512-QQtaxnoDJeAkDvDKWCLiwIXkTgRhwYDEQCghU9Z6q03iyek/rxRh/2lC3HB7P8sWT2xC/y5JDctPLBIGzHKbhw==} + engines: {node: '>=14'} + hasBin: true + pretty-format@29.7.0: resolution: {integrity: sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} @@ -4014,6 +4224,10 @@ packages: tinybench@2.8.0: resolution: {integrity: sha512-1/eK7zUnIklz4JUUlL+658n58XO2hHLQfSk1Zf2LKieUjxidN16eKFEoDEfjHc3ohofSSqK3X5yO6VGb6iW8Lw==} + tinyglobby@0.2.14: + resolution: {integrity: sha512-tX5e7OM1HnYr2+a2C/4V0htOcSQcoSTH9KgJnVvNm5zm/cyEWKJ7j7YutsH9CxMdtOkkLFy2AHrMci9IM8IPZQ==} + engines: {node: '>=12.0.0'} + tinypool@0.8.4: resolution: {integrity: sha512-i11VH5gS6IFeLY3gMBQ00/MmLncVP7JLXOw1vlgkytLmJK7QnEr7NXf0LBdxfmNPAeyetukOk0bOYrJrFGjYJQ==} engines: {node: '>=14.0.0'} @@ -4055,6 +4269,16 @@ packages: ts-log@2.2.5: resolution: {integrity: sha512-PGcnJoTBnVGy6yYNFxWVNkdcAuAMstvutN9MgDJIV6L0oG8fB+ZNNy1T+wJzah8RPGor1mZuPQkVfXNDpy9eHA==} + tsconfck@3.1.6: + resolution: {integrity: sha512-ks6Vjr/jEw0P1gmOVwutM3B7fWxoWBL2KRDb1JfqGVawBmO5UsvmWOQFGHBPl5yxYz4eERr19E6L7NMv+Fej4w==} + engines: {node: ^18 || >=20} + hasBin: true + peerDependencies: + typescript: ^5.0.0 + peerDependenciesMeta: + typescript: + optional: true + tsconfig-paths@3.14.2: resolution: {integrity: sha512-o/9iXgCYc5L/JxCHPe3Hvh8Q/2xm5Z+p18PESBU6Ff33695QnCHBEjcytY2q19ua7Mbl/DavtBOLq+oG0RCL+g==} @@ -4079,6 +4303,11 @@ packages: peerDependencies: typescript: '>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta' + tsx@4.20.3: + resolution: {integrity: sha512-qjbnuR9Tr+FJOMBqJCW5ehvIo/buZq7vH7qD7JziU98h6l3qGy0a/yPFjwO+y0/T7GFpNgNAvEcPPVfyT8rrPQ==} + engines: {node: '>=18.0.0'} + hasBin: true + type-check@0.4.0: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} engines: {node: '>= 0.8.0'} @@ -4207,6 +4436,14 @@ packages: engines: {node: ^18.0.0 || >=20.0.0} hasBin: true + vite-tsconfig-paths@5.1.4: + resolution: {integrity: sha512-cYj0LRuLV2c2sMqhqhGpaO3LretdtMn/BVX4cPLanIZuwwrkVl+lK84E/miEXkCHWXuq65rhNN4rXsBcOB3S4w==} + peerDependencies: + vite: '*' + peerDependenciesMeta: + vite: + optional: true + vite@5.2.10: resolution: {integrity: sha512-PAzgUZbP7msvQvqdSD+ErD5qGnSFiGOoWmV5yAKUEI0kdhjbH6nMWVyZQC/hSc4aXwc0oJ9aEdIiF9Oje0JFCw==} engines: {node: ^18.0.0 || >=20.0.0} @@ -4432,6 +4669,12 @@ snapshots: '@jridgewell/gen-mapping': 0.3.3 '@jridgewell/trace-mapping': 0.3.19 + '@apidevtools/json-schema-ref-parser@11.9.3': + dependencies: + '@jsdevtools/ono': 7.1.3 + '@types/json-schema': 7.0.15 + js-yaml: 4.1.0 + '@ardatan/relay-compiler@12.0.0(graphql@16.8.1)': dependencies: '@babel/core': 7.23.0 @@ -4696,9 +4939,9 @@ snapshots: '@babel/core': 7.23.0 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-import-assertions@7.22.5(@babel/core@7.24.0)': + '@babel/plugin-syntax-import-assertions@7.22.5(@babel/core@7.23.0)': dependencies: - '@babel/core': 7.24.0 + '@babel/core': 7.23.0 '@babel/helper-plugin-utils': 7.22.5 '@babel/plugin-syntax-jsx@7.22.5(@babel/core@7.23.0)': @@ -5068,72 +5311,147 @@ snapshots: '@esbuild/aix-ppc64@0.20.2': optional: true + '@esbuild/aix-ppc64@0.25.5': + optional: true + '@esbuild/android-arm64@0.20.2': optional: true + '@esbuild/android-arm64@0.25.5': + optional: true + '@esbuild/android-arm@0.20.2': optional: true + '@esbuild/android-arm@0.25.5': + optional: true + '@esbuild/android-x64@0.20.2': optional: true + '@esbuild/android-x64@0.25.5': + optional: true + '@esbuild/darwin-arm64@0.20.2': optional: true + '@esbuild/darwin-arm64@0.25.5': + optional: true + '@esbuild/darwin-x64@0.20.2': optional: true + '@esbuild/darwin-x64@0.25.5': + optional: true + '@esbuild/freebsd-arm64@0.20.2': optional: true + '@esbuild/freebsd-arm64@0.25.5': + optional: true + '@esbuild/freebsd-x64@0.20.2': optional: true + '@esbuild/freebsd-x64@0.25.5': + optional: true + '@esbuild/linux-arm64@0.20.2': optional: true + '@esbuild/linux-arm64@0.25.5': + optional: true + '@esbuild/linux-arm@0.20.2': optional: true + '@esbuild/linux-arm@0.25.5': + optional: true + '@esbuild/linux-ia32@0.20.2': optional: true + '@esbuild/linux-ia32@0.25.5': + optional: true + '@esbuild/linux-loong64@0.20.2': optional: true + '@esbuild/linux-loong64@0.25.5': + optional: true + '@esbuild/linux-mips64el@0.20.2': optional: true + '@esbuild/linux-mips64el@0.25.5': + optional: true + '@esbuild/linux-ppc64@0.20.2': optional: true + '@esbuild/linux-ppc64@0.25.5': + optional: true + '@esbuild/linux-riscv64@0.20.2': optional: true + '@esbuild/linux-riscv64@0.25.5': + optional: true + '@esbuild/linux-s390x@0.20.2': optional: true + '@esbuild/linux-s390x@0.25.5': + optional: true + '@esbuild/linux-x64@0.20.2': optional: true + '@esbuild/linux-x64@0.25.5': + optional: true + + '@esbuild/netbsd-arm64@0.25.5': + optional: true + '@esbuild/netbsd-x64@0.20.2': optional: true + '@esbuild/netbsd-x64@0.25.5': + optional: true + + '@esbuild/openbsd-arm64@0.25.5': + optional: true + '@esbuild/openbsd-x64@0.20.2': optional: true + '@esbuild/openbsd-x64@0.25.5': + optional: true + '@esbuild/sunos-x64@0.20.2': optional: true + '@esbuild/sunos-x64@0.25.5': + optional: true + '@esbuild/win32-arm64@0.20.2': optional: true + '@esbuild/win32-arm64@0.25.5': + optional: true + '@esbuild/win32-ia32@0.20.2': optional: true + '@esbuild/win32-ia32@0.25.5': + optional: true + '@esbuild/win32-x64@0.20.2': optional: true + '@esbuild/win32-x64@0.25.5': + optional: true + '@eslint-community/eslint-utils@4.4.0(eslint@8.31.0)': dependencies: eslint: 8.31.0 @@ -5170,7 +5488,13 @@ snapshots: '@floating-ui/utils@0.1.6': {} - '@graphql-codegen/cli@3.3.1(@babel/core@7.24.0)(@types/node@18.18.3)(enquirer@2.4.1)(graphql@16.8.1)': + '@graphql-codegen/add@3.2.0(graphql@16.8.1)': + dependencies: + '@graphql-codegen/plugin-helpers': 2.7.2(graphql@16.8.1) + graphql: 16.8.1 + tslib: 2.4.1 + + '@graphql-codegen/cli@3.3.1(@babel/core@7.23.0)(@types/node@18.18.3)(enquirer@2.4.1)(graphql@16.8.1)': dependencies: '@babel/generator': 7.23.0 '@babel/template': 7.22.15 @@ -5178,9 +5502,9 @@ snapshots: '@graphql-codegen/core': 3.1.0(graphql@16.8.1) '@graphql-codegen/plugin-helpers': 4.2.0(graphql@16.8.1) '@graphql-tools/apollo-engine-loader': 7.3.26(graphql@16.8.1) - '@graphql-tools/code-file-loader': 7.3.23(@babel/core@7.24.0)(graphql@16.8.1) - '@graphql-tools/git-loader': 7.3.0(@babel/core@7.24.0)(graphql@16.8.1) - '@graphql-tools/github-loader': 7.3.28(@babel/core@7.24.0)(@types/node@18.18.3)(graphql@16.8.1) + '@graphql-tools/code-file-loader': 7.3.23(@babel/core@7.23.0)(graphql@16.8.1) + '@graphql-tools/git-loader': 7.3.0(@babel/core@7.23.0)(graphql@16.8.1) + '@graphql-tools/github-loader': 7.3.28(@babel/core@7.23.0)(@types/node@18.18.3)(graphql@16.8.1) '@graphql-tools/graphql-file-loader': 7.5.17(graphql@16.8.1) '@graphql-tools/json-file-loader': 7.4.18(graphql@16.8.1) '@graphql-tools/load': 7.8.14(graphql@16.8.1) @@ -5370,9 +5694,9 @@ snapshots: tslib: 2.6.2 value-or-promise: 1.0.12 - '@graphql-tools/code-file-loader@7.3.23(@babel/core@7.24.0)(graphql@16.8.1)': + '@graphql-tools/code-file-loader@7.3.23(@babel/core@7.23.0)(graphql@16.8.1)': dependencies: - '@graphql-tools/graphql-tag-pluck': 7.5.2(@babel/core@7.24.0)(graphql@16.8.1) + '@graphql-tools/graphql-tag-pluck': 7.5.2(@babel/core@7.23.0)(graphql@16.8.1) '@graphql-tools/utils': 9.2.1(graphql@16.8.1) globby: 11.1.0 graphql: 16.8.1 @@ -5442,9 +5766,9 @@ snapshots: tslib: 2.6.2 value-or-promise: 1.0.12 - '@graphql-tools/git-loader@7.3.0(@babel/core@7.24.0)(graphql@16.8.1)': + '@graphql-tools/git-loader@7.3.0(@babel/core@7.23.0)(graphql@16.8.1)': dependencies: - '@graphql-tools/graphql-tag-pluck': 7.5.2(@babel/core@7.24.0)(graphql@16.8.1) + '@graphql-tools/graphql-tag-pluck': 7.5.2(@babel/core@7.23.0)(graphql@16.8.1) '@graphql-tools/utils': 9.2.1(graphql@16.8.1) graphql: 16.8.1 is-glob: 4.0.3 @@ -5455,11 +5779,11 @@ snapshots: - '@babel/core' - supports-color - '@graphql-tools/github-loader@7.3.28(@babel/core@7.24.0)(@types/node@18.18.3)(graphql@16.8.1)': + '@graphql-tools/github-loader@7.3.28(@babel/core@7.23.0)(@types/node@18.18.3)(graphql@16.8.1)': dependencies: '@ardatan/sync-fetch': 0.0.1 '@graphql-tools/executor-http': 0.1.10(@types/node@18.18.3)(graphql@16.8.1) - '@graphql-tools/graphql-tag-pluck': 7.5.2(@babel/core@7.24.0)(graphql@16.8.1) + '@graphql-tools/graphql-tag-pluck': 7.5.2(@babel/core@7.23.0)(graphql@16.8.1) '@graphql-tools/utils': 9.2.1(graphql@16.8.1) '@whatwg-node/fetch': 0.8.8 graphql: 16.8.1 @@ -5480,10 +5804,10 @@ snapshots: tslib: 2.6.2 unixify: 1.0.0 - '@graphql-tools/graphql-tag-pluck@7.5.2(@babel/core@7.24.0)(graphql@16.8.1)': + '@graphql-tools/graphql-tag-pluck@7.5.2(@babel/core@7.23.0)(graphql@16.8.1)': dependencies: '@babel/parser': 7.23.0 - '@babel/plugin-syntax-import-assertions': 7.22.5(@babel/core@7.24.0) + '@babel/plugin-syntax-import-assertions': 7.22.5(@babel/core@7.23.0) '@babel/traverse': 7.23.0 '@babel/types': 7.23.0 '@graphql-tools/utils': 9.2.1(graphql@16.8.1) @@ -5727,6 +6051,8 @@ snapshots: '@jridgewell/resolve-uri': 3.1.1 '@jridgewell/sourcemap-codec': 1.4.15 + '@jsdevtools/ono@7.1.3': {} + '@manypkg/find-root@1.1.0': dependencies: '@babel/runtime': 7.25.6 @@ -6341,14 +6667,14 @@ snapshots: '@rushstack/eslint-patch@1.5.1': {} - '@saleor/app-sdk@1.0.0(graphql@16.8.1)(next@15.1.7(@babel/core@7.24.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': + '@saleor/app-sdk@1.0.0(graphql@16.8.1)(next@15.1.7(@babel/core@7.23.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1))(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/semantic-conventions': 1.30.0 debug: 4.4.0 graphql: 16.8.1 jose: 5.10.0 - next: 15.1.7(@babel/core@7.24.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + next: 15.1.7(@babel/core@7.23.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) raw-body: 3.0.0 react: 18.3.1 react-dom: 18.3.1(react@18.3.1) @@ -6429,6 +6755,8 @@ snapshots: '@types/json5@0.0.29': {} + '@types/lodash@4.17.17': {} + '@types/node@12.20.55': {} '@types/node@18.18.3': {} @@ -6755,7 +7083,7 @@ snapshots: dependencies: pvtsutils: 1.3.5 pvutils: 1.1.3 - tslib: 2.6.2 + tslib: 2.8.1 assertion-error@1.1.0: {} @@ -7316,6 +7644,34 @@ snapshots: '@esbuild/win32-ia32': 0.20.2 '@esbuild/win32-x64': 0.20.2 + esbuild@0.25.5: + optionalDependencies: + '@esbuild/aix-ppc64': 0.25.5 + '@esbuild/android-arm': 0.25.5 + '@esbuild/android-arm64': 0.25.5 + '@esbuild/android-x64': 0.25.5 + '@esbuild/darwin-arm64': 0.25.5 + '@esbuild/darwin-x64': 0.25.5 + '@esbuild/freebsd-arm64': 0.25.5 + '@esbuild/freebsd-x64': 0.25.5 + '@esbuild/linux-arm': 0.25.5 + '@esbuild/linux-arm64': 0.25.5 + '@esbuild/linux-ia32': 0.25.5 + '@esbuild/linux-loong64': 0.25.5 + '@esbuild/linux-mips64el': 0.25.5 + '@esbuild/linux-ppc64': 0.25.5 + '@esbuild/linux-riscv64': 0.25.5 + '@esbuild/linux-s390x': 0.25.5 + '@esbuild/linux-x64': 0.25.5 + '@esbuild/netbsd-arm64': 0.25.5 + '@esbuild/netbsd-x64': 0.25.5 + '@esbuild/openbsd-arm64': 0.25.5 + '@esbuild/openbsd-x64': 0.25.5 + '@esbuild/sunos-x64': 0.25.5 + '@esbuild/win32-arm64': 0.25.5 + '@esbuild/win32-ia32': 0.25.5 + '@esbuild/win32-x64': 0.25.5 + escalade@3.1.1: {} escape-string-regexp@1.0.5: {} @@ -7620,6 +7976,10 @@ snapshots: transitivePeerDependencies: - encoding + fdir@6.4.6(picomatch@4.0.2): + optionalDependencies: + picomatch: 4.0.2 + figures@3.2.0: dependencies: escape-string-regexp: 1.0.5 @@ -7710,6 +8070,10 @@ snapshots: call-bind: 1.0.2 get-intrinsic: 1.2.1 + get-tsconfig@4.10.1: + dependencies: + resolve-pkg-maps: 1.0.0 + get-tsconfig@4.7.2: dependencies: resolve-pkg-maps: 1.0.0 @@ -7759,6 +8123,8 @@ snapshots: merge2: 1.4.1 slash: 3.0.0 + globrex@0.1.2: {} + gopd@1.0.1: dependencies: get-intrinsic: 1.2.1 @@ -8149,6 +8515,18 @@ snapshots: json-parse-even-better-errors@2.3.1: {} + json-schema-to-typescript@15.0.4: + dependencies: + '@apidevtools/json-schema-ref-parser': 11.9.3 + '@types/json-schema': 7.0.15 + '@types/lodash': 4.17.17 + is-glob: 4.0.3 + js-yaml: 4.1.0 + lodash: 4.17.21 + minimist: 1.2.8 + prettier: 3.5.3 + tinyglobby: 0.2.14 + json-schema-traverse@0.4.1: {} json-stable-stringify-without-jsonify@1.0.1: {} @@ -8335,7 +8713,7 @@ snapshots: natural-compare@1.4.0: {} - next@15.1.7(@babel/core@7.24.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1): + next@15.1.7(@babel/core@7.23.0)(@opentelemetry/api@1.9.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1): dependencies: '@next/env': 15.1.7 '@swc/counter': 0.1.3 @@ -8345,7 +8723,7 @@ snapshots: postcss: 8.4.31 react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - styled-jsx: 5.1.6(@babel/core@7.24.0)(react@18.3.1) + styled-jsx: 5.1.6(@babel/core@7.23.0)(react@18.3.1) optionalDependencies: '@next/swc-darwin-arm64': 15.1.7 '@next/swc-darwin-x64': 15.1.7 @@ -8570,6 +8948,8 @@ snapshots: picomatch@2.3.1: {} + picomatch@4.0.2: {} + pify@4.0.1: {} pkg-types@1.1.0: @@ -8594,6 +8974,8 @@ snapshots: prettier@2.8.8: {} + prettier@3.5.3: {} + pretty-format@29.7.0: dependencies: '@jest/schemas': 29.6.3 @@ -8796,7 +9178,7 @@ snapshots: rxjs@7.8.1: dependencies: - tslib: 2.6.2 + tslib: 2.8.1 safe-array-concat@1.0.1: dependencies: @@ -9011,12 +9393,12 @@ snapshots: dependencies: js-tokens: 9.0.0 - styled-jsx@5.1.6(@babel/core@7.24.0)(react@18.3.1): + styled-jsx@5.1.6(@babel/core@7.23.0)(react@18.3.1): dependencies: client-only: 0.0.1 react: 18.3.1 optionalDependencies: - '@babel/core': 7.24.0 + '@babel/core': 7.23.0 supports-color@5.5.0: dependencies: @@ -9044,6 +9426,11 @@ snapshots: tinybench@2.8.0: {} + tinyglobby@0.2.14: + dependencies: + fdir: 6.4.6(picomatch@4.0.2) + picomatch: 4.0.2 + tinypool@0.8.4: {} tinyspy@2.2.1: {} @@ -9079,6 +9466,10 @@ snapshots: ts-log@2.2.5: {} + tsconfck@3.1.6(typescript@5.0.4): + optionalDependencies: + typescript: 5.0.4 + tsconfig-paths@3.14.2: dependencies: '@types/json5': 0.0.29 @@ -9106,6 +9497,13 @@ snapshots: tslib: 1.14.1 typescript: 5.6.2 + tsx@4.20.3: + dependencies: + esbuild: 0.25.5 + get-tsconfig: 4.10.1 + optionalDependencies: + fsevents: 2.3.3 + type-check@0.4.0: dependencies: prelude-ls: 1.2.1 @@ -9245,6 +9643,17 @@ snapshots: - supports-color - terser + vite-tsconfig-paths@5.1.4(typescript@5.0.4)(vite@5.2.10(@types/node@18.18.3)): + dependencies: + debug: 4.4.0 + globrex: 0.1.2 + tsconfck: 3.1.6(typescript@5.0.4) + optionalDependencies: + vite: 5.2.10(@types/node@18.18.3) + transitivePeerDependencies: + - supports-color + - typescript + vite@5.2.10(@types/node@18.18.3): dependencies: esbuild: 0.20.2 diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml new file mode 100644 index 00000000..d0b7dbe2 --- /dev/null +++ b/pnpm-workspace.yaml @@ -0,0 +1,3 @@ +onlyBuiltDependencies: + - esbuild + - sharp diff --git a/scripts/generate-app-webhooks-types.ts b/scripts/generate-app-webhooks-types.ts new file mode 100644 index 00000000..e06ce9bb --- /dev/null +++ b/scripts/generate-app-webhooks-types.ts @@ -0,0 +1,61 @@ +import { writeFileSync } from "node:fs"; + +import { compile } from "json-schema-to-typescript"; + +const schemaFileNames = [ + // List of all Saleor webhook response schemas - uncomment those you need + // "CheckoutCalculateTaxes", + // "CheckoutFilterShippingMethods", + // "ListStoredPaymentMethods", + // "OrderCalculateTaxes", + "OrderFilterShippingMethods", + // "PaymentGatewayInitializeSession", + // "PaymentGatewayInitializeTokenizationSession", + // "ShippingListMethodsForCheckout", + // "ShippingListMethodsForOrder", + // "StoredPaymentMethodDeleteRequested", + // "TransactionCancelationRequested", + // "TransactionChargeRequested", + // "TransactionInitializeSession", + // "TransactionProcessSession", + // "TransactionRefundRequested", +]; + +const path = "https://raw.githubusercontent.com/saleor/saleor/main/saleor/json_schemas/"; + +const convertToKebabCase = (fileName: string): string => { + return fileName + .replace(/([A-Z])/g, "-$1") + .toLowerCase() + .replace(/^-/, ""); +}; + +const schemaMapping = schemaFileNames.map((fileName) => ({ + fileName: convertToKebabCase(fileName), + url: `${path}${fileName}.json`, +})); + +async function main() { + await Promise.all( + schemaMapping.map(async ({ fileName, url }) => { + const res = await fetch(url); + + const fetchedSchema = await res.json(); + + const compiledTypes = await compile(fetchedSchema, fileName, { + additionalProperties: false, + }); + + writeFileSync(`./generated/app-webhooks-types/${fileName}.ts`, compiledTypes); + }) + ); +} + +try { + console.log("Fetching JSON schemas from Saleor GitHub repository..."); + await main(); + console.log("Successfully generated TypeScript files from JSON schemas."); +} catch (error) { + console.error(`Error generating webhook response types: ${error}`); + process.exit(1); +} diff --git a/src/order-example.tsx b/src/order-example.tsx index dfe1b2ba..fa0ece59 100644 --- a/src/order-example.tsx +++ b/src/order-example.tsx @@ -1,48 +1,16 @@ import { actions, useAppBridge } from "@saleor/app-sdk/app-bridge"; import { Box, Text } from "@saleor/macaw-ui"; -import gql from "graphql-tag"; import Link from "next/link"; -import { useLastOrderQuery } from "../generated/graphql"; +import { useLastOrderQuery } from "@/generated/graphql"; /** * GraphQL Code Generator scans for gql tags and generates types based on them. * The below query is used to generate the "useLastOrderQuery" hook. - * If you modify it, make sure to run "pnpm codegen" to regenerate the types. + * If you modify it, make sure to run "pnpm run generate:app-graphql-types" to regenerate the types. */ -gql` - query LastOrder { - orders(first: 1) { - edges { - node { - id - number - created - user { - firstName - lastName - } - shippingAddress { - country { - country - } - } - total { - gross { - amount - currency - } - } - lines { - id - } - } - } - } - } -`; -function generateNumberOfLinesText(lines: any[]) { +function generateNumberOfLinesText(lines: readonly { readonly id: string }[]) { if (lines.length === 0) { return "no lines"; } diff --git a/src/pages/api/manifest.ts b/src/pages/api/manifest.ts index 89690010..1bebec26 100644 --- a/src/pages/api/manifest.ts +++ b/src/pages/api/manifest.ts @@ -1,8 +1,10 @@ import { createManifestHandler } from "@saleor/app-sdk/handlers/next"; import { AppManifest } from "@saleor/app-sdk/types"; -import packageJson from "../../../package.json"; +import packageJson from "@/package.json"; + import { orderCreatedWebhook } from "./webhooks/order-created"; +import { orderFilterShippingMethodsWebhook } from "./webhooks/order-filter-shipping-methods"; /** * App SDK helps with the valid Saleor App Manifest creation. Read more: @@ -28,7 +30,7 @@ export default createManifestHandler({ */ permissions: [ /** - * Add permission to allow "ORDER_CREATED" webhook registration. + * Add permission to allow "ORDER_CREATED" / "ORDER_FILTER_SHIPPING_METHODS" webhooks registration. * * This can be removed */ @@ -44,7 +46,10 @@ export default createManifestHandler({ * Easiest way to create webhook is to use app-sdk * https://github.com/saleor/saleor-app-sdk/blob/main/docs/saleor-webhook.md */ - webhooks: [orderCreatedWebhook.getWebhookManifest(apiBaseURL)], + webhooks: [ + orderCreatedWebhook.getWebhookManifest(apiBaseURL), + orderFilterShippingMethodsWebhook.getWebhookManifest(apiBaseURL), + ], /** * Optionally, extend Dashboard with custom UIs * https://docs.saleor.io/docs/3.x/developer/extending/apps/extending-dashboard-with-apps diff --git a/src/pages/api/webhooks/order-created.ts b/src/pages/api/webhooks/order-created.ts index e74c65b2..ce080dee 100644 --- a/src/pages/api/webhooks/order-created.ts +++ b/src/pages/api/webhooks/order-created.ts @@ -1,12 +1,11 @@ import { SaleorAsyncWebhook } from "@saleor/app-sdk/handlers/next"; -import { createClient } from "@/lib/create-graphq-client"; -import { saleorApp } from "@/saleor-app"; - import { OrderCreatedSubscriptionDocument, OrderCreatedWebhookPayloadFragment, -} from "../../../../generated/graphql"; +} from "@/generated/graphql"; +import { createClient } from "@/lib/create-graphq-client"; +import { saleorApp } from "@/saleor-app"; /** * Create abstract Webhook. It decorates handler and performs security checks under the hood. @@ -22,7 +21,7 @@ export const orderCreatedWebhook = new SaleorAsyncWebhook { const { diff --git a/src/pages/api/webhooks/order-filter-shipping-methods.ts b/src/pages/api/webhooks/order-filter-shipping-methods.ts new file mode 100644 index 00000000..63e20a9b --- /dev/null +++ b/src/pages/api/webhooks/order-filter-shipping-methods.ts @@ -0,0 +1,67 @@ +import { SaleorSyncWebhook } from "@saleor/app-sdk/handlers/next"; + +import { FilterShippingMethods } from "@/generated/app-webhooks-types/order-filter-shipping-methods"; +import { + OrderFilterShippingMethodsPayloadFragment, + OrderFilterShippingMethodsSubscriptionDocument, +} from "@/generated/graphql"; +import { saleorApp } from "@/saleor-app"; + +/** + * Create abstract Webhook. It decorates handler and performs security checks under the hood. + * + * orderFilterShippingMethodsWebhook.getWebhookManifest() must be called in api/manifest too! + */ +export const orderFilterShippingMethodsWebhook = + new SaleorSyncWebhook({ + name: "Order Filter Shipping Methods", + webhookPath: "api/webhooks/order-filter-shipping-methods", + event: "ORDER_FILTER_SHIPPING_METHODS", + apl: saleorApp.apl, + query: OrderFilterShippingMethodsSubscriptionDocument, + }); + +/** + * Export decorated Next.js pages router handler, which adds extra context + */ +export default orderFilterShippingMethodsWebhook.createHandler((req, res, ctx) => { + const { + /** + * Access payload from Saleor - defined above + */ + payload, + /** + * Saleor event that triggers the webhook (here - ORDER_FILTER_SHIPPING_METHODS) + */ + event, + /** + * App's URL + */ + baseUrl, + /** + * Auth data (from APL) - contains token and saleorApiUrl that can be used to construct graphQL client + */ + authData, + } = ctx; + + /** + * Perform logic based on Saleor Event payload e.g filter shipping methods + * This is a synchronous webhook, so you can return the response directly. + */ + console.log(`Filtering shipping methods for order id: ${payload.order?.id}`); + + const response: FilterShippingMethods = { + excluded_methods: [], + }; + + return res.status(200).json(response); +}); + +/** + * Disable body parser for this endpoint, so signature can be verified + */ +export const config = { + api: { + bodyParser: false, + }, +}; diff --git a/tsconfig.json b/tsconfig.json index e626cf50..0f70eb77 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,6 +1,6 @@ { "compilerOptions": { - "target": "es5", + "target": "esnext", "lib": ["dom", "dom.iterable", "esnext"], "allowJs": true, "skipLibCheck": true, @@ -16,7 +16,9 @@ "incremental": true, "baseUrl": ".", "paths": { - "@/*": ["src/*"] + "@/*": ["src/*"], + "@/generated/*": ["generated/*"], + "@/package.json": ["package.json"] } }, "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"], diff --git a/vitest.config.ts b/vitest.config.ts index af5af05a..a2ad3938 100644 --- a/vitest.config.ts +++ b/vitest.config.ts @@ -1,9 +1,10 @@ import react from "@vitejs/plugin-react"; +import tsconfigPaths from "vite-tsconfig-paths"; import { defineConfig } from "vitest/config"; // https://vitejs.dev/config/ export default defineConfig({ - plugins: [react()], + plugins: [react(), tsconfigPaths()], test: { passWithNoTests: true, environment: "jsdom",