> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bugbybug.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Verify BugByBug OTLP Exporter

> Verify OTLP exporter and confirm BugByBug is receiving traces

## Verify your OTLP exporter

Once your OTLP HTTP exporter is configured, you can verify that BugByBug is receiving telemetry in two ways:

* Trigger a handled exception in your application.
* Send a manual test trace directly to the ingestion endpoint.

The first option is the recommended path because it uses your real application instrumentation.
The second option is useful when you want to confirm your API key and endpoint before instrumenting the rest of your app.

### 1. Trigger a test error

Force a handled exception in your application and record it on the active span.

```javascript theme={null}
try {
  // Your application logic
} catch (error) {
  span.recordException(error);
  span.setStatus({ code: SpanStatusCode.ERROR, message: error.message });
}
```

BugByBug reads standard OpenTelemetry exception events, so recording the exception and setting the span status to error helps ensure the event appears correctly in your dashboard.

### 2. Optional: send a manual test trace

If you want to verify your API key and endpoint independently of your application code, you can send a manual OTLP JSON trace directly to BugByBug.

```bash theme={null}
curl -X POST https://nexus.bugbybug.com/v1/traces \
  -H "Content-Type: application/json" \
  -H "x-api-key: <YOUR_API_KEY>" \
  -d '{
    "resourceSpans": [
      {
        "resource": {
          "attributes": [
            {
              "key": "service.name",
              "value": { "stringValue": "bugbybug-connection-test" }
            }
          ]
        },
        "scopeSpans": [
          {
            "spans": [
              {
                "traceId": "0123456789abcdef0123456789abcdef",
                "spanId": "0123456789abcdef",
                "name": "verification-span",
                "events": [
                  {
                    "name": "exception",
                    "timeUnixNano": "1700000000000000000",
                    "attributes": [
                      {
                        "key": "exception.type",
                        "value": { "stringValue": "ConnectionTestException" }
                      },
                      {
                        "key": "exception.message",
                        "value": { "stringValue": "Successfully connected to BugByBug!" }
                      }
                    ]
                  }
                ]
              }
            ]
          }
        ]
      }
    ]
  }'
```

This request uses the same OTLP JSON structure BugByBug expects, and the exception event follows OpenTelemetry’s exception convention.

### 3. Confirm the data

After the test runs, open your BugByBug dashboard and look for the test span or exception event in your error feed.
If the request succeeds, you should see the `ConnectionTestException` (or your application's custom error) in your error feed, complete with the attributes and event data extracted from the payload.
