diff --git a/.changeset/silver-elephants-deny.md b/.changeset/silver-elephants-deny.md
new file mode 100644
index 00000000000..646efc6ba15
--- /dev/null
+++ b/.changeset/silver-elephants-deny.md
@@ -0,0 +1,5 @@
+---
+"saleor-dashboard": patch
+---
+
+Added support for the new channel setting: `checkoutSettings.automaticallyCompleteFullyPaidCheckouts`. Setting can be changed in channel configuration page.
diff --git a/introspection.json b/introspection.json
index 98e13d0eb03..cb18dbe7382 100644
--- a/introspection.json
+++ b/introspection.json
@@ -13,7 +13,7 @@
{
"kind": "OBJECT",
"name": "AccountAddressCreate",
- "description": "Create a new address for the customer. \n\nRequires one of the following permissions: AUTHENTICATED_USER.\n\nTriggers the following webhook events:\n- CUSTOMER_UPDATED (async): A customer account was updated.\n- ADDRESS_CREATED (async): An address was created.",
+ "description": "Create a new address for the customer.\n\nRequires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER.\n\nTriggers the following webhook events:\n- CUSTOMER_UPDATED (async): A customer account was updated.\n- ADDRESS_CREATED (async): An address was created.",
"fields": [
{
"name": "accountErrors",
@@ -1307,6 +1307,12 @@
"isDeprecated": false,
"deprecationReason": null
},
+ {
+ "name": "LOGIN_ATTEMPT_DELAYED",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "MISSING_CHANNEL_SLUG",
"description": null,
@@ -1378,6 +1384,12 @@
"description": null,
"isDeprecated": false,
"deprecationReason": null
+ },
+ {
+ "name": "UNKNOWN_IP_ADDRESS",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
}
],
"possibleTypes": null
@@ -1937,7 +1949,7 @@
{
"kind": "OBJECT",
"name": "AccountUpdate",
- "description": "Updates the account of the logged-in user. \n\nRequires one of the following permissions: AUTHENTICATED_USER.\n\nTriggers the following webhook events:\n- CUSTOMER_UPDATED (async): A customer account was updated.\n- CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated.",
+ "description": "Updates the account of the logged-in user.\n\nRequires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER.\n\nTriggers the following webhook events:\n- CUSTOMER_UPDATED (async): A customer account was updated.\n- CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated.",
"fields": [
{
"name": "accountErrors",
@@ -2865,6 +2877,18 @@
"isDeprecated": false,
"deprecationReason": null
},
+ {
+ "name": "skipValidation",
+ "description": "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.\n\nAdded in Saleor 3.19.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "type": {
+ "kind": "SCALAR",
+ "name": "Boolean",
+ "ofType": null
+ },
+ "defaultValue": "false",
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "streetAddress1",
"description": "Address.",
@@ -18364,7 +18388,7 @@
},
{
"name": "totalPrice",
- "description": "The sum of the the checkout line prices, with all the taxes,shipping costs, and discounts included.\n\nTriggers the following webhook events:\n- CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired.",
+ "description": "The sum of the checkout line prices, with all the taxes,shipping costs, and discounts included.\n\nTriggers the following webhook events:\n- CHECKOUT_CALCULATE_TAXES (sync): Optionally triggered when checkout prices are expired.",
"args": [],
"type": {
"kind": "NON_NULL",
@@ -18940,7 +18964,7 @@
{
"kind": "OBJECT",
"name": "CheckoutCreate",
- "description": "Create a new checkout.\n\nTriggers the following webhook events:\n- CHECKOUT_CREATED (async): A checkout was created.",
+ "description": "Create a new checkout.\n\n`skipValidation` field requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions.\n\nTriggers the following webhook events:\n- CHECKOUT_CREATED (async): A checkout was created.",
"fields": [
{
"name": "checkout",
@@ -19309,7 +19333,7 @@
"inputFields": [
{
"name": "billingAddress",
- "description": "Billing address of the customer.",
+ "description": "Billing address of the customer. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions.",
"type": {
"kind": "INPUT_OBJECT",
"name": "AddressInput",
@@ -19381,7 +19405,7 @@
},
{
"name": "shippingAddress",
- "description": "The mailing address to where the checkout will be shipped. Note: the address will be ignored if the checkout doesn't contain shippable items.",
+ "description": "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.",
"type": {
"kind": "INPUT_OBJECT",
"name": "AddressInput",
@@ -20284,7 +20308,7 @@
{
"kind": "OBJECT",
"name": "CheckoutFullyPaid",
- "description": "Event sent when checkout is fully paid with transactions.\n\nAdded in Saleor 3.13.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "description": "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.\n\nAdded in Saleor 3.13.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
"fields": [
{
"name": "checkout",
@@ -21655,6 +21679,22 @@
"name": "CheckoutSettings",
"description": "Represents the channel-specific checkout settings.\n\nAdded in Saleor 3.15.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
"fields": [
+ {
+ "name": "automaticallyCompleteFullyPaidCheckouts",
+ "description": "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.\n\nAdded in Saleor 3.20.",
+ "args": [],
+ "type": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "Boolean",
+ "ofType": null
+ }
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "useLegacyErrorFlow",
"description": "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.\n\nAdded in Saleor 3.15.This field will be removed in Saleor 4.0.",
@@ -21683,6 +21723,18 @@
"description": null,
"fields": null,
"inputFields": [
+ {
+ "name": "automaticallyCompleteFullyPaidCheckouts",
+ "description": "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.\n\nAdded in Saleor 3.20.",
+ "type": {
+ "kind": "SCALAR",
+ "name": "Boolean",
+ "ofType": null
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "useLegacyErrorFlow",
"description": "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. \n\nAdded in Saleor 3.15.\n\nDEPRECATED: this field will be removed in Saleor 4.0.",
@@ -25248,7 +25300,7 @@
{
"kind": "ENUM",
"name": "CountryCode",
- "description": "An enumeration.",
+ "description": "Represents country codes defined by the ISO 3166-1 alpha-2 standard.\n\nThe `EU` value is DEPRECATED and will be removed in Saleor 3.21.",
"fields": null,
"inputFields": null,
"interfaces": null,
@@ -50767,8 +50819,20 @@
"fields": [
{
"name": "accountAddressCreate",
- "description": "Create a new address for the customer. \n\nRequires one of the following permissions: AUTHENTICATED_USER.\n\nTriggers the following webhook events:\n- CUSTOMER_UPDATED (async): A customer account was updated.\n- ADDRESS_CREATED (async): An address was created.",
+ "description": "Create a new address for the customer.\n\nRequires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER.\n\nTriggers the following webhook events:\n- CUSTOMER_UPDATED (async): A customer account was updated.\n- ADDRESS_CREATED (async): An address was created.",
"args": [
+ {
+ "name": "customerId",
+ "description": "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.\n\nAdded in Saleor 3.19.",
+ "type": {
+ "kind": "SCALAR",
+ "name": "ID",
+ "ofType": null
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "input",
"description": "Fields required to create address.",
@@ -51026,8 +51090,20 @@
},
{
"name": "accountUpdate",
- "description": "Updates the account of the logged-in user. \n\nRequires one of the following permissions: AUTHENTICATED_USER.\n\nTriggers the following webhook events:\n- CUSTOMER_UPDATED (async): A customer account was updated.\n- CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated.",
+ "description": "Updates the account of the logged-in user.\n\nRequires one of following set of permissions: AUTHENTICATED_USER or AUTHENTICATED_APP + IMPERSONATE_USER.\n\nTriggers the following webhook events:\n- CUSTOMER_UPDATED (async): A customer account was updated.\n- CUSTOMER_METADATA_UPDATED (async): Optionally called when customer's metadata was updated.",
"args": [
+ {
+ "name": "customerId",
+ "description": "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.\n\nAdded in Saleor 3.19.",
+ "type": {
+ "kind": "SCALAR",
+ "name": "ID",
+ "ofType": null
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "input",
"description": "Fields required to update the account of the logged-in user.",
@@ -53090,7 +53166,7 @@
},
{
"name": "checkoutCreate",
- "description": "Create a new checkout.\n\nTriggers the following webhook events:\n- CHECKOUT_CREATED (async): A checkout was created.",
+ "description": "Create a new checkout.\n\n`skipValidation` field requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions.\n\nTriggers the following webhook events:\n- CHECKOUT_CREATED (async): A checkout was created.",
"args": [
{
"name": "input",
@@ -63472,19 +63548,15 @@
},
{
"name": "transactionEventReport",
- "description": "Report the event for the transaction.\n\nAdded in Saleor 3.13.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.\n\nRequires 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.",
+ "description": "Report the event for the transaction.\n\nAdded in Saleor 3.13.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.\n\nRequires 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.\n\nTriggers the following webhook events:\n- TRANSACTION_ITEM_METADATA_UPDATED (async): Optionally called when transaction's metadata was updated.\n- CHECKOUT_FULLY_PAID (async): Optionally called when the checkout charge status changed to `FULL` or `OVERCHARGED`.\n- ORDER_UPDATED (async): Optionally called when the transaction is related to the order and the order was updated.",
"args": [
{
"name": "amount",
- "description": "The amount of the event to report.",
+ "description": "The amount of the event to report. \n\nRequired 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.",
"type": {
- "kind": "NON_NULL",
- "name": null,
- "ofType": {
- "kind": "SCALAR",
- "name": "PositiveDecimal",
- "ofType": null
- }
+ "kind": "SCALAR",
+ "name": "PositiveDecimal",
+ "ofType": null
},
"defaultValue": null,
"isDeprecated": false,
@@ -63586,6 +63658,46 @@
"isDeprecated": false,
"deprecationReason": null
},
+ {
+ "name": "transactionMetadata",
+ "description": "Fields required to update the transaction metadata.\n\nAdded in Saleor 3.17.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "INPUT_OBJECT",
+ "name": "MetadataInput",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "transactionPrivateMetadata",
+ "description": "Fields required to update the transaction private metadata.\n\nAdded in Saleor 3.17.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "INPUT_OBJECT",
+ "name": "MetadataInput",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "type",
"description": "Current status of the event to report.",
@@ -67164,6 +67276,18 @@
"isDeprecated": true,
"deprecationReason": "This field will be removed in Saleor 4.0. Use the `discounts` field instead. "
},
+ {
+ "name": "undiscountedShippingPrice",
+ "description": "Undiscounted total price of shipping.\n\nAdded in Saleor 3.19.",
+ "args": [],
+ "type": {
+ "kind": "OBJECT",
+ "name": "Money",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "undiscountedTotal",
"description": "Undiscounted total amount of the order.",
@@ -71765,6 +71889,12 @@
"isDeprecated": false,
"deprecationReason": null
},
+ {
+ "name": "PLACED_AUTOMATICALLY_FROM_PAID_CHECKOUT",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "PLACED_FROM_DRAFT",
"description": null,
@@ -71985,6 +72115,26 @@
"isDeprecated": false,
"deprecationReason": null
},
+ {
+ "name": "checkoutTokens",
+ "description": null,
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "UUID",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "created",
"description": null,
@@ -73986,6 +74136,18 @@
"isDeprecated": false,
"deprecationReason": null
},
+ {
+ "name": "isPriceOverridden",
+ "description": "Returns True, if the line unit price was overridden.\n\nAdded in Saleor 3.14.",
+ "args": [],
+ "type": {
+ "kind": "SCALAR",
+ "name": "Boolean",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "isShippingRequired",
"description": "Whether the product variant requires shipping.",
@@ -82228,6 +82390,12 @@
"isDeprecated": false,
"deprecationReason": null
},
+ {
+ "name": "CHECKOUT_COMPLETION_IN_PROGRESS",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "CHECKOUT_EMAIL_NOT_SET",
"description": null,
@@ -100652,11 +100820,15 @@
},
{
"name": "type",
- "description": "Defines the promotion type. Implicate the required promotion rules predicate type and whether the promotion rules will give the catalogue or order discount. \n\nThe default value is `Catalogue`.\n\nThis field will be required from Saleor 3.20.\n\nAdded in Saleor 3.19.",
+ "description": "Defines the promotion type. Implicate the required promotion rules predicate type and whether the promotion rules will give the catalogue or order discount. \n\nAdded in Saleor 3.19.",
"type": {
- "kind": "ENUM",
- "name": "PromotionTypeEnum",
- "ofType": null
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "ENUM",
+ "name": "PromotionTypeEnum",
+ "ofType": null
+ }
},
"defaultValue": null,
"isDeprecated": false,
@@ -105355,7 +105527,7 @@
},
{
"name": "checkout",
- "description": "Look up a checkout by id.\n\nRequires one of the following permissions to query checkouts that belong to other users: MANAGE_CHECKOUTS, IMPERSONATE_USER. ",
+ "description": "Look up a checkout by id.\n\nRequires one of the following permissions to query a checkout, if a checkout is in inactive channel: MANAGE_CHECKOUTS, IMPERSONATE_USER, HANDLE_PAYMENTS. ",
"args": [
{
"name": "id",
@@ -105453,7 +105625,7 @@
},
{
"name": "checkouts",
- "description": "List of checkouts.\n\nRequires one of the following permissions: MANAGE_CHECKOUTS.",
+ "description": "List of checkouts.\n\nRequires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS.",
"args": [
{
"name": "after",
@@ -105708,7 +105880,7 @@
},
{
"name": "customers",
- "description": "List of the shop's customers.\n\nRequires one of the following permissions: MANAGE_ORDERS, MANAGE_USERS.",
+ "description": "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.\n\nRequires one of the following permissions: MANAGE_ORDERS, MANAGE_USERS.",
"args": [
{
"name": "after",
@@ -106694,7 +106866,7 @@
"args": [
{
"name": "externalReference",
- "description": "External ID of an order. \n\nAdded in Saleor 3.10.",
+ "description": "External ID of an order. \n\nAdded in Saleor 3.10..\n\nRequires one of the following permissions: MANAGE_ORDERS.",
"type": {
"kind": "SCALAR",
"name": "String",
@@ -108542,7 +108714,7 @@
"args": [
{
"name": "id",
- "description": "ID of an warehouse",
+ "description": "ID of a stock",
"type": {
"kind": "NON_NULL",
"name": null,
@@ -113710,13 +113882,9 @@
"description": "Translated shipping method name.",
"args": [],
"type": {
- "kind": "NON_NULL",
- "name": null,
- "ofType": {
- "kind": "SCALAR",
- "name": "String",
- "ofType": null
- }
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
},
"isDeprecated": false,
"deprecationReason": null
@@ -117391,8 +117559,8 @@
"ofType": null
}
},
- "isDeprecated": false,
- "deprecationReason": null
+ "isDeprecated": true,
+ "deprecationReason": "This field will be removed in Saleor 4.0."
},
{
"name": "metadata",
@@ -121480,6 +121648,105 @@
"name": "Subscription",
"description": null,
"fields": [
+ {
+ "name": "draftOrderCreated",
+ "description": "Event sent when new draft order is created.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "DraftOrderCreated",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "draftOrderDeleted",
+ "description": "Event sent when draft order is deleted.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "DraftOrderDeleted",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "draftOrderUpdated",
+ "description": "Event sent when draft order is updated.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "DraftOrderUpdated",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "event",
"description": "Look up subscription event.\n\nAdded in Saleor 3.2.",
@@ -121491,6 +121758,402 @@
},
"isDeprecated": false,
"deprecationReason": null
+ },
+ {
+ "name": "orderBulkCreated",
+ "description": "Event sent when orders are imported.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderBulkCreated",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderCancelled",
+ "description": "Event sent when order is cancelled.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderCancelled",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderConfirmed",
+ "description": "Event sent when order is confirmed.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderConfirmed",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderCreated",
+ "description": "Event sent when new order is created.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderCreated",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderExpired",
+ "description": "Event sent when order becomes expired.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderExpired",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderFulfilled",
+ "description": "Event sent when order is fulfilled.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderFulfilled",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderFullyPaid",
+ "description": "Event sent when order is fully paid.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderFullyPaid",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderFullyRefunded",
+ "description": "The order is fully refunded.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderFullyRefunded",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderMetadataUpdated",
+ "description": "Event sent when order metadata is updated.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderMetadataUpdated",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderPaid",
+ "description": "Payment has been made. The order may be partially or fully paid.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderPaid",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderRefunded",
+ "description": "The order received a refund. The order may be partially or fully refunded.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderRefunded",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "orderUpdated",
+ "description": "Event sent when order is updated.\n\nAdded in Saleor 3.20.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "args": [
+ {
+ "name": "channels",
+ "description": "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.",
+ "type": {
+ "kind": "LIST",
+ "name": null,
+ "ofType": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ }
+ }
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "OrderUpdated",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
}
],
"inputFields": null,
@@ -124222,7 +124885,7 @@
},
{
"name": "shippingPrice",
- "description": "The price of shipping method.",
+ "description": "The price of shipping method, includes shipping voucher discount if applied.",
"args": [],
"type": {
"kind": "NON_NULL",
@@ -124290,6 +124953,22 @@
},
"isDeprecated": false,
"deprecationReason": null
+ },
+ {
+ "name": "type",
+ "description": "Indicates which part of the order the discount should affect: SUBTOTAL or SHIPPING.",
+ "args": [],
+ "type": {
+ "kind": "NON_NULL",
+ "name": null,
+ "ofType": {
+ "kind": "ENUM",
+ "name": "TaxableObjectDiscountTypeEnum",
+ "ofType": null
+ }
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
}
],
"inputFields": null,
@@ -124297,6 +124976,29 @@
"enumValues": null,
"possibleTypes": null
},
+ {
+ "kind": "ENUM",
+ "name": "TaxableObjectDiscountTypeEnum",
+ "description": "Indicates which part of the order the discount should affect: SUBTOTAL or SHIPPING.",
+ "fields": null,
+ "inputFields": null,
+ "interfaces": null,
+ "enumValues": [
+ {
+ "name": "SHIPPING",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "SUBTOTAL",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "possibleTypes": null
+ },
{
"kind": "OBJECT",
"name": "TaxableObjectLine",
@@ -124380,7 +125082,7 @@
},
{
"name": "totalPrice",
- "description": "Price of the order line.",
+ "description": "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.",
"args": [],
"type": {
"kind": "NON_NULL",
@@ -124396,7 +125098,7 @@
},
{
"name": "unitPrice",
- "description": "Price of the single item in the order line.",
+ "description": "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.",
"args": [],
"type": {
"kind": "NON_NULL",
@@ -125787,7 +126489,7 @@
{
"kind": "OBJECT",
"name": "TransactionEventReport",
- "description": "Report the event for the transaction.\n\nAdded in Saleor 3.13.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.\n\nRequires 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.",
+ "description": "Report the event for the transaction.\n\nAdded in Saleor 3.13.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.\n\nRequires 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.\n\nTriggers the following webhook events:\n- TRANSACTION_ITEM_METADATA_UPDATED (async): Optionally called when transaction's metadata was updated.\n- CHECKOUT_FULLY_PAID (async): Optionally called when the checkout charge status changed to `FULL` or `OVERCHARGED`.\n- ORDER_UPDATED (async): Optionally called when the transaction is related to the order and the order was updated.",
"fields": [
{
"name": "alreadyProcessed",
@@ -125943,6 +126645,12 @@
"description": null,
"isDeprecated": false,
"deprecationReason": null
+ },
+ {
+ "name": "REQUIRED",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
}
],
"possibleTypes": null
@@ -126219,6 +126927,12 @@
"inputFields": null,
"interfaces": null,
"enumValues": [
+ {
+ "name": "CHECKOUT_COMPLETION_IN_PROGRESS",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "GRAPHQL_ERROR",
"description": null,
@@ -127286,6 +128000,12 @@
"inputFields": null,
"interfaces": null,
"enumValues": [
+ {
+ "name": "CHECKOUT_COMPLETION_IN_PROGRESS",
+ "description": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
{
"name": "GRAPHQL_ERROR",
"description": null,
@@ -135056,6 +135776,67 @@
},
"isDeprecated": false,
"deprecationReason": null
+ },
+ {
+ "name": "stocks",
+ "description": "Stocks that belong to this warehouse.\n\nAdded in Saleor 3.20.\n\nRequires one of the following permissions: MANAGE_PRODUCTS, MANAGE_ORDERS.",
+ "args": [
+ {
+ "name": "after",
+ "description": "Return the elements in the list that come after the specified cursor.",
+ "type": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "before",
+ "description": "Return the elements in the list that come before the specified cursor.",
+ "type": {
+ "kind": "SCALAR",
+ "name": "String",
+ "ofType": null
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "first",
+ "description": "Retrieve the first n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query.",
+ "type": {
+ "kind": "SCALAR",
+ "name": "Int",
+ "ofType": null
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ },
+ {
+ "name": "last",
+ "description": "Retrieve the last n elements from the list. Note that the system only allows fetching a maximum of 100 objects in a single query.",
+ "type": {
+ "kind": "SCALAR",
+ "name": "Int",
+ "ofType": null
+ },
+ "defaultValue": null,
+ "isDeprecated": false,
+ "deprecationReason": null
+ }
+ ],
+ "type": {
+ "kind": "OBJECT",
+ "name": "StockCountableConnection",
+ "ofType": null
+ },
+ "isDeprecated": false,
+ "deprecationReason": null
}
],
"inputFields": null,
@@ -136768,7 +137549,7 @@
},
{
"name": "customHeaders",
- "description": "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-*\" and \"Authorization*\" keys are allowed.\n\nAdded in Saleor 3.12.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "description": "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.\n\nAdded in Saleor 3.12.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
"type": {
"kind": "SCALAR",
"name": "JSONString",
@@ -140530,7 +141311,7 @@
},
{
"name": "customHeaders",
- "description": "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-*\" and \"Authorization*\" keys are allowed.\n\nAdded in Saleor 3.12.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
+ "description": "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.\n\nAdded in Saleor 3.12.\n\nNote: this API is currently in Feature Preview and can be subject to changes at later point.",
"type": {
"kind": "SCALAR",
"name": "JSONString",
diff --git a/locale/defaultMessages.json b/locale/defaultMessages.json
index 6f66f2b0411..18aea1d296e 100644
--- a/locale/defaultMessages.json
+++ b/locale/defaultMessages.json
@@ -2369,6 +2369,10 @@
"context": "no card defuned alert message",
"string": "You haven’t defined a gift card product!"
},
+ "E4GW+N": {
+ "context": "fully paid checkout automatically completed message",
+ "string": "Order created automatically from fully paid checkout"
+ },
"E54eoT": {
"string": "Creating the navigation structure is done by dragging and dropping. Simply create a new menu item and then drag it into its destined place. You can move items inside one another to create a tree structure and drag items up and down to create a hierarchy"
},
@@ -2754,6 +2758,10 @@
"context": "dialog header",
"string": "Delete Variant"
},
+ "GFkb2t": {
+ "context": "automatically complete checkouts checkbox label",
+ "string": "Automatically complete checkouts when fully paid"
+ },
"GJAX0z": {
"context": "order history message",
"string": "Order was placed"
@@ -6858,6 +6866,10 @@
"context": "product type name",
"string": "Type Name"
},
+ "hIh8bm": {
+ "context": "automatically complete checkouts checkbox description",
+ "string": "When enabled, checkouts detected as fully paid will be completed automatically, without checkoutComplete mutation. ({link})"
+ },
"hJDnLg": {
"context": "section header",
"string": "Upcoming Apps"
diff --git a/schema.graphql b/schema.graphql
index 1644d256c5f..2f96313284b 100644
--- a/schema.graphql
+++ b/schema.graphql
@@ -14,9 +14,9 @@ directive @webhookEventsInfo(
) on FIELD | FIELD_DEFINITION | INPUT_OBJECT | OBJECT
"""
-Create a new address for the customer.
+Create a new address for the customer.
-Requires one of the following permissions: AUTHENTICATED_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.
@@ -326,6 +326,7 @@ enum AccountErrorCode {
JWT_MISSING_TOKEN
JWT_SIGNATURE_EXPIRED
LEFT_NOT_MANAGEABLE_PERMISSION
+ LOGIN_ATTEMPT_DELAYED
MISSING_CHANNEL_SLUG
NOT_FOUND
OUT_OF_SCOPE_GROUP
@@ -338,6 +339,7 @@ enum AccountErrorCode {
PASSWORD_TOO_SIMILAR
REQUIRED
UNIQUE
+ UNKNOWN_IP_ADDRESS
}
"""Fields required to update the user."""
@@ -478,9 +480,9 @@ type AccountSetPasswordRequested implements Event {
}
"""
-Updates the account of the logged-in user.
+Updates the account of the logged-in user.
-Requires one of the following permissions: AUTHENTICATED_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.
@@ -700,6 +702,15 @@ input AddressInput {
"""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
@@ -4708,7 +4719,7 @@ type Checkout implements Node & ObjectWithMetadata {
totalBalance: Money!
"""
- The sum of the the checkout line prices, with all the taxes,shipping costs, and discounts included.
+ 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.
@@ -4894,6 +4905,8 @@ type CheckoutCountableEdge {
"""
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.
"""
@@ -4971,7 +4984,9 @@ enum CheckoutCreateFromOrderUnavailableVariantErrorCode {
}
input CheckoutCreateInput {
- """Billing address of the customer."""
+ """
+ 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."""
@@ -4989,7 +5004,7 @@ input CheckoutCreateInput {
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.
+ 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
@@ -5179,7 +5194,7 @@ type CheckoutFilterShippingMethods implements Event {
}
"""
-Event sent when checkout is fully paid with transactions.
+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.
Added in Saleor 3.13.
@@ -5544,6 +5559,13 @@ 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 `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!
+
"""
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.
@@ -5553,6 +5575,13 @@ type CheckoutSettings {
}
input CheckoutSettingsInput {
+ """
+ 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
+
"""
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.
@@ -6416,7 +6445,11 @@ type ConfirmEmailChange {
user: User
}
-"""An enumeration."""
+"""
+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
@@ -11773,15 +11806,22 @@ input MoveProductInput {
type Mutation {
"""
- Create a new address for the customer.
+ Create a new address for the customer.
- Requires one of the following permissions: AUTHENTICATED_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.
- 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!
@@ -11882,15 +11922,22 @@ type Mutation {
): AccountSetDefaultAddress
"""
- Updates the account of the logged-in user.
+ Updates the account of the logged-in user.
- Requires one of the following permissions: AUTHENTICATED_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
@@ -12673,6 +12720,8 @@ type Mutation {
"""
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.
"""
@@ -16342,10 +16391,19 @@ type Mutation {
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(
- """The amount of the event to report."""
- amount: PositiveDecimal!
+ """
+ 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!]
@@ -16376,6 +16434,20 @@ type Mutation {
"""
token: UUID
+ """
+ Fields required to update the transaction metadata.
+
+ Added in Saleor 3.17.
+ """
+ transactionMetadata: [MetadataInput!]
+
+ """
+ Fields required to update the transaction private metadata.
+
+ Added in Saleor 3.17.
+ """
+ transactionPrivateMetadata: [MetadataInput!]
+
"""Current status of the event to report."""
type: TransactionEventTypeEnum!
): TransactionEventReport
@@ -17277,6 +17349,13 @@ type Order implements Node & ObjectWithMetadata {
"""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!
@@ -18298,6 +18377,7 @@ enum OrderEventsEnum {
PAYMENT_REFUNDED
PAYMENT_VOIDED
PLACED
+ PLACED_AUTOMATICALLY_FROM_PAID_CHECKOUT
PLACED_FROM_DRAFT
REMOVED_PRODUCTS
TRACKING_UPDATED
@@ -18338,6 +18418,7 @@ input OrderFilterInput {
channels: [ID!]
chargeStatus: [OrderChargeStatusEnum!]
checkoutIds: [ID!]
+ checkoutTokens: [UUID!]
created: DateRangeInput
customer: String
giftCardBought: Boolean
@@ -18895,6 +18976,13 @@ type OrderLine implements Node & ObjectWithMetadata {
"""
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!
@@ -20903,6 +20991,7 @@ enum PaymentErrorCode {
BALANCE_CHECK_ERROR
BILLING_ADDRESS_NOT_SET
CHANNEL_INACTIVE
+ CHECKOUT_COMPLETION_IN_PROGRESS
CHECKOUT_EMAIL_NOT_SET
GRAPHQL_ERROR
INVALID
@@ -25382,13 +25471,9 @@ input PromotionCreateInput {
"""
Defines the promotion type. Implicate the required promotion rules predicate type and whether the promotion rules will give the catalogue or order discount.
- The default value is `Catalogue`.
-
- This field will be required from Saleor 3.20.
-
Added in Saleor 3.19.
"""
- type: PromotionTypeEnum
+ type: PromotionTypeEnum!
}
"""
@@ -26784,7 +26869,7 @@ type Query {
"""
Look up a checkout by id.
- Requires one of the following permissions to query checkouts that belong to other users: MANAGE_CHECKOUTS, IMPERSONATE_USER.
+ Requires one of the following permissions to query a checkout, if a checkout is in inactive channel: MANAGE_CHECKOUTS, IMPERSONATE_USER, HANDLE_PAYMENTS.
"""
checkout(
"""
@@ -26828,7 +26913,7 @@ type Query {
"""
List of checkouts.
- Requires one of the following permissions: MANAGE_CHECKOUTS.
+ Requires one of the following permissions: MANAGE_CHECKOUTS, HANDLE_PAYMENTS.
"""
checkouts(
"""Return the elements in the list that come after the specified cursor."""
@@ -26919,7 +27004,7 @@ type Query {
): CollectionCountableConnection
"""
- List of the shop's customers.
+ 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.
"""
@@ -27263,7 +27348,9 @@ type Query {
"""
External ID of an order.
- Added in Saleor 3.10.
+ Added in Saleor 3.10..
+
+ Requires one of the following permissions: MANAGE_ORDERS.
"""
externalReference: String
@@ -27877,7 +27964,7 @@ type Query {
Requires one of the following permissions: MANAGE_PRODUCTS.
"""
stock(
- """ID of an warehouse"""
+ """ID of a stock"""
id: ID!
): Stock
@@ -29234,7 +29321,7 @@ type ShippingMethodTranslation implements Node {
language: LanguageDisplay!
"""Translated shipping method name."""
- name: String!
+ name: String
"""
Represents the shipping method fields to translate.
@@ -30104,7 +30191,7 @@ type Shop implements ObjectWithMetadata {
Requires one of the following permissions: AUTHENTICATED_STAFF_USER.
"""
- limits: LimitInfo!
+ 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!]!
@@ -31141,12 +31228,222 @@ input StringFilterInput {
}
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 {
@@ -31765,7 +32062,9 @@ type TaxableObject {
"""Determines if prices contain entered tax.."""
pricesEnteredWithTax: Boolean!
- """The price of shipping method."""
+ """
+ The price of shipping method, includes shipping voucher discount if applied.
+ """
shippingPrice: Money!
"""The source object related to this tax object."""
@@ -31779,6 +32078,19 @@ type TaxableObjectDiscount {
"""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 {
@@ -31797,10 +32109,14 @@ type TaxableObjectLine {
"""The source line related to this tax line."""
sourceLine: TaxSourceLine!
- """Price of the order line."""
+ """
+ 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."""
+ """
+ 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."""
@@ -32219,6 +32535,11 @@ 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 {
"""Defines if the reported event hasn't been processed earlier."""
@@ -32254,6 +32575,7 @@ enum TransactionEventReportErrorCode {
INCORRECT_DETAILS
INVALID
NOT_FOUND
+ REQUIRED
}
"""
@@ -32351,6 +32673,7 @@ type TransactionInitializeError {
"""An enumeration."""
enum TransactionInitializeErrorCode {
+ CHECKOUT_COMPLETION_IN_PROGRESS
GRAPHQL_ERROR
INVALID
NOT_FOUND
@@ -32651,6 +32974,7 @@ type TransactionProcessError {
"""An enumeration."""
enum TransactionProcessErrorCode {
+ CHECKOUT_COMPLETION_IN_PROGRESS
GRAPHQL_ERROR
INVALID
MISSING_PAYMENT_APP
@@ -34550,6 +34874,31 @@ type Warehouse implements Node & ObjectWithMetadata {
"""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."""
@@ -34918,7 +35267,7 @@ input WebhookCreateInput {
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-*" and "Authorization*" keys are allowed.
+ 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.
@@ -36529,7 +36878,7 @@ input WebhookUpdateInput {
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-*" and "Authorization*" keys are allowed.
+ 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.
diff --git a/src/channels/components/ChannelForm/AutomaticallyCompleteCheckouts.tsx b/src/channels/components/ChannelForm/AutomaticallyCompleteCheckouts.tsx
new file mode 100644
index 00000000000..0744609926b
--- /dev/null
+++ b/src/channels/components/ChannelForm/AutomaticallyCompleteCheckouts.tsx
@@ -0,0 +1,58 @@
+import Link from "@dashboard/components/Link";
+import { FormChange } from "@dashboard/hooks/useForm";
+import { DOCS_ULRS } from "@dashboard/links";
+import { Box, Checkbox, Text } from "@saleor/macaw-ui-next";
+import React from "react";
+import { FormattedMessage } from "react-intl";
+
+import { messages } from "./messages";
+
+interface AutomaticallyCompleteCheckoutsProps {
+ onChange: FormChange;
+ isChecked: boolean;
+ hasError: boolean;
+ disabled?: boolean;
+}
+
+export const AutomaticallyCompleteCheckouts = ({
+ onChange,
+ isChecked,
+ hasError,
+ disabled,
+}: AutomaticallyCompleteCheckoutsProps) => (
+
+
+ onChange({ target: { name: "automaticallyCompleteCheckouts", value } })
+ }
+ disabled={disabled}
+ >
+
+
+ {" "}
+
+
+ {" "}
+
+
+
+
+ ),
+ }}
+ />
+
+
+
+);
diff --git a/src/channels/components/ChannelForm/ChannelForm.tsx b/src/channels/components/ChannelForm/ChannelForm.tsx
index 41a7b4ab135..48b38eaae86 100644
--- a/src/channels/components/ChannelForm/ChannelForm.tsx
+++ b/src/channels/components/ChannelForm/ChannelForm.tsx
@@ -1,3 +1,4 @@
+import { AutomaticallyCompleteCheckouts } from "@dashboard/channels/components/ChannelForm/AutomaticallyCompleteCheckouts";
import {
ChannelShippingZones,
ChannelWarehouses,
@@ -41,6 +42,7 @@ export interface FormData extends StockSettingsInput {
deleteExpiredOrdersAfter: number;
allowUnpaidOrders: boolean;
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum;
+ automaticallyCompleteCheckouts: boolean;
}
export interface ChannelFormProps {
@@ -56,6 +58,7 @@ export interface ChannelFormProps {
onDefaultCountryChange: (event: ChangeEvent) => void;
onMarkAsPaidStrategyChange: () => void;
onTransactionFlowStrategyChange: () => void;
+ onAutomaticallyCompleteCheckoutsChange: () => void;
}
export const ChannelForm: React.FC = ({
@@ -71,6 +74,7 @@ export const ChannelForm: React.FC = ({
onDefaultCountryChange,
onMarkAsPaidStrategyChange,
onTransactionFlowStrategyChange,
+ onAutomaticallyCompleteCheckoutsChange,
}) => {
const intl = useIntl();
const [, copy] = useClipboard();
@@ -212,6 +216,13 @@ export const ChannelForm: React.FC = ({
hasError={!!formErrors.defaultTransactionFlowStrategy}
disabled={disabled}
/>
+
+
>
);
diff --git a/src/channels/components/ChannelForm/messages.ts b/src/channels/components/ChannelForm/messages.ts
index 2a1c005fede..d9d2b947e80 100644
--- a/src/channels/components/ChannelForm/messages.ts
+++ b/src/channels/components/ChannelForm/messages.ts
@@ -67,4 +67,15 @@ export const messages = defineMessages({
"When enabled, all transactions would require an additional step to be charged. ({link})",
description: "When enabled, all transactions would require an additional step to be charged.",
},
+ automaticallyCompleteCheckoutsLabel: {
+ id: "GFkb2t",
+ defaultMessage: "Automatically complete checkouts when fully paid",
+ description: "automatically complete checkouts checkbox label",
+ },
+ automaticallyCompleteCheckoutsDescription: {
+ id: "hIh8bm",
+ defaultMessage:
+ "When enabled, checkouts detected as fully paid will be completed automatically, without checkoutComplete mutation. ({link})",
+ description: "automatically complete checkouts checkbox description",
+ },
});
diff --git a/src/channels/fixtures.ts b/src/channels/fixtures.ts
index 24859fc42cb..3e3b7abd951 100644
--- a/src/channels/fixtures.ts
+++ b/src/channels/fixtures.ts
@@ -58,6 +58,10 @@ export const channelsList: ChannelDetailsFragment[] = [
__typename: "PaymentSettings",
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum.CHARGE,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: true,
+ __typename: "CheckoutSettings",
+ },
},
{
__typename: "Channel",
@@ -98,6 +102,10 @@ export const channelsList: ChannelDetailsFragment[] = [
__typename: "PaymentSettings",
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum.CHARGE,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: true,
+ __typename: "CheckoutSettings",
+ },
},
{
__typename: "Channel",
@@ -138,6 +146,10 @@ export const channelsList: ChannelDetailsFragment[] = [
__typename: "PaymentSettings",
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum.CHARGE,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: true,
+ __typename: "CheckoutSettings",
+ },
},
{
__typename: "Channel",
@@ -178,6 +190,10 @@ export const channelsList: ChannelDetailsFragment[] = [
__typename: "PaymentSettings",
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum.CHARGE,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: true,
+ __typename: "CheckoutSettings",
+ },
},
{
__typename: "Channel",
@@ -218,6 +234,10 @@ export const channelsList: ChannelDetailsFragment[] = [
__typename: "PaymentSettings",
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum.CHARGE,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: true,
+ __typename: "CheckoutSettings",
+ },
},
{
__typename: "Channel",
@@ -258,6 +278,10 @@ export const channelsList: ChannelDetailsFragment[] = [
__typename: "PaymentSettings",
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum.CHARGE,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: true,
+ __typename: "CheckoutSettings",
+ },
},
{
__typename: "Channel",
@@ -298,6 +322,10 @@ export const channelsList: ChannelDetailsFragment[] = [
__typename: "PaymentSettings",
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum.CHARGE,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: true,
+ __typename: "CheckoutSettings",
+ },
},
];
@@ -340,6 +368,10 @@ export const channel: ChannelDetailsFragment = {
__typename: "PaymentSettings",
defaultTransactionFlowStrategy: TransactionFlowStrategyEnum.CHARGE,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: true,
+ __typename: "CheckoutSettings",
+ },
};
type ProductChannelsWithPricing = NonNullable[0] & {
diff --git a/src/channels/pages/ChannelDetailsPage/ChannelDetailsPage.tsx b/src/channels/pages/ChannelDetailsPage/ChannelDetailsPage.tsx
index d2bc82f7748..94970a57c78 100644
--- a/src/channels/pages/ChannelDetailsPage/ChannelDetailsPage.tsx
+++ b/src/channels/pages/ChannelDetailsPage/ChannelDetailsPage.tsx
@@ -102,8 +102,14 @@ const ChannelDetailsPage = function ({
channel?.defaultCountry.country || "",
);
const countryChoices = mapCountriesToChoices(countries || []);
- const { defaultCountry, stockSettings, orderSettings, paymentSettings, ...formData } =
- channel || ({} as ChannelDetailsFragment);
+ const {
+ defaultCountry,
+ stockSettings,
+ orderSettings,
+ paymentSettings,
+ checkoutSettings,
+ ...formData
+ } = channel || ({} as ChannelDetailsFragment);
const initialStockSettings: StockSettingsInput = {
allocationStrategy: AllocationStrategyEnum.PRIORITIZE_SORTING_ORDER,
...stockSettings,
@@ -125,6 +131,7 @@ const ChannelDetailsPage = function ({
deleteExpiredOrdersAfter: orderSettings?.deleteExpiredOrdersAfter,
allowUnpaidOrders: orderSettings?.allowUnpaidOrders,
defaultTransactionFlowStrategy: paymentSettings?.defaultTransactionFlowStrategy,
+ automaticallyCompleteCheckouts: checkoutSettings?.automaticallyCompleteFullyPaidCheckouts,
};
const getFilteredShippingZonesChoices = (
shippingZonesToDisplay: ChannelShippingZones,
@@ -211,6 +218,13 @@ const ChannelDetailsPage = function ({
: TransactionFlowStrategyEnum.CHARGE,
});
};
+
+ const handleAutomaticallyCompleteCheckoutsChange = () => {
+ set({
+ automaticallyCompleteCheckouts: !data.automaticallyCompleteCheckouts,
+ });
+ };
+
const allErrors = [...errors, ...validationErrors];
return (
@@ -239,6 +253,7 @@ const ChannelDetailsPage = function ({
onDefaultCountryChange={handleDefaultCountrySelect}
onMarkAsPaidStrategyChange={handleMarkAsPaidStrategyChange}
onTransactionFlowStrategyChange={handleTransactionFlowStrategyChange}
+ onAutomaticallyCompleteCheckoutsChange={handleAutomaticallyCompleteCheckoutsChange}
errors={allErrors}
/>
diff --git a/src/channels/views/ChannelCreate/ChannelCreate.tsx b/src/channels/views/ChannelCreate/ChannelCreate.tsx
index 077e0011f92..89509534f8e 100644
--- a/src/channels/views/ChannelCreate/ChannelCreate.tsx
+++ b/src/channels/views/ChannelCreate/ChannelCreate.tsx
@@ -74,6 +74,7 @@ export const ChannelCreateView = () => {
slug,
warehousesIdsToAdd,
warehousesToDisplay,
+ automaticallyCompleteCheckouts,
}: FormData) => {
const input: ChannelCreateInput = {
name,
@@ -93,6 +94,9 @@ export const ChannelCreateView = () => {
deleteExpiredOrdersAfter,
allowUnpaidOrders,
},
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: automaticallyCompleteCheckouts,
+ },
};
return saveChannel(input, warehousesToDisplay);
diff --git a/src/channels/views/ChannelDetails/ChannelDetails.tsx b/src/channels/views/ChannelDetails/ChannelDetails.tsx
index 2c457ea787e..ef237b15746 100644
--- a/src/channels/views/ChannelDetails/ChannelDetails.tsx
+++ b/src/channels/views/ChannelDetails/ChannelDetails.tsx
@@ -104,12 +104,16 @@ export const ChannelDetails: React.FC = ({ id, params }) =>
warehousesIdsToAdd,
warehousesIdsToRemove,
warehousesToDisplay,
+ automaticallyCompleteCheckouts,
}: FormData) => {
const updateChannelMutation = updateChannel({
variables: {
id: data?.channel.id,
input: {
name,
+ checkoutSettings: {
+ automaticallyCompleteFullyPaidCheckouts: automaticallyCompleteCheckouts,
+ },
slug,
defaultCountry,
addShippingZones: shippingZonesIdsToAdd,
diff --git a/src/fragments/channels.ts b/src/fragments/channels.ts
index 71aa61fb0f0..bcb233a565f 100644
--- a/src/fragments/channels.ts
+++ b/src/fragments/channels.ts
@@ -40,5 +40,8 @@ export const channelDetailsFragment = gql`
paymentSettings {
defaultTransactionFlowStrategy
}
+ checkoutSettings {
+ automaticallyCompleteFullyPaidCheckouts
+ }
}
`;
diff --git a/src/graphql/hooks.generated.ts b/src/graphql/hooks.generated.ts
index 311eed0d480..1873240bec8 100644
--- a/src/graphql/hooks.generated.ts
+++ b/src/graphql/hooks.generated.ts
@@ -655,6 +655,9 @@ export const ChannelDetailsFragmentDoc = gql`
paymentSettings {
defaultTransactionFlowStrategy
}
+ checkoutSettings {
+ automaticallyCompleteFullyPaidCheckouts
+ }
}
${ChannelFragmentDoc}
${WarehouseFragmentDoc}`;
diff --git a/src/graphql/typePolicies.generated.ts b/src/graphql/typePolicies.generated.ts
index 69b0bbe3144..12b4c3a34eb 100644
--- a/src/graphql/typePolicies.generated.ts
+++ b/src/graphql/typePolicies.generated.ts
@@ -1278,8 +1278,9 @@ export type CheckoutRemovePromoCodeFieldPolicy = {
checkoutErrors?: FieldPolicy | FieldReadFunction,
errors?: FieldPolicy | FieldReadFunction
};
-export type CheckoutSettingsKeySpecifier = ('useLegacyErrorFlow' | CheckoutSettingsKeySpecifier)[];
+export type CheckoutSettingsKeySpecifier = ('automaticallyCompleteFullyPaidCheckouts' | 'useLegacyErrorFlow' | CheckoutSettingsKeySpecifier)[];
export type CheckoutSettingsFieldPolicy = {
+ automaticallyCompleteFullyPaidCheckouts?: FieldPolicy | FieldReadFunction,
useLegacyErrorFlow?: FieldPolicy | FieldReadFunction
};
export type CheckoutShippingAddressUpdateKeySpecifier = ('checkout' | 'checkoutErrors' | 'errors' | CheckoutShippingAddressUpdateKeySpecifier)[];
@@ -2978,7 +2979,7 @@ export type ObjectWithMetadataFieldPolicy = {
privateMetafield?: FieldPolicy | FieldReadFunction,
privateMetafields?: FieldPolicy | FieldReadFunction
};
-export type OrderKeySpecifier = ('actions' | 'authorizeStatus' | 'availableCollectionPoints' | 'availableShippingMethods' | 'billingAddress' | 'canFinalize' | 'channel' | 'chargeStatus' | 'checkoutId' | 'collectionPointName' | 'created' | 'customerNote' | 'deliveryMethod' | 'discount' | 'discountName' | 'discounts' | 'displayGrossPrices' | 'errors' | 'events' | 'externalReference' | 'fulfillments' | 'giftCards' | 'grantedRefunds' | 'id' | 'invoices' | 'isPaid' | 'isShippingRequired' | 'languageCode' | 'languageCodeEnum' | 'lines' | 'metadata' | 'metafield' | 'metafields' | 'number' | 'origin' | 'original' | 'paymentStatus' | 'paymentStatusDisplay' | 'payments' | 'privateMetadata' | 'privateMetafield' | 'privateMetafields' | 'redirectUrl' | 'shippingAddress' | 'shippingMethod' | 'shippingMethodName' | 'shippingMethods' | 'shippingPrice' | 'shippingTaxClass' | 'shippingTaxClassMetadata' | 'shippingTaxClassName' | 'shippingTaxClassPrivateMetadata' | 'shippingTaxRate' | 'status' | 'statusDisplay' | 'subtotal' | 'taxExemption' | 'token' | 'total' | 'totalAuthorizePending' | 'totalAuthorized' | 'totalBalance' | 'totalCancelPending' | 'totalCanceled' | 'totalCaptured' | 'totalChargePending' | 'totalCharged' | 'totalGrantedRefund' | 'totalRefundPending' | 'totalRefunded' | 'totalRemainingGrant' | 'trackingClientId' | 'transactions' | 'translatedDiscountName' | 'undiscountedTotal' | 'updatedAt' | 'user' | 'userEmail' | 'voucher' | 'voucherCode' | 'weight' | OrderKeySpecifier)[];
+export type OrderKeySpecifier = ('actions' | 'authorizeStatus' | 'availableCollectionPoints' | 'availableShippingMethods' | 'billingAddress' | 'canFinalize' | 'channel' | 'chargeStatus' | 'checkoutId' | 'collectionPointName' | 'created' | 'customerNote' | 'deliveryMethod' | 'discount' | 'discountName' | 'discounts' | 'displayGrossPrices' | 'errors' | 'events' | 'externalReference' | 'fulfillments' | 'giftCards' | 'grantedRefunds' | 'id' | 'invoices' | 'isPaid' | 'isShippingRequired' | 'languageCode' | 'languageCodeEnum' | 'lines' | 'metadata' | 'metafield' | 'metafields' | 'number' | 'origin' | 'original' | 'paymentStatus' | 'paymentStatusDisplay' | 'payments' | 'privateMetadata' | 'privateMetafield' | 'privateMetafields' | 'redirectUrl' | 'shippingAddress' | 'shippingMethod' | 'shippingMethodName' | 'shippingMethods' | 'shippingPrice' | 'shippingTaxClass' | 'shippingTaxClassMetadata' | 'shippingTaxClassName' | 'shippingTaxClassPrivateMetadata' | 'shippingTaxRate' | 'status' | 'statusDisplay' | 'subtotal' | 'taxExemption' | 'token' | 'total' | 'totalAuthorizePending' | 'totalAuthorized' | 'totalBalance' | 'totalCancelPending' | 'totalCanceled' | 'totalCaptured' | 'totalChargePending' | 'totalCharged' | 'totalGrantedRefund' | 'totalRefundPending' | 'totalRefunded' | 'totalRemainingGrant' | 'trackingClientId' | 'transactions' | 'translatedDiscountName' | 'undiscountedShippingPrice' | 'undiscountedTotal' | 'updatedAt' | 'user' | 'userEmail' | 'voucher' | 'voucherCode' | 'weight' | OrderKeySpecifier)[];
export type OrderFieldPolicy = {
actions?: FieldPolicy | FieldReadFunction,
authorizeStatus?: FieldPolicy | FieldReadFunction,
@@ -3054,6 +3055,7 @@ export type OrderFieldPolicy = {
trackingClientId?: FieldPolicy | FieldReadFunction,
transactions?: FieldPolicy | FieldReadFunction,
translatedDiscountName?: FieldPolicy | FieldReadFunction,
+ undiscountedShippingPrice?: FieldPolicy | FieldReadFunction,
undiscountedTotal?: FieldPolicy | FieldReadFunction,
updatedAt?: FieldPolicy | FieldReadFunction,
user?: FieldPolicy | FieldReadFunction,
@@ -3372,12 +3374,13 @@ export type OrderGrantedRefundLineFieldPolicy = {
quantity?: FieldPolicy | FieldReadFunction,
reason?: FieldPolicy | FieldReadFunction
};
-export type OrderLineKeySpecifier = ('allocations' | 'digitalContentUrl' | 'id' | 'isGift' | 'isShippingRequired' | 'metadata' | 'metafield' | 'metafields' | 'privateMetadata' | 'privateMetafield' | 'privateMetafields' | 'productName' | 'productSku' | 'productVariantId' | 'quantity' | 'quantityFulfilled' | 'quantityToFulfill' | 'saleId' | 'taxClass' | 'taxClassMetadata' | 'taxClassName' | 'taxClassPrivateMetadata' | 'taxRate' | 'thumbnail' | 'totalPrice' | 'translatedProductName' | 'translatedVariantName' | 'undiscountedTotalPrice' | 'undiscountedUnitPrice' | 'unitDiscount' | 'unitDiscountReason' | 'unitDiscountType' | 'unitDiscountValue' | 'unitPrice' | 'variant' | 'variantName' | 'voucherCode' | OrderLineKeySpecifier)[];
+export type OrderLineKeySpecifier = ('allocations' | 'digitalContentUrl' | 'id' | 'isGift' | 'isPriceOverridden' | 'isShippingRequired' | 'metadata' | 'metafield' | 'metafields' | 'privateMetadata' | 'privateMetafield' | 'privateMetafields' | 'productName' | 'productSku' | 'productVariantId' | 'quantity' | 'quantityFulfilled' | 'quantityToFulfill' | 'saleId' | 'taxClass' | 'taxClassMetadata' | 'taxClassName' | 'taxClassPrivateMetadata' | 'taxRate' | 'thumbnail' | 'totalPrice' | 'translatedProductName' | 'translatedVariantName' | 'undiscountedTotalPrice' | 'undiscountedUnitPrice' | 'unitDiscount' | 'unitDiscountReason' | 'unitDiscountType' | 'unitDiscountValue' | 'unitPrice' | 'variant' | 'variantName' | 'voucherCode' | OrderLineKeySpecifier)[];
export type OrderLineFieldPolicy = {
allocations?: FieldPolicy | FieldReadFunction,
digitalContentUrl?: FieldPolicy | FieldReadFunction,
id?: FieldPolicy | FieldReadFunction,
isGift?: FieldPolicy | FieldReadFunction,
+ isPriceOverridden?: FieldPolicy | FieldReadFunction,
isShippingRequired?: FieldPolicy | FieldReadFunction,
metadata?: FieldPolicy | FieldReadFunction,
metafield?: FieldPolicy | FieldReadFunction,
@@ -5933,9 +5936,24 @@ export type StoredPaymentMethodRequestDeleteFieldPolicy = {
errors?: FieldPolicy | FieldReadFunction,
result?: FieldPolicy | FieldReadFunction
};
-export type SubscriptionKeySpecifier = ('event' | SubscriptionKeySpecifier)[];
+export type SubscriptionKeySpecifier = ('draftOrderCreated' | 'draftOrderDeleted' | 'draftOrderUpdated' | 'event' | 'orderBulkCreated' | 'orderCancelled' | 'orderConfirmed' | 'orderCreated' | 'orderExpired' | 'orderFulfilled' | 'orderFullyPaid' | 'orderFullyRefunded' | 'orderMetadataUpdated' | 'orderPaid' | 'orderRefunded' | 'orderUpdated' | SubscriptionKeySpecifier)[];
export type SubscriptionFieldPolicy = {
- event?: FieldPolicy | FieldReadFunction
+ draftOrderCreated?: FieldPolicy | FieldReadFunction,
+ draftOrderDeleted?: FieldPolicy | FieldReadFunction,
+ draftOrderUpdated?: FieldPolicy | FieldReadFunction,
+ event?: FieldPolicy | FieldReadFunction,
+ orderBulkCreated?: FieldPolicy | FieldReadFunction,
+ orderCancelled?: FieldPolicy | FieldReadFunction,
+ orderConfirmed?: FieldPolicy | FieldReadFunction,
+ orderCreated?: FieldPolicy | FieldReadFunction,
+ orderExpired?: FieldPolicy | FieldReadFunction,
+ orderFulfilled?: FieldPolicy | FieldReadFunction,
+ orderFullyPaid?: FieldPolicy | FieldReadFunction,
+ orderFullyRefunded?: FieldPolicy | FieldReadFunction,
+ orderMetadataUpdated?: FieldPolicy | FieldReadFunction,
+ orderPaid?: FieldPolicy | FieldReadFunction,
+ orderRefunded?: FieldPolicy | FieldReadFunction,
+ orderUpdated?: FieldPolicy | FieldReadFunction
};
export type TaxClassKeySpecifier = ('countries' | 'id' | 'metadata' | 'metafield' | 'metafields' | 'name' | 'privateMetadata' | 'privateMetafield' | 'privateMetafields' | TaxClassKeySpecifier)[];
export type TaxClassFieldPolicy = {
@@ -6104,10 +6122,11 @@ export type TaxableObjectFieldPolicy = {
shippingPrice?: FieldPolicy | FieldReadFunction,
sourceObject?: FieldPolicy | FieldReadFunction
};
-export type TaxableObjectDiscountKeySpecifier = ('amount' | 'name' | TaxableObjectDiscountKeySpecifier)[];
+export type TaxableObjectDiscountKeySpecifier = ('amount' | 'name' | 'type' | TaxableObjectDiscountKeySpecifier)[];
export type TaxableObjectDiscountFieldPolicy = {
amount?: FieldPolicy | FieldReadFunction,
- name?: FieldPolicy | FieldReadFunction
+ name?: FieldPolicy | FieldReadFunction,
+ type?: FieldPolicy | FieldReadFunction
};
export type TaxableObjectLineKeySpecifier = ('chargeTaxes' | 'productName' | 'productSku' | 'quantity' | 'sourceLine' | 'totalPrice' | 'unitPrice' | 'variantName' | TaxableObjectLineKeySpecifier)[];
export type TaxableObjectLineFieldPolicy = {
@@ -6726,7 +6745,7 @@ export type VoucherUpdatedFieldPolicy = {
version?: FieldPolicy | FieldReadFunction,
voucher?: FieldPolicy | FieldReadFunction
};
-export type WarehouseKeySpecifier = ('address' | 'clickAndCollectOption' | 'companyName' | 'email' | 'externalReference' | 'id' | 'isPrivate' | 'metadata' | 'metafield' | 'metafields' | 'name' | 'privateMetadata' | 'privateMetafield' | 'privateMetafields' | 'shippingZones' | 'slug' | WarehouseKeySpecifier)[];
+export type WarehouseKeySpecifier = ('address' | 'clickAndCollectOption' | 'companyName' | 'email' | 'externalReference' | 'id' | 'isPrivate' | 'metadata' | 'metafield' | 'metafields' | 'name' | 'privateMetadata' | 'privateMetafield' | 'privateMetafields' | 'shippingZones' | 'slug' | 'stocks' | WarehouseKeySpecifier)[];
export type WarehouseFieldPolicy = {
address?: FieldPolicy | FieldReadFunction,
clickAndCollectOption?: FieldPolicy | FieldReadFunction,
@@ -6743,7 +6762,8 @@ export type WarehouseFieldPolicy = {
privateMetafield?: FieldPolicy | FieldReadFunction,
privateMetafields?: FieldPolicy | FieldReadFunction,
shippingZones?: FieldPolicy | FieldReadFunction,
- slug?: FieldPolicy | FieldReadFunction
+ slug?: FieldPolicy | FieldReadFunction,
+ stocks?: FieldPolicy | FieldReadFunction
};
export type WarehouseCountableConnectionKeySpecifier = ('edges' | 'pageInfo' | 'totalCount' | WarehouseCountableConnectionKeySpecifier)[];
export type WarehouseCountableConnectionFieldPolicy = {
diff --git a/src/graphql/types.generated.ts b/src/graphql/types.generated.ts
index 459fa2fe73c..eefe99f4e52 100644
--- a/src/graphql/types.generated.ts
+++ b/src/graphql/types.generated.ts
@@ -51,6 +51,7 @@ export enum AccountErrorCode {
JWT_MISSING_TOKEN = 'JWT_MISSING_TOKEN',
JWT_SIGNATURE_EXPIRED = 'JWT_SIGNATURE_EXPIRED',
LEFT_NOT_MANAGEABLE_PERMISSION = 'LEFT_NOT_MANAGEABLE_PERMISSION',
+ LOGIN_ATTEMPT_DELAYED = 'LOGIN_ATTEMPT_DELAYED',
MISSING_CHANNEL_SLUG = 'MISSING_CHANNEL_SLUG',
NOT_FOUND = 'NOT_FOUND',
OUT_OF_SCOPE_GROUP = 'OUT_OF_SCOPE_GROUP',
@@ -62,7 +63,8 @@ export enum AccountErrorCode {
PASSWORD_TOO_SHORT = 'PASSWORD_TOO_SHORT',
PASSWORD_TOO_SIMILAR = 'PASSWORD_TOO_SIMILAR',
REQUIRED = 'REQUIRED',
- UNIQUE = 'UNIQUE'
+ UNIQUE = 'UNIQUE',
+ UNKNOWN_IP_ADDRESS = 'UNKNOWN_IP_ADDRESS'
}
/** Fields required to update the user. */
@@ -134,6 +136,14 @@ export type AddressInput = {
phone?: InputMaybe;
/** Postal code. */
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.
+ *
+ * Added in Saleor 3.19.
+ *
+ * Note: this API is currently in Feature Preview and can be subject to changes at later point.
+ */
+ skipValidation?: InputMaybe;
/** Address. */
streetAddress1?: InputMaybe;
/** Address. */
@@ -1218,7 +1228,7 @@ export enum CheckoutCreateFromOrderUnavailableVariantErrorCode {
}
export type CheckoutCreateInput = {
- /** Billing address of the customer. */
+ /** Billing address of the customer. `skipValidation` requires HANDLE_CHECKOUTS and AUTHENTICATED_APP permissions. */
billingAddress?: InputMaybe;
/** Slug of a channel in which to create a checkout. */
channel?: InputMaybe;
@@ -1228,7 +1238,7 @@ export type CheckoutCreateInput = {
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. */
+ /** 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;
/**
* The checkout validation rules that can be changed.
@@ -1333,6 +1343,12 @@ export type CheckoutLineUpdateInput = {
};
export type CheckoutSettingsInput = {
+ /**
+ * 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?: 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.
*
@@ -1548,7 +1564,11 @@ export enum ConfigurationTypeFieldEnum {
STRING = 'STRING'
}
-/** An enumeration. */
+/**
+ * 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.
+ */
export enum CountryCode {
AD = 'AD',
AE = 'AE',
@@ -4047,6 +4067,7 @@ export enum OrderEventsEnum {
PAYMENT_REFUNDED = 'PAYMENT_REFUNDED',
PAYMENT_VOIDED = 'PAYMENT_VOIDED',
PLACED = 'PLACED',
+ PLACED_AUTOMATICALLY_FROM_PAID_CHECKOUT = 'PLACED_AUTOMATICALLY_FROM_PAID_CHECKOUT',
PLACED_FROM_DRAFT = 'PLACED_FROM_DRAFT',
REMOVED_PRODUCTS = 'REMOVED_PRODUCTS',
TRACKING_UPDATED = 'TRACKING_UPDATED',
@@ -4063,6 +4084,7 @@ export type OrderFilterInput = {
channels?: InputMaybe>;
chargeStatus?: InputMaybe>;
checkoutIds?: InputMaybe>;
+ checkoutTokens?: InputMaybe>;
created?: InputMaybe;
customer?: InputMaybe;
giftCardBought?: InputMaybe;
@@ -4704,6 +4726,7 @@ export enum PaymentErrorCode {
BALANCE_CHECK_ERROR = 'BALANCE_CHECK_ERROR',
BILLING_ADDRESS_NOT_SET = 'BILLING_ADDRESS_NOT_SET',
CHANNEL_INACTIVE = 'CHANNEL_INACTIVE',
+ CHECKOUT_COMPLETION_IN_PROGRESS = 'CHECKOUT_COMPLETION_IN_PROGRESS',
CHECKOUT_EMAIL_NOT_SET = 'CHECKOUT_EMAIL_NOT_SET',
GRAPHQL_ERROR = 'GRAPHQL_ERROR',
INVALID = 'INVALID',
@@ -5980,13 +6003,9 @@ export type PromotionCreateInput = {
/**
* Defines the promotion type. Implicate the required promotion rules predicate type and whether the promotion rules will give the catalogue or order discount.
*
- * The default value is `Catalogue`.
- *
- * This field will be required from Saleor 3.20.
- *
* Added in Saleor 3.19.
*/
- type?: InputMaybe;
+ type: PromotionTypeEnum;
};
/** An enumeration. */
@@ -6987,6 +7006,12 @@ export enum TaxExemptionManageErrorCode {
NOT_FOUND = 'NOT_FOUND'
}
+/** Indicates which part of the order the discount should affect: SUBTOTAL or SHIPPING. */
+export enum TaxableObjectDiscountTypeEnum {
+ SHIPPING = 'SHIPPING',
+ SUBTOTAL = 'SUBTOTAL'
+}
+
export type TaxedMoneyInput = {
/** Gross value of an item. */
gross: Scalars['PositiveDecimal'];
@@ -7119,7 +7144,8 @@ export enum TransactionEventReportErrorCode {
GRAPHQL_ERROR = 'GRAPHQL_ERROR',
INCORRECT_DETAILS = 'INCORRECT_DETAILS',
INVALID = 'INVALID',
- NOT_FOUND = 'NOT_FOUND'
+ NOT_FOUND = 'NOT_FOUND',
+ REQUIRED = 'REQUIRED'
}
/**
@@ -7185,6 +7211,7 @@ export enum TransactionFlowStrategyEnum {
/** An enumeration. */
export enum TransactionInitializeErrorCode {
+ CHECKOUT_COMPLETION_IN_PROGRESS = 'CHECKOUT_COMPLETION_IN_PROGRESS',
GRAPHQL_ERROR = 'GRAPHQL_ERROR',
INVALID = 'INVALID',
NOT_FOUND = 'NOT_FOUND',
@@ -7207,6 +7234,7 @@ export enum TransactionKind {
/** An enumeration. */
export enum TransactionProcessErrorCode {
+ CHECKOUT_COMPLETION_IN_PROGRESS = 'CHECKOUT_COMPLETION_IN_PROGRESS',
GRAPHQL_ERROR = 'GRAPHQL_ERROR',
INVALID = 'INVALID',
MISSING_PAYMENT_APP = 'MISSING_PAYMENT_APP',
@@ -7692,7 +7720,7 @@ export type WebhookCreateInput = {
/** 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-*" and "Authorization*" keys are allowed.
+ * 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.
*
@@ -8857,7 +8885,7 @@ export type WebhookUpdateInput = {
/** 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-*" and "Authorization*" keys are allowed.
+ * 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.
*
@@ -9204,7 +9232,7 @@ export type ChannelCreateMutationVariables = Exact<{
}>;
-export type ChannelCreateMutation = { __typename: 'Mutation', channelCreate: { __typename: 'ChannelCreate', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
+export type ChannelCreateMutation = { __typename: 'Mutation', channelCreate: { __typename: 'ChannelCreate', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
export type ChannelUpdateMutationVariables = Exact<{
id: Scalars['ID'];
@@ -9212,7 +9240,7 @@ export type ChannelUpdateMutationVariables = Exact<{
}>;
-export type ChannelUpdateMutation = { __typename: 'Mutation', channelUpdate: { __typename: 'ChannelUpdate', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
+export type ChannelUpdateMutation = { __typename: 'Mutation', channelUpdate: { __typename: 'ChannelUpdate', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
export type ChannelDeleteMutationVariables = Exact<{
id: Scalars['ID'];
@@ -9227,14 +9255,14 @@ export type ChannelActivateMutationVariables = Exact<{
}>;
-export type ChannelActivateMutation = { __typename: 'Mutation', channelActivate: { __typename: 'ChannelActivate', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
+export type ChannelActivateMutation = { __typename: 'Mutation', channelActivate: { __typename: 'ChannelActivate', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
export type ChannelDeactivateMutationVariables = Exact<{
id: Scalars['ID'];
}>;
-export type ChannelDeactivateMutation = { __typename: 'Mutation', channelDeactivate: { __typename: 'ChannelDeactivate', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
+export type ChannelDeactivateMutation = { __typename: 'Mutation', channelDeactivate: { __typename: 'ChannelDeactivate', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
export type ChannelReorderWarehousesMutationVariables = Exact<{
channelId: Scalars['ID'];
@@ -9242,7 +9270,7 @@ export type ChannelReorderWarehousesMutationVariables = Exact<{
}>;
-export type ChannelReorderWarehousesMutation = { __typename: 'Mutation', channelReorderWarehouses: { __typename: 'ChannelReorderWarehouses', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
+export type ChannelReorderWarehousesMutation = { __typename: 'Mutation', channelReorderWarehouses: { __typename: 'ChannelReorderWarehouses', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null, errors: Array<{ __typename: 'ChannelError', code: ChannelErrorCode, field: string | null, message: string | null }> } | null };
export type BaseChannelsQueryVariables = Exact<{ [key: string]: never; }>;
@@ -9252,14 +9280,14 @@ export type BaseChannelsQuery = { __typename: 'Query', channels: Array<{ __typen
export type ChannelsQueryVariables = Exact<{ [key: string]: never; }>;
-export type ChannelsQuery = { __typename: 'Query', channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null };
+export type ChannelsQuery = { __typename: 'Query', channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null };
export type ChannelQueryVariables = Exact<{
id: Scalars['ID'];
}>;
-export type ChannelQuery = { __typename: 'Query', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null };
+export type ChannelQuery = { __typename: 'Query', channel: { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } } | null };
export type CollectionUpdateMutationVariables = Exact<{
id: Scalars['ID'];
@@ -9781,7 +9809,7 @@ export type PromotionCreateMutationVariables = Exact<{
}>;
-export type PromotionCreateMutation = { __typename: 'Mutation', promotionCreate: { __typename: 'PromotionCreate', errors: Array<{ __typename: 'PromotionCreateError', field: string | null, message: string | null, code: PromotionCreateErrorCode, index: number | null }>, promotion: { __typename: 'Promotion', id: string, name: string, type: PromotionTypeEnum | null, description: any | null, startDate: any, endDate: any | null, rules: Array<{ __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null }> | null } | null } | null };
+export type PromotionCreateMutation = { __typename: 'Mutation', promotionCreate: { __typename: 'PromotionCreate', errors: Array<{ __typename: 'PromotionCreateError', field: string | null, message: string | null, code: PromotionCreateErrorCode, index: number | null }>, promotion: { __typename: 'Promotion', id: string, name: string, type: PromotionTypeEnum | null, description: any | null, startDate: any, endDate: any | null, rules: Array<{ __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null }> | null } | null } | null };
export type PromotionUpdateMutationVariables = Exact<{
id: Scalars['ID'];
@@ -9789,7 +9817,7 @@ export type PromotionUpdateMutationVariables = Exact<{
}>;
-export type PromotionUpdateMutation = { __typename: 'Mutation', promotionUpdate: { __typename: 'PromotionUpdate', errors: Array<{ __typename: 'PromotionUpdateError', field: string | null, message: string | null, code: PromotionUpdateErrorCode }>, promotion: { __typename: 'Promotion', id: string, name: string, type: PromotionTypeEnum | null, description: any | null, startDate: any, endDate: any | null, rules: Array<{ __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null }> | null } | null } | null };
+export type PromotionUpdateMutation = { __typename: 'Mutation', promotionUpdate: { __typename: 'PromotionUpdate', errors: Array<{ __typename: 'PromotionUpdateError', field: string | null, message: string | null, code: PromotionUpdateErrorCode }>, promotion: { __typename: 'Promotion', id: string, name: string, type: PromotionTypeEnum | null, description: any | null, startDate: any, endDate: any | null, rules: Array<{ __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null }> | null } | null } | null };
export type PromotionDeleteMutationVariables = Exact<{
id: Scalars['ID'];
@@ -9804,14 +9832,14 @@ export type PromotionRuleUpdateMutationVariables = Exact<{
}>;
-export type PromotionRuleUpdateMutation = { __typename: 'Mutation', promotionRuleUpdate: { __typename: 'PromotionRuleUpdate', errors: Array<{ __typename: 'PromotionRuleUpdateError', field: string | null, message: string | null, code: PromotionRuleUpdateErrorCode, channels: Array | null }>, promotionRule: { __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null } | null } | null };
+export type PromotionRuleUpdateMutation = { __typename: 'Mutation', promotionRuleUpdate: { __typename: 'PromotionRuleUpdate', errors: Array<{ __typename: 'PromotionRuleUpdateError', field: string | null, message: string | null, code: PromotionRuleUpdateErrorCode, channels: Array | null }>, promotionRule: { __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null } | null } | null };
export type PromotionRuleCreateMutationVariables = Exact<{
input: PromotionRuleCreateInput;
}>;
-export type PromotionRuleCreateMutation = { __typename: 'Mutation', promotionRuleCreate: { __typename: 'PromotionRuleCreate', errors: Array<{ __typename: 'PromotionRuleCreateError', field: string | null, message: string | null, code: PromotionRuleCreateErrorCode }>, promotionRule: { __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null } | null } | null };
+export type PromotionRuleCreateMutation = { __typename: 'Mutation', promotionRuleCreate: { __typename: 'PromotionRuleCreate', errors: Array<{ __typename: 'PromotionRuleCreateError', field: string | null, message: string | null, code: PromotionRuleCreateErrorCode }>, promotionRule: { __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null } | null } | null };
export type PromotionRuleDeleteMutationVariables = Exact<{
id: Scalars['ID'];
@@ -9903,7 +9931,7 @@ export type PromotionDetailsQueryVariables = Exact<{
}>;
-export type PromotionDetailsQuery = { __typename: 'Query', promotion: { __typename: 'Promotion', id: string, name: string, type: PromotionTypeEnum | null, description: any | null, startDate: any, endDate: any | null, rules: Array<{ __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null }> | null } | null };
+export type PromotionDetailsQuery = { __typename: 'Query', promotion: { __typename: 'Promotion', id: string, name: string, type: PromotionTypeEnum | null, description: any | null, startDate: any, endDate: any | null, rules: Array<{ __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null }> | null } | null };
export type RuleConditionsSelectedOptionsDetailsQueryVariables = Exact<{
categoriesIds?: InputMaybe | Scalars['ID']>;
@@ -9984,7 +10012,7 @@ export type ChannelErrorFragment = { __typename: 'ChannelError', code: ChannelEr
export type ChannelFragment = { __typename: 'Channel', id: string, isActive: boolean, name: string, slug: string, currencyCode: string, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } };
-export type ChannelDetailsFragment = { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } };
+export type ChannelDetailsFragment = { __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } };
export type CollectionFragment = { __typename: 'Collection', id: string, name: string, channelListings: Array<{ __typename: 'CollectionChannelListing', isPublished: boolean, publishedAt: any | null, channel: { __typename: 'Channel', id: string, name: string } }> | null };
@@ -10008,9 +10036,9 @@ export type VoucherCodeFragment = { __typename: 'VoucherCode', code: string | nu
export type VoucherDetailsFragment = { __typename: 'Voucher', usageLimit: number | null, used: number, applyOncePerOrder: boolean, applyOncePerCustomer: boolean, onlyForStaff: boolean, singleUse: boolean, id: string, name: string | null, startDate: any, endDate: any | null, type: VoucherTypeEnum, discountValueType: DiscountValueTypeEnum, minCheckoutItemsQuantity: number | null, productsCount: { __typename: 'ProductCountableConnection', totalCount: number | null } | null, collectionsCount: { __typename: 'CollectionCountableConnection', totalCount: number | null } | null, categoriesCount: { __typename: 'CategoryCountableConnection', totalCount: number | null } | null, products?: { __typename: 'ProductCountableConnection', edges: Array<{ __typename: 'ProductCountableEdge', node: { __typename: 'Product', id: string, name: string, productType: { __typename: 'ProductType', id: string, name: string }, thumbnail: { __typename: 'Image', url: string } | null, channelListings: Array<{ __typename: 'ProductChannelListing', id: string, isPublished: boolean, publishedAt: any | null, isAvailableForPurchase: boolean | null, availableForPurchaseAt: any | null, visibleInListings: boolean, channel: { __typename: 'Channel', id: string, name: string, currencyCode: string } }> | null } }>, pageInfo: { __typename: 'PageInfo', endCursor: string | null, hasNextPage: boolean, hasPreviousPage: boolean, startCursor: string | null } } | null, collections?: { __typename: 'CollectionCountableConnection', edges: Array<{ __typename: 'CollectionCountableEdge', node: { __typename: 'Collection', id: string, name: string, products: { __typename: 'ProductCountableConnection', totalCount: number | null } | null } }>, pageInfo: { __typename: 'PageInfo', endCursor: string | null, hasNextPage: boolean, hasPreviousPage: boolean, startCursor: string | null } } | null, categories?: { __typename: 'CategoryCountableConnection', edges: Array<{ __typename: 'CategoryCountableEdge', node: { __typename: 'Category', id: string, name: string, products: { __typename: 'ProductCountableConnection', totalCount: number | null } | null } }>, pageInfo: { __typename: 'PageInfo', endCursor: string | null, hasNextPage: boolean, hasPreviousPage: boolean, startCursor: string | null } } | null, countries: Array<{ __typename: 'CountryDisplay', code: string, country: string }> | null, channelListings: Array<{ __typename: 'VoucherChannelListing', id: string, discountValue: number, currency: string, channel: { __typename: 'Channel', id: string, name: string, currencyCode: string }, minSpent: { __typename: 'Money', amount: number, currency: string } | null }> | null, metadata: Array<{ __typename: 'MetadataItem', key: string, value: string }>, privateMetadata: Array<{ __typename: 'MetadataItem', key: string, value: string }> };
-export type PromotionRuleDetailsFragment = { __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null };
+export type PromotionRuleDetailsFragment = { __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null };
-export type PromotionDetailsFragment = { __typename: 'Promotion', id: string, name: string, type: PromotionTypeEnum | null, description: any | null, startDate: any, endDate: any | null, rules: Array<{ __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null }> | null };
+export type PromotionDetailsFragment = { __typename: 'Promotion', id: string, name: string, type: PromotionTypeEnum | null, description: any | null, startDate: any, endDate: any | null, rules: Array<{ __typename: 'PromotionRule', id: string, name: string | null, description: any | null, giftIds: Array | null, rewardType: RewardTypeEnum | null, rewardValueType: RewardValueTypeEnum | null, rewardValue: any | null, cataloguePredicate: any | null, orderPredicate: any | null, channels: Array<{ __typename: 'Channel', hasOrders: boolean, id: string, isActive: boolean, name: string, slug: string, currencyCode: string, warehouses: Array<{ __typename: 'Warehouse', id: string, name: string }>, orderSettings: { __typename: 'OrderSettings', markAsPaidStrategy: MarkAsPaidStrategyEnum, deleteExpiredOrdersAfter: any, allowUnpaidOrders: boolean }, paymentSettings: { __typename: 'PaymentSettings', defaultTransactionFlowStrategy: TransactionFlowStrategyEnum }, checkoutSettings: { __typename: 'CheckoutSettings', automaticallyCompleteFullyPaidCheckouts: boolean }, defaultCountry: { __typename: 'CountryDisplay', code: string, country: string }, stockSettings: { __typename: 'StockSettings', allocationStrategy: AllocationStrategyEnum } }> | null }> | null };
export type PromotionFragment = { __typename: 'Promotion', id: string, name: string, startDate: any, endDate: any | null, type: PromotionTypeEnum | null, metadata: Array<{ __typename: 'MetadataItem', key: string, value: string }>, privateMetadata: Array<{ __typename: 'MetadataItem', key: string, value: string }> };
@@ -10440,7 +10468,7 @@ export type SaleTranslationFragment = { __typename: 'SaleTranslatableContent', s
export type VoucherTranslationFragment = { __typename: 'VoucherTranslatableContent', name: string | null, voucher: { __typename: 'Voucher', id: string, name: string | null } | null, translation: { __typename: 'VoucherTranslation', id: string, name: string | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null };
-export type ShippingMethodTranslationFragment = { __typename: 'ShippingMethodTranslatableContent', id: string, name: string, description: any | null, shippingMethod: { __typename: 'ShippingMethodType', id: string } | null, translation: { __typename: 'ShippingMethodTranslation', id: string, name: string, description: any | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null };
+export type ShippingMethodTranslationFragment = { __typename: 'ShippingMethodTranslatableContent', id: string, name: string, description: any | null, shippingMethod: { __typename: 'ShippingMethodType', id: string } | null, translation: { __typename: 'ShippingMethodTranslation', id: string, name: string | null, description: any | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null };
export type PageTranslationFragment = { __typename: 'PageTranslatableContent', page: { __typename: 'Page', id: string, content: any | null, seoDescription: string | null, seoTitle: string | null, title: string } | null, translation: { __typename: 'PageTranslation', id: string, content: any | null, seoDescription: string | null, seoTitle: string | null, title: string | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null, attributeValues: Array<{ __typename: 'AttributeValueTranslatableContent', id: string, name: string, plainText: string | null, richText: any | null, attributeValue: { __typename: 'AttributeValue', id: string } | null, attribute: { __typename: 'AttributeTranslatableContent', id: string, name: string } | null, translation: { __typename: 'AttributeValueTranslation', id: string, name: string, plainText: string | null, richText: any | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null }> };
@@ -12335,7 +12363,7 @@ export type UpdateShippingMethodTranslationsMutationVariables = Exact<{
}>;
-export type UpdateShippingMethodTranslationsMutation = { __typename: 'Mutation', shippingPriceTranslate: { __typename: 'ShippingPriceTranslate', errors: Array<{ __typename: 'TranslationError', code: TranslationErrorCode, field: string | null, message: string | null }>, shippingMethod: { __typename: 'ShippingMethodType', id: string, name: string, description: any | null, translation: { __typename: 'ShippingMethodTranslation', id: string, name: string, description: any | null, language: { __typename: 'LanguageDisplay', language: string } } | null } | null } | null };
+export type UpdateShippingMethodTranslationsMutation = { __typename: 'Mutation', shippingPriceTranslate: { __typename: 'ShippingPriceTranslate', errors: Array<{ __typename: 'TranslationError', code: TranslationErrorCode, field: string | null, message: string | null }>, shippingMethod: { __typename: 'ShippingMethodType', id: string, name: string, description: any | null, translation: { __typename: 'ShippingMethodTranslation', id: string, name: string | null, description: any | null, language: { __typename: 'LanguageDisplay', language: string } } | null } | null } | null };
export type UpdateMenuItemTranslationsMutationVariables = Exact<{
id: Scalars['ID'];
@@ -12432,7 +12460,7 @@ export type ShippingMethodTranslationsQueryVariables = Exact<{
}>;
-export type ShippingMethodTranslationsQuery = { __typename: 'Query', translations: { __typename: 'TranslatableItemConnection', edges: Array<{ __typename: 'TranslatableItemEdge', node: { __typename: 'AttributeTranslatableContent' } | { __typename: 'AttributeValueTranslatableContent' } | { __typename: 'CategoryTranslatableContent' } | { __typename: 'CollectionTranslatableContent' } | { __typename: 'MenuItemTranslatableContent' } | { __typename: 'PageTranslatableContent' } | { __typename: 'ProductTranslatableContent' } | { __typename: 'ProductVariantTranslatableContent' } | { __typename: 'PromotionRuleTranslatableContent' } | { __typename: 'PromotionTranslatableContent' } | { __typename: 'SaleTranslatableContent' } | { __typename: 'ShippingMethodTranslatableContent', id: string, name: string, description: any | null, shippingMethod: { __typename: 'ShippingMethodType', id: string } | null, translation: { __typename: 'ShippingMethodTranslation', id: string, name: string, description: any | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null } | { __typename: 'VoucherTranslatableContent' } }>, pageInfo: { __typename: 'PageInfo', endCursor: string | null, hasNextPage: boolean, hasPreviousPage: boolean, startCursor: string | null } } | null };
+export type ShippingMethodTranslationsQuery = { __typename: 'Query', translations: { __typename: 'TranslatableItemConnection', edges: Array<{ __typename: 'TranslatableItemEdge', node: { __typename: 'AttributeTranslatableContent' } | { __typename: 'AttributeValueTranslatableContent' } | { __typename: 'CategoryTranslatableContent' } | { __typename: 'CollectionTranslatableContent' } | { __typename: 'MenuItemTranslatableContent' } | { __typename: 'PageTranslatableContent' } | { __typename: 'ProductTranslatableContent' } | { __typename: 'ProductVariantTranslatableContent' } | { __typename: 'PromotionRuleTranslatableContent' } | { __typename: 'PromotionTranslatableContent' } | { __typename: 'SaleTranslatableContent' } | { __typename: 'ShippingMethodTranslatableContent', id: string, name: string, description: any | null, shippingMethod: { __typename: 'ShippingMethodType', id: string } | null, translation: { __typename: 'ShippingMethodTranslation', id: string, name: string | null, description: any | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null } | { __typename: 'VoucherTranslatableContent' } }>, pageInfo: { __typename: 'PageInfo', endCursor: string | null, hasNextPage: boolean, hasPreviousPage: boolean, startCursor: string | null } } | null };
export type MenuItemTranslationsQueryVariables = Exact<{
language: LanguageCodeEnum;
@@ -12526,7 +12554,7 @@ export type ShippingMethodTranslationDetailsQueryVariables = Exact<{
}>;
-export type ShippingMethodTranslationDetailsQuery = { __typename: 'Query', translation: { __typename: 'AttributeTranslatableContent' } | { __typename: 'AttributeValueTranslatableContent' } | { __typename: 'CategoryTranslatableContent' } | { __typename: 'CollectionTranslatableContent' } | { __typename: 'MenuItemTranslatableContent' } | { __typename: 'PageTranslatableContent' } | { __typename: 'ProductTranslatableContent' } | { __typename: 'ProductVariantTranslatableContent' } | { __typename: 'PromotionRuleTranslatableContent' } | { __typename: 'PromotionTranslatableContent' } | { __typename: 'SaleTranslatableContent' } | { __typename: 'ShippingMethodTranslatableContent', id: string, name: string, description: any | null, shippingMethod: { __typename: 'ShippingMethodType', id: string } | null, translation: { __typename: 'ShippingMethodTranslation', id: string, name: string, description: any | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null } | { __typename: 'VoucherTranslatableContent' } | null };
+export type ShippingMethodTranslationDetailsQuery = { __typename: 'Query', translation: { __typename: 'AttributeTranslatableContent' } | { __typename: 'AttributeValueTranslatableContent' } | { __typename: 'CategoryTranslatableContent' } | { __typename: 'CollectionTranslatableContent' } | { __typename: 'MenuItemTranslatableContent' } | { __typename: 'PageTranslatableContent' } | { __typename: 'ProductTranslatableContent' } | { __typename: 'ProductVariantTranslatableContent' } | { __typename: 'PromotionRuleTranslatableContent' } | { __typename: 'PromotionTranslatableContent' } | { __typename: 'SaleTranslatableContent' } | { __typename: 'ShippingMethodTranslatableContent', id: string, name: string, description: any | null, shippingMethod: { __typename: 'ShippingMethodType', id: string } | null, translation: { __typename: 'ShippingMethodTranslation', id: string, name: string | null, description: any | null, language: { __typename: 'LanguageDisplay', code: LanguageCodeEnum, language: string } } | null } | { __typename: 'VoucherTranslatableContent' } | null };
export type MenuItemTranslationDetailsQueryVariables = Exact<{
id: Scalars['ID'];
diff --git a/src/links.ts b/src/links.ts
index 39306c97691..220e9c4e29c 100644
--- a/src/links.ts
+++ b/src/links.ts
@@ -1,2 +1,7 @@
export const TECHNICAL_HELP_CTA_URL =
"https://www.getclockwise.com/c/rian-dillon-saleor-io/short-call-with-saleor";
+
+export const DOCS_ULRS = {
+ TRANSACTIONS_AUTOMATIC_CHECKOUT_COMPLETION:
+ "https://docs.saleor.io/developer/payments/transactions#automatic-checkout-completion",
+};
diff --git a/src/orders/components/OrderHistory/messages.ts b/src/orders/components/OrderHistory/messages.ts
index 69b45f5e1d2..16ce345cf43 100644
--- a/src/orders/components/OrderHistory/messages.ts
+++ b/src/orders/components/OrderHistory/messages.ts
@@ -205,6 +205,12 @@ export const getEventMessage = (event: OrderEventFragment, intl: IntlShape): str
defaultMessage: "Order was marked as paid",
description: "order history message",
});
+ case OrderEventsEnum.PLACED_AUTOMATICALLY_FROM_PAID_CHECKOUT:
+ return intl.formatMessage({
+ id: "E4GW+N",
+ defaultMessage: "Order created automatically from fully paid checkout",
+ description: "fully paid checkout automatically completed message",
+ });
case OrderEventsEnum.OTHER:
return event.message;
case OrderEventsEnum.OVERSOLD_ITEMS: