agentsclimarketplace

Sentry integration

Skill Ampli-Group/agentic-mobile-blueprint/.agents/skills/sentry-integration

The production-ready foundation for shipping mobile and web apps. Auth, deployment, monitoring, and CI/CD — already wired together.

Install
npx -y skills add Ampli-Group/agentic-mobile-blueprint --skill sentry-integration

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

  • 4 stars4 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.

What its author says it does

Copied from the file, not written here

Add Sentry error tracking to Supabase Edge Functions. Use when creating functions that need error monitoring.

SKILL.md

2.3 KB, as published. Nobody here has run it

Sentry Integration for Supabase Edge Functions

Helpers Available

Module _shared/sentry.ts provides:

  • initSentry() - Initialize (call once)
  • handleError() - Capture errors automatically
  • setSentryUser() - Track user (optional)
  • addBreadcrumb() - Track flow (optional)

Usage

Basic Pattern

import { initSentry, handleError } from '../_shared/sentry.ts';

initSentry();

Deno.serve(async (req: Request) => {
  if (req.method === 'OPTIONS') {
    return new Response('ok', { headers: corsHeaders });
  }

  try {
    const result = await processData();
    return new Response(JSON.stringify({ success: true }));
  } catch (error) {
    return handleError(error, { functionName: 'my-function', corsHeaders });
  }
});

With User Context

import { initSentry, setSentryUser, handleError } from '../_shared/sentry.ts';
import { authenticate } from '../_shared/auth.ts';

initSentry();

Deno.serve(async (req: Request) => {
  try {
    const { user } = await authenticate(req);
    setSentryUser(user.id, user.email);
    
    // Your logic
    
    return new Response(JSON.stringify({ success: true }));
  } catch (error) {
    return handleError(error, { functionName: 'auth-function', corsHeaders });
  }
});

With Breadcrumbs

import { initSentry, addBreadcrumb, handleError } from '../_shared/sentry.ts';

initSentry();

try {
  addBreadcrumb('Started processing');
  const result = await process();
  addBreadcrumb('Completed', { count: result.length });
} catch (error) {
  return handleError(error, { functionName: 'processor', corsHeaders });
}

Setup

  1. Set SENTRY_DSN in .env.local:

    SENTRY_DSN=https://[email protected]/123456
    
  2. Module exists at supabase/functions/_shared/sentry.ts (already created)

What Gets Captured

✅ Error message and stack trace
✅ Function name (tagged)
✅ Request details
✅ User context (if set)
✅ Breadcrumbs (if added)
❌ Authorization headers (auto-removed)

Testing

throw new Error('Test error for Sentry');

Check Sentry dashboard for the error with full context.

Keep looking

Skills are one crate of 328,083. 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.