POST api/shoppingcart/add/items?shoppingCartId={shoppingCartId}

Request Information

URI Parameters

NameDescriptionTypeAdditional information
shoppingCartId

globally unique identifier

Required

Body Parameters

CreateCartItems
NameDescriptionTypeAdditional information
CartItems

Collection of CartItem

None.

accountId

globally unique identifier

None.

Request Formats

application/json, text/json

Sample:
{
  "CartItems": [
    {
      "WebProductId": "c4a71472-b481-4c2e-83e1-b4b1bd8b7a18",
      "WebProductName": "sample string 2",
      "ParentWebProductId": "fc14a23e-ff2c-4960-883b-6f45a547af22",
      "Quantity": 4,
      "Price": 5.0
    },
    {
      "WebProductId": "c4a71472-b481-4c2e-83e1-b4b1bd8b7a18",
      "WebProductName": "sample string 2",
      "ParentWebProductId": "fc14a23e-ff2c-4960-883b-6f45a547af22",
      "Quantity": 4,
      "Price": 5.0
    }
  ],
  "accountId": "ff2210f7-dda7-40d2-9088-d2a150060f66"
}

application/xml, text/xml

Sample:
<CreateCartItems xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/HRCI.Services.BL.Models">
  <CartItems>
    <CartItem>
      <ParentWebProductId>fc14a23e-ff2c-4960-883b-6f45a547af22</ParentWebProductId>
      <Price>5</Price>
      <Quantity>4</Quantity>
      <WebProductId>c4a71472-b481-4c2e-83e1-b4b1bd8b7a18</WebProductId>
      <WebProductName>sample string 2</WebProductName>
    </CartItem>
    <CartItem>
      <ParentWebProductId>fc14a23e-ff2c-4960-883b-6f45a547af22</ParentWebProductId>
      <Price>5</Price>
      <Quantity>4</Quantity>
      <WebProductId>c4a71472-b481-4c2e-83e1-b4b1bd8b7a18</WebProductId>
      <WebProductName>sample string 2</WebProductName>
    </CartItem>
  </CartItems>
  <accountId>ff2210f7-dda7-40d2-9088-d2a150060f66</accountId>
</CreateCartItems>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

IHttpActionResult

None.

Response Formats

application/json, text/json, application/xml, text/xml

Sample:

Sample not available.