Skip to content

Routing to Dynatrace docs link #72

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions openllmetry/integrations/dynatrace.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ Analyze all collected LLM traces within Dynatrace by using the native OpenTeleme

Go to your Dynatrace environment and create a new access token under **Manage Access Tokens**.
The access token needs the following permission scopes that allow the ingest of OpenTelemetry spans, metrics and logs
(openTelemetryTrace.ingest, metrics.ingest, logs.ingest).
(openTelemetryTrace.ingest, metrics.ingest, logs.ingest, events.ingest, metrics.read, settings.write).

Set `TRACELOOP_BASE_URL` environment variable to the URL of your Dynatrace OpenTelemetry ingest endpoint
Initialize OpenLLMetry with the token to collect all the relevant KPIs.

```bash
TRACELOOP_BASE_URL=https://<YOUR_ENV>.live.dynatrace.com\api\v2\otlp
```
Add in the OTLP API endpoint of your Dynatrace environment.

Set the `TRACELOOP_HEADERS` environment variable to include your previously created access token
from traceloop.sdk import Traceloop
headers = { "Authorization": "Api-Token <YOUR_DT_API_TOKEN>" }
Traceloop.init(
app_name="<your-service>",
api_endpoint="https://<YOUR_ENV>.live.dynatrace.com/api/v2/otlp",
headers=headers
)

```bash
TRACELOOP_HEADERS=Authorization=Api-Token%20<YOUR_ACCESS_TOKEN>
```

Done! All the exported spans along with their span attributes will show up within the Dynatrace trace view.
Done! All the exported spans along with their span attributes will show up within the Dynatrace trace view. For more information, check out the [docs link](https://docs.dynatrace.com/docs/shortlink/ai-ml-get-started).