> ## Documentation Index
> Fetch the complete documentation index at: https://docs.honeycomb.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Attributes in the Honeycomb OpenTelemetry Swift SDK

> Reference the standard attributes the Honeycomb OpenTelemetry Swift SDK automatically adds to spans.

When you instrument your application using the Honeycomb OpenTelemetry Swift SDK, spans automatically include a standard set of attributes.
These attributes provide essential context about the environment, runtime, device, and SDK versions--helping you understand where and how telemetry is being generated.

## Core Span Attributes

Every span includes some core attributes.

* `honeycomb.distro.runtime_version`: Operating system version on the device.
* `honeycomb.distro.version`: Version of the Honeycomb SDK in use.
* `os.description`: String describing the OS version, build ID, and SDK level.
* `os.name`: OS name. Always `iOS` for iOS devices.
* `os.type`: OS type. Always `darwin` on Apple platforms.
* `os.version`: Current OS Version.
* `service.name`: Name of your application. Set via `setServiceName()` or inferred from your bundle.
* `service.version`: Version of your application. Set via `setServiceVersion()`. Defaults to being inferred from your bundle.
* `telemetry.distro.name`: Name of the Honeycomb SDK in use. Always `honeycomb-opentelemetry-swift` for the Honeycomb OpenTelemetry Swift SDK.
* `telemetry.distro.version`: Version of the Honeycomb SDK in use.
* `telemetry.sdk.language`: Coding language for the Honeycomb SDK in use. Always `swift` for the Honeycomb OpenTelemetry Swift SDK.
* `telemetry.sdk.name`: Name of the telemetry SDK used to generate telemetry data. Always `opentelemetry` for the Honeycomb OpenTelemetry Swift SDK.
* `telemetry.sdk.version`: Version of the OpenTelemetry SDK in use.

## UIDevice Attributes

If your application uses [UIKit](https://developer.apple.com/documentation/uikit), the SDK also includes device-level attributes from [UIDevice](https://developer.apple.com/documentation/uikit/uidevice).
These give insight into the physical device running your application.

* `device.id`: Vendor-specific device identifier. ([UIDevice.identifierForVendor](https://developer.apple.com/documentation/uikit/uidevice/identifierforvendor))
* `device.name`: Name of the device. ([UIDevice.name](https://developer.apple.com/documentation/uikit/uidevice/name))
* `device.systemName`: Operating system (OS) name. ([UIDevice.systemName](https://developer.apple.com/documentation/uikit/uidevice/systemname))
* `device.systemVersion`: OS version string. ([UIDevice.systemVersion](https://developer.apple.com/documentation/uikit/uidevice/systemversion))
* `device.model`: Device model name. ([UIDevice.model](https://developer.apple.com/documentation/uikit/uidevice/model))
* `device.localizedModel`: Localized version of the device model. ([UIDevice.localizedModel](https://developer.apple.com/documentation/uikit/uidevice/localizedmodel))
* `device.userInterfaceIdiom`: Type of interface the device uses. ([UIDevice.userInterfaceIdiom](https://developer.apple.com/documentation/uikit/uidevice/userinterfaceidiom))
* `device.isMultitaskingSupported`: Indicates whether the device supports multitasking. ([UIDevice.isMultitaskingSupported](https://developer.apple.com/documentation/uikit/uidevice/ismultitaskingsupported))
* `device.orientation`: Current device orientation. ([UIDevice.orientation](https://developer.apple.com/documentation/uikit/uidevice/orientation)
* `device.isLowPowerModeEnabled`: Indicates whether Low Power Mode is currently active. ([UIDevice.isLowPowerModeEnabled](https://developer.apple.com/documentation/foundation/processinfo/islowpowermodeenabled))
* `device.isBatteryMonitoringEnabled`: Indicates whether battery monitoring is turned on. ([UIDevice.isBatteryMonitoringEnabled](https://developer.apple.com/documentation/uikit/uidevice/isbatterymonitoringenabled))
* `device.batteryLevel`: Battery level. Included only if `UIDevice.current.batteryStateAttributesEnabled` is set to `true`. ([UIDevice.batteryLevel](https://developer.apple.com/documentation/uikit/uidevice/batterylevel))
* `device.batteryState`: Battery state. Included only if `UIDevice.current.batteryStateAttributesEnabled` is set to `true`. ([UIDevice.batteryState](https://developer.apple.com/documentation/uikit/uidevice/batterystate-swift.property))

## MetricKit Attributes

If [MetricKit](https://developer.apple.com/documentation/metrickit) is available and you've enabled MetricKit instrumentation, the SDK adds system performance and behavior metrics.
These help identify performance bottlenecks, power usage trends, and device conditions.

### Application Metadata

* `metrickit.metadata.app_build_version`: (String) Application bundle version. ([MXMetaData.applicationBuildVersion](https://developer.apple.com/documentation/metrickit/mxmetadata/applicationbuildversion/))

* `metrickit.metadata.device_type`: (String) Hardware identifier for the device. ([MXMetaData.deviceType](https://developer.apple.com/documentation/metrickit/mxmetadata/devicetype/))

* `metrickit.metadata.is_test_flight_app`: (Bool) Indicates whether the application is registered with TestFlight. ([MXMetaData.isTestFlightA](https://developer.apple.com/documentation/metrickit/mxmetadata/istestflightapp/))

* `metrickit.metadata.low_power_mode_enabled`: (Bool) Indicates whether low power mode is enabled. ([MXMetaData.lowPowerModeEnabled](https://developer.apple.com/documentation/metrickit/mxmetadata/lowpowermodeenabled/))

* `metrickit.metadata.os_version`: (String) OS version, version number, and build number. ([MXMetaData.osVersion](https://developer.apple.com/documentation/metrickit/mxmetadata/osversion/))

* `metrickit.metadata.platform_arch`: (String) Name of the processor architecture. ([MXMetaData.platformArchitecture](https://developer.apple.com/documentation/metrickit/mxmetadata/platformarchitecture/))

* `metrickit.metadata.region_format`: (String) Short country code for the region format setting. ([MXMetaData.regionFormat](https://developer.apple.com/documentation/metrickit/mxmetadata/regionformat/))

* `metrickit.metadata.pid`: (Int) Process ID of the running application. ([MXMetaData.pid](https://developer.apple.com/documentation/metrickit/mxmetadata/pid/))

### Application Version History

* `metrickit.includes_multiple_application_versions`: (Bool) Indicates whether the application version changed during the reporting window. ([MXMetricPayload.includesMultipleApplicationVersions](https://developer.apple.com/documentation/metrickit/mxmetricpayload/includesmultipleapplicationversions/))

* `metrickit.latest_application_version`: (String) Application version at the end of the reporting window. ([MXMetricPayload.latestApplicationVersion](https://developer.apple.com/documentation/metrickit/mxmetricpayload/latestapplicationversion/))

### CPU and GPU Usage

* `metrickit.cpu.cpu_time`: (Double) Total amount of CPU time used by the application. ([MXCPUMetric.cumulativeCPUTime](https://developer.apple.com/documentation/metrickit/mxcpumetric/cumulativecputime/))

* `metrickit.cpu.instruction_count`: Total number of CPU instructions executed during the reporting window. ([MXCPUMetric.cumulativeCPUInstructions](https://developer.apple.com/documentation/metrickit/mxcpumetric/cumulativecpuinstructions/))

* `metrickit.gpu.time`: (Double) Total amount of GPU time used by the application. ([MXGPUMetric.cumulativeGPUTime](https://developer.apple.com/documentation/metrickit/mxgpumetric/cumulativegputime/))

### Cellular Connectivity

* `metrickit.cellular_condition.bars_average`: (Double) Average cellular signal strength. ([MXCellularConditionMetric.histogrammedCellularConditionTime](https://developer.apple.com/documentation/metrickit/mxcellularconditionmetric/histogrammedcellularconditiontime/))

### Application Run Time

* `metrickit.app_time.foreground_time`: (Double) Total time the application spent in the foreground. ([MXAppRunTimeMetric.cumulativeForegroundTime](https://developer.apple.com/documentation/metrickit/mxappruntimemetric/cumulativeforegroundtime/))

* `metrickit.app_time.background_time`: (Double) Total time the application spent in the background. ([MXAppRunTimeMetric.cumulativeBackgroundTime](https://developer.apple.com/documentation/metrickit/mxappruntimemetric/cumulativebackgroundtime/))

* `metrickit.app_time.background_audio_time`: (Double) Total time playing audio while in the background. ([MXAppRunTimeMetric.cumulativeBackgroundAudioTime](https://developer.apple.com/documentation/metrickit/mxappruntimemetric/cumulativebackgroundaudiotime/))

* `metrickit.app_time.background_location_time`: (Double) Total time using location services in the background. ([MXAppRunTimeMetric.cumulativeBackgroundLocationTime](https://developer.apple.com/documentation/metrickit/mxappruntimemetric/cumulativebackgroundlocationtime/))

### Location Accuracy

* `metrickit.location_activity.best_accuracy_for_nav_time`: (Double) Total time spent tracking the current location at the best accuracy for navigation. ([MXLocationActivityMetric.cumulativeBestAccuracyForNavigationTime](https://developer.apple.com//documentation/metrickit/mxlocationactivitymetric/cumulativebestaccuracyfornavigationtime/))

* `metrickit.location_activity.best_accuracy_time`: (Double) Total time spent tracking the current location at the best general accuracy. ([MXLocationActivityMetric.cumulativeBestAccuracyTime](https://developer.apple.com/documentation/metrickit/mxlocationactivitymetric/cumulativebestaccuracytime/))

* `metrickit.location_activity.accuracy_10m_time`: (Double) Total time spent tracking the current location to an accuracy of 10 meters. ([MXLocationActivityMetric.cumulativeNearestTenMetersAccuracyTime](https://developer.apple.com/documentation/metrickit/mxlocationactivitymetric/cumulativenearesttenmetersaccuracytime/))

* `metrickit.location_activity.accuracy_100m_time`: (Double) Total time spent tracking the current location to an accuracy of 100 meters. ([MXLocationActivityMetric.cumulativeHundredMetersAccuracyTime](https://developer.apple.com/documentation/metrickit/mxlocationactivitymetric/cumulativehundredmetersaccuracytime/))

* `metrickit.location_activity.accuracy_1km_time`: (Double) Total time spent tracking the current location to an accuracy of 1 kilometer. ([MXLocationActivityMetric.cumulativeKilometerAccuracyTime](https://developer.apple.com/documentation/metrickit/mxlocationactivitymetric/cumulativekilometeraccuracytime/))

* `metrickit.location_activity.accuracy_3km_time`: (Double) Total time spent tracking the current location to an accuracy of 3 kilometers. ([MXLocationActivityMetric.cumulativeThreeKilometersAccuracyTime](https://developer.apple.com/documentation/metrickit/mxlocationactivitymetric/cumulativethreekilometersaccuracytime/))

### Network Transfer

* `metrickit.network_transfer.wifi_upload`: (Double) Total amount of data uploaded over WiFi connection. ([MXNetworkTransferMetric.cumulativeWifiUpload](https://developer.apple.com/documentation/metrickit/mxnetworktransfermetric/cumulativewifiupload))

* `metrickit.network_transfer.wifi_download`: (Double) Total amount of data downloaded over WiFi connection. ([MXNetworkTransferMetric..cumulativeWifiDownload](https://developer.apple.com/documentation/metrickit/mxnetworktransfermetric/cumulativewifidownload))

* `metrickit.network_transfer.cellular_upload`: (Double) Total amount of data uploaded over cellular connection. ([MXNetworkTransferMetric.cumulativeCellularUpload](https://developer.apple.com/documentation/metrickit/mxnetworktransfermetric/cumulativecellularupload))

* `metrickit.network_transfer.cellular_download`: (Double) Total amount of data downloaded over cellular connection. ([MXNetworkTransferMetric.cumulativeCellularDownload](https://developer.apple.com/documentation/metrickit/mxnetworktransfermetric/cumulativecellulardownload))

### Application Launch

* `metrickit.app_launch.time_to_first_draw_average`: (Double) Average time taken to launch the application. ([MXAppLaunchMetric.histogrammedTimeToFirstDraw](https://developer.apple.com/documentation/metrickit/mxapplaunchmetric/histogrammedtimetofirstdraw))

* `metrickit.app_launch.app_resume_time_average`: (Double) Average time taken to resume the application from the background. ([MXAppLaunchMetric.histogrammedApplicationResumeTime](https://developer.apple.com/documentation/metrickit/mxapplaunchmetric/histogrammedapplicationresumetime))

* `metrickit.app_launch.optimized_time_to_first_draw_average`: (Double) Average time for prewarmed launches. ([MXAppLaunchMetric.histogrammedOptimizedTimeToFirstDraw](https://developer.apple.com/documentation/metrickit/mxapplaunchmetric/histogrammedoptimizedtimetofirstdraw))

* `metrickit.app_launch.extended_launch_average`: (Double) Average time taken to launch, including extended launch tasks. ([MXAppLaunchMetric.histogrammedExtendedLaunch](https://developer.apple.com/documentation/metrickit/mxapplaunchmetric/histogrammedextendedlaunch))

### Application Responsiveness

* `metrickit.app_responsiveness.hang_time_average`: (Double) Average amount of time the application is too busy to handle user interaction responsively. ([MXAppResponsivenessMetric.histogrammedApplicationHangTime](https://developer.apple.com/documentation/metrickit/mxappresponsivenessmetric/histogrammedapplicationhangtime))

### Disk I/O

* `metrickit.diskio.logical_write_count`: (Double) Total amount of data written to disk. ([MXDiskIOMetric.cumulativeLogicalWrites](https://developer.apple.com/documentation/metrickit/mxdiskiometric/cumulativelogicalwrites))

### Memory

* `metrickit.memory.peak_memory_usage`: (Double) Largest amount of memory used by the application. ([MXMemoryMetric.peakMemoryUsage](https://developer.apple.com/documentation/metrickit/mxmemorymetric/peakmemoryusage))

* `metrickit.memory.suspended_memory_average`: (Double) Average amount of memory used by the application when it's suspended. ([MXMemoryMetric.averageSuspendedMemory](https://developer.apple.com/documentation/metrickit/mxmemorymetric/averagesuspendedmemory))

### Display

* `metrickit.display.pixel_luminance_average`: (Double) Average amount of pixel luminosity on an OLED display. ([MXDisplayMetric.averagePixelLuminance](https://developer.apple.com/documentation/metrickit/mxdisplaymetric/averagepixelluminance))

### Animation

* `metrickit.animation.scroll_hitch_time_ratio`: (Double) Ratio of time spent hitching while scrolling (UIScrollView). ([MXAnimationMetric.scrollHitchTimeRatio](https://developer.apple.com/documentation/metrickit/mxanimationmetric/scrollhitchtimeratio))

### Application Exit Metrics

* `metrickit.app_exit.foreground.normal_app_exit_count`: (Int) Number of times the application exited normally from the foreground. ([MXForegroundExitData.cumulativeNormalAppExitCount](https://developer.apple.com/documentation/metrickit/mxforegroundexitdata/cumulativenormalappexitcount))

* `metrickit.app_exit.foreground.memory_resource_limit_exit_count`: (Int) Number of times the application was terminated from the foreground for using too much memory. ([MXForegroundExitData.cumulativeMemoryResourceLimitExitCount](https://developer.apple.com/documentation/metrickit/mxforegroundexitdata/cumulativememoryresourcelimitexitcount))

* `metrickit.app_exit.foreground.bad_access_exit_count`: (Int) Number of times the application was terminated from the foreground for attempting an invalid memory access. ([MXForegroundExitData.cumulativeBadAccessExitCount](https://developer.apple.com/documentation/metrickit/mxforegroundexitdata/cumulativebadaccessexitcount))

* `metrickit.app_exit.foreground.abnormal_exit_count`: (Int) Number of times the application exited abnormally from the foreground. ([MXForegroundExitData.cumulativeAbnormalExitCount](https://developer.apple.com/documentation/metrickit/mxforegroundexitdata/cumulativeabnormalexitcount))

* `metrickit.app_exit.foreground.illegal_instruction_exit_count`: (Int) Number of times the application was terminated from the foreground for attempting to execute an illegal or undefined instruction. ([MXForegroundExitData.cumulativeIllegalInstructionExitCount](https://developer.apple.com/documentation/metrickit/mxforegroundexitdata/cumulativeillegalinstructionexitcount))

* `metrickit.app_exit.foreground.app_watchdog_exit_count`: (Int) Number of times the system watchdog terminated the application from the foreground. ([MXForegroundExitData.cumulativeAppWatchdogExitCount](https://developer.apple.com/documentation/metrickit/mxforegroundexitdata/cumulativeappwatchdogexitcount))

* `metrickit.app_exit.background.normal_app_exit_count`: (Int) Number of times the application exited normally from the background. ([MXBackgroundExitData.cumulativeNormalAppExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativenormalappexitcount))

* `metrickit.app_exit.background.memory_resource_limit_exit_count`: (Int) Number of times the application was terminated from the background for using too much memory. ([MXBackgroundExitData.cumulativeMemoryResourceLimitExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativememoryresourcelimitexitcount))

* `metrickit.app_exit.background.cpu_resource_limit_exit_count`: (Int) Number of times the application was terminated from the background for using too much CPU time. ([MXBackgroundExitData.cumulativeCPUResourceLimitExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativecpuresourcelimitexitcount))

* `metrickit.app_exit.background.memory_pressure_exit_count`: (Int) Number of times the application was terminated from the background to free up memory. ([MXBackgroundExitData.cumulativeMemoryPressureExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativememorypressureexitcount))

* `metrickit.app_exit.background.bad_access_exit_count`: (Int) Number of times the application was terminated from the background for attempting an invalid memory access. ([MXBackgroundExitData.cumulativeBadAccessExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativebadaccessexitcount))

* `metrickit.app_exit.background.abnormal_exit_count`: (Int) Number of times the application exited abnormally from the background. ([MXBackgroundExitData.cumulativeAbnormalExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativeabnormalexitcount))

* `metrickit.app_exit.background.illegal_instruction_exit_count`: (Int) Number of times the application was terminated from the background for attempting to execute an illegal or undefined instruction. ([MXBackgroundExitData.cumulativeIllegalInstructionExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativeillegalinstructionexitcount))

* `metrickit.app_exit.background.app_watchdog_exit_count`: (Int) Number of times the system watchdog terminated the application from the background. ([MXBackgroundExitData.cumulativeAppWatchdogExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativeappwatchdogexitcount))

* `metrickit.app_exit.background.suspended_with_locked_file_exit_count`: (Int) Number of times the application was terminated from the background while being suspended and having file locks. ([MXBackgroundExitData.cumulativeSuspendedWithLockedFileExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativesuspendedwithlockedfileexitcount))

* `metrickit.app_exit.background.background_task_assertion_timeout_exit_count`: (Int) Number of times the application was terminated from the background for exceeding the allocated time for a background task. ([MXBackgroundExitData.cumulativeBackgroundTaskAssertionTimeoutExitCount](https://developer.apple.com/documentation/metrickit/mxbackgroundexitdata/cumulativebackgroundtaskassertiontimeoutexitcount))

### Diagnostics

* `metrickit.diagnostic.cpu_exception.total_cpu_time`: (Double) Total CPU time used during the exception. ([MXCPUExceptionDiagnostic.totalCPUTime](https://developer.apple.com/documentation/metrickit/mxcpuexceptiondiagnostic/totalcputime))

* `metrickit.diagnostic.cpu_exception.total_sampled_time`: (Double) Total time the application was sampled during the exception. ([MXCPUExceptionDiagnostic.totalSampledTime](https://developer.apple.com/documentation/metrickit/mxcpuexceptiondiagnostic/totalsampledtime))

* `metrickit.diagnostic.disk_write_exception.total_writes_caused`: (Double) Total amount of data written to disk during the disk write exception. ([MXDiskWriteExceptionDiagnostic.totalWritesCaused](https://developer.apple.com/documentation/metrickit/mxdiskwriteexceptiondiagnostic/totalwritescaused))

* `metrickit.diagnostic.hang.hang_duration`: (Double) Amount of time the app is busy and unable to respond to user interaction. ([MXHangDiagnostic.hangDuration](https://developer.apple.com/documentation/metrickit/mxhangdiagnostic/hangduration))

* `metrickit.diagnostic.crash.exception.mach_exception_type`: (Int) Mach exception type of the crash. ([MXCrashDiagnostic.exceptionType](https://developer.apple.com/documentation/metrickit/mxcrashdiagnostic/exceptiontype))

* `metrickit.diagnostic.crash.exception.code`: (Int) Encoded processor-specific information for the crash. ([MXCrashDiagnostic.exceptionCode](https://developer.apple.com/documentation/metrickit/mxcrashdiagnostic/exceptioncode))

* `metrickit.diagnostic.crash.exception.signal`: (Int) Signal associated with the crash. ([MXCrashDiagnostic.exceptionSignal](https://developer.apple.com/documentation/metrickit/mxcrashdiagnostic/signal))

* `metrickit.diagnostic.crash.exception.objc.message`: (String) Exception message string that explains the reason for the Objective-C exception. ([MXCrashDiagnosticObjectiveCExceptionReason](https://developer.apple.com/documentation/metrickit/mxcrashdiagnosticobjectivecexceptionreason))

* `metrickit.diagnostic.crash.exception.objc.type`: (String) Type of the Objective-C exception. ([MXCrashDiagnosticObjectiveCExceptionReason](https://developer.apple.com/documentation/metrickit/mxcrashdiagnosticobjectivecexceptionreason))

* `metrickit.diagnostic.crash.exception.termination_reason`: (String) Reason the application was terminated as a human-readable string. ([MXCrashDiagnostic.terminationReason](https://developer.apple.com/documentation/metrickit/mxcrashdiagnostic/terminationreason))

* `metrickit.diagnostic.crash.exception.objc.name`: (String) Name of the Objective-C exception that triggered the crash. ([MXCrashDiagnosticObjectiveCExceptionReason](https://developer.apple.com/documentation/metrickit/mxcrashdiagnosticobjectivecexceptionreason))

* `metrickit.diagnostic.crash.exception.objc.classname`: (String) Name of the Objective-C class in which the exception occurred. ([MXCrashDiagnosticObjectiveCExceptionReason](https://developer.apple.com/documentation/metrickit/mxcrashdiagnosticobjectivecexceptionreason))

* `metrickit.diagnostic.app_launch.launch_duration`: (Double) Total duration of the application launch, measured from process start until the application is responsive. ([MXAppLaunchDiagnostic.launchDuration](https://developer.apple.com/documentation/metrickit/mxapplaunchdiagnostic/launchduration))
