# Send a test event to a logging destination

> Source: https://elaichi.ai/docs/api-reference/logging-destinations/observability-destination/testobservabilitydestination/

`POST /observability-destination/{id}/test`

Resource: **Observability Destination** · API: **Logging destinations**

## Path parameters

- **`id`** _(string, required)_
  Logging destination id (`ldst_…`).

## Request body

- **`config`** _(object)_
  Non-secret provider settings.
  - **`site`** _(string)_
    Datadog site.
    Allowed: `us1`, `us3`, `us5`, `eu`, `ap1`
  - **`tags`** _(array<string>)_
  - **`log_types`** _(array<string>)_
    Which slices of the audit trail to forward: `tool_call` = MCP/tool executions, `auth` = membership, role, invite and credential events, `admin` = everything else.
- **`secrets`** _(object)_
  Write-only credentials, stored encrypted and never returned. Sending `secrets` REPLACES the whole stored bag, so include every key the provider needs, not just the one you are changing.
  - **`api_key`** _(string)_
    Datadog API key — required for `datadog`.
  - **`token`** _(string)_
    Splunk HEC token.
  - **`shared_key`** _(string)_
    Sentinel shared key.

## Response body

- **`ok`** _(boolean)_
- **`status`** _(integer,null)_
  HTTP status returned by the provider, when there was one.
- **`error`** _(string,null)_
  Failure detail; null when `ok` is true.

## Code examples

### curl

```bash
curl -X POST 'https://api.elaichi.ai/observability-destination/<id>/test' \
  -H 'Authorization: Bearer $ELAICHI_API_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"config":{},"secrets":{}}'
```

### JavaScript

```javascript
const body = {
  "config": {},
  "secrets": {}
};

const response = await fetch('https://api.elaichi.ai/observability-destination/<id>/test', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer ' + process.env.ELAICHI_API_TOKEN,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify(body),
});

const data = await response.json();
console.log(data);
```

### Python

```python
import os
import requests

url = "https://api.elaichi.ai/observability-destination/<id>/test"
headers = {
    "Authorization": f"Bearer {os.environ['ELAICHI_API_TOKEN']}",
    "Content-Type": "application/json",
}
payload = {
    "config": {},
    "secrets": {}
}

response = requests.post(url, headers=headers, json=payload)
print(response.json())
```
