# List Ingestion Keys

### Endpoint

**POST** `/api/rbac/ingestion-keys/list`

### Authentication

This endpoint requires API Key authentication via the Authorization header.

### Headers

```bash
Authorization: Bearer <YOUR_API_KEY>
Content-Type: application/json
```

### Request Body

Optional filters for ingestion keys:

```json
{
  "name": "string",
  "type": "sensor|thirdParty|rum",
  "remoteConfig": boolean
}
```

| Parameter      | Type    | Required | Description                                              |
| -------------- | ------- | -------- | -------------------------------------------------------- |
| `name`         | string  | No       | Filter by exact key name                                 |
| `type`         | string  | No       | Filter by key type (`"sensor"`, `"thirdParty"`, `"rum"`) |
| `remoteConfig` | boolean | No       | Filter by remote configuration status                    |

### Examples

#### Get All Ingestion Keys

```bash
curl -L \
  --request POST \
  --url 'https://api.groundcover.com/api/rbac/ingestion-keys/list' \
  --header 'Authorization: Bearer <YOUR_API_KEY>' \
  --header 'Content-Type: application/json' \
  --data '{}'
```

#### Filter by Type

Get only sensor keys:

```bash
curl -L \
  --request POST \
  --url 'https://api.groundcover.com/api/rbac/ingestion-keys/list' \
  --header 'Authorization: Bearer <YOUR_API_KEY>' \
  --header 'Content-Type: application/json' \
  --data '{
    "type": "sensor"
  }'
```

#### Filter by Name and Remote Config

```bash
curl -L \
  --request POST \
  --url 'https://api.groundcover.com/api/rbac/ingestion-keys/list' \
  --header 'Authorization: Bearer <YOUR_API_KEY>' \
  --header 'Content-Type: application/json' \
  --data '{
    "name": "my-sensor-key",
    "remoteConfig": true
  }'
```

#### Response Example

```json
[
  {
    "id": "12345678-1234-1234-1234-123456789abc",
    "name": "production-sensor-key",
    "createdBy": "user@company.com",
    "creationDate": "2025-08-31T11:48:18Z",
    "key": "gcik_AEBAAAD4_XXXXXXXXX_XXXXXXXXX_XXXXXXXX",
    "type": "sensor",
    "remoteConfig": true,
    "tags": []
  },
  {
    "id": "87654321-4321-4321-4321-987654321def",
    "name": "my-sensor-key",
    "createdBy": "admin@company.com",
    "creationDate": "2025-08-31T11:48:18Z",
    "key": "gcik_AEBAAAC7_XXXXXXXXX_XXXXXXXXX_XXXXXXXX",
    "type": "sensor",
    "remoteConfig": true,
    "tags": []
  },
  {
    "id": "abcdefab-cdef-abcd-efab-cdefabcdefab",
    "name": "third-party-integration",
    "createdBy": "developer@company.com",
    "creationDate": "2025-08-31T11:48:18Z",
    "key": "gcik_AEBAAAHP_XXXXXXXXX_XXXXXXXXX_XXXXXXXX",
    "type": "thirdParty",
    "remoteConfig": false,
    "tags": []
  }
]
```

### Response Schema

| Field          | Type    | Description                                    |
| -------------- | ------- | ---------------------------------------------- |
| `id`           | string  | Unique identifier for the ingestion key (UUID) |
| `name`         | string  | Human-readable name for the key                |
| `createdBy`    | string  | Email of the user who created the key          |
| `creationDate` | string  | ISO 8601 timestamp of key creation             |
| `key`          | string  | The actual ingestion key (starts with `gcik_`) |
| `type`         | string  | Key type (`"sensor"`, `"thirdParty"`, `"rum"`) |
| `remoteConfig` | boolean | Whether remote configuration is enabled        |
| `tags`         | array   | Array of tags associated with the key          |

### Related Documentation

For comprehensive information about ingestion keys, including creation, usage, and best practices, see:

* [Ingestion Keys](https://docs.groundcover.com/use-groundcover/remote-access-and-apis/ingestion-keys)


---

# 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.groundcover.com/use-groundcover/remote-access-and-apis/api-examples/list-ingestion-keys.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.
