Integrating using an AI prompt
The Integrate with AI section shows you a ready-made prompt for a simple integration of Better Stack error tracking into your app using Claude Code or Cursor.
- Navigate to Errors -> Applications -> Your application -> Ingest.
- Scroll to Integrate with AI and click on the prompt to copy it.
- Use it in Claude Code or similar tool to automatically integrate Better Stack into your application.
Not using Claude Code or similar agentic dev-tool?
You can integrate your app manually using Sentry SDK.
Examples
Even if you use an AI agent, it's helpful to see what the final integration code looks like. Here are a few examples of how to use the Sentry SDK:
Couldn't find example for your application?
Read our Sentry SDK integration guide for more languages.
See the error in Better Stack
After running the prompt and triggering an error, you should see your first report in Errors 🚀