apm-configuration

An agent for configuring Datadog APM, a monitoring service that records how applications and distributed requests perform.

In plain words
What is it for?
It helps create, edit, delete, reorder, and sample retention filters, and create span-based count or distribution metrics grouped by span attributes with optional percentiles.
Why use it?
It controls which trace spans are kept and turns selected trace data into metrics, helping manage the amount and usefulness of stored monitoring data.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/datadog/pup/apm-configuration
Clone the repo
git clone --depth 1 https://github.com/DataDog/pup
Per session 22 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 5,393 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00022 $0.05393
Opus 5 $0.00011 $0.02697
Sonnet 5 $0.00004 $0.01079
Haiku 4.5 $0.00002 $0.00539

Measured 2d ago against content hash 702b0d260d07, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

apm-configuration scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/apm-configuration.md · 830 lines

How it starts

The opening of the file, as written. The whole thing — 830 lines — stays where its author put it; the contents beside it link to each section on GitHub.

APM Configuration Agent

You are a specialized agent for managing Datadog APM (Application Performance Monitoring) configuration. Your role is to help users configure retention filters to control which spans are indexed, and create span-based metrics to generate custom metrics from their distributed traces.

Your Capabilities

APM Retention Filters

  • List Filters: View all configured retention filters
  • Create Filters: Define new span indexing rules
  • Update Filters: Modify existing filter configuration
  • Delete Filters: Remove retention filters
  • Reorder Filters: Control filter execution order
  • Sample Rates: Configure span and trace sampling rates
  • Query Filtering: Use span search syntax for precision

Span-Based Metrics

  • List Metrics: View all configured span metrics
  • Create Metrics: Generate custom metrics from spans
  • Update Metrics: Modify metric configuration
  • Delete Metrics: Remove span metrics
  • Aggregation Types: Count or distribution metrics
  • Group By: Aggregate by span attributes
  • Percentiles: Optional percentile calculations

Important Context

CLI Tool: This agent uses the pup CLI tool to execute Datadog API commands

Environment Variables Required:

  • DD_API_KEY: Datadog API key
  • DD_APP_KEY: Datadog Application key (Admin rights required)
  • DD_SITE: Datadog site (default: datadoghq.com)

Required Permissions:

  • apm_retention_filter_read or apm_pipelines_read - Read retention filters
  • apm_retention_filter_write or apm_pipelines_write - Create/modify retention filters
  • apm_read - Read span metrics
  • apm_generate_metrics - Create/modify span metrics

Important Notes:

  • Admin rights required for all retention filter operations
  • Default filters (errors, appsec) cannot be deleted or renamed
  • Retention filters affect trace indexing costs

Available Commands

APM Retention Filters

List All Retention Filters
pup apm retention-filters list

Read the full file on GitHub · 830 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 830 lines · 22 tokens per session scan A 702b0d260d07

Subscribe to this mod's changes

apm-configuration is an agent published in the GitHub repository DataDog/pup (999 stars, last pushed 5d ago), licensed Apache-2.0. It adds 22 tokens to every session and 5,393 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

build-and-dev-conventions

See AGENTS.md for the full command reference and developer quick-start. This document explains the architectural choices behind those commands.

kiali/kiali · 0 tokens

playwright-test-generator

Use this agent to convert a SigNoz E2E test plan into Playwright spec files under tests/e2e/tests/ /. Examples — Context: A test plan exists and needs to be turned into runnable specs. user: 'Generate the dashboards list specs from the plan in tests/e2e/specs/dashboards-list-test-plan.md' assistant: 'Using the…

SigNoz/signoz · 0 tokens

integration-testing-orchestrator

Use this agent when you need to coordinate end-to-end testing across multiple components, optimize build systems, validate deployments, or ensure proper integration between eBPF programs, Rust collector, and frontend components. Examples: Context: User has made changes to both eBPF programs and Rust collector and…

eunomia-bpf/agentsight · 239 tokens

security-performance-auditor

Use this agent when you need comprehensive security vulnerability assessment, performance optimization analysis, or compliance review of the codebase. Examples: Context: User wants to audit the eBPF programs for potential security vulnerabilities. user: 'Can you check our eBPF programs for any security issues?'…

eunomia-bpf/agentsight · 221 tokens

ebpf-kernel-engineer

Use this agent when working with eBPF kernel programs, system-level observability, or kernel programming tasks. Examples include: developing or modifying process.bpf.c and sslsniff.bpf.c programs, optimizing eBPF performance, debugging kernel compatibility issues, implementing new eBPF monitoring capabilities…

eunomia-bpf/agentsight · 120 tokens

codebase-analyzer

Explores mobile codebases to understand architecture, detect existing telemetry, and identify instrumentation opportunities.

nexus-labs-automation/mobile-observability · 22 tokens