Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .cursor/rules/api.mdc
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ Public API is tracked via `.api` files generated by the [ABI validation](https:/
- `./gradlew check` validates current code against `.api` files and fails on unintended changes.
- `@ApiStatus.Internal` marks classes/methods as internal — they still appear in `.api` files but are not part of the public contract.
- `@ApiStatus.Experimental` marks API that may change in future versions.
- `@HybridSdkApi` marks non-customer API that a hybrid SDK (React Native, Flutter, .NET, Unity, Unreal, Godot, KMP, Capacitor) uses. Add it to new API that a hybrid SDK calls, and to an element a hybrid SDK calls when you mark it `@ApiStatus.Internal`. Customer-facing API doesn't need it.
- Before changing, moving, or removing an element marked `@HybridSdkApi`, find the hybrid SDKs that use it and coordinate with their teams. They often call it through bindings, JNI, or reflection by name, so no compiler catches the break.

## Key Public API Classes

Expand Down
2 changes: 1 addition & 1 deletion .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Include a link to Sentry when applicable:
- [ ] I updated the wizard if needed.
- [ ] Review from the native team if needed.
- [ ] No breaking change or entry added to the changelog.
- [ ] No breaking change for hybrid SDKs or communicated to hybrid SDKs.
- [ ] No breaking change for hybrid SDKs or communicated to hybrid SDKs. New API for hybrid SDKs is marked `@HybridSdkApi`.
- [ ] Public API changes reviewed by another Mobile SDK team member or implemented according to the [develop docs](https://develop.sentry.dev/) spec.


Expand Down
2 changes: 1 addition & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ rule file in `.cursor/rules/`:

| Rule | Read it when working on |
|---|---|
| `api` | Public API surface, binary compatibility, `.api` files, `updateKotlinAbi`, `IScope`/`IScopes`/`Sentry` static API, protocol classes |
| `api` | Public API surface, binary compatibility, `.api` files, `updateKotlinAbi`, `@HybridSdkApi`, API for hybrid SDKs, `IScope`/`IScopes`/`Sentry` static API, protocol classes |
| `options` | `SentryOptions`, namespaced options, `ExternalOptions`, `sentry.properties`, `ManifestMetadataReader`, Spring Boot properties |
| `scopes` | Scope management, forking, lifecycle, `ScopeType`, thread-local storage, scope bleeding, Hub → Scopes migration |
| `deduplication` | Duplicate event detection, `DuplicateEventDetectionEventProcessor`, `enableDeduplication` |
Expand Down
3 changes: 3 additions & 0 deletions REVIEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ rule file in [`.cursor/rules/`](.cursor/rules) for the area the diff touches (`a

- New public API must be intentional: new classes/methods not for public use need
`@ApiStatus.Internal`, new unstable API needs `@ApiStatus.Experimental`.
- Non-customer API added for a hybrid SDK (React Native, Flutter, .NET, Unity, ...) needs
`@HybridSdkApi`. Changing, moving, or removing an element marked `@HybridSdkApi` needs a callout
that the hybrid SDK teams using it were told.
- Removing or changing the signature of public API, or silently changing a default, sampling rate,
or feature toggle, without a deprecation and a `CHANGELOG.md`/`MIGRATION.md` note.
- New features must be **opt-in by default** via `SentryOptions` (or a namespaced options class).
Expand Down
Loading