Create Crash Report
horizon_create_crash_reportSend a crash, non-fatal exception, or ANR report with device details to horizOn Crash Reporting so issues group by fingerprint.
Instructions
Submits one crash (CRASH), caught exception (NON_FATAL) or freeze (ANR) with device data to horizOn Crash Reporting, grouped by fingerprint. Use when: the game crashed (send on next start) or caught an exception worth tracking. Not for: technical events without a crash (use horizon_create_log) and messages written by players (use horizon_submit_feedback). Requires: a sessionId registered with horizon_create_crash_session for this app run; userId is optional. Side effects: adds one report per call (a repeat adds a duplicate) and marks the session as crashed. Reports with the same fingerprint form one group; a group marked resolved becomes REGRESSED when a newer app version crashes again. Returns: {id, groupId, createdAt}; groupId identifies the crash group in the dashboard. Errors: 400 when a required field is missing or too long: fix it and resend. Needs HORIZON_API_KEY. Every failure returns an error result (isError) with the HTTP status and body: a 401 that horizon_test_connection also returns means HORIZON_API_KEY is wrong, 429 means the account's per-minute rate limit was reached (wait a minute, then retry).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| os | Yes | OS details (e.g. 'Android 14', 'iOS 17.2') | |
| type | Yes | Crash type: CRASH (fatal), NON_FATAL (exception), or ANR (Application Not Responding) | |
| userId | No | Player user ID (UUID) from horizon_signup_* or horizon_signin_*, if a player is signed in | |
| message | Yes | Error or exception message (1 to 5000 characters) | |
| platform | Yes | Platform (e.g. 'Android', 'iOS', 'Windows') | |
| sessionId | Yes | The sessionId registered with horizon_create_crash_session for this app run (1 to 100 characters) | |
| appVersion | Yes | App version (e.g. '1.2.3') | |
| customKeys | No | String key to string value metadata such as level or build flavor (max 10 entries) | |
| sdkVersion | Yes | horizOn SDK version, for example '1.8.2' (1 to 50 characters) | |
| stackTrace | No | Full stack trace (max 20000 characters) | |
| breadcrumbs | No | Recent events before the crash, oldest first (max 50) | |
| deviceModel | Yes | Device model (e.g. 'Pixel 8', 'iPhone 15') | |
| fingerprint | Yes | Grouping key: reports with the same fingerprint form one crash group, for example a hash of exception type and top stack frame (1 to 128 characters) | |
| deviceMemoryMb | No | Device RAM in MB, for example 8192 |