From b356998095c645effe258074f4733c65004d19b7 Mon Sep 17 00:00:00 2001 From: Philipp Hofmann Date: Fri, 14 Jun 2024 10:50:01 +0200 Subject: [PATCH] fix(apple): Docs for enableMetricKitRawPayload (#10334) * fix(apple): Docs for enableMetricKitAttachments Add docs for enableMetricKitAttachments available on Cocoa 8.29.0 and above. * rename to enableMetricKitRawPayload * Update docs/platforms/apple/common/configuration/metric-kit.mdx Co-authored-by: Karl Heinz Struggl * Update docs/platforms/apple/common/configuration/metric-kit.mdx Co-authored-by: Karl Heinz Struggl --------- Co-authored-by: Karl Heinz Struggl --- .../apple/common/configuration/metric-kit.mdx | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/docs/platforms/apple/common/configuration/metric-kit.mdx b/docs/platforms/apple/common/configuration/metric-kit.mdx index a6c9875c46479..e8d6f2fc5ab30 100644 --- a/docs/platforms/apple/common/configuration/metric-kit.mdx +++ b/docs/platforms/apple/common/configuration/metric-kit.mdx @@ -34,3 +34,25 @@ SentrySDK.start { options in options.enableMetricKit = YES; }]; ``` + +You can enable `enableMetricKitRawPayload` to view the raw MetricKit diagnostic payload in JSON format as an attachment on the converted event in Sentry. This feature is available on Cocoa 8.29.0 and up. + +```swift {tabTitle:Swift} +import Sentry + +SentrySDK.start { options in + options.dsn = "___PUBLIC_DSN___" + options.enableMetricKit = true + options.enableMetricKitRawPayload = true +} +``` + +```objc {tabTitle:Objective-C} +@import Sentry; + +[SentrySDK startWithConfigureOptions:^(SentryOptions *options) { + options.dsn = @"___PUBLIC_DSN___"; + options.enableMetricKit = YES; + options.enableMetricKitRawPayload = YES; +}]; +```