Totals
The totals resource calculates the total costs for:
Read Cart Total
Retrieve the total cost of all cart line items before cart total discounts are applied.
Workflow
- Start with cart
GET
the link with rel: total- Render the response
Response Fields
Type: totals.total
Name | Description | Type |
---|---|---|
cost | The total costs. This is an array because the total cost have multiple currencies. For example, $20 USD + 20,000 loyalty points. | array |
currency | The currency the cost is in. | string |
amount | The decimal value of the cost. | decimal |
display | Formatted currency string that can be displayed on the client application. | string |
Read Cart Line Item Total
Retrieve the total cost of a single cart line item for a requested quantity, after cart line item discounts are applied.
Workflow
- Start with line-item
GET
the link with rel: total- Render the response
Response Fields
Type: totals.total
Name | Description | Type |
---|---|---|
cost | The total costs. This is an array because the total cost have multiple currencies. For example, $20 USD + 20,000 loyalty points. | array |
currency | The currency the cost is in. | string |
amount | The decimal value of the cost. | decimal |
display | Formatted currency string that can be displayed on the client application. | string |
Read Order Total
Retrieve the total cost of the shopper’s order including taxes and shipping costs.
Workflow
- Start with order
GET
the link with rel: total- Render the response
Response Fields
Type: totals.total
Name | Description | Type |
---|---|---|
cost | The total costs. This is an array because the total cost have multiple currencies. For example, $20 USD + 20,000 loyalty points. | array |
currency | The currency the cost is in. | string |
amount | The decimal value of the cost. | decimal |
display | Formatted currency string that can be displayed on the client application. | string |
Read Shipment Total
Retrieve the total cost for a shipment.
Workflow
- Start with shipment
GET
the link with rel: total- Render the response
Response Fields
Type: totals.total
Name | Description | Type |
---|---|---|
cost | The total costs. This is an array because the total cost have multiple currencies. For example, $20 USD + 20,000 loyalty points. | array |
currency | The currency the cost is in. | string |
amount | The decimal value of the cost. | decimal |
display | Formatted currency string that can be displayed on the client application. | string |
Read Shipment Line Item Total
Retrieve the total cost for a shipment line item.
Workflow
- Start with shipment-line-item
GET
the link with rel: total- Render the response
Response Fields
Type: totals.total
Name | Description | Type |
---|---|---|
cost | The total costs. This is an array because the total cost have multiple currencies. For example, $20 USD + 20,000 loyalty points. | array |
currency | The currency the cost is in. | string |
amount | The decimal value of the cost. | decimal |
display | Formatted currency string that can be displayed on the client application. | string |