> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # RemoveCoupon # Package: checkout # Namespace: CheckoutService # Method link: https://dev.wix.com/docs/api-reference/business-solutions/e-commerce/purchase-flow/checkout/checkout/remove-coupon.md ## Permission Scopes: Manage Orders: SCOPE.DC-STORES.MANAGE-ORDERS ## Introduction Removes the coupon from a specified checkout. --- ## REST API ### Schema ``` Method: removeCoupon Description: Removes the coupon from a specified checkout. URL: https://www.wixapis.com/ecom/v1/checkouts/{id}/remove-coupon Method: POST Return type: RemoveCouponResponse - name: checkout | type: Checkout | description: Updated checkout after removal of coupon. - name: id | type: string | description: Checkout GUID. - name: lineItems | type: array | description: Line items. Max: 300 items - name: id | type: string | description: Line item GUID. - name: quantity | type: integer | description: Item quantity. Min: `"1"` Max: `"100000"` - name: catalogReference | type: CatalogReference | description: Catalog and item reference. Includes GUIDs for the item and the catalog it came from, as well as further optional info. Optional for custom line items, which don't trigger the Catalog service plugin. - name: catalogItemId | type: string | description: GUID of the item within the catalog it belongs to. - name: appId | type: string | description: GUID of the app providing the catalog. You can get your app's GUID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/). For items from Wix catalogs, the following values always apply: + Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"` + Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"` + Wix Restaurants: `"9a5d83fd-8570-482e-81ab-cfa88942ee60"` - name: options | type: object | description: Additional item details in `key:value` pairs. Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items. For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration.md) or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration.md), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction.md). - name: productName | type: ProductName | description: Item name. + Stores - `product.name` + Bookings - `service.info.name` + Events - `ticket.name` - name: original | type: string | description: __Required.__ Item name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). Min: 1 character. Max: 200 characters. - name: translated | type: string | description: Item name translated into the buyer's language. Min: 1 character. Max: 400 characters. Default: Same as `original`. - name: url | type: PageUrlV2 | description: URL to the item's page on the site. - name: relativePath | type: string | description: The relative path for the page within the site. For example, `/product-page/a-product`. - name: url | type: string | description: The page's full URL. For example, `https://mysite.com/product-page/a-product`. - name: price | type: MultiCurrencyPrice | description: Item price **after** catalog-defined discount and line item discounts. - name: amount | type: string | description: Amount. - name: convertedAmount | type: string | description: Converted amount. - name: formattedAmount | type: string | description: Amount formatted with currency symbol. - name: formattedConvertedAmount | type: string | description: Converted amount formatted with currency symbol. - name: lineItemPrice | type: MultiCurrencyPrice | description: Total line item price **after** catalog-defined discount and line item discounts. - name: fullPrice | type: MultiCurrencyPrice | description: Item price **before** catalog-defined discount. Defaults to `price` when not provided. - name: priceBeforeDiscounts | type: MultiCurrencyPrice | description: Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. - name: totalPriceAfterTax | type: MultiCurrencyPrice | description: Total price after all discounts and tax. - name: totalPriceBeforeTax | type: MultiCurrencyPrice | description: Total price after discounts, and before tax. - name: taxDetails | type: ItemTaxFullDetails | description: Tax details for this line item. - name: taxableAmount | type: MultiCurrencyPrice | description: Amount for which tax is calculated. - name: taxRate | type: string | description: Tax rate %, as a decimal point between 0 and 1. - name: totalTax | type: MultiCurrencyPrice | description: Calculated tax, based on `taxable_amount` and `tax_rate`. - name: taxBreakdown | type: array | description: tax information for a line item. - name: jurisdiction | type: string | description: The name of the jurisdiction to which this tax detail applies. For example, "New York" or "Quebec". - name: nonTaxableAmount | type: MultiCurrencyPrice | description: The amount of this line item price that was considered nontaxable. (Decimal value) - name: rate | type: string | description: The rate at which this tax detail was calculated, e.g 0.1000 signifies 10% tax and 2.0000 signifies 200% tax. (Decimal value) - name: taxAmount | type: MultiCurrencyPrice | description: The amount of tax estimated for this line item. (Decimal value) - name: taxableAmount | type: MultiCurrencyPrice | description: The taxable amount of this line item. - name: taxType | type: string | description: The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc. - name: taxName | type: string | description: The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc. This name should be explicit enough to allow the merchant to understand what tax was calculated. - name: jurisdictionType | type: JurisdictionType | description: The type of the jurisdiction in which this tax detail applies. - enum: UNDEFINED, COUNTRY, STATE, COUNTY, CITY, SPECIAL - name: discount | type: MultiCurrencyPrice | description: Discount for this line item's entire quantity. - name: descriptionLines | type: array | description: Line item description lines. Used for display purposes for the cart, checkout and order. - ONE-OF: - name: plainText | type: PlainTextValue | description: Description line plain text value. - name: original | type: string | description: Description line plain text value in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Description line plain text value translated into the buyer's language. Default: Same as `original`. - name: colorInfo | type: Color | description: Description line color value. - name: original | type: string | description: Description line color name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Description line color name translated into the buyer's language. Default: Same as `original`. - name: code | type: string | description: HEX or RGB color code for display. - name: name | type: DescriptionLineName | description: Description line name. - name: original | type: string | description: Description line name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Description line name translated into the buyer's language. Default: Same as `original`. - name: media | type: Image | description: Line item image details. - name: id | type: string | description: WixMedia image GUID. - name: url | type: string | description: Image URL. - name: height | type: integer | description: Original image height. - name: width | type: integer | description: Original image width. - name: altText | type: string | description: Image alt text. - name: filename | type: string | description: Image filename. - name: availability | type: ItemAvailabilityInfo | description: Item availability details. - name: status | type: ItemAvailabilityStatus | description: Item availability status. - enum: - AVAILABLE: - NOT_FOUND: Item does not exist. - NOT_AVAILABLE: Item is not in stock. - PARTIALLY_AVAILABLE: Available quantity is less than requested. - name: quantityAvailable | type: integer | description: Quantity available. - name: physicalProperties | type: PhysicalProperties | description: Physical properties of the item. When relevant, contains information such as SKU, item weight, and shippability. - name: weight | type: number | description: Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. - name: sku | type: string | description: Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). - name: shippable | type: boolean | description: Whether this line item is shippable. - name: itemType | type: ItemType | description: Item type. Either a preset type or custom. - ONE-OF: - name: preset | type: ItemTypePreset | description: Preset item type. - enum: UNRECOGNISED, PHYSICAL, DIGITAL, GIFT_CARD, SERVICE - name: custom | type: string | description: Custom item type. When none of the preset types are suitable, specifies the custom type. - name: subscriptionOptionInfo | type: SubscriptionOptionInfo | description: Subscription option information. - name: subscriptionSettings | type: SubscriptionSettings | description: Subscription option settings. - name: frequency | type: SubscriptionFrequency | description: Frequency of recurring payment. - enum: UNDEFINED, DAY, WEEK, MONTH, YEAR - name: interval | type: integer | description: Interval of recurring payment. Default: `1`. If SubscriptionFrequency is Day the minimum interval is 7 - name: autoRenewal | type: boolean | description: Whether subscription is renewed automatically at the end of each period. - name: billingCycles | type: integer | description: Number of billing cycles before subscription ends. Ignored if `autoRenewal` is `true`. - name: enableCustomerCancellation | type: boolean | description: Whether to allow the customer to cancel the subscription.. - name: freeTrialPeriod | type: FreeTrialPeriod | description: Period until first cycle starts. If applied payNow will be 0 If None => no free trial - name: frequency | type: SubscriptionFrequency | description: Frequency of period. Values: DAY, WEEK, MONTH, YEAR - name: interval | type: integer | description: Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial. - name: title | type: Title | description: Subscription option title. - name: original | type: string | description: Subscription option name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Subscription option name translated into the buyer's language. Default: Same as `original`. - name: description | type: Description | description: Subscription option description. - name: original | type: string | description: Subscription option description. - name: translated | type: string | description: Translated subscription option description. - name: paymentOption | type: PaymentOptionType | description: Type of selected payment option for current item. Default: `FULL_PAYMENT_ONLINE` - enum: - FULL_PAYMENT_ONLINE: The entire payment for this item happens as part of the checkout. - FULL_PAYMENT_OFFLINE: The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. - MEMBERSHIP: Payment for this item is done by charging a membership. Any remaining amount not covered by the membership, such as item modifiers, is paid online. - DEPOSIT_ONLINE: Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. - MEMBERSHIP_OFFLINE: Payment for this item can only be done by charging a membership and must be manually redeemed in the dashboard by the site admin. When selected, `price` is `0`. - MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER: Item price is charged to online membership. Any remaining amount not covered by the membership, such as item modifiers, is paid offline. - name: serviceProperties | type: ServiceProperties | description: Service properties. When relevant, this contains information such as date and number of participants. - name: scheduledDate | type: string | description: Date and time the service is to be provided, in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format. For example, the start time of a class. - name: numberOfParticipants | type: integer | description: The number of people participating in the service. For example, the number of people attending a class or the number of people per hotel room. - name: rootCatalogItemId | type: string | description: In cases where `catalogReference.catalogItemId` is NOT the actual catalog item GUID, this field will return the true item's GUID. + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking GUID. Therefore this value is set to the service GUID. + In most cases, this field has the same value as `catalogReference.catalogItemId`. + Used in membership validation. - name: priceDescription | type: PriceDescription | description: Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". - name: original | type: string | description: __Required.__ Price description in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Price description translated into the buyer's language. Default: Same as `original`. - name: depositAmount | type: MultiCurrencyPrice | description: Partial payment to be paid upfront during the checkout. Eligible for catalog items with `lineItem.paymentOption` type `DEPOSIT_ONLINE` only. - name: deliveryProfileId | type: string | description: Delivery profile GUID. - name: customLineItem | type: boolean | description: Whether the line item is a custom line item. Custom line items don't trigger the Catalog service plugin. - name: consentRequiredPaymentPolicy | type: string | description: Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page. - name: catalogOverrideFields | type: CatalogOverrideFields | description: Overriding values for catalog item properties. To override catalog fields, your app must have the permission scope named "Manage eCommerce - Admin Permissions". Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions.md). - name: productName | type: ProductName | description: Item name. - name: price | type: string | description: Item price **after** discounts. - name: fullPrice | type: string | description: Item price **before** discounts. - name: descriptionLines | type: array | description: Item description lines. Used when displaying the line item to customers. - name: physicalProperties | type: PhysicalProperties | description: Physical properties of the item. - name: image | type: Image | description: Item image. - name: id | type: string | description: WixMedia image GUID. - name: height | type: integer | description: Original image height. - name: width | type: integer | description: Original image width. - name: altText | type: string | description: Image alt text. Optional. - name: filename | type: string | description: Image filename. Optional. - name: paymentOption | type: PaymentOption | description: Payment method selected for the item. - name: value | type: PaymentOptionType | description: Type of selected payment option for current item. Default: `FULL_PAYMENT_ONLINE` - name: depositAmount | type: string | description: Only eligible for catalog items with `lineItem.paymentOption.value` type of `DEPOSIT_ONLINE`. - name: savePaymentMethod | type: boolean | description: Whether to save the payment method on the order. Default: `false` - name: inventoryAppId | type: string | description: GUID of the app managing the inventory. - name: priceUndetermined | type: boolean | description: Whether the price is not yet defined, and will be updated after the order is created. - name: fixedQuantity | type: boolean | description: Whether the line item quantity is fixed and cannot be changed. - name: savePaymentMethod | type: boolean | description: Whether to save the payment method on the order. Default: `false` - name: taxableAddress | type: TaxableAddress | description: Address to use for tax calculation purposes. - ONE-OF: - name: addressType | type: TaxableAddressType | description: taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. - enum: BUSINESS, BILLING, SHIPPING - name: extendedFields | type: ExtendedFields | description: Custom extended fields for the line item object. [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md) must be configured using the 'Checkout & Orders - Line Items Schema Plugin' in the app dashboard before they can be accessed with API calls. - name: namespaces | type: object | description: Extended field data. Each key corresponds to the namespace of the app that created the extended fields. The value of each key is structured according to the schema defined when the extended fields were configured. You can only access fields for which you have the appropriate permissions. Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md). - name: policies | type: array | description: Policies to be displayed to the customer on the checkout page. - name: title | type: string | description: Policy title - should be translated - name: content | type: string | description: Policy content - should be translated - name: membersOnly | type: boolean | description: Whether the item can only be purchased by site members. Default: `false` - name: modifierGroups | type: array | description: Modifier groups that were added to the item. - name: id | type: string | description: Modifier group GUID. - name: name | type: TranslatableString | description: Modifier group name. - name: original | type: string | description: __Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). Min: 1 character. Max: 200 characters. - name: translated | type: string | description: String translated into the buyer's language. Min: 1 character. Max: 400 characters. Default: Same as `original`. - name: modifiers | type: array | description: List of modifiers in this group. - name: id | type: string | description: Modifier GUID. - name: quantity | type: integer | description: The quantity of this modifier. - name: label | type: TranslatableString | description: Primary display label for the modifier. - name: details | type: TranslatableString | description: Additional details. - name: price | type: MultiCurrencyPrice | description: The price of the modifier. - name: modifiersTotalPrice | type: MultiCurrencyPrice | description: Total price of all item modifiers. Included in the item price. - name: billingInfo | type: AddressWithContact | description: Billing information. - name: address | type: Address | description: Address. - name: country | type: string | description: Two-letter country code in [ISO-3166 alpha-2](https://www.iso.org/obp/ui/#search/code/) format. - name: subdivision | type: string | description: Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://www.iso.org/standard/72483.html) format. - name: city | type: string | description: City name. - name: postalCode | type: string | description: Postal or zip code. - name: streetAddress | type: StreetAddress | description: Street address. - name: number | type: string | description: Street number. - name: name | type: string | description: Street name. - name: addressLine | type: string | description: Main address line (usually street name and number). - name: addressLine2 | type: string | description: Free text providing more detailed address info. Usually contains apt, suite, floor. - name: geocode | type: AddressLocation | description: Geocode object containing latitude and longitude coordinates. - name: latitude | type: number | description: Address latitude. - name: longitude | type: number | description: Address longitude. - name: countryFullname | type: string | description: Country's full name. - name: subdivisionFullname | type: string | description: Subdivision full-name. - name: contactDetails | type: FullAddressContactDetails | description: Contact details. - name: firstName | type: string | description: First name. - name: lastName | type: string | description: Last name. - name: phone | type: string | description: Phone number. - name: company | type: string | description: Company name. - name: vatId | type: VatId | description: Tax information (for Brazil only). If GUID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. - name: id | type: string | description: Customer's tax GUID. - name: type | type: VatType | description: Tax type. Supported values: + `CPF`: for individual tax payers + `CNPJ`: for corporations - enum: - UNSPECIFIED: - CPF: CPF - for individual tax payers. - CNPJ: CNPJ - for corporations - name: shippingInfo | type: ShippingInfo | description: Shipping information. - name: shippingDestination | type: AddressWithContact | description: Shipping address and contact details. - name: selectedCarrierServiceOption | type: SelectedCarrierServiceOption | description: Selected option out of the options allowed for the `region`. - name: code | type: string | description: Unique identifier of selected option. For example, "usps_std_overnight". - name: title | type: string | description: Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). For example, "Standard" or "First-Class Package International". - name: logistics | type: DeliveryLogistics | description: Delivery logistics. - name: deliveryTime | type: string | description: Expected delivery time, in free text. For example, "3-5 business days". - name: instructions | type: string | description: Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot". - name: pickupDetails | type: PickupDetails | description: Pickup details. - name: address | type: Address | description: Pickup address. - name: pickupMethod | type: PickupMethod | description: Pickup method - enum: STORE_PICKUP, PICKUP_POINT - name: cost | type: SelectedCarrierServiceOptionPrices | description: Shipping costs. - name: totalPriceAfterTax | type: MultiCurrencyPrice | description: Total shipping price, after discount and after tax. - name: totalPriceBeforeTax | type: MultiCurrencyPrice | description: Total price of shipping after discounts (when relevant), and before tax. - name: taxDetails | type: ItemTaxFullDetails | description: Tax details. - name: totalDiscount | type: MultiCurrencyPrice | description: Shipping discount before tax. - name: price | type: MultiCurrencyPrice | description: Shipping price before discount and before tax. - name: requestedShippingOption | type: boolean | description: Were we able to find the requested shipping option, or otherwise we fallback to the default one (the first) - name: carrierId | type: string | description: This carrier's unique GUID - name: deliveryAllocations | type: array | description: Delivery solution allocations to different delivery carriers and delivery regions - name: deliveryCarrier | type: Carrier | description: The delivery option's carrier details, could be multiple if the delivery option is a combination of multiple carriers - name: appId | type: string | description: The carrier app id - name: code | type: string | description: Unique code that acts as an GUID for a shipping rate. For example, `"usps_std_overnight"`. - name: deliveryRegion | type: Region | description: The delivery region that are relevant for this delivery solution. - name: id | type: string | description: The delivery region id. - name: name | type: string | description: The delivery region name. - name: applicableLineItems | type: ApplicableLineItems | description: Populated if the delivery solution is a partially supplied by this carrier. - name: lineItemIds | type: array | description: Line items that the delivery solution is for. - name: partial | type: boolean | description: If the delivery solution is a partial and doesn't apply to all items. - name: region | type: ShippingRegion | description: Shipping region. Based on the address provided. - name: id | type: string | description: Shipping region GUID. - name: name | type: string | description: Shipping region name. - name: carrierServiceOptions | type: array | description: All carrier options for this shipping rule. - name: carrierId | type: string | description: Carrier GUID. - name: shippingOptions | type: array | description: Shipping options offered by this carrier for this request. - name: code | type: string | description: Unique code of provided shipping option like "usps_std_overnight". For legacy calculators this would be the UUGUID of the option. - name: title | type: string | description: Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). For example, "Standard" or "First-Class Package International". - name: logistics | type: DeliveryLogistics | description: Delivery logistics. - name: cost | type: ShippingPrice | description: Sipping price information. - name: price | type: MultiCurrencyPrice | description: Shipping price. - name: otherCharges | type: array | description: Other costs such as insurance, handling & packaging for fragile items, etc. - name: type | type: ChargeType | description: Type of additional cost. - enum: HANDLING_FEE, INSURANCE - name: price | type: MultiCurrencyPrice | description: Price of added cost. - name: details | type: string | description: Description of the additional charge. For example, `"Handling fee of $5 applied for gift wrapping"`. - name: deliveryAllocations | type: array | description: Delivery solution allocations to different delivery carriers and delivery regions - name: partial | type: boolean | description: If the delivery solution is a partial and doesn't apply to all items. - name: buyerNote | type: string | description: [Buyer note](https://support.wix.com/en/article/collecting-and-viewing-buyer-notes) left by the customer. - name: buyerInfo | type: BuyerInfo | description: Buyer information. - name: contactId | type: string | description: Contact GUID. Auto-created if one does not yet exist. For more information, see the Contacts API. - name: email | type: string | description: Buyer email address. - name: conversionCurrency | type: string | description: The currency [selected by the customer](https://support.wix.com/en/article/multicurrency-an-overview) during the purchase flow, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format. This reflects the customer’s preferred display currency and may differ from the site’s default currency. When no specific currency is selected by the customer, this matches the `currency` property. - name: priceSummary | type: PriceSummary | description: Calculated price summary for the checkout. - name: subtotal | type: MultiCurrencyPrice | description: Subtotal of all line items, before discounts and before tax. - name: shipping | type: MultiCurrencyPrice | description: Total shipping price, before discounts and before tax. - name: tax | type: MultiCurrencyPrice | description: Total tax. - name: discount | type: MultiCurrencyPrice | description: Total calculated discount value. - name: total | type: MultiCurrencyPrice | description: Total price after discounts, gift cards, and tax. - name: additionalFees | type: MultiCurrencyPrice | description: Total additional fees price before tax. - name: calculationErrors | type: CalculationErrors | description: Errors when calculating totals. - ONE-OF: - name: generalShippingCalculationError | type: Details | description: General shipping calculation error. - ONE-OF: - name: applicationError | type: ApplicationError | description: - name: code | type: string | description: Error code. - name: description | type: string | description: Description of the error. - name: data | type: object | description: Data related to the error. - name: validationError | type: ValidationError | description: - name: fieldViolations | type: array | description: - name: field | type: string | description: - name: description | type: string | description: - name: violatedRule | type: RuleType | description: - enum: VALIDATION, OTHER, MAX, MIN, MAX_LENGTH, MIN_LENGTH, MAX_SIZE, MIN_SIZE, FORMAT, DECIMAL_LTE, DECIMAL_GTE, DECIMAL_LT, DECIMAL_GT, DECIMAL_MAX_SCALE, INVALID_ENUM_VALUE, REQUIRED_FIELD, FIELD_NOT_ALLOWED, ONE_OF_ALIGNMENT, EXACT_LENGTH, EXACT_SIZE, REQUIRED_ONE_OF_FIELD - name: ruleName | type: string | description: applicable when violated_rule=OTHER - name: data | type: object | description: - name: systemError | type: SystemError | description: - name: errorCode | type: string | description: Error code. - name: carrierErrors | type: CarrierErrors | description: Errors related to the delivery carrier. - name: errors | type: array | description: Carrier errors. - name: carrierId | type: string | description: Carrier GUID. - name: error | type: Details | description: Error details. - name: selectedShippingOptionError | type: Details | description: Error related to the selected shipping option. - name: taxCalculationError | type: Details | description: Tax calculation error. - name: couponCalculationError | type: Details | description: Coupon calculation error. - name: orderValidationErrors | type: array | description: Order validation errors. - name: membershipError | type: Details | description: Membership payment methods calculation errors For example, will indicate that a line item that must be paid with membership payment doesn't have one or selected memberships are invalid - name: discountsCalculationError | type: Details | description: Discount Rule calculation error. - name: giftCard | type: GiftCard | description: Applied gift card details. >**Note:** Gift cards are supported through the Wix UI, though the service plugin is not currently available. Learn more about [Wix Gift Cards](https://support.wix.com/en/article/setting-up-wix-gift-cards-9451439). - name: obfuscatedCode | type: string | description: Gift card obfuscated code. - name: amount | type: MultiCurrencyPrice | description: Actual amount to be redeemed from the gift card. - name: appId | type: string | description: App GUID of the gift card provider. - name: externalId | type: string | description: External GUID in the gift card provider's system. Used for integration and tracking across different platforms. - name: requestedAmount | type: MultiCurrencyPrice | description: Requested amount to redeem from the gift card. - name: appliedDiscounts | type: array | description: Applied discounts. - ONE-OF: - name: coupon | type: Coupon | description: Coupon details. - name: id | type: string | description: Coupon GUID. - name: code | type: string | description: Coupon code. - name: amount | type: MultiCurrencyPrice | description: Coupon value. - name: name | type: string | description: Coupon name. - name: merchantDiscount | type: MerchantDiscount | description: Merchant discount. - name: amount | type: MultiCurrencyPrice | description: Discount value. - name: percentage | type: number | description: Discount Percentage. Will be calculated from items price before other discounts. - name: discountRule | type: DiscountRule | description: Discount rule - name: id | type: string | description: Discount rule GUID - name: name | type: DiscountRuleName | description: Discount rule name - name: original | type: string | description: Original discount rule name (in site's default language). - name: translated | type: string | description: Translated discount rule name according to buyer language. Defaults to `original` when not provided. - name: amount | type: MultiCurrencyPrice | description: Discount value. - name: discountType | type: DiscountType | description: Discount type. - enum: GLOBAL, SPECIFIC_ITEMS, SHIPPING - name: lineItemIds | type: array | description: IDs of line items the discount applies to. - name: customFields | type: array | description: Custom fields. - name: value | type: Value | description: Custom field value. - ONE-OF: - name: nullValue | type: | description: - name: numberValue | type: number | description: - name: stringValue | type: string | description: - name: boolValue | type: boolean | description: - name: structValue | type: object | description: - name: listValue | type: ListValue | description: - name: values | type: array | description: - name: title | type: string | description: Custom field title. - name: translatedTitle | type: string | description: Translated custom field title. - name: weightUnit | type: WeightUnit | description: Weight measurement unit. Defaults to a site's weight unit. - enum: - UNSPECIFIED_WEIGHT_UNIT: Weight unit can't be classified due to an error. - KG: Kilograms. - LB: Pounds. - name: taxSummary | type: TaxSummary | description: Tax summary. - name: taxableAmount | type: MultiCurrencyPrice | description: Amount for which tax is calculated, added from line items. - name: totalTax | type: MultiCurrencyPrice | description: Calculated tax, added from line items. - name: currency | type: string | description: The site’s default currency, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format. This represents the base currency configured for the site and remains constant regardless of the customer’s currency selection. - name: channelType | type: ChannelType | description: Sales channel that submitted the order. - enum: - UNSPECIFIED: Unspecified sales channel. This value is not supported. - WEB: A web client. - POS: [Point of sale solutions](https://support.wix.com/en/wix-mobile-pos-2196395). - EBAY: [eBay shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-ebay-shop). - AMAZON: [Amazon shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-amazon-shop). - OTHER_PLATFORM: Other sales platform. - WIX_APP_STORE: [Wix Owner app](https://support.wix.com/article/wix-owner-app-an-overview). - WIX_INVOICES: Wix Invoices app in [your dashboard](https://www.wix.com/my-account/site-selector/?buttonText=Select%20Site&title=Select%20a%20Site&autoSelectOnSingleSite=true&actionUrl=https:%2F%2Fwww.wix.com%2Fdashboard%2F%7B%7BmetaSiteId%7D%7D%2Finvoices/settings/general-settings) - BACKOFFICE_MERCHANT: Wix merchant backoffice. - WISH: Wish sales channel. - CLASS_PASS: [ClassPass sales channel](https://support.wix.com/en/article/wix-bookings-letting-clients-book-your-services-with-classpass). - GLOBAL_E: Global-E sales channel. - FACEBOOK: [Facebook shop](https://support.wix.com/en/article/wix-stores-changes-to-facebook-shops). - ETSY: [Etsy sales channel](https://support.wix.com/en/article/wix-stores-request-adding-etsy-as-a-sales-channel). - TIKTOK: [TikTok sales channel](https://support.wix.com/en/article/wix-stores-request-adding-tiktok-as-a-sales-channel). - FAIRE_COM: [Faire marketplace integration](https://support.wix.com/en/article/wix-stores-creating-a-faire-store-using-the-faire-integration-app). - PAYPAL_AGENTIC_CHECKOUT: PayPal Agentic Checkout sales channel. - STRIPE_AGENTIC_CHECKOUT: Stripe Agentic Checkout sales channel. - name: siteLanguage | type: string | description: Site language in which original values are shown. - name: buyerLanguage | type: string | description: Language for communication with the buyer. Defaults to the site language. For a site that supports multiple languages, this is the language the buyer selected. - name: completed | type: boolean | description: Whether an order was successfully created from this checkout. For an order to be successful, it must be successfully paid for (unless the total is 0). - name: taxIncludedInPrice | type: boolean | description: Whether tax is included in line item prices. - name: createdBy | type: CreatedBy | description: GUID of the checkout's initiator. - ONE-OF: - name: userId | type: string | description: User GUID. When the order was created by a Wix user on behalf of a buyer. For example, via POS (point of service). - name: memberId | type: string | description: Member GUID. When the order was created by a **logged in** site visitor. - name: visitorId | type: string | description: Visitor GUID. When the order was created by a site visitor that was **not** logged in. - name: appId | type: string | description: App GUID. When the order was created by an external application or Wix service. - name: createdDate | type: string | description: Date and time the checkout was created. - name: updatedDate | type: string | description: Date and time the checkout was updated. - name: payNow | type: PriceSummary | description: Minimal amount to pay in order to place the order. - name: payLater | type: PriceSummary | description: Remaining amount for the order to be fully paid. - name: membershipOptions | type: MembershipOptions | description: Memberships to apply when creating the order. - name: eligibleMemberships | type: array | description: Reserved for internal use. - name: id | type: string | description: Membership GUID. - name: appId | type: string | description: GUID of the application providing this payment option. - name: name | type: MembershipName | description: The name of this membership. - name: original | type: string | description: Membership name. - name: translated | type: string | description: Translated membership name. Defaults to `original` when not provided. - name: lineItemIds | type: array | description: Line item GUIDs which are "paid" for by this membership. - name: credits | type: MembershipPaymentCredits | description: Optional - For a membership that has limited credits, information about credit usage. - name: total | type: integer | description: Membership's initial value. - name: remaining | type: integer | description: Membership's remaining value. - name: expirationDate | type: string | description: Optional - TMembership expiry date. - name: additionalData | type: object | description: Additional data about this membership. - name: invalidMemberships | type: array | description: Reserved for internal use. - name: membership | type: Membership | description: Membership details. - name: reason | type: string | description: Reason why this membership is invalid and cannot be used. - name: selectedMemberships | type: SelectedMemberships | description: Selected membership to apply to this checkout. - name: memberships | type: array | description: Selected memberships. - name: id | type: string | description: Membership GUID. - name: appId | type: string | description: GUID of the app providing this payment option. - name: lineItemIds | type: array | description: IDs of the line items this membership applies to. - name: additionalFees | type: array | description: Additional Fees. - name: code | type: string | description: Additional fee's unique code (or GUID) for future processing. - name: name | type: string | description: Additional fee's name. - name: price | type: MultiCurrencyPrice | description: Additional fee's price. - name: taxDetails | type: ItemTaxFullDetails | description: Tax details. - name: providerAppId | type: string | description: Provider's app id. - name: priceBeforeTax | type: MultiCurrencyPrice | description: Additional fee's price before tax. - name: priceAfterTax | type: MultiCurrencyPrice | description: Additional fee's price after tax. - name: lineItemIds | type: array | description: Optional - Line items associated with this additional fee. If no `lineItemIds` are provided, the fee will be associated with the whole cart/checkout/order. - name: source | type: AdditionalFeeSource | description: the source the additional fee was added from - enum: - UNKNOWN_ADDITIONAL_FEE_SOURCE: - SERVICE_PLUGIN: The additional fee was added by an additional fee service plugin - ITEM: The additional fee was added on the item either via the catalog or on custom line item - MANUAL: The additional fee was added manually on the request - SHIPPING: The additional fee was added by the shipping provider - PLATFORM: The additional fee was added by a Wix vertical and represents a Wix platform fee - name: translatedName | type: string | description: The translated name of the additional fee. The translation language is determined by the `languages` field in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: cartId | type: string | description: Cart GUID that this checkout was created from. Empty if this checkout wasn't created from a cart. - name: violations | type: array | description: List of validation violations raised by the [Validations service plugin](https://dev.wix.com/docs/rest/business-solutions/e-commerce/service-plugins/validations-integration-service-plugin/introduction.md). - name: severity | type: Severity | description: Severity of the violation. The violations are shown on the cart and checkout pages. A warning is displayed as yellow, and allows a site visitor to proceed with caution. An error is displayed as red, and doesn't allow a site visitor to proceed with the eCommerce flow. - enum: - WARNING: The user is allowed to move forward in the flow. - ERROR: The user is blocked from moving forward in the flow. For example, if callerContext is CART - moving to checkout is blocked. if callerContext is CHECKOUT, placing an order is blocked. - name: target | type: Target | description: Target location on a checkout or cart page where the violation will be displayed. - ONE-OF: - name: other | type: Other | description: General (other) violation. - name: name | type: NameInOther | description: Location on a checkout or a cart page where a general (other) violation will be displayed. - enum: - OTHER_DEFAULT: Default location, in case no specific location is specified. - name: lineItem | type: LineItem | description: Specific line item violation. - name: name | type: NameInLineItem | description: Location on a checkout or a cart page where the specific line item violation will be displayed. - enum: - LINE_ITEM_DEFAULT: Default location, in case no specific location is specified. - name: id | type: string | description: GUID of the line item containing the violation. - name: description | type: string | description: Violation description. Can include rich text. Only HTTP or HTTPS links in the following format are allowed: `Click me`. - name: extendedFields | type: ExtendedFields | description: Custom field data for the checkout object. [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md) must be configured in the app dashboard before they can be accessed with API calls. - name: purchaseFlowId | type: string | description: Persistent GUID that correlates between the various eCommerce elements: cart, checkout, and order. - name: customSettings | type: CustomSettings | description: Additional settings for customization of the checkout process. > **Notes:** > * Custom settings can only be set when creating a checkout. > * To access and manage custom checkout page content, your app must have the permission scope named "Manage eCommerce - Admin Permissions". Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions.md). - name: lockGiftCard | type: boolean | description: Whether to restrict the option to add or remove a gift card on the checkout page. Default: `false` - name: lockCouponCode | type: boolean | description: Whether to restrict the option to add or remove a coupon code on the checkout page. Default: `false` - name: disabledPolicyAgreementCheckbox | type: boolean | description: Whether to disable policy agreement checkout in the checkout page Default: `false` - name: disabledManualPayment | type: boolean | description: Whether to disable manual payment option for this checkout. Default: `false` - name: customContentReference | type: CustomContentReference | description: Reference GUIDs for the app and component providing custom checkout page content. To access and manage custom checkout page content, your app must have the permission scope named "Manage eCommerce - Admin Permissions". Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions.md). - name: appId | type: string | description: GUID of the app providing the content. You can get your app's GUID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/). - name: componentId | type: string | description: GUID of the component within the app it belongs to. You can get your component's GUID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/). - name: externalReference | type: ExternalReference | description: References to an external app and resource associated with this checkout. Used for integration and tracking across different platforms. - name: appId | type: string | description: GUID of the app associated with the purchase flow. For example, the Wix Pay Links app GUID. - name: resourceId | type: string | description: Reference to an external resource GUID. Used to link the purchase flow to a specific entity in an external system. For example, a Wix Pay Link GUID. - name: payAfterFreeTrial | type: PriceSummary | description: Payment for subscriptions after free trial period. - name: businessLocationId | type: string | description: The business location GUID associated with the checkout. To learn more, see the Locations API. - name: paymentCurrency | type: string | description: The currency used for payment, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format. This is determined by the [customer's selected currency](https://support.wix.com/en/article/multicurrency-an-overview) and the site’s supported payment currencies. If the customer’s selected currency is supported for payment, this matches the `conversionCurrency` property. If not supported, this falls back to the `currency` property. - name: taxExemptGroupId | type: string | description: Tax exempt group GUID to use for tax exemptions. ``` ### Examples ### RemoveCoupon ```curl ~~~cURL curl -X POST 'https://www.wixapis.com/ecom/v1/checkouts/98efbd87-8097-44e9-9005-72093d7a21d5/remove-coupon' \ -H 'Content-Type: application/json' \ -H 'Authorization: ' ~~~ ``` --- ## JavaScript SDK ### Schema ``` Method: wixClientAdmin.checkout.CheckoutService.removeCoupon(_id) Description: Removes the coupon from a specified checkout. # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: _id Method parameters: param name: _id | type: string | description: GUID of the checkout to remove the coupon from. | required: true Return type: PROMISE - name: checkout | type: Checkout | description: Updated checkout after removal of coupon. - name: _id | type: string | description: Checkout GUID. - name: lineItems | type: array | description: Line items. Max: 300 items - name: _id | type: string | description: Line item GUID. - name: quantity | type: integer | description: Item quantity. Min: `"1"` Max: `"100000"` - name: catalogReference | type: CatalogReference | description: Catalog and item reference. Includes GUIDs for the item and the catalog it came from, as well as further optional info. Optional for custom line items, which don't trigger the Catalog service plugin. - name: catalogItemId | type: string | description: GUID of the item within the catalog it belongs to. - name: appId | type: string | description: GUID of the app providing the catalog. You can get your app's GUID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/). For items from Wix catalogs, the following values always apply: + Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"` + Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"` + Wix Restaurants: `"9a5d83fd-8570-482e-81ab-cfa88942ee60"` - name: options | type: object | description: Additional item details in `key:value` pairs. Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items. For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration.md) or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration.md), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction.md). - name: productName | type: ProductName | description: Item name. + Stores - `product.name` + Bookings - `service.info.name` + Events - `ticket.name` - name: original | type: string | description: __Required.__ Item name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). Min: 1 character. Max: 200 characters. - name: translated | type: string | description: Item name translated into the buyer's language. Min: 1 character. Max: 400 characters. Default: Same as `original`. - name: url | type: string | description: URL to the item's page on the site. - name: price | type: MultiCurrencyPrice | description: Item price **after** catalog-defined discount and line item discounts. - name: amount | type: string | description: Amount. - name: convertedAmount | type: string | description: Converted amount. - name: formattedAmount | type: string | description: Amount formatted with currency symbol. - name: formattedConvertedAmount | type: string | description: Converted amount formatted with currency symbol. - name: lineItemPrice | type: MultiCurrencyPrice | description: Total line item price **after** catalog-defined discount and line item discounts. - name: fullPrice | type: MultiCurrencyPrice | description: Item price **before** catalog-defined discount. Defaults to `price` when not provided. - name: priceBeforeDiscounts | type: MultiCurrencyPrice | description: Item price **before** line item discounts and **after** catalog-defined discount. Defaults to `price` when not provided. - name: totalPriceAfterTax | type: MultiCurrencyPrice | description: Total price after all discounts and tax. - name: totalPriceBeforeTax | type: MultiCurrencyPrice | description: Total price after discounts, and before tax. - name: taxDetails | type: ItemTaxFullDetails | description: Tax details for this line item. - name: taxableAmount | type: MultiCurrencyPrice | description: Amount for which tax is calculated. - name: taxRate | type: string | description: Tax rate %, as a decimal point between 0 and 1. - name: totalTax | type: MultiCurrencyPrice | description: Calculated tax, based on `taxable_amount` and `tax_rate`. - name: taxBreakdown | type: array | description: tax information for a line item. - name: jurisdiction | type: string | description: The name of the jurisdiction to which this tax detail applies. For example, "New York" or "Quebec". - name: nonTaxableAmount | type: MultiCurrencyPrice | description: The amount of this line item price that was considered nontaxable. (Decimal value) - name: rate | type: string | description: The rate at which this tax detail was calculated, e.g 0.1000 signifies 10% tax and 2.0000 signifies 200% tax. (Decimal value) - name: taxAmount | type: MultiCurrencyPrice | description: The amount of tax estimated for this line item. (Decimal value) - name: taxableAmount | type: MultiCurrencyPrice | description: The taxable amount of this line item. - name: taxType | type: string | description: The type of tax that was calculated. Depends on the jurisdiction's tax laws. For example, "Sales Tax", "Income Tax", "Value Added Tax", etc. - name: taxName | type: string | description: The name of the tax against which this tax amount was calculated. For example, "NY State Sales Tax", "Quebec GST", etc. This name should be explicit enough to allow the merchant to understand what tax was calculated. - name: jurisdictionType | type: JurisdictionType | description: The type of the jurisdiction in which this tax detail applies. - enum: UNDEFINED, COUNTRY, STATE, COUNTY, CITY, SPECIAL - name: discount | type: MultiCurrencyPrice | description: Discount for this line item's entire quantity. - name: descriptionLines | type: array | description: Line item description lines. Used for display purposes for the cart, checkout and order. - ONE-OF: - name: plainText | type: PlainTextValue | description: Description line plain text value. - name: original | type: string | description: Description line plain text value in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Description line plain text value translated into the buyer's language. Default: Same as `original`. - name: colorInfo | type: Color | description: Description line color value. - name: original | type: string | description: Description line color name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Description line color name translated into the buyer's language. Default: Same as `original`. - name: code | type: string | description: HEX or RGB color code for display. - name: name | type: DescriptionLineName | description: Description line name. - name: original | type: string | description: Description line name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Description line name translated into the buyer's language. Default: Same as `original`. - name: media | type: string | description: Line item image details. - name: availability | type: ItemAvailabilityInfo | description: Item availability details. - name: status | type: ItemAvailabilityStatus | description: Item availability status. - enum: - AVAILABLE: - NOT_FOUND: Item does not exist. - NOT_AVAILABLE: Item is not in stock. - PARTIALLY_AVAILABLE: Available quantity is less than requested. - name: quantityAvailable | type: integer | description: Quantity available. - name: physicalProperties | type: PhysicalProperties | description: Physical properties of the item. When relevant, contains information such as SKU, item weight, and shippability. - name: weight | type: number | description: Line item weight. Measurement unit matches the weight unit specified in `weightUnit` in the request. - name: sku | type: string | description: Stock-keeping unit. Learn more about [SKUs](https://www.wix.com/encyclopedia/definition/stock-keeping-unit-sku). - name: shippable | type: boolean | description: Whether this line item is shippable. - name: itemType | type: ItemType | description: Item type. Either a preset type or custom. - ONE-OF: - name: preset | type: ItemTypePreset | description: Preset item type. - enum: UNRECOGNISED, PHYSICAL, DIGITAL, GIFT_CARD, SERVICE - name: custom | type: string | description: Custom item type. When none of the preset types are suitable, specifies the custom type. - name: subscriptionOptionInfo | type: SubscriptionOptionInfo | description: Subscription option information. - name: subscriptionSettings | type: SubscriptionSettings | description: Subscription option settings. - name: frequency | type: SubscriptionFrequency | description: Frequency of recurring payment. - enum: UNDEFINED, DAY, WEEK, MONTH, YEAR - name: interval | type: integer | description: Interval of recurring payment. Default: `1`. If SubscriptionFrequency is Day the minimum interval is 7 - name: autoRenewal | type: boolean | description: Whether subscription is renewed automatically at the end of each period. - name: billingCycles | type: integer | description: Number of billing cycles before subscription ends. Ignored if `autoRenewal` is `true`. - name: enableCustomerCancellation | type: boolean | description: Whether to allow the customer to cancel the subscription.. - name: freeTrialPeriod | type: FreeTrialPeriod | description: Period until first cycle starts. If applied payNow will be 0 If None => no free trial - name: frequency | type: SubscriptionFrequency | description: Frequency of period. Values: DAY, WEEK, MONTH, YEAR - name: interval | type: integer | description: Number of frequency units in the free trial period. For example, frequency `MONTH` with interval `3` means a 3-month free trial. - name: title | type: Title | description: Subscription option title. - name: original | type: string | description: Subscription option name in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Subscription option name translated into the buyer's language. Default: Same as `original`. - name: description | type: Description | description: Subscription option description. - name: original | type: string | description: Subscription option description. - name: translated | type: string | description: Translated subscription option description. - name: paymentOption | type: PaymentOptionType | description: Type of selected payment option for current item. Default: `FULL_PAYMENT_ONLINE` - enum: - FULL_PAYMENT_ONLINE: The entire payment for this item happens as part of the checkout. - FULL_PAYMENT_OFFLINE: The entire payment for this item happens after checkout. For example, when using cash, check, or other offline payment methods. - MEMBERSHIP: Payment for this item is done by charging a membership. Any remaining amount not covered by the membership, such as item modifiers, is paid online. - DEPOSIT_ONLINE: Partial payment to be paid upfront during checkout. The initial amount to be paid for each line item is specified in `depositAmount`. - MEMBERSHIP_OFFLINE: Payment for this item can only be done by charging a membership and must be manually redeemed in the dashboard by the site admin. When selected, `price` is `0`. - MEMBERSHIP_ONLINE_WITH_OFFLINE_REMAINDER: Item price is charged to online membership. Any remaining amount not covered by the membership, such as item modifiers, is paid offline. - name: serviceProperties | type: ServiceProperties | description: Service properties. When relevant, this contains information such as date and number of participants. - name: scheduledDate | type: Date | description: Date and time the service is to be provided, in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations) format. For example, the start time of a class. - name: numberOfParticipants | type: integer | description: The number of people participating in the service. For example, the number of people attending a class or the number of people per hotel room. - name: rootCatalogItemId | type: string | description: In cases where `catalogReference.catalogItemId` is NOT the actual catalog item GUID, this field will return the true item's GUID. + For example, for Wix Bookings, `catalogReference.catalogItemId` is the booking GUID. Therefore this value is set to the service GUID. + In most cases, this field has the same value as `catalogReference.catalogItemId`. + Used in membership validation. - name: priceDescription | type: PriceDescription | description: Additional description for the price. For example, when price is 0 but additional details about the actual price are needed - "Starts at $67". - name: original | type: string | description: __Required.__ Price description in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: translated | type: string | description: Price description translated into the buyer's language. Default: Same as `original`. - name: depositAmount | type: MultiCurrencyPrice | description: Partial payment to be paid upfront during the checkout. Eligible for catalog items with `lineItem.paymentOption` type `DEPOSIT_ONLINE` only. - name: deliveryProfileId | type: string | description: Delivery profile GUID. - name: customLineItem | type: boolean | description: Whether the line item is a custom line item. Custom line items don't trigger the Catalog service plugin. - name: consentRequiredPaymentPolicy | type: string | description: Item payment policy that requires customer consent to complete purchase. The payment policy will be displayed on the checkout page. - name: catalogOverrideFields | type: CatalogOverrideFields | description: Overriding values for catalog item properties. To override catalog fields, your app must have the permission scope named "Manage eCommerce - Admin Permissions". Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions.md). - name: productName | type: ProductName | description: Item name. - name: price | type: string | description: Item price **after** discounts. - name: fullPrice | type: string | description: Item price **before** discounts. - name: descriptionLines | type: array | description: Item description lines. Used when displaying the line item to customers. - name: physicalProperties | type: PhysicalProperties | description: Physical properties of the item. - name: image | type: string | description: Item image. - name: paymentOption | type: PaymentOption | description: Payment method selected for the item. - name: value | type: PaymentOptionType | description: Type of selected payment option for current item. Default: `FULL_PAYMENT_ONLINE` - name: depositAmount | type: string | description: Only eligible for catalog items with `lineItem.paymentOption.value` type of `DEPOSIT_ONLINE`. - name: savePaymentMethod | type: boolean | description: Whether to save the payment method on the order. Default: `false` - name: inventoryAppId | type: string | description: GUID of the app managing the inventory. - name: priceUndetermined | type: boolean | description: Whether the price is not yet defined, and will be updated after the order is created. - name: fixedQuantity | type: boolean | description: Whether the line item quantity is fixed and cannot be changed. - name: savePaymentMethod | type: boolean | description: Whether to save the payment method on the order. Default: `false` - name: taxableAddress | type: TaxableAddress | description: Address to use for tax calculation purposes. - ONE-OF: - name: addressType | type: TaxableAddressType | description: taxable address type. if this field is selected, the address is automatically resolved, and the tax is calculated accordingly. - enum: BUSINESS, BILLING, SHIPPING - name: extendedFields | type: ExtendedFields | description: Custom extended fields for the line item object. [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md) must be configured using the 'Checkout & Orders - Line Items Schema Plugin' in the app dashboard before they can be accessed with API calls. - name: namespaces | type: object | description: Extended field data. Each key corresponds to the namespace of the app that created the extended fields. The value of each key is structured according to the schema defined when the extended fields were configured. You can only access fields for which you have the appropriate permissions. Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md). - name: policies | type: array | description: Policies to be displayed to the customer on the checkout page. - name: title | type: string | description: Policy title - should be translated - name: content | type: string | description: Policy content - should be translated - name: membersOnly | type: boolean | description: Whether the item can only be purchased by site members. Default: `false` - name: modifierGroups | type: array | description: Modifier groups that were added to the item. - name: _id | type: string | description: Modifier group GUID. - name: name | type: TranslatableString | description: Modifier group name. - name: original | type: string | description: __Required.__ String in the site's default language as defined in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). Min: 1 character. Max: 200 characters. - name: translated | type: string | description: String translated into the buyer's language. Min: 1 character. Max: 400 characters. Default: Same as `original`. - name: modifiers | type: array | description: List of modifiers in this group. - name: _id | type: string | description: Modifier GUID. - name: quantity | type: integer | description: The quantity of this modifier. - name: label | type: TranslatableString | description: Primary display label for the modifier. - name: details | type: TranslatableString | description: Additional details. - name: price | type: MultiCurrencyPrice | description: The price of the modifier. - name: modifiersTotalPrice | type: MultiCurrencyPrice | description: Total price of all item modifiers. Included in the item price. - name: billingInfo | type: AddressWithContact | description: Billing information. - name: address | type: Address | description: Address. - name: streetAddress | type: StreetAddress | description: none - name: name | type: string | description: none - name: number | type: string | description: none - name: city | type: string | description: none - name: subdivision | type: string | description: none - name: country | type: string | description: none - name: postalCode | type: string | description: none - name: addressLine2 | type: string | description: none - name: contactDetails | type: FullAddressContactDetails | description: Contact details. - name: firstName | type: string | description: First name. - name: lastName | type: string | description: Last name. - name: phone | type: string | description: Phone number. - name: company | type: string | description: Company name. - name: vatId | type: VatId | description: Tax information (for Brazil only). If GUID is provided, `vatId.type` must also be set, `UNSPECIFIED` is not allowed. - name: _id | type: string | description: Customer's tax GUID. - name: type | type: VatType | description: Tax type. Supported values: + `CPF`: for individual tax payers + `CNPJ`: for corporations - enum: - UNSPECIFIED: - CPF: CPF - for individual tax payers. - CNPJ: CNPJ - for corporations - name: shippingInfo | type: ShippingInfo | description: Shipping information. - name: shippingDestination | type: AddressWithContact | description: Shipping address and contact details. - name: selectedCarrierServiceOption | type: SelectedCarrierServiceOption | description: Selected option out of the options allowed for the `region`. - name: code | type: string | description: Unique identifier of selected option. For example, "usps_std_overnight". - name: title | type: string | description: Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). For example, "Standard" or "First-Class Package International". - name: logistics | type: DeliveryLogistics | description: Delivery logistics. - name: deliveryTime | type: string | description: Expected delivery time, in free text. For example, "3-5 business days". - name: instructions | type: string | description: Instructions for caller, e.g for pickup: "Please deliver during opening hours, and please don't park in disabled parking spot". - name: pickupDetails | type: PickupDetails | description: Pickup details. - name: address | type: Address | description: Pickup address. - name: pickupMethod | type: PickupMethod | description: Pickup method - enum: STORE_PICKUP, PICKUP_POINT - name: cost | type: SelectedCarrierServiceOptionPrices | description: Shipping costs. - name: totalPriceAfterTax | type: MultiCurrencyPrice | description: Total shipping price, after discount and after tax. - name: totalPriceBeforeTax | type: MultiCurrencyPrice | description: Total price of shipping after discounts (when relevant), and before tax. - name: taxDetails | type: ItemTaxFullDetails | description: Tax details. - name: totalDiscount | type: MultiCurrencyPrice | description: Shipping discount before tax. - name: price | type: MultiCurrencyPrice | description: Shipping price before discount and before tax. - name: requestedShippingOption | type: boolean | description: Were we able to find the requested shipping option, or otherwise we fallback to the default one (the first) - name: carrierId | type: string | description: This carrier's unique GUID - name: deliveryAllocations | type: array | description: Delivery solution allocations to different delivery carriers and delivery regions - name: deliveryCarrier | type: Carrier | description: The delivery option's carrier details, could be multiple if the delivery option is a combination of multiple carriers - name: appId | type: string | description: The carrier app id - name: code | type: string | description: Unique code that acts as an GUID for a shipping rate. For example, `"usps_std_overnight"`. - name: deliveryRegion | type: Region | description: The delivery region that are relevant for this delivery solution. - name: _id | type: string | description: The delivery region id. - name: name | type: string | description: The delivery region name. - name: applicableLineItems | type: ApplicableLineItems | description: Populated if the delivery solution is a partially supplied by this carrier. - name: lineItemIds | type: array | description: Line items that the delivery solution is for. - name: partial | type: boolean | description: If the delivery solution is a partial and doesn't apply to all items. - name: region | type: ShippingRegion | description: Shipping region. Based on the address provided. - name: _id | type: string | description: Shipping region GUID. - name: name | type: string | description: Shipping region name. - name: carrierServiceOptions | type: array | description: All carrier options for this shipping rule. - name: carrierId | type: string | description: Carrier GUID. - name: shippingOptions | type: array | description: Shipping options offered by this carrier for this request. - name: code | type: string | description: Unique code of provided shipping option like "usps_std_overnight". For legacy calculators this would be the UUGUID of the option. - name: title | type: string | description: Title of the option, such as USPS Standard Overnight Delivery (in the requested locale). For example, "Standard" or "First-Class Package International". - name: logistics | type: DeliveryLogistics | description: Delivery logistics. - name: cost | type: ShippingPrice | description: Sipping price information. - name: price | type: MultiCurrencyPrice | description: Shipping price. - name: otherCharges | type: array | description: Other costs such as insurance, handling & packaging for fragile items, etc. - name: type | type: ChargeType | description: Type of additional cost. - enum: HANDLING_FEE, INSURANCE - name: price | type: MultiCurrencyPrice | description: Price of added cost. - name: details | type: string | description: Description of the additional charge. For example, `"Handling fee of $5 applied for gift wrapping"`. - name: deliveryAllocations | type: array | description: Delivery solution allocations to different delivery carriers and delivery regions - name: partial | type: boolean | description: If the delivery solution is a partial and doesn't apply to all items. - name: buyerNote | type: string | description: [Buyer note](https://support.wix.com/en/article/collecting-and-viewing-buyer-notes) left by the customer. - name: buyerInfo | type: BuyerInfo | description: Buyer information. - name: contactId | type: string | description: Contact GUID. Auto-created if one does not yet exist. For more information, see the Contacts API. - name: email | type: string | description: Buyer email address. - name: conversionCurrency | type: string | description: The currency [selected by the customer](https://support.wix.com/en/article/multicurrency-an-overview) during the purchase flow, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format. This reflects the customer’s preferred display currency and may differ from the site’s default currency. When no specific currency is selected by the customer, this matches the `currency` property. - name: priceSummary | type: PriceSummary | description: Calculated price summary for the checkout. - name: subtotal | type: MultiCurrencyPrice | description: Subtotal of all line items, before discounts and before tax. - name: shipping | type: MultiCurrencyPrice | description: Total shipping price, before discounts and before tax. - name: tax | type: MultiCurrencyPrice | description: Total tax. - name: discount | type: MultiCurrencyPrice | description: Total calculated discount value. - name: total | type: MultiCurrencyPrice | description: Total price after discounts, gift cards, and tax. - name: additionalFees | type: MultiCurrencyPrice | description: Total additional fees price before tax. - name: calculationErrors | type: CalculationErrors | description: Errors when calculating totals. - ONE-OF: - name: generalShippingCalculationError | type: Details | description: General shipping calculation error. - ONE-OF: - name: applicationError | type: ApplicationError | description: - name: code | type: string | description: Error code. - name: description | type: string | description: Description of the error. - name: data | type: object | description: Data related to the error. - name: validationError | type: ValidationError | description: - name: fieldViolations | type: array | description: - name: field | type: string | description: - name: description | type: string | description: - name: violatedRule | type: RuleType | description: - enum: VALIDATION, OTHER, MAX, MIN, MAX_LENGTH, MIN_LENGTH, MAX_SIZE, MIN_SIZE, FORMAT, DECIMAL_LTE, DECIMAL_GTE, DECIMAL_LT, DECIMAL_GT, DECIMAL_MAX_SCALE, INVALID_ENUM_VALUE, REQUIRED_FIELD, FIELD_NOT_ALLOWED, ONE_OF_ALIGNMENT, EXACT_LENGTH, EXACT_SIZE, REQUIRED_ONE_OF_FIELD - name: ruleName | type: string | description: applicable when violated_rule=OTHER - name: data | type: object | description: - name: systemError | type: SystemError | description: - name: errorCode | type: string | description: Error code. - name: carrierErrors | type: CarrierErrors | description: Errors related to the delivery carrier. - name: errors | type: array | description: Carrier errors. - name: carrierId | type: string | description: Carrier GUID. - name: error | type: Details | description: Error details. - name: selectedShippingOptionError | type: Details | description: Error related to the selected shipping option. - name: taxCalculationError | type: Details | description: Tax calculation error. - name: couponCalculationError | type: Details | description: Coupon calculation error. - name: orderValidationErrors | type: array | description: Order validation errors. - name: membershipError | type: Details | description: Membership payment methods calculation errors For example, will indicate that a line item that must be paid with membership payment doesn't have one or selected memberships are invalid - name: discountsCalculationError | type: Details | description: Discount Rule calculation error. - name: giftCard | type: GiftCard | description: Applied gift card details. >**Note:** Gift cards are supported through the Wix UI, though the service plugin is not currently available. Learn more about [Wix Gift Cards](https://support.wix.com/en/article/setting-up-wix-gift-cards-9451439). - name: obfuscatedCode | type: string | description: Gift card obfuscated code. - name: amount | type: MultiCurrencyPrice | description: Actual amount to be redeemed from the gift card. - name: appId | type: string | description: App GUID of the gift card provider. - name: externalId | type: string | description: External GUID in the gift card provider's system. Used for integration and tracking across different platforms. - name: requestedAmount | type: MultiCurrencyPrice | description: Requested amount to redeem from the gift card. - name: appliedDiscounts | type: array | description: Applied discounts. - ONE-OF: - name: coupon | type: Coupon | description: Coupon details. - name: _id | type: string | description: Coupon GUID. - name: code | type: string | description: Coupon code. - name: amount | type: MultiCurrencyPrice | description: Coupon value. - name: name | type: string | description: Coupon name. - name: merchantDiscount | type: MerchantDiscount | description: Merchant discount. - name: amount | type: MultiCurrencyPrice | description: Discount value. - name: percentage | type: number | description: Discount Percentage. Will be calculated from items price before other discounts. - name: discountRule | type: DiscountRule | description: Discount rule - name: _id | type: string | description: Discount rule GUID - name: name | type: DiscountRuleName | description: Discount rule name - name: original | type: string | description: Original discount rule name (in site's default language). - name: translated | type: string | description: Translated discount rule name according to buyer language. Defaults to `original` when not provided. - name: amount | type: MultiCurrencyPrice | description: Discount value. - name: discountType | type: DiscountType | description: Discount type. - enum: GLOBAL, SPECIFIC_ITEMS, SHIPPING - name: lineItemIds | type: array | description: IDs of line items the discount applies to. - name: customFields | type: array | description: Custom fields. - name: value | type: Value | description: Custom field value. - ONE-OF: - name: nullValue | type: | description: - name: numberValue | type: number | description: - name: stringValue | type: string | description: - name: boolValue | type: boolean | description: - name: structValue | type: object | description: - name: listValue | type: ListValue | description: - name: values | type: array | description: - name: title | type: string | description: Custom field title. - name: translatedTitle | type: string | description: Translated custom field title. - name: weightUnit | type: WeightUnit | description: Weight measurement unit. Defaults to a site's weight unit. - enum: - UNSPECIFIED_WEIGHT_UNIT: Weight unit can't be classified due to an error. - KG: Kilograms. - LB: Pounds. - name: taxSummary | type: TaxSummary | description: Tax summary. - name: taxableAmount | type: MultiCurrencyPrice | description: Amount for which tax is calculated, added from line items. - name: totalTax | type: MultiCurrencyPrice | description: Calculated tax, added from line items. - name: currency | type: string | description: The site’s default currency, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format. This represents the base currency configured for the site and remains constant regardless of the customer’s currency selection. - name: channelType | type: ChannelType | description: Sales channel that submitted the order. - enum: - UNSPECIFIED: Unspecified sales channel. This value is not supported. - WEB: A web client. - POS: [Point of sale solutions](https://support.wix.com/en/wix-mobile-pos-2196395). - EBAY: [eBay shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-ebay-shop). - AMAZON: [Amazon shop](https://support.wix.com/en/article/wix-stores-connecting-and-setting-up-an-amazon-shop). - OTHER_PLATFORM: Other sales platform. - WIX_APP_STORE: [Wix Owner app](https://support.wix.com/article/wix-owner-app-an-overview). - WIX_INVOICES: Wix Invoices app in [your dashboard](https://www.wix.com/my-account/site-selector/?buttonText=Select%20Site&title=Select%20a%20Site&autoSelectOnSingleSite=true&actionUrl=https:%2F%2Fwww.wix.com%2Fdashboard%2F%7B%7BmetaSiteId%7D%7D%2Finvoices/settings/general-settings) - BACKOFFICE_MERCHANT: Wix merchant backoffice. - WISH: Wish sales channel. - CLASS_PASS: [ClassPass sales channel](https://support.wix.com/en/article/wix-bookings-letting-clients-book-your-services-with-classpass). - GLOBAL_E: Global-E sales channel. - FACEBOOK: [Facebook shop](https://support.wix.com/en/article/wix-stores-changes-to-facebook-shops). - ETSY: [Etsy sales channel](https://support.wix.com/en/article/wix-stores-request-adding-etsy-as-a-sales-channel). - TIKTOK: [TikTok sales channel](https://support.wix.com/en/article/wix-stores-request-adding-tiktok-as-a-sales-channel). - FAIRE_COM: [Faire marketplace integration](https://support.wix.com/en/article/wix-stores-creating-a-faire-store-using-the-faire-integration-app). - PAYPAL_AGENTIC_CHECKOUT: PayPal Agentic Checkout sales channel. - STRIPE_AGENTIC_CHECKOUT: Stripe Agentic Checkout sales channel. - name: siteLanguage | type: string | description: Site language in which original values are shown. - name: buyerLanguage | type: string | description: Language for communication with the buyer. Defaults to the site language. For a site that supports multiple languages, this is the language the buyer selected. - name: completed | type: boolean | description: Whether an order was successfully created from this checkout. For an order to be successful, it must be successfully paid for (unless the total is 0). - name: taxIncludedInPrice | type: boolean | description: Whether tax is included in line item prices. - name: createdBy | type: CreatedBy | description: GUID of the checkout's initiator. - ONE-OF: - name: userId | type: string | description: User GUID. When the order was created by a Wix user on behalf of a buyer. For example, via POS (point of service). - name: memberId | type: string | description: Member GUID. When the order was created by a **logged in** site visitor. - name: visitorId | type: string | description: Visitor GUID. When the order was created by a site visitor that was **not** logged in. - name: appId | type: string | description: App GUID. When the order was created by an external application or Wix service. - name: _createdDate | type: Date | description: Date and time the checkout was created. - name: _updatedDate | type: Date | description: Date and time the checkout was updated. - name: payNow | type: PriceSummary | description: Minimal amount to pay in order to place the order. - name: payLater | type: PriceSummary | description: Remaining amount for the order to be fully paid. - name: membershipOptions | type: MembershipOptions | description: Memberships to apply when creating the order. - name: eligibleMemberships | type: array | description: Reserved for internal use. - name: _id | type: string | description: Membership GUID. - name: appId | type: string | description: GUID of the application providing this payment option. - name: name | type: MembershipName | description: The name of this membership. - name: original | type: string | description: Membership name. - name: translated | type: string | description: Translated membership name. Defaults to `original` when not provided. - name: lineItemIds | type: array | description: Line item GUIDs which are "paid" for by this membership. - name: credits | type: MembershipPaymentCredits | description: Optional - For a membership that has limited credits, information about credit usage. - name: total | type: integer | description: Membership's initial value. - name: remaining | type: integer | description: Membership's remaining value. - name: expirationDate | type: Date | description: Optional - TMembership expiry date. - name: additionalData | type: object | description: Additional data about this membership. - name: invalidMemberships | type: array | description: Reserved for internal use. - name: membership | type: Membership | description: Membership details. - name: reason | type: string | description: Reason why this membership is invalid and cannot be used. - name: selectedMemberships | type: SelectedMemberships | description: Selected membership to apply to this checkout. - name: memberships | type: array | description: Selected memberships. - name: _id | type: string | description: Membership GUID. - name: appId | type: string | description: GUID of the app providing this payment option. - name: lineItemIds | type: array | description: IDs of the line items this membership applies to. - name: additionalFees | type: array | description: Additional Fees. - name: code | type: string | description: Additional fee's unique code (or GUID) for future processing. - name: name | type: string | description: Additional fee's name. - name: price | type: MultiCurrencyPrice | description: Additional fee's price. - name: taxDetails | type: ItemTaxFullDetails | description: Tax details. - name: providerAppId | type: string | description: Provider's app id. - name: priceBeforeTax | type: MultiCurrencyPrice | description: Additional fee's price before tax. - name: priceAfterTax | type: MultiCurrencyPrice | description: Additional fee's price after tax. - name: lineItemIds | type: array | description: Optional - Line items associated with this additional fee. If no `lineItemIds` are provided, the fee will be associated with the whole cart/checkout/order. - name: source | type: AdditionalFeeSource | description: the source the additional fee was added from - enum: - UNKNOWN_ADDITIONAL_FEE_SOURCE: - SERVICE_PLUGIN: The additional fee was added by an additional fee service plugin - ITEM: The additional fee was added on the item either via the catalog or on custom line item - MANUAL: The additional fee was added manually on the request - SHIPPING: The additional fee was added by the shipping provider - PLATFORM: The additional fee was added by a Wix vertical and represents a Wix platform fee - name: translatedName | type: string | description: The translated name of the additional fee. The translation language is determined by the `languages` field in the [request envelope](https://dev.wix.com/docs/build-apps/develop-your-app/frameworks/self-hosting/supported-extensions/backend-extensions/add-self-hosted-service-plugin-extensions.md#request-envelope). - name: cartId | type: string | description: Cart GUID that this checkout was created from. Empty if this checkout wasn't created from a cart. - name: violations | type: array | description: List of validation violations raised by the [Validations service plugin](https://dev.wix.com/docs/rest/business-solutions/e-commerce/service-plugins/validations-integration-service-plugin/introduction.md). - name: severity | type: Severity | description: Severity of the violation. The violations are shown on the cart and checkout pages. A warning is displayed as yellow, and allows a site visitor to proceed with caution. An error is displayed as red, and doesn't allow a site visitor to proceed with the eCommerce flow. - enum: - WARNING: The user is allowed to move forward in the flow. - ERROR: The user is blocked from moving forward in the flow. For example, if callerContext is CART - moving to checkout is blocked. if callerContext is CHECKOUT, placing an order is blocked. - name: target | type: Target | description: Target location on a checkout or cart page where the violation will be displayed. - ONE-OF: - name: other | type: Other | description: General (other) violation. - name: name | type: NameInOther | description: Location on a checkout or a cart page where a general (other) violation will be displayed. - enum: - OTHER_DEFAULT: Default location, in case no specific location is specified. - name: lineItem | type: LineItem | description: Specific line item violation. - name: name | type: NameInLineItem | description: Location on a checkout or a cart page where the specific line item violation will be displayed. - enum: - LINE_ITEM_DEFAULT: Default location, in case no specific location is specified. - name: _id | type: string | description: GUID of the line item containing the violation. - name: description | type: string | description: Violation description. Can include rich text. Only HTTP or HTTPS links in the following format are allowed: `Click me`. - name: extendedFields | type: ExtendedFields | description: Custom field data for the checkout object. [Extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields.md) must be configured in the app dashboard before they can be accessed with API calls. - name: purchaseFlowId | type: string | description: Persistent GUID that correlates between the various eCommerce elements: cart, checkout, and order. - name: customSettings | type: CustomSettings | description: Additional settings for customization of the checkout process. > **Notes:** > * Custom settings can only be set when creating a checkout. > * To access and manage custom checkout page content, your app must have the permission scope named "Manage eCommerce - Admin Permissions". Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions.md). - name: lockGiftCard | type: boolean | description: Whether to restrict the option to add or remove a gift card on the checkout page. Default: `false` - name: lockCouponCode | type: boolean | description: Whether to restrict the option to add or remove a coupon code on the checkout page. Default: `false` - name: disabledPolicyAgreementCheckbox | type: boolean | description: Whether to disable policy agreement checkout in the checkout page Default: `false` - name: disabledManualPayment | type: boolean | description: Whether to disable manual payment option for this checkout. Default: `false` - name: customContentReference | type: CustomContentReference | description: Reference GUIDs for the app and component providing custom checkout page content. To access and manage custom checkout page content, your app must have the permission scope named "Manage eCommerce - Admin Permissions". Learn more about [permission scopes](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/about-permissions.md). - name: appId | type: string | description: GUID of the app providing the content. You can get your app's GUID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/). - name: componentId | type: string | description: GUID of the component within the app it belongs to. You can get your component's GUID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/). - name: externalReference | type: ExternalReference | description: References to an external app and resource associated with this checkout. Used for integration and tracking across different platforms. - name: appId | type: string | description: GUID of the app associated with the purchase flow. For example, the Wix Pay Links app GUID. - name: resourceId | type: string | description: Reference to an external resource GUID. Used to link the purchase flow to a specific entity in an external system. For example, a Wix Pay Link GUID. - name: payAfterFreeTrial | type: PriceSummary | description: Payment for subscriptions after free trial period. - name: businessLocationId | type: string | description: The business location GUID associated with the checkout. To learn more, see the Locations API. - name: paymentCurrency | type: string | description: The currency used for payment, in three-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format. This is determined by the [customer's selected currency](https://support.wix.com/en/article/multicurrency-an-overview) and the site’s supported payment currencies. If the customer’s selected currency is supported for payment, this matches the `conversionCurrency` property. If not supported, this falls back to the `currency` property. - name: taxExemptGroupId | type: string | description: Tax exempt group GUID to use for tax exemptions. ``` ### Examples ### Remove coupon from a checkout ```javascript /************************************** * Backend code - my-backend-file.web.js/ts * **************************************/ import { Permissions, webMethod } from '@wix/web-methods'; import { checkout } from '@wix/ecom'; export const myRemoveCouponFunction = webMethod(Permissions.Anyone, async (checkoutId) => { try { const updatedCheckout = await checkout.removeCoupon(checkoutId); console.log('Success! Updated checkout:', updatedCheckout); return updatedCheckout; } catch (error) { console.error(error); // Handle the error } }); /************* * Page code * ************/ import { myRemoveCouponFunction } from 'backend/my-backend-file.web'; // Sample checkoutId: const checkoutId = '75b0d071-8ca0-4227-962f-91d0605c8c3a'; myRemoveCouponFunction(checkoutId) .then((updatedCheckout) => { const checkoutId = updatedCheckout.checkout._id; const appliedDiscounts = updatedCheckout.checkout.appliedDiscounts; // appliedCoupon boolean value is false if no coupon exists on checkout const appliedCoupon = appliedDiscounts.some(({ coupon }) => coupon); console.log('Success! Updated checkout:', updatedCheckout); return updatedCheckout; }) .catch((error) => { console.error(error); // Handle the error }); /* Promise resolves to: * * { * "_id": "75b0d071-8ca0-4227-962f-91d0605c8c3a", * "lineItems": [ * { * "_id": "00000000-0000-0000-0000-000000000001", * "quantity": 3, * "catalogReference": { * "catalogItemId": "c8539b66-7a44-fe18-affc-afec4be8562a", * "appId": "215238eb-22a5-4c36-9e7b-e7c08025e04e" * }, * "productName": { * "original": "Shirt", * "translated": "Shirt" * }, * "url": "https://example.wixsite.com", * "price": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * }, * "lineItemPrice": { * "amount": "30", * "convertedAmount": "30", * "formattedAmount": "$30.00", * "formattedConvertedAmount": "$30.00" * }, * "fullPrice": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * }, * "priceBeforeDiscounts": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * }, * "totalPriceAfterTax": { * "amount": "30", * "convertedAmount": "30", * "formattedAmount": "$30.00", * "formattedConvertedAmount": "$30.00" * }, * "totalPriceBeforeTax": { * "amount": "30", * "convertedAmount": "30", * "formattedAmount": "$30.00", * "formattedConvertedAmount": "$30.00" * }, * "taxDetails": { * "taxableAmount": { * "amount": "30", * "convertedAmount": "30", * "formattedAmount": "$30.00", * "formattedConvertedAmount": "$30.00" * }, * "taxRate": "0", * "totalTax": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "rateBreakdown": [] * }, * "discount": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "descriptionLines": [], * "media": "wix:image://v1/3c76e2_c5331f937348492a97df87b0a3b34ea4~mv2.jpg#originWidth=1000&originHeight=1000", * "availability": { * "status": "AVAILABLE" * }, * "physicalProperties": { * "sku": "364115376135191", * "shippable": true * }, * "itemType": { * "preset": "PHYSICAL" * }, * "paymentOption": "FULL_PAYMENT_ONLINE", * "rootCatalogItemId": "c8539b66-7a44-fe18-affc-afec4be8562a" * }, * { * "_id": "00000000-0000-0000-0000-000000000002", * "quantity": 1, * "catalogReference": { * "catalogItemId": "df19c1f7-07d8-a265-42f8-e8dfa824cc6e", * "appId": "215238eb-22a5-4c36-9e7b-e7c08025e04e", * "options": { * "variantId": "2f430d69-9b75-4874-bfbd-c5f6fa5aff3d", * "customTextFields": { * "birthday card": "Happy Birthday!" * } * } * }, * "productName": { * "original": "Shoe", * "translated": "Shoe" * }, * "url": "https://example.wixsite.com", * "price": { * "amount": "85", * "convertedAmount": "85", * "formattedAmount": "$85.00", * "formattedConvertedAmount": "$85.00" * }, * "lineItemPrice": { * "amount": "85", * "convertedAmount": "85", * "formattedAmount": "$85.00", * "formattedConvertedAmount": "$85.00" * }, * "fullPrice": { * "amount": "85", * "convertedAmount": "85", * "formattedAmount": "$85.00", * "formattedConvertedAmount": "$85.00" * }, * "priceBeforeDiscounts": { * "amount": "85", * "convertedAmount": "85", * "formattedAmount": "$85.00", * "formattedConvertedAmount": "$85.00" * }, * "totalPriceAfterTax": { * "amount": "85", * "convertedAmount": "85", * "formattedAmount": "$85.00", * "formattedConvertedAmount": "$85.00" * }, * "totalPriceBeforeTax": { * "amount": "85", * "convertedAmount": "85", * "formattedAmount": "$85.00", * "formattedConvertedAmount": "$85.00" * }, * "taxDetails": { * "taxableAmount": { * "amount": "85", * "convertedAmount": "85", * "formattedAmount": "$85.00", * "formattedConvertedAmount": "$85.00" * }, * "taxRate": "0", * "totalTax": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "rateBreakdown": [] * }, * "discount": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "descriptionLines": [ * { * "name": { * "original": "Color", * "translated": "Color" * }, * "colorInfo": { * "original": "Brown", * "translated": "Brown", * "code": "#783f04" * } * }, * { * "name": { * "original": "birthday card", * "translated": "birthday card" * }, * "plainText": { * "original": "Happy Birthday!", * "translated": "Happy Birthday!" * } * } * ], * "media": "wix:image://v1/3c76e2_bf235c38610f4d2a905db71095b351cf~mv2.jpg#originWidth=1000&originHeight=1000", * "availability": { * "status": "AVAILABLE", * "quantityAvailable": 30 * }, * "physicalProperties": { * "sku": "364215376135191", * "shippable": true * }, * "itemType": { * "preset": "PHYSICAL" * }, * "paymentOption": "FULL_PAYMENT_ONLINE", * "rootCatalogItemId": "df19c1f7-07d8-a265-42f8-e8dfa824cc6e" * }, * { * "_id": "00000000-0000-0000-0000-000000000003", * "quantity": 1, * "catalogReference": { * "catalogItemId": "9fe8c5b2-9c94-7153-ebb9-8533695e2b6f", * "appId": "215238eb-22a5-4c36-9e7b-e7c08025e04e", * "options": { * "Size": "Large", * "Color": "White" * } * }, * "price": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "fullPrice": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "priceBeforeDiscounts": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "descriptionLines": [], * "availability": { * "status": "NOT_FOUND" * }, * "paymentOption": "FULL_PAYMENT_ONLINE" * } * ], * "billingInfo": { * "address": { * "addressLine1": "235 West 23rd Street", * "addressLine2": "3rd floor", * "city": "New York", * "subdivision": "US-NY", * "country": "US", * "postalCode": "10011" * }, * "contactDetails": { * "firstName": "Jane", * "lastName": "Doe", * "phone": "+1234567890" * } * }, * "shippingInfo": { * "shippingDestination": { * "address": { * "addressLine1": "235 West 23rd Street", * "addressLine2": "3rd floor", * "city": "New York", * "subdivision": "US-NY", * "country": "US", * "postalCode": "10011" * }, * "contactDetails": { * "firstName": "Jane", * "lastName": "Doe", * "phone": "+1234567890" * } * }, * "selectedCarrierServiceOption": { * "code": "ed5bbce2-9533-dff4-7db0-13702fd139c5", * "title": "Standard US Shipping", * "logistics": { * "deliveryTime": "" * }, * "cost": { * "totalPriceAfterTax": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * }, * "totalPriceBeforeTax": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * }, * "taxDetails": { * "taxRate": "0", * "totalTax": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "rateBreakdown": [] * }, * "price": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * } * }, * "requestedShippingOption": true, * "otherCharges": [], * "carrierId": "c8a08776-c095-4dec-8553-8f9698d86adc" * }, * "region": { * "_id": "009fbe5d-89d3-7825-cbbf-1aab4d908b73", * "name": "USA shipping" * }, * "carrierServiceOptions": [ * { * "carrierId": "c8a08776-c095-4dec-8553-8f9698d86adc", * "shippingOptions": [ * { * "code": "ed5bbce2-9533-dff4-7db0-13702fd139c5", * "title": "Standard US Shipping", * "logistics": { * "deliveryTime": "" * }, * "cost": { * "price": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * }, * "otherCharges": [] * } * } * ] * } * ] * }, * "buyerNote": "Please wrap it up as a present", * "buyerInfo": { * "contactId": "f7dc17a6-825a-466e-a78e-c4abea0217db", * "email": "Janedoe@example.com", * "memberId": "c43190d2-eea3-493e-b6e8-f146850c6873" * }, * "conversionCurrency": "USD", * "priceSummary": { * "subtotal": { * "amount": "115", * "convertedAmount": "115", * "formattedAmount": "$115.00", * "formattedConvertedAmount": "$115.00" * }, * "shipping": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * }, * "tax": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "discount": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "total": { * "amount": "125", * "convertedAmount": "125", * "formattedAmount": "$125.00", * "formattedConvertedAmount": "$125.00" * }, * "additionalFees": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * } * }, * "calculationErrors": { * "orderValidationErrors": [] * }, * "appliedDiscounts": [], * "customFields": [ * { * "value": "12345", * "title": "Tax ID", * "translatedTitle": "Tax ID" * } * ], * "weightUnit": "KG", * "currency": "USD", * "channelType": "WEB", * "siteLanguage": "en", * "buyerLanguage": "en", * "completed": false, * "taxIncludedInPrice": false, * "createdBy": { * "memberId": "c43190d2-eea3-493e-b6e8-f146850c6873" * }, * "_createdDate": "2022-10-19T14:22:03.847Z", * "_updatedDate": "2022-10-19T14:22:30.842Z", * "payNow": { * "subtotal": { * "amount": "115", * "convertedAmount": "115", * "formattedAmount": "$115.00", * "formattedConvertedAmount": "$115.00" * }, * "shipping": { * "amount": "10", * "convertedAmount": "10", * "formattedAmount": "$10.00", * "formattedConvertedAmount": "$10.00" * }, * "tax": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "discount": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "total": { * "amount": "125", * "convertedAmount": "125", * "formattedAmount": "$125.00", * "formattedConvertedAmount": "$125.00" * }, * "additionalFees": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * } * }, * "payLater": { * "subtotal": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "shipping": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "tax": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "discount": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "total": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * }, * "additionalFees": { * "amount": "0", * "convertedAmount": "0", * "formattedAmount": "$0.00", * "formattedConvertedAmount": "$0.00" * } * }, * "membershipOptions": { * "eligibleMemberships": [], * "invalidMemberships": [], * "selectedMemberships": { * "memberships": [] * } * }, * "additionalFees": [] * } * */ ``` ### removeCoupon (self-hosted) Self-hosted SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md). ```javascript import { createClient } from '@wix/sdk'; import { checkout } from '@wix/ecom'; // Import the auth strategy for the relevant access type // Import the relevant host module if needed const myWixClient = createClient ({ modules: { checkout }, // Include the auth strategy and host as relevant }); async function removeCoupon(_id) { const response = await myWixClient.checkout.removeCoupon(_id); }; ``` ---