Collect totals

quote Cart Total Management V1Collect Totals Put

Set shipping/billing methods and additional data for cart and collect totals.

put

/V1/carts/mine/collect-totals

Header parameters
Content-Typestring
Example: application/json
Body
object
Example: {"paymentMethod":{"method":"<string>","po_number":"<string>","additional_data":["<string>","<string>"],"extension_attributes":{"agreement_ids":["<string>","<string>"]}},"shippingCarrierCode":"<string>","shippingMethodCode":"<string>","additionalData":{"extension_attributes":{"gift_messages":[{"sender":"<string>","recipient":"<string>","message":"<string>","gift_message_id":"<integer>","customer_id":"<integer>","extension_attributes":{"entity_id":"cillum enim Excepteur","entity_type":"laborum elit veniam est"}},{"sender":"<string>","recipient":"<string>","message":"<string>","gift_message_id":"<integer>","customer_id":"<integer>","extension_attributes":{"entity_id":"ullamco sed exercitation labore","entity_type":"do tempor nulla dolore proident"}}]},"custom_attributes":[{"attribute_code":"exercitation incididunt in","value":"aliquip"},{"attribute_code":"qui","value":"anim eiusmod enim ea"}]}}
Responses
curl -L \
  --request PUT \
  --url 'http://{{baseurl}}/V1/carts/mine/collect-totals' \
  --header 'Content-Type: application/json' \
  --data '{
    "paymentMethod": {
      "method": "<string>",
      "po_number": "<string>",
      "additional_data": [
        "<string>",
        "<string>"
      ],
      "extension_attributes": {
        "agreement_ids": [
          "<string>",
          "<string>"
        ]
      }
    },
    "shippingCarrierCode": "<string>",
    "shippingMethodCode": "<string>",
    "additionalData": {
      "extension_attributes": {
        "gift_messages": [
          {
            "sender": "<string>",
            "recipient": "<string>",
            "message": "<string>",
            "gift_message_id": "<integer>",
            "customer_id": "<integer>",
            "extension_attributes": {
              "entity_id": "cillum enim Excepteur",
              "entity_type": "laborum elit veniam est"
            }
          },
          {
            "sender": "<string>",
            "recipient": "<string>",
            "message": "<string>",
            "gift_message_id": "<integer>",
            "customer_id": "<integer>",
            "extension_attributes": {
              "entity_id": "ullamco sed exercitation labore",
              "entity_type": "do tempor nulla dolore proident"
            }
          }
        ]
      },
      "custom_attributes": [
        {
          "attribute_code": "exercitation incididunt in",
          "value": "aliquip"
        },
        {
          "attribute_code": "qui",
          "value": "anim eiusmod enim ea"
        }
      ]
    }
  }'
{
  "weee_tax_applied_amount": 60755706.8580344,
  "total_segments": [
    {
      "code": "ad tempor anim ipsum",
      "value": 16297270.936728075,
      "title": "dolor dolore pariatur",
      "area": "occaecat",
      "extension_attributes": {
        "tax_grandtotal_details": [
          {
            "amount": -82934909.15754491,
            "rates": [
              {
                "value": "<Error: Too many levels of nesting to fake this schema>"
              },
              {
                "value": "<Error: Too many levels of nesting to fake this schema>"
              }
            ],
            "group_id": -24838007
          },
          {
            "amount": -20775294.562663138,
            "rates": [
              {
                "value": "<Error: Too many levels of nesting to fake this schema>"
              },
              {
                "value": "<Error: Too many levels of nesting to fake this schema>"
              }
            ],
            "group_id": -70022741
          }
        ],
        "vertex_tax_calculation_messages": [
          "ut ex Duis do",
          "ad eu occaecat"
        ]
      }
    },
    {
      "code": "elit est",
      "value": -9983868.413395718,
      "title": "tempor adipisicing aute",
      "area": "dolor Excepteur minim id voluptate",
      "extension_attributes": {
        "tax_grandtotal_details": [
          {
            "amount": -59899499.6119877,
            "rates": [
              {
                "value": "<Error: Too many levels of nesting to fake this schema>"
              },
              {
                "value": "<Error: Too many levels of nesting to fake this schema>"
              }
            ],
            "group_id": 24209409
          },
          {
            "amount": -34005626.344232894,
            "rates": [
              {
                "value": "<Error: Too many levels of nesting to fake this schema>"
              },
              {
                "value": "<Error: Too many levels of nesting to fake this schema>"
              }
            ],
            "group_id": -97748780
          }
        ],
        "vertex_tax_calculation_messages": [
          "qui sed",
          "consectetur quis dolore est"
        ]
      }
    }
  ],
  "grand_total": 53388921.572937995,
  "base_grand_total": 74430602.28983408,
  "subtotal": 61832736.098612875,
  "base_subtotal": 17993435.48102285,
  "discount_amount": 21508241.72508794,
  "base_discount_amount": 93733227.36224553,
  "subtotal_with_discount": -74486915.22384454,
  "base_subtotal_with_discount": -81404334.97137111,
  "shipping_amount": -23336906.65898244,
  "base_shipping_amount": 19371395.13158205,
  "shipping_discount_amount": 87786472.47204217,
  "base_shipping_discount_amount": 80062701.42786613,
  "tax_amount": 86005818.12712583,
  "base_tax_amount": -78833183.76671675,
  "shipping_tax_amount": -76092538.74097401,
  "base_shipping_tax_amount": 15397382.709030256,
  "subtotal_incl_tax": 69362008.96207744,
  "base_subtotal_incl_tax": 36939107.429860115,
  "shipping_incl_tax": 4963547.948041305,
  "base_shipping_incl_tax": 19414568.369195044,
  "base_currency_code": "est do in tempor",
  "quote_currency_code": "Lorem tempor Excepteur nulla officia",
  "coupon_code": "officia in",
  "items_qty": -51912152,
  "items": [
    {
      "item_id": 37459718,
      "price": 34515738.4445273,
      "base_price": 39845150.853557736,
      "qty": -15413531.592034206,
      "row_total": -34881793.505893596,
      "base_row_total": 61195261.704752415,
      "options": "voluptate",
      "weee_tax_applied_amount": -64938872.74466652,
      "weee_tax_applied": "dolore quis adipisicing aliqua pariatur",
      "row_total_with_discount": 40996810.44143927,
      "tax_amount": -22518782.453900024,
      "base_tax_amount": -74167559.54631445,
      "tax_percent": -40548829.03644925,
      "discount_amount": 92886270.66723058,
      "base_discount_amount": -36722725.20734872,
      "discount_percent": 12187945.589098483,
      "price_incl_tax": 7139442.109478503,
      "base_price_incl_tax": 46118216.54988706,
      "row_total_incl_tax": -57649996.221814215,
      "base_row_total_incl_tax": -46786751.130193725,
      "extension_attributes": {},
      "name": "irure et Duis ipsum aliquip"
    },
    {
      "item_id": -40278158,
      "price": -75868165.99584365,
      "base_price": 21725817.957303077,
      "qty": -48538804.96811307,
      "row_total": 14553380.314327091,
      "base_row_total": 6476155.691399649,
      "options": "ad aliqua quis",
      "weee_tax_applied_amount": 27045337.737182036,
      "weee_tax_applied": "labore do id",
      "row_total_with_discount": 31683139.385813728,
      "tax_amount": -25052170.762623444,
      "base_tax_amount": -94623591.8447809,
      "tax_percent": -29573850.794136852,
      "discount_amount": 75741154.20852757,
      "base_discount_amount": -11475092.026047885,
      "discount_percent": 55414421.9585551,
      "price_incl_tax": 38037654.69392055,
      "base_price_incl_tax": -23859367.50927922,
      "row_total_incl_tax": 25051576.59574531,
      "base_row_total_incl_tax": 54196575.08320376,
      "extension_attributes": {},
      "name": "nisi irure"
    }
  ],
  "extension_attributes": {
    "coupon_label": "magna"
  }
}