---
title: HypeXAPI.sendStatementByDataset
slug: hypexapisendstatementbydataset
description: Learn how to use the function described in this document to generate statements based on dataset attributes. Simply pass in the desired element, and the function will automatically create a statement using its attributes. An example is provided to help yo
docTags: 
createdAt: 2022-05-04T09:53:01.000Z
---

This function sends a statement based on dataset attributes.

To use this function, simply pass in the element that you want the attributes to be taken from. The function will then send a statement based on those attributes.

For example, if you have an element with the following attributes:

data-xapi-actor = "John Doe"
data-xapi-verb = "likes"
data-xapi-object = "cats"

The function will send a statement like this: `John Doe` `likes` `cats`

```javascript

HypeXAPI.sendStatementByDataset(element);
```

