---
title: "Data objects"
slug: "data-objects"
abstract: "List of objects offered by Sitecore Discover JavaScript SDK for React."
---
# Data objects

This topic lists the various object definitions included in Sitecore Discover JavaScript SDK for React.

## Context

This object describes the widget, page, user, and many other attributes.

Extract the context object from the SDK, with the following method:

```js
import { PageController } from '@sitecore-discover/react';

const context = PageController.getContext();
```

## ProductEventModel

This object describes a product.

| Property | Type | Description |
| --- | --- | --- |
| `sku` | string | Required.<br><br>The stock keeping unit (SKU) of the product. |
| `quantity` | number | Optional.<br><br>Number of units of the product. |
| `price` | number | Optional.<br><br>Price used to calculate the order. |
| `priceOriginal` | number | Optional.<br><br>The originally posted price of the product. |

## UserEventModel

This object describes a user.

| Property | Type | Description |
| --- | --- | --- |
| `email` | string | Required.<br><br>The email address of the user. |
| `id` | string | Required.<br><br>ID of the user. |
| `emailId` | string | Optional.<br><br>ID for the email address of the user. |

## CheckoutEventModel

This object describes the checkout event.

| Property | Type | Description |
| --- | --- | --- |
| `orderId` | string | Required.<br><br>ID of the order. |
| `total` | number | Required.<br><br>Order total. |
| `subtotal` | number | Optional.<br><br>Subtotal of the order. |

## ContextUser

The `ContextUser` object contains information about the user.

| Property | Type | Description |
| --- | --- | --- |
| `groups` | array of strings | List of IDs of the groups the user belongs to. |
| `order_id` | array of strings | List of IDs of orders. |

### removePageProductGroup

The method removes the page product group.

Returns: `IContext`

| Argument | Type | Description |
| --- | --- | --- |
| `value` | string | Required. This object describes the page. |
| `filter` | function | Accepts any function in the following format: `(v: any) => boolean`. |