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
20 changes: 20 additions & 0 deletions docs/platforms/android/session-replay/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,26 @@ The SDK can't determine whether foregrounding returns to the same sensitive scre
- If a deep link opens a non-sensitive product screen, call `resume()` from that destination after the sensitive content is no longer visible.
- If a notification or normal navigation opens another non-sensitive screen, call `resume()` from the new screen instead of from the sensitive screen's exit callback.

### Pause Touch Tracking on Sensitive Screens

Starting with version 8.65.0, the SDK can stop recording touches while it continues to record the screen. Use this on screens where masking hides the content, but the touch positions could reveal the input, such as a custom PIN pad or a masked `WebView`.

Call `pauseTouchTracking()` before showing the sensitive content and `resumeTouchTracking()` after the content is hidden. Touch tracking stays paused for all replays in the same app process, including new replays and replays restarted with `stop()` and `start()`, until you call `resumeTouchTracking()`. Calling `resume()` doesn't resume touch tracking, and `resumeTouchTracking()` doesn't record touches while the replay is paused with `pause()`. You can call `pauseTouchTracking()` before a replay starts. Breadcrumbs aren't affected; use [`beforeBreadcrumb`](/platforms/android/enriching-events/breadcrumbs/#customize-breadcrumbs) to filter them.

```kotlin {tabTitle:Kotlin}
Sentry.replay().pauseTouchTracking()

// Record touches again after leaving the sensitive screen.
Sentry.replay().resumeTouchTracking()
```

```java {tabTitle:Java}
Sentry.replay().pauseTouchTracking();

// Record touches again after leaving the sensitive screen.
Sentry.replay().resumeTouchTracking();
```

### Stop or Flush Recording

Call `stop()` to end the current replay. In session mode, the SDK sends any pending segment before stopping. In buffer mode, it discards the unsent buffer. A later call to `start()` or `startBuffering()` creates a new replay session.
Expand Down
27 changes: 27 additions & 0 deletions docs/platforms/apple/common/session-replay/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,33 @@ SentrySDK.replay.resume()
[SentryObjCSDK.replay resume];
```

### Pause Touch Tracking on Sensitive Screens

Starting with version 9.35.0, the SDK can stop recording touches while it continues to record the screen. Use this on screens where masking hides the content, but the touch positions could reveal the input, such as a custom PIN pad or a masked `WKWebView`.

Call `pauseTouchTracking()` before showing the sensitive content and `resumeTouchTracking()` after the content is hidden. Touch tracking stays paused for all replays in the same app process, including new replays and replays restarted with `stop()` and `start()`, until you call `resumeTouchTracking()`. Calling `resume()` doesn't resume touch tracking, and `resumeTouchTracking()` doesn't record touches while the replay is paused with `pause()`. You can call `pauseTouchTracking()` before a replay starts. Breadcrumbs aren't affected; use [`beforeBreadcrumb`](/platforms/apple/enriching-events/breadcrumbs/#customize-breadcrumbs) to filter them.

```swift {tabTitle:Swift} {mdExpandTabs}
SentrySDK.replay.pauseTouchTracking()

// Record touches again after leaving the sensitive screen.
SentrySDK.replay.resumeTouchTracking()
```

```objc {tabTitle:Objective-C}
[SentrySDK.replay pauseTouchTracking];

// Record touches again after leaving the sensitive screen.
[SentrySDK.replay resumeTouchTracking];
```

```objc {tabTitle:Objective-C (SentryObjC)}
[SentryObjCSDK.replay pauseTouchTracking];

// Record touches again after leaving the sensitive screen.
[SentryObjCSDK.replay resumeTouchTracking];
```

### Stop or Flush Recording

Call `stop()` to end the current replay. A later call to `start()` or `startBuffering()` creates a new replay instead of resuming the stopped one.
Expand Down
17 changes: 17 additions & 0 deletions docs/platforms/dart/guides/flutter/session-replay/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,23 @@ try {

Here, `showSensitiveScreen()` represents your app's navigation flow and should complete after the sensitive screen closes. Continue to configure <PlatformLink to="/session-replay/privacy/">masking rules</PlatformLink> for recorded content. Pausing Replay does not disable other SDK features, such as error reporting.

### Pause Touch Tracking Around Sensitive Content

Starting with version 10.5.0, the SDK can stop recording touches while it continues to record the screen. Use this on screens where masking hides the content, but the touch positions could reveal the input, such as a custom PIN pad or a masked `WebView`.

Call `pauseTouchTracking()` before showing the sensitive content and `resumeTouchTracking()` after hiding it. Touch tracking stays paused for all replays in the same app process, including new replays and replays restarted with `stop()` and `start()`, until you call `resumeTouchTracking()`. Calling `resume()` doesn't resume touch tracking, and `resumeTouchTracking()` doesn't record touches while the replay is paused with `pause()`. You can call `pauseTouchTracking()` before a replay starts. Breadcrumbs aren't affected; use [`beforeBreadcrumb`](/platforms/dart/guides/flutter/enriching-events/breadcrumbs/#customize-breadcrumbs) to filter them.

```dart
await SentryFlutter.replay.pauseTouchTracking();
try {
await showSensitiveScreen();
} finally {
await SentryFlutter.replay.resumeTouchTracking();
}
```

`pauseTouchTracking()` and `resumeTouchTracking()` are supported on iOS and Android only. On other platforms, including Web, they do nothing.

### End or Send a Replay

Call `stop()` to end the current replay. Starting again creates a new replay with a new replay ID:
Expand Down
19 changes: 19 additions & 0 deletions docs/platforms/react-native/common/session-replay/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,25 @@ Sentry.getReplay()?.resume();

</Alert>

### Pause Touch Tracking on Sensitive Screens

Starting with version 8.36.0, the SDK can stop recording touches while it continues to record the screen. Use this on screens where masking hides the content, but the touch positions could reveal the input, such as a custom PIN pad or a masked `WebView`.

Call `pauseTouchTracking()` before showing the sensitive content and `resumeTouchTracking()` after the content is hidden. Touch tracking stays paused for all replays in the same app process, including new replays and replays restarted with `stop()` and `start()`, until you call `resumeTouchTracking()`. Calling `resume()` doesn't resume touch tracking, and `resumeTouchTracking()` doesn't record touches while the replay is paused with `pause()`. You can call `pauseTouchTracking()` before a replay starts. Breadcrumbs aren't affected; use [`beforeBreadcrumb`](/platforms/react-native/enriching-events/breadcrumbs/#customize-breadcrumbs) to filter them.

```javascript
Sentry.getReplay()?.pauseTouchTracking();

// Record touches again after leaving the sensitive screen.
Sentry.getReplay()?.resumeTouchTracking();
```

<Alert>

`pauseTouchTracking()` and `resumeTouchTracking()` are supported on iOS and Android only. On React Native Web they are no-ops (a debug message is logged).

</Alert>

### Stop or Flush Recording

Call `stop()` to end the current replay. In session mode, the SDK sends any pending segment before stopping. In buffer mode, it discards the unsent buffer. A later call to `start()` or `startBuffering()` creates a new replay session.
Expand Down
Loading