> ## Documentation Index
> Fetch the complete documentation index at: https://developer.fabric.inc/llms.txt
> Use this file to discover all available pages before exploring further.

# Cart soft delete (cart decoupled)

> Cart soft delete, add the deleted boolean flag as true and add the order number to the cart (cart decoupled)



## OpenAPI

````yaml oms_v1 delete /api-cart/cart-decoupled/{cartId}
openapi: 3.0.0
info:
  description: Order Management System
  version: 1.0.0
  title: Orders v1 (OMS v1)
  contact:
    email: oms-team@fabric.inc
  license:
    name: fabric API license
    url: https://fabric.inc/api-license
servers:
  - url: https://prod01-apigw.{customer_name}.fabric.zone
    description: Production
    variables:
      customer_name:
        default: yourcompany
        description: Customer name, provided by support team
security: []
tags:
  - name: Cart
    description: >-
      Cart APIs<br /><br />**Note:** These are the legacy Cart APIs. To view
      fabric's new Cart APIs, navigate to *Cart API > Cart* from the left side
      navigation pane.
  - name: Bill To
    description: Bill To APIs [Deprecated]
  - name: Ship To
    description: >-
      Ship To APIs<br /><br />**Note:** These are the legacy Ship To APIs. To
      view fabric's new Shipping APIs, navigate to *Cart API > Shipping* from
      the left side navigation pane.
  - name: Wishlist
    description: Wishlist APIs
  - name: Cart Decoupled
    description: Cart Decoupled APIs
  - name: Warehouse
    description: Warehouse APIs
  - name: Inventory
    description: Inventory APIs
  - name: Attributes
    description: >-
      Attributes APIs<br /><br />**Note:** These are the legacy Attribute APIs.
      To view fabric's new Attribute APIs, navigate to *Cart API > Attribute*
      from the left side navigation pane.
  - name: List
    description: List APIs
  - name: Tax/Address Validate
    description: Tax/Address Validate APIs
  - name: Shipping
    description: Shipping APIs
  - name: Payments
    description: Payments APIs
  - name: Order
    description: Order APIs
paths:
  /api-cart/cart-decoupled/{cartId}:
    delete:
      tags:
        - Cart
      summary: Cart soft delete (cart decoupled)
      description: >-
        Cart soft delete, add the deleted boolean flag as true and add the order
        number to the cart (cart decoupled)
      operationId: softDeleteCartDecoupled
      parameters:
        - in: path
          name: cartId
          required: true
          schema:
            type: string
            minLength: 24
            maxLength: 24
            example: 5e5818a84d030c206b2ffb02
        - $ref: '#/components/parameters/xSiteContent'
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - orderNumber
              properties:
                orderNumber:
                  type: string
                  minLength: 15
                  maxLength: 15
                  example: 1234-1234-12345
      responses:
        '200':
          $ref: '#/components/responses/SoftDeleteCart'
        '400':
          $ref: '#/components/responses/GenericClientError'
        '404':
          $ref: '#/components/responses/CartNotFound'
        '500':
          $ref: '#/components/responses/GenericServerError'
components:
  parameters:
    xSiteContent:
      name: x-site-context
      in: header
      description: >-
        The `x-site-context` header is a JSON object that contains information
        about the source you wish to pull from. The mandatory `account` is the
        24 character identifier found in Copilot. The `channel` (Sales channel
        ID), `stage` (environment name), and `date` attributes can be used to
        further narrow the scope of your data source.
      required: true
      schema:
        type: string
        example: >-
          {"date": "2023-01-01T00:00:00.000Z", "channel": 12, "account":
          "1234abcd5678efgh9ijklmno","stage":"production"}
  responses:
    SoftDeleteCart:
      description: Soft delete cart
      content:
        application/json:
          schema:
            allOf:
              - allOf:
                  - type: object
                    properties:
                      registeredUser:
                        type: boolean
                        example: false
                      account:
                        type: string
                      approver:
                        type: string
                      po:
                        type: string
                      cartId:
                        type: number
                        example: 111166
                      status:
                        type: string
                        example: pending
                      allPromosApplied:
                        type: array
                      attributes:
                        type: array
                      __v:
                        type: number
                        example: 0
                      totalAmount:
                        type: object
                        properties:
                          currency:
                            type: string
                            maxLength: 3
                            minLength: 3
                            example: USD
                          amount:
                            type: number
                            example: 38
                      quantity:
                        type: number
                        example: 2
                  - $ref: '#/components/schemas/timeStamp'
              - type: object
                properties:
                  deleted:
                    type: boolean
                    example: true
                  items:
                    type: array
                    items:
                      allOf:
                        - type: object
                          properties:
                            price:
                              type: object
                              properties:
                                discount:
                                  type: object
                                  properties:
                                    discountAmount:
                                      type: number
                                      example: 0
                                    price:
                                      type: number
                                      example: 0
                                    promosApplied:
                                      type: array
                                sale:
                                  type: number
                                  example: 0
                                base:
                                  type: number
                                  example: 19
                                currency:
                                  type: string
                                  example: USD
                            sample:
                              type: boolean
                              example: false
                            isUnique:
                              type: boolean
                              example: false
                            discountedQuantity:
                              type: number
                              example: 0
                            group:
                              type: array
                              items:
                                type: string
                                example: '123123123123123123123123'
                            weightUnit:
                              type: string
                              example: lb
                            isPickup:
                              type: boolean
                              example: false
                            itemId:
                              type: number
                              example: 15
                            sku:
                              type: string
                              example: sk231212
                            taxCode:
                              type: string
                              example: TC1234567890
                            title:
                              type: string
                              example: fabric t-shirt
                            weight:
                              type: number
                              example: 4.2
                            quantity:
                              type: number
                              example: 2
                            lineItemId:
                              type: number
                              example: 1
                            attributeTotalPrice:
                              type: number
                              example: 0
                            totalPrice:
                              type: object
                              properties:
                                currency:
                                  type: string
                                  example: USD
                                amount:
                                  type: number
                                  example: 38
                            attributes:
                              type: array
                            id:
                              type: string
                              example: 6141a40c13f13a000876272a
                        - type: object
                          properties:
                            _id:
                              type: string
                              example: 5fee9d59f2f08a1b3cbdea08
                            createdAt:
                              type: string
                              example: '2020-12-31T02:09:53.914Z'
                            updatedAt:
                              type: string
                              example: '2020-12-31T02:09:53.914Z'
    GenericClientError:
      description: A generic client error
      content:
        application/json:
          schema:
            type: object
            properties:
              code:
                description: The error code
                type: string
              message:
                description: The error message
                type: string
    CartNotFound:
      description: Cart not found
      content:
        application/json:
          schema:
            type: object
            properties:
              code:
                description: The error code
                example: CART_NOT_FOUND
                type: string
              message:
                description: The error message
                example: Cart not found.
                type: string
    GenericServerError:
      description: A generic server error
      content:
        application/json:
          schema:
            type: object
            properties:
              code:
                description: The error code
                type: string
              message:
                description: The error message
                type: string
  schemas:
    timeStamp:
      type: object
      properties:
        _id:
          type: string
          example: 5fee9d59f2f08a1b3cbdea08
        createdAt:
          type: string
          example: '2020-12-31T02:09:53.914Z'
        updatedAt:
          type: string
          example: '2020-12-31T02:09:53.914Z'

````