# Order summary component

The order summary component lists the products in the customer's cart at checkout-time and provides an item-level and order-level breakdown of how much they are to be charged, denominated in the [checkout-session's](https://docs.digitalriver.com/digital-river-api-reference/2021-12-13/drop-in-checkout-sessions/checkout-sessions-basics) [`currency`](https://docs.digitalriver.com/digital-river-api-reference/2021-12-13/drop-in-checkout-sessions/checkout-sessions-basics#currency).

For each of that resource's [`items[]`](https://docs.digitalriver.com/digital-river-api-reference/2021-12-13/drop-in-checkout-sessions/checkout-sessions-basics#product-data), the component displays its `quantity` along with the `image` and `name` that you either passed in [`productDetails`](/digital-river-api/product-management/skus.md#product-details) or stored in the referenced [SKU](/digital-river-api/product-management/skus.md#skus).

As customers progress through the various checkout stages, Digital River computes applicable taxes and shipping costs and then updates the experience.

<figure><img src="/files/OP47nraicn6wSGeN9X7w" alt=""><figcaption></figcaption></figure>

## Creating the order summary component

To create an instance of the order summary component, pass `'ordersummary'` to [`createComponent()`](/digital-river-api/developer-resources/digitalrivercheckout.js-reference/digitalrivercheckout-object/components.md#createcomponent-componenttype).

```javascript
let orderSummaryComponent;
...
orderSummaryComponent = components.createComponent('ordersummary');
```

## Mounting the order summary component

To attach the order summary component to your DOM, pass the `id` of its container to [`mount()`](/digital-river-api/developer-resources/digitalrivercheckout.js-reference/digitalrivercheckout-object/components.md#mount-elementid).

```javascript
<div id="order-summary-container" style="display: block">
...
orderSummaryComponent.mount('order-summary-container');
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.digitalriver.com/digital-river-api/developer-resources/digitalrivercheckout.js-reference/digitalrivercheckout-object/components/order-summary-component.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
