getsentry/sentry-java is a Java and Android software development kit for sending application errors, events, and diagnostic information to Sentry. It is used by developers working with Java, Android, Kotlin, and other JVM-based applications to monitor software behavior. The catalogue rules, skills, instructions, and setting support workflows around this SDK.
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.
npx agentmods add rules/getsentry/sentry-java/new_modulegit clone --depth 1 https://github.com/getsentry/sentry-javaWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/getsentry/sentry-java/new_module)<a href="https://agentmods.dev/rules/getsentry/sentry-java/new_module"><img src="https://agentmods.dev/badge/rules/getsentry/sentry-java/new_module.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00007 | $0.01141 |
| Opus 5 | $0.00003 | $0.00571 |
| Sonnet 5 | $0.00001 | $0.00228 |
| Haiku 4.5 | $0.00001 | $0.00114 |
Grade A, and why
new_module 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 yesterday.
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.
How it starts
The opening of the file, as written. The whole thing — 118 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Module Addition Rules for sentry-java
Overview
This document outlines the complete process for adding a new module to the sentry-java repository. Follow these steps in order to ensure proper integration and release management.
Step-by-Step Process
1. Create the Module Structure
-
Create the new module, conforming to the existing naming conventions and build scripts. Copy the
build.gradle.ktsof the closest existing integration rather than writing one from scratch —sentry-kafkais a good JVM template,sentry-android-timbera good Android one. -
Add the module to the include list in
settings.gradle.kts
If adding a sentry-samples module, also add it to the ignoredProjects list in the root build.gradle.kts:
ignoredProjects.addAll(
listOf(
// ... existing projects ...
"sentry-samples-{module-name}"
)
)
- Add a
SENTRY_{MODULE}_SDK_NAMEconstant to theConfig.Sentryblock inbuildSrc/src/main/java/Config.kt:
val SENTRY_FOO_SDK_NAME = "$SENTRY_JAVA_SDK_NAME.foo"
The module's build.gradle.kts consumes it in both buildConfig and the jar manifest
(Sentry-SDK-Name / Sentry-SDK-Package-Name) — see sentry-kafka/build.gradle.kts.
-
Add the instrumented library to
gradle/libs.versions.tomland depend on it withcompileOnly(libs.<lib>), so the integration does not force the dependency on users. -
Register the integration with the SDK so it is reported in the
sdkpayload. Every integration does this — seesentry-openfeature/.../SentryOpenFeatureHook.java:
static {
SentryIntegrationPackageStorage.getInstance()
.addPackage("maven:io.sentry:sentry-{module-name}", BuildConfig.VERSION_NAME);
}
// then, from the constructor:
addIntegrationToSdkVersion("{IntegrationName}");
- If adding a JVM sample, add E2E (system) tests, following the structure we have in the existing JVM examples.
The test should then be added to
test/system-test-runner.pyand.github/workflows/system-tests-backend.yml.
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.
- yesterday First seen · 118 lines · 7 tokens per session scan A 586a6ef55c05
new_module is a cursor rule published in the GitHub repository getsentry/sentry-java (1,349 stars, last pushed today), licensed MIT. It adds 7 tokens to every session and 1,141 once invoked, about $0.0000 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-09-03.
Other cursor rules, from other repositories
android-viewmodel
Android ViewModel conventions — StateFlow, repository abstraction, coroutines, no LiveData.
swiftui-accessibility
SwiftUI accessibility rules for VoiceOver — labels, hints, traits, values, and attribute preservation.
project-status
PriceGrab shipped state and product backlog (read first).
commit-sponsors
Every git commit message must acknowledge BetterDesk supporters.
security-threat-and-stability
Maximum security scrutiny on issues/PRs and stability-first code changes.
best-practices
Engineering best practices for this codebase.