> For the complete documentation index, see [llms.txt](https://guide.sphericaldefence.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://guide.sphericaldefence.com/guide/integrations/splunk.md).

# Splunk

This page describes how to configure a Splunk integration with a Spherical CloudFormation stack.

## Pre-installation configuration

Before you install a Spherical stack, you must first set up a **HTTP Event Collector** in your installation of **Splunk**.

1. For **Splunk Enterprise** or self-service **Splunk Cloud**, first go to 'Settings'.
2. Click 'Data inputs' and navigate to 'HTTP Event Collector'.
3. Click 'Global Settings'.&#x20;
4. Click the Enable button, and then click Save. (For more information, see "Enable HTTP Event Collector" in the Getting Data in the Splunk manual).&#x20;

   *Note: For managed Splunk Cloud, submit a support ticket to have the feature enabled.*&#x20;
5. Create at least one input token. You'll need this token later.

![Settings for Splunk Enterprise and self-service Splunk Cloud.](https://726634092-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-Lu2R1YRoZxfOod-DWOM%2F-LuIa8mmrkAlx9e6rpIX%2F-LuIakfvk3gLGAutYP4o%2Fimage.png?alt=media\&token=e69cf723-f70b-4e63-845e-5f1610afc0b1)

![Data input settings.](https://726634092-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-Lu2R1YRoZxfOod-DWOM%2F-LuIk93y-W4QWlnElKeK%2F-LuIkGDzNQVi1Whz1DP4%2Fimage.png?alt=media\&token=1438a396-d18c-4fdc-867d-34cdf20c35eb)

### Token

1. For Splunk Enterprise or self-service Splunk Cloud, click the 'Add New' button.&#x20;
2. Proceed through the 'Add Data' workflow until you've successfully created a token. \
   *(For more information, see 'Create an Event Collector' token in the 'Getting Data In' Splunk manual).*
3. For managed Splunk Cloud, submit a support ticket to create or manage a token.

![Configuring a new token for recieving HT](https://726634092-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-Lu2R1YRoZxfOod-DWOM%2F-LuIa8mmrkAlx9e6rpIX%2F-LuIbUleCeRS18XPJHI1%2Fimage.png?alt=media\&token=3fa0abd5-ac42-4e28-8e95-566db6be8ca2)

### Splunk URL

In addition to an authorisation token, you also need a Splunk URL. This varies depending on your type of Splunk deployment.

*Enterprise:* `<protocol>://<host>:<port>/<endpoint>` \
*Managed Cloud:* `<protocol>://http-inputs-<host>:<port>/<endpoint>` \
*Self-Service Cloud:* `<protocol>://input-<host>:<port>/<endpoint>`

| Field    | Description                                                                                  |
| -------- | -------------------------------------------------------------------------------------------- |
| Protocol | Either HTTP or HTTPs                                                                         |
| Host     | The Splunk instance that runs HEC                                                            |
| Port     | The HEC port number, which is 8088 by default, but you can change in the HEC Global Settings |
| Endpoint | The HEC endpoint you want to use. Usually this is the `/services/collector` endpoint         |

Once you have got both a **Splunk URL** and a **Token**, you can go ahead and create a Spherical stack using CloudFormation.
