MageSmith
PUTQuote · Magento 2.4.9 Self (customer or admin)

PUT /V1/carts/mine

PUT /V1/carts/mine is a Magento 2 REST endpoint in the Quote module. Save quote. Requires a customer or admin Bearer token (whichever owns the resource).

Last verified: against Magento 2.4.9.

Returns

void

Service contract

Magento\Quote\Api\CartRepositoryInterface::save

Authorization

Self — a customer Bearer token (when the caller owns the resource) or an admin token both work.

Body parameters

quote Magento\Quote\Api\Data\CartInterface Required

Example request

Auto-generated from the service contract — paste-ready against your store's /rest/default base. Replace the host, store code, ACL token, and any required values before running.

Headers

Accept
application/json
Content-Type
application/json
Authorization
Bearer <ACCESS_TOKEN> customer or admin token (whoever owns the resource)

Path

/V1/carts/mine

Body

{
  "quote": {
    "billing_address": {
      "city": "",
      "company": "",
      "country_id": "",
      "custom_attributes": [
        {
          "attribute_code": "",
          "value": ""
        }
      ],
      "customer_address_id": 0,
      "customer_id": 0,
      "email": "",
      "extension_attributes": {},
      "fax": "",
      "firstname": "",
      "id": 0,
      "lastname": "",
      "middlename": "",
      "postcode": "",
      "prefix": "",
      "region": "",
      "region_code": "",
      "region_id": 0,
      "same_as_billing": 0,
      "save_in_address_book": 0,
      "street": [
        {}
      ],
      "suffix": "",
      "telephone": "",
      "vat_id": ""
    },
    "converted_at": "",
    "created_at": "",
    "currency": {
      "base_currency_code": "",
      "base_to_global_rate": 0,
      "base_to_quote_rate": 0,
      "extension_attributes": {},
      "global_currency_code": "",
      "quote_currency_code": "",
      "store_currency_code": "",
      "store_to_base_rate": 0,
      "store_to_quote_rate": 0
    },
    "customer": {
      "addresses": [
        {
          "city": "",
          "company": "",
          "country_id": "",
          "custom_attributes": [
            {
              "attribute_code": "",
              "value": ""
            }
          ],
          "customer_id": 0,
          "default_billing": false,
          "default_shipping": false,
          "extension_attributes": {},
          "fax": "",
          "firstname": "",
          "id": 0,
          "lastname": "",
          "middlename": "",
          "postcode": "",
          "prefix": "",
          "region": {},
          "region_id": 0,
          "street": [
            {}
          ],
          "suffix": "",
          "telephone": "",
          "vat_id": ""
        }
      ],
      "confirmation": "",
      "created_at": "",
      "created_in": "",
      "custom_attributes": [
        {
          "attribute_code": "",
          "value": ""
        }
      ],
      "default_billing": "",
      "default_shipping": "",
      "disable_auto_group_change": 0,
      "dob": "",
      "email": "",
      "extension_attributes": {},
      "firstname": "",
      "gender": 0,
      "group_id": 0,
      "id": 0,
      "lastname": "",
      "middlename": "",
      "prefix": "",
      "store_id": 0,
      "suffix": "",
      "taxvat": "",
      "updated_at": "",
      "website_id": 0
    },
    "customer_is_guest": false,
    "customer_note": "",
    "customer_note_notify": false,
    "customer_tax_class_id": 0,
    "extension_attributes": {},
    "id": 0,
    "is_active": false,
    "is_virtual": false,
    "items": [
      {
        "extension_attributes": {},
        "item_id": 0,
        "name": "",
        "price": 0,
        "product_option": {
          "extension_attributes": {}
        },
        "product_type": "",
        "qty": 0,
        "quote_id": "",
        "sku": ""
      }
    ],
    "items_count": 0,
    "items_qty": 0,
    "orig_order_id": 0,
    "reserved_order_id": "",
    "store_id": 0,
    "updated_at": ""
  }
}

Every Magento dev tool, in one hosted workspace.

Free to sign up. Nothing to install. Drafts, audits, and projects saved across every tool.