agentsclimarketplace

Monitoring sentry datadog

Skill TakuroFukamizu/google-ai-studio-to-prod-skills/skills/monitoring-sentry-datadog

Use when adding error tracking, monitoring, or observability to a Gemini or AI application, setting up Sentry for error tracking or Datadog for metrics and APMFrom its SKILL.md

Install
npx -y skills add TakuroFukamizu/google-ai-studio-to-prod-skills --skill monitoring-sentry-datadog

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

2.6 KB, as published. Nobody here has run it

Monitoring with Sentry & Datadog

Overview

Add production monitoring to Gemini API applications. Sentry for error tracking and crash reporting; Datadog for metrics, APM, and dashboards. Can use one or both.

When to Use

  • User says "監視入れて", "add monitoring", "add error tracking"
  • App is deployed and needs observability
  • User is experiencing errors in production and has no visibility

When NOT to use: For local development debugging.

Platform Decision

NeedSentryDatadog
Error trackingExcellentGood
APM / TracesGoodExcellent
Custom metricsLimitedExcellent
Free tier5K errors/mo14-day trial
Setup effort5 min15 min
Best for"Just tell me when it breaks""I need dashboards and deep metrics"

Recommendation: Start with Sentry (fast setup, free tier). Add Datadog when you need metrics/dashboards.

Sentry Quick Setup (Python)

# pip install sentry-sdk
import sentry_sdk

sentry_sdk.init(
    dsn=os.environ["SENTRY_DSN"],
    traces_sample_rate=0.1,
    environment=os.environ.get("ENVIRONMENT", "production"),
)

Sentry Quick Setup (Node.js)

// npm install @sentry/node
const Sentry = require("@sentry/node");

Sentry.init({
  dsn: process.env.SENTRY_DSN,
  tracesSampleRate: 0.1,
  environment: process.env.ENVIRONMENT || "production",
});

Key Metrics to Track for Gemini Apps

MetricWhy
Gemini API latencyDetect slowdowns
Token usage per requestCost monitoring
Error rate by endpointIdentify failing routes
Rate limit hits (429s)Capacity planning
Response quality scoresIf using evals

Implementation Steps

  1. Create Sentry project at sentry.io (or self-hosted)
  2. Install SDK and initialize in app entry point
  3. Add DSN to environment — Secret Manager or platform env vars
  4. Tag requests — Add user context, request IDs
  5. Set up alerts — Error spike, latency threshold
  6. (Optional) Add Datadog — Install agent, configure APM

Common Mistakes

  • traces_sample_rate=1.0 in production — Sample at 0.1 or lower to control costs
  • Missing environment tag — Always set environment to distinguish staging/production
  • No source maps (Node.js) — Upload source maps for readable stack traces
  • Ignoring Gemini API errors — Catch and report google.api_core.exceptions explicitly

Keep looking

Skills are one crate of 607,533. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.