> For the complete documentation index, see [llms.txt](https://docs.onum.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.onum.com/listeners/listener-integrations/pull-data-from-http-endpoints/pull-data-from-the-sentinelone-api/activities.md).

# Activities

## Overview

Get a list of activities through the [SentinelOne API](https://www.postman.com/api-evangelist/sentinelone/request/2p2rz4w/get-activities?sideView=agentMode) using the **HTTP Pull** Listener.

## HTTP Pull Listener configuration

In Falcon Onum, go to the **Listeners** area and click **New Listener > HTTP Pull**. Give a name to your new Listener and enter the following data:

### Parameters

Add the following parameter:

* **Name** - `sentinelOneDomain`
* **Value** - Enter your SentinelOne domain.

### Secrets

You must define these credentials in Onum:

* `sentinelOneApiToken` will reference your SentinelOne API token.

To do it, click **Add element** and enter a **Name** for the secret (in this case, `sentinelOneApiToken`). Then, click the **Value** field and select **New secret** to create a new one:

* Give the secret a **Name**.
* Turn off the **Expiration date** option.
* Click **Add new value** and paste the secret corresponding to the value.
* Click **Save**.

You can now select the secret you just created in the **Value** field list.

{% hint style="info" %}
Learn more about secrets in Onum in [this article](/settings/organization-settings/secrets-management.md).
{% endhint %}

### Setup

After entering the required parameters and secrets, you can choose to manually enter the rest of configuration fields, or simply paste the given YAML:

{% tabs %}
{% tab title="Config as YAML" %}
Toggle **ON** the **Config as YAML** option to enable a free text field where you can paste the following YAML:

```yaml
withTemporalWindow: true
temporalWindow:
  duration: 5m
  offset: 5m
  tz: UTC
  format: RFC3339
withAuthentication: false
withEnumerationPhase: false
collectionPhase:
  paginationType: "cursor"
  cursorSelector: ".pagination.nextCursor"
  initialRequest:
    method: GET
    url: "https://${parameters.sentinelOneDomain}/web/api/v2.1/activities"
    headers:
      - name: Accept
        value: application/json
      - name: Authorization
        value: "ApiToken ${secrets.sentinelOneApiToken}"
    queryParams: 
      - name: createdAt__gte
        value: "${temporalWindow.from}"
      - name: createdAt__lte
        value: "${temporalWindow.to}"
  nextRequest:
    method: GET
    url: "https://${parameters.sentinelOneDomain}/web/api/v2.1/activities"
    headers:
      - name: Accept
        value: application/json
      - name: Authorization
        value: "ApiToken ${secrets.sentinelOneApiToken}"
  output:
    select: ".data"
    map: "."
    outputMode: element 
```

{% endtab %}

{% tab title="Manually configure" %}
**Temporal Window**

Toggle **ON** to add a temporal window for events. This repeatedly shifts the time window over which data is collected.

* **Duration** - `5m`
* **Offset** - `5m`
* **Format** - `RFC3339`

**Collection Phase**

* **Pagination Type** - `Cursor`
* **Cursor Selector** - `.pagination.nextCursor`
* **Initial Request**&#x20;
  * **Response Type** - `JSON`
  * **Method** - `GET`
  * **URL** - `https://${parameters.sentinelOneDomain}/web/api/v2.1/activities`
* **Headers**
  * **Name** - `Accept`
  * **Value** - `application/json`
  * **Name** - `Authorization`
  * **Value** - `ApiToken ${secrets.sentinelOneApiToken}`
* **Query Params**
  * **Name** - `createdAt__gte`
  * **Value** - `${temporalWindow.from}`
  * **Name** - `createdAt__lte`
  * **Value** - `${temporalWindow.to}`
* **Next Request**
  * **Response type** - `JSON`
  * **Method** - `GET`
  * **URL** - `https://${parameters.sentinelOneDomain}/web/api/v2.1/activities`
* **Headers**
  * **Name** - `Accept`
  * **Value** - `application/json`
  * **Name** - `Authorization`
  * **Value** - `ApiToken ${secrets.sentinelOneApiToken}`
* **Output**&#x20;
  * **Select** - `.data`
  * **Map** - `.`
  * **Output Mode** - `element`
    {% endtab %}
    {% endtabs %}

When you're done, click **Create labels** to move on to the next step and define the required [Labels](https://app.gitbook.com/o/9sm794iTBacZSmhxRER6/s/kxZeV4nlXcIAjMGZxzLI/the-workspace/listeners/labels) if needed.
