[{"data":1,"prerenderedAt":4582},["ShallowReactive",2],{"beacon-doc-\u002Fbeacon\u002Fdocs\u002Fapi-reference":3,"beacon-docs-all":578},{"id":4,"title":5,"body":6,"description":568,"extension":569,"meta":570,"navigation":571,"order":572,"path":573,"published":571,"section":574,"seo":575,"stem":576,"__hash__":577},"beaconDocs\u002Fbeacon\u002Fdocs\u002Fapi-reference.md","API Reference",{"type":7,"value":8,"toc":554},"minimark",[9,13,17,22,25,35,41,45,53,169,173,181,185,265,270,273,278,312,317,343,377,381,384,401,405,408,420,424,427,458,479,489,493,496,502,512,516,523,527,530,550],[10,11,5],"h1",{"id":12},"api-reference",[14,15,16],"p",{},"Beacon provides a REST API for direct integration when an SDK is not suitable for your environment. The API is used internally by all Beacon SDKs.",[18,19,21],"h2",{"id":20},"interactive-documentation","Interactive Documentation",[14,23,24],{},"Full interactive API documentation is available at:",[14,26,27],{},[28,29,30],"strong",{},[31,32,34],"a",{"href":33},"#","Beacon API Reference (Scalar)",[14,36,37],{},[38,39,40],"em",{},"The API documentation URL will be available when Beacon launches. The interactive docs let you explore endpoints, view request\u002Fresponse schemas, and test calls directly from your browser.",[18,42,44],{"id":43},"authentication","Authentication",[14,46,47,48,52],{},"All ingestion API requests require an API key passed as a Bearer token in the ",[49,50,51],"code",{},"Authorization"," header:",[54,55,60],"pre",{"className":56,"code":57,"language":58,"meta":59,"style":59},"language-bash shiki shiki-themes github-dark","curl -X POST https:\u002F\u002Fapi.beacon.softagility.com\u002Fv1\u002Fevents \\\n  -H \"Authorization: Bearer your-api-key\" \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -d '[{\n    \"event_id\": \"01912345-6789-7abc-def0-123456789abc\",\n    \"category\": \"reports\",\n    \"name\": \"report_exported\",\n    \"timestamp\": \"2026-03-20T14:30:00Z\",\n    \"actor_id\": \"user-123\",\n    \"source_app\": \"MyApp\",\n    \"source_version\": \"1.2.0\",\n    \"properties\": { \"format\": \"pdf\", \"row_count\": \"1500\" }\n  }]'\n","bash","",[49,61,62,85,96,106,115,121,127,133,139,145,151,157,163],{"__ignoreMap":59},[63,64,67,71,75,79,82],"span",{"class":65,"line":66},"line",1,[63,68,70],{"class":69},"svObZ","curl",[63,72,74],{"class":73},"sDLfK"," -X",[63,76,78],{"class":77},"sU2Wk"," POST",[63,80,81],{"class":77}," https:\u002F\u002Fapi.beacon.softagility.com\u002Fv1\u002Fevents",[63,83,84],{"class":73}," \\\n",[63,86,88,91,94],{"class":65,"line":87},2,[63,89,90],{"class":73},"  -H",[63,92,93],{"class":77}," \"Authorization: Bearer your-api-key\"",[63,95,84],{"class":73},[63,97,99,101,104],{"class":65,"line":98},3,[63,100,90],{"class":73},[63,102,103],{"class":77}," \"Content-Type: application\u002Fjson\"",[63,105,84],{"class":73},[63,107,109,112],{"class":65,"line":108},4,[63,110,111],{"class":73},"  -d",[63,113,114],{"class":77}," '[{\n",[63,116,118],{"class":65,"line":117},5,[63,119,120],{"class":77},"    \"event_id\": \"01912345-6789-7abc-def0-123456789abc\",\n",[63,122,124],{"class":65,"line":123},6,[63,125,126],{"class":77},"    \"category\": \"reports\",\n",[63,128,130],{"class":65,"line":129},7,[63,131,132],{"class":77},"    \"name\": \"report_exported\",\n",[63,134,136],{"class":65,"line":135},8,[63,137,138],{"class":77},"    \"timestamp\": \"2026-03-20T14:30:00Z\",\n",[63,140,142],{"class":65,"line":141},9,[63,143,144],{"class":77},"    \"actor_id\": \"user-123\",\n",[63,146,148],{"class":65,"line":147},10,[63,149,150],{"class":77},"    \"source_app\": \"MyApp\",\n",[63,152,154],{"class":65,"line":153},11,[63,155,156],{"class":77},"    \"source_version\": \"1.2.0\",\n",[63,158,160],{"class":65,"line":159},12,[63,161,162],{"class":77},"    \"properties\": { \"format\": \"pdf\", \"row_count\": \"1500\" }\n",[63,164,166],{"class":65,"line":165},13,[63,167,168],{"class":77},"  }]'\n",[18,170,172],{"id":171},"base-url","Base URL",[54,174,179],{"className":175,"code":177,"language":178},[176],"language-text","https:\u002F\u002Fapi.beacon.softagility.com\u002Fv1\n","text",[49,180,177],{"__ignoreMap":59},[18,182,184],{"id":183},"ingestion-endpoints","Ingestion Endpoints",[186,187,188,204],"table",{},[189,190,191],"thead",{},[192,193,194,198,201],"tr",{},[195,196,197],"th",{},"Method",[195,199,200],{},"Endpoint",[195,202,203],{},"Description",[205,206,207,223,237,251],"tbody",{},[192,208,209,215,220],{},[210,211,212],"td",{},[49,213,214],{},"POST",[210,216,217],{},[49,218,219],{},"\u002Fv1\u002Fevents",[210,221,222],{},"Track one or more events (batch, up to 1000)",[192,224,225,229,234],{},[210,226,227],{},[49,228,214],{},[210,230,231],{},[49,232,233],{},"\u002Fv1\u002Fevents\u002Fsessions",[210,235,236],{},"Start a new session",[192,238,239,243,248],{},[210,240,241],{},[49,242,214],{},[210,244,245],{},[49,246,247],{},"\u002Fv1\u002Fevents\u002Fsessions\u002Fend",[210,249,250],{},"End an active session",[192,252,253,257,262],{},[210,254,255],{},[49,256,214],{},[210,258,259],{},[49,260,261],{},"\u002Fv1\u002Fevents\u002Fexceptions",[210,263,264],{},"Report an exception with stack trace",[266,267,269],"h3",{"id":268},"post-v1events","POST \u002Fv1\u002Fevents",[14,271,272],{},"Send a JSON array of event objects. Max payload 1 MB, max 1000 events per batch.",[14,274,275],{},[28,276,277],{},"Required fields per event:",[279,280,281,288,294,300,306],"ul",{},[282,283,284,287],"li",{},[49,285,286],{},"event_id"," — UUID (v7 recommended)",[282,289,290,293],{},[49,291,292],{},"category"," — String, max 128 chars",[282,295,296,299],{},[49,297,298],{},"name"," — String, max 256 chars",[282,301,302,305],{},[49,303,304],{},"timestamp"," — ISO 8601 datetime",[282,307,308,311],{},[49,309,310],{},"actor_id"," — String, max 512 chars",[14,313,314],{},[28,315,316],{},"Optional fields:",[279,318,319,325,331,337],{},[282,320,321,324],{},[49,322,323],{},"source_app"," — Application name",[282,326,327,330],{},[49,328,329],{},"source_version"," — Application version",[282,332,333,336],{},[49,334,335],{},"properties"," — Object with custom properties",[282,338,339,342],{},[49,340,341],{},"session_id"," — UUID linking event to a session",[14,344,345,348,349,352,353,356,357,360,361,364,365,368,369,372,373,376],{},[28,346,347],{},"Response:"," ",[49,350,351],{},"200"," (all accepted), ",[49,354,355],{},"207"," (partial success), ",[49,358,359],{},"400"," (validation error), ",[49,362,363],{},"401"," (invalid API key), ",[49,366,367],{},"402"," (plan event limit reached), ",[49,370,371],{},"413"," (payload too large), ",[49,374,375],{},"429"," (rate limited)",[266,378,380],{"id":379},"post-v1eventssessions","POST \u002Fv1\u002Fevents\u002Fsessions",[14,382,383],{},"Start a new session.",[14,385,386,348,389,391,392,391,394,391,396,391,398],{},[28,387,388],{},"Required fields:",[49,390,341],{},", ",[49,393,310],{},[49,395,323],{},[49,397,329],{},[49,399,400],{},"started_at",[266,402,404],{"id":403},"post-v1eventssessionsend","POST \u002Fv1\u002Fevents\u002Fsessions\u002Fend",[14,406,407],{},"End an active session.",[14,409,410,348,412,391,414,391,417],{},[28,411,388],{},[49,413,341],{},[49,415,416],{},"ended_at",[49,418,419],{},"end_reason",[266,421,423],{"id":422},"post-v1eventsexceptions","POST \u002Fv1\u002Fevents\u002Fexceptions",[14,425,426],{},"Report an exception.",[14,428,429,348,431,391,434,391,437,440,441,444,445,448,449,391,452,391,454,391,456],{},[28,430,388],{},[49,432,433],{},"exception_id",[49,435,436],{},"exception_type",[49,438,439],{},"severity"," (",[49,442,443],{},"fatal"," or ",[49,446,447],{},"non_fatal","), ",[49,450,451],{},"occurred_at",[49,453,310],{},[49,455,323],{},[49,457,329],{},[14,459,460,348,462,465,466,469,470,473,474,391,476],{},[28,461,316],{},[49,463,464],{},"message"," (max 1000 chars), ",[49,467,468],{},"stack_trace"," (max 32,768 chars), ",[49,471,472],{},"breadcrumbs"," (JSON array), ",[49,475,341],{},[49,477,478],{},"environment_context",[14,480,481,348,483,485,486],{},[28,482,347],{},[49,484,351],{}," with ",[49,487,488],{},"{ \"exception_id\": \"...\", \"status\": \"accepted\", \"fingerprint\": \"...\" }",[18,490,492],{"id":491},"rate-limits","Rate Limits",[14,494,495],{},"Rate limits are per-minute and configurable per plan. Rate limit headers are included in every response:",[54,497,500],{"className":498,"code":499,"language":178},[176],"X-RateLimit-Limit: 600\nX-RateLimit-Remaining: 598\nX-RateLimit-Reset: 1711929600\n",[49,501,499],{"__ignoreMap":59},[14,503,504,505,507,508,511],{},"When rate limited, the API returns ",[49,506,375],{}," with a ",[49,509,510],{},"Retry-After"," header.",[18,513,515],{"id":514},"hard-caps","Hard Caps",[14,517,518,519,522],{},"When a tenant reaches their plan's monthly event limit, the API returns ",[49,520,521],{},"402 Payment Required",". Events are rejected until the limit resets or the plan is upgraded. SDKs queue events locally during hard cap periods and retry automatically.",[18,524,526],{"id":525},"sdks","SDKs",[14,528,529],{},"For most integrations, we recommend using an SDK instead of the API directly. SDKs handle batching, offline persistence, session management, breadcrumbs, and retry logic automatically.",[279,531,532,538,544],{},[282,533,534],{},[31,535,537],{"href":536},"\u002Fbeacon\u002Fdocs\u002Fsdk\u002Fdotnet",".NET SDK",[282,539,540],{},[31,541,543],{"href":542},"\u002Fbeacon\u002Fdocs\u002Fsdk\u002Fcpp","C++ SDK",[282,545,546],{},[31,547,549],{"href":548},"\u002Fbeacon\u002Fdocs\u002Fsdk\u002Fjavascript","JavaScript\u002FTypeScript SDK",[551,552,553],"style",{},"html pre.shiki code .svObZ, html code.shiki .svObZ{--shiki-default:#B392F0}html pre.shiki code .sDLfK, html code.shiki .sDLfK{--shiki-default:#79B8FF}html pre.shiki code .sU2Wk, html code.shiki .sU2Wk{--shiki-default:#9ECBFF}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}",{"title":59,"searchDepth":87,"depth":87,"links":555},[556,557,558,559,565,566,567],{"id":20,"depth":87,"text":21},{"id":43,"depth":87,"text":44},{"id":171,"depth":87,"text":172},{"id":183,"depth":87,"text":184,"children":560},[561,562,563,564],{"id":268,"depth":98,"text":269},{"id":379,"depth":98,"text":380},{"id":403,"depth":98,"text":404},{"id":422,"depth":98,"text":423},{"id":491,"depth":87,"text":492},{"id":514,"depth":87,"text":515},{"id":525,"depth":87,"text":526},"REST API documentation for direct Beacon integration.","md",{},true,20,"\u002Fbeacon\u002Fdocs\u002Fapi-reference","Reference",{"title":5,"description":568},"beacon\u002Fdocs\u002Fapi-reference","NYoN1PzxAR8BnJQTeO6nJIsraYwF8FaKw4jz9dDUkHs",[579,1108,2400,3234,4203],{"id":580,"title":581,"body":582,"description":1101,"extension":569,"meta":1102,"navigation":571,"order":66,"path":1103,"published":571,"section":1104,"seo":1105,"stem":1106,"__hash__":1107},"beaconDocs\u002Fbeacon\u002Fdocs\u002Fgetting-started.md","Getting Started",{"type":7,"value":583,"toc":1088},[584,588,591,595,611,615,619,622,685,689,692,778,781,857,860,874,878,881,912,916,919,977,981,984,988,991,996,1013,1018,1035,1038,1042,1045,1055,1059,1085],[10,585,587],{"id":586},"getting-started-with-beacon","Getting Started with Beacon",[14,589,590],{},"Beacon is a product analytics platform built for ISVs shipping desktop, web, server, and cloud applications. This guide walks you through going from zero to your first tracked event.",[18,592,594],{"id":593},"prerequisites","Prerequisites",[279,596,597,605,608],{},[282,598,599,600,604],{},"A Beacon account (",[31,601,603],{"href":602},"\u002Fbeacon","start your free trial",")",[282,606,607],{},"Your API key and API base URL (found in your Beacon dashboard under Settings)",[282,609,610],{},"An application built with .NET, C++, or JavaScript\u002FTypeScript",[18,612,614],{"id":613},"quick-start","Quick Start",[266,616,618],{"id":617},"_1-choose-your-sdk","1. Choose Your SDK",[14,620,621],{},"Beacon provides native SDKs for three platforms:",[186,623,624,637],{},[189,625,626],{},[192,627,628,631,634],{},[195,629,630],{},"Platform",[195,632,633],{},"Package",[195,635,636],{},"Install Command",[205,638,639,654,670],{},[192,640,641,644,649],{},[210,642,643],{},".NET",[210,645,646],{},[49,647,648],{},"SoftAgility.Beacon",[210,650,651],{},[49,652,653],{},"dotnet add package SoftAgility.Beacon",[192,655,656,659,664],{},[210,657,658],{},"C++",[210,660,661],{},[49,662,663],{},"beacon_sdk",[210,665,666,667,604],{},"CMake FetchContent (see ",[31,668,669],{"href":542},"C++ SDK docs",[192,671,672,675,680],{},[210,673,674],{},"JavaScript\u002FTypeScript",[210,676,677],{},[49,678,679],{},"@softagility\u002Fbeacon-js",[210,681,682],{},[49,683,684],{},"npm install @softagility\u002Fbeacon-js",[266,686,688],{"id":687},"_2-initialize-the-sdk","2. Initialize the SDK",[14,690,691],{},"Add Beacon to your application startup. Here is a .NET example using dependency injection:",[54,693,697],{"className":694,"code":695,"language":696,"meta":59,"style":59},"language-csharp shiki shiki-themes github-dark","services.AddBeacon(options =>\n{\n    options.ApiKey = \"your-api-key\";\n    options.ApiBaseUrl = \"https:\u002F\u002Fapi.beacon.softagility.com\";\n    options.AppName = \"MyApp\";\n    options.AppVersion = \"1.2.0\";\n});\n","csharp",[49,698,699,718,723,737,749,761,773],{"__ignoreMap":59},[63,700,701,705,708,711,714],{"class":65,"line":66},[63,702,704],{"class":703},"s95oV","services.",[63,706,707],{"class":69},"AddBeacon",[63,709,710],{"class":703},"(",[63,712,713],{"class":69},"options",[63,715,717],{"class":716},"snl16"," =>\n",[63,719,720],{"class":65,"line":87},[63,721,722],{"class":703},"{\n",[63,724,725,728,731,734],{"class":65,"line":98},[63,726,727],{"class":703},"    options.ApiKey ",[63,729,730],{"class":716},"=",[63,732,733],{"class":77}," \"your-api-key\"",[63,735,736],{"class":703},";\n",[63,738,739,742,744,747],{"class":65,"line":108},[63,740,741],{"class":703},"    options.ApiBaseUrl ",[63,743,730],{"class":716},[63,745,746],{"class":77}," \"https:\u002F\u002Fapi.beacon.softagility.com\"",[63,748,736],{"class":703},[63,750,751,754,756,759],{"class":65,"line":117},[63,752,753],{"class":703},"    options.AppName ",[63,755,730],{"class":716},[63,757,758],{"class":77}," \"MyApp\"",[63,760,736],{"class":703},[63,762,763,766,768,771],{"class":65,"line":123},[63,764,765],{"class":703},"    options.AppVersion ",[63,767,730],{"class":716},[63,769,770],{"class":77}," \"1.2.0\"",[63,772,736],{"class":703},[63,774,775],{"class":65,"line":129},[63,776,777],{"class":703},"});\n",[14,779,780],{},"Or initialize directly without DI:",[54,782,784],{"className":694,"code":783,"language":696,"meta":59,"style":59},"var tracker = BeaconTracker.Configure(options =>\n{\n    options.ApiKey = \"your-api-key\";\n    options.ApiBaseUrl = \"https:\u002F\u002Fapi.beacon.softagility.com\";\n    options.AppName = \"MyApp\";\n    options.AppVersion = \"1.2.0\";\n});\n",[49,785,786,809,813,823,833,843,853],{"__ignoreMap":59},[63,787,788,791,794,797,800,803,805,807],{"class":65,"line":66},[63,789,790],{"class":716},"var",[63,792,793],{"class":69}," tracker",[63,795,796],{"class":716}," =",[63,798,799],{"class":703}," BeaconTracker.",[63,801,802],{"class":69},"Configure",[63,804,710],{"class":703},[63,806,713],{"class":69},[63,808,717],{"class":716},[63,810,811],{"class":65,"line":87},[63,812,722],{"class":703},[63,814,815,817,819,821],{"class":65,"line":98},[63,816,727],{"class":703},[63,818,730],{"class":716},[63,820,733],{"class":77},[63,822,736],{"class":703},[63,824,825,827,829,831],{"class":65,"line":108},[63,826,741],{"class":703},[63,828,730],{"class":716},[63,830,746],{"class":77},[63,832,736],{"class":703},[63,834,835,837,839,841],{"class":65,"line":117},[63,836,753],{"class":703},[63,838,730],{"class":716},[63,840,758],{"class":77},[63,842,736],{"class":703},[63,844,845,847,849,851],{"class":65,"line":123},[63,846,765],{"class":703},[63,848,730],{"class":716},[63,850,770],{"class":77},[63,852,736],{"class":703},[63,854,855],{"class":65,"line":129},[63,856,777],{"class":703},[14,858,859],{},"See the full setup guide for your platform:",[279,861,862,866,870],{},[282,863,864],{},[31,865,537],{"href":536},[282,867,868],{},[31,869,543],{"href":542},[282,871,872],{},[31,873,549],{"href":548},[266,875,877],{"id":876},"_3-identify-the-user-and-start-a-session","3. Identify the User and Start a Session",[14,879,880],{},"Beacon uses actors to associate events with users or devices. Identify the current actor and start a session:",[54,882,884],{"className":694,"code":883,"language":696,"meta":59,"style":59},"tracker.Identify(\"user-123\");\ntracker.StartSession();\n",[49,885,886,902],{"__ignoreMap":59},[63,887,888,891,894,896,899],{"class":65,"line":66},[63,889,890],{"class":703},"tracker.",[63,892,893],{"class":69},"Identify",[63,895,710],{"class":703},[63,897,898],{"class":77},"\"user-123\"",[63,900,901],{"class":703},");\n",[63,903,904,906,909],{"class":65,"line":87},[63,905,890],{"class":703},[63,907,908],{"class":69},"StartSession",[63,910,911],{"class":703},"();\n",[266,913,915],{"id":914},"_4-track-your-first-event","4. Track Your First Event",[14,917,918],{},"Events are organized by category and name:",[54,920,922],{"className":694,"code":921,"language":696,"meta":59,"style":59},"tracker.Track(\"reports\", \"report_exported\", new\n{\n    format = \"pdf\",\n    row_count = 1500\n});\n",[49,923,924,946,950,963,973],{"__ignoreMap":59},[63,925,926,928,931,933,936,938,941,943],{"class":65,"line":66},[63,927,890],{"class":703},[63,929,930],{"class":69},"Track",[63,932,710],{"class":703},[63,934,935],{"class":77},"\"reports\"",[63,937,391],{"class":703},[63,939,940],{"class":77},"\"report_exported\"",[63,942,391],{"class":703},[63,944,945],{"class":716},"new\n",[63,947,948],{"class":65,"line":87},[63,949,722],{"class":703},[63,951,952,955,957,960],{"class":65,"line":98},[63,953,954],{"class":703},"    format ",[63,956,730],{"class":716},[63,958,959],{"class":77}," \"pdf\"",[63,961,962],{"class":703},",\n",[63,964,965,968,970],{"class":65,"line":108},[63,966,967],{"class":703},"    row_count ",[63,969,730],{"class":716},[63,971,972],{"class":73}," 1500\n",[63,974,975],{"class":65,"line":117},[63,976,777],{"class":703},[266,978,980],{"id":979},"_5-view-your-data","5. View Your Data",[14,982,983],{},"Log in to the Beacon dashboard. Events appear in real time in the Event Explorer. From there you can build funnels, analyze retention, and segment users.",[18,985,987],{"id":986},"environment-collection","Environment Collection",[14,989,990],{},"Each SDK automatically collects environment data and sends it as a header with each request. The data varies by platform:",[14,992,993],{},[28,994,995],{},".NET and C++ SDKs:",[279,997,998,1001,1004,1007,1010],{},[282,999,1000],{},"Operating system and version",[282,1002,1003],{},"Runtime version (.NET version, compiler)",[282,1005,1006],{},"Hardware (CPU, memory, display resolution)",[282,1008,1009],{},"Locale and timezone",[282,1011,1012],{},"Application version",[14,1014,1015],{},[28,1016,1017],{},"JavaScript \u002F TypeScript SDK:",[279,1019,1020,1023,1026,1029,1032],{},[282,1021,1022],{},"Browser name and version",[282,1024,1025],{},"Screen and viewport dimensions",[282,1027,1028],{},"Language and platform",[282,1030,1031],{},"Device type (desktop, mobile, tablet)",[282,1033,1034],{},"Connection type (when available)",[14,1036,1037],{},"No PII is collected. All data is environment and session metadata.",[18,1039,1041],{"id":1040},"offline-behavior","Offline Behavior",[14,1043,1044],{},"The .NET and C++ SDKs include built-in offline persistence via a local SQLite database. If your application loses connectivity, events are queued locally and sync automatically when the connection returns. No data is lost, and the queue persists across application restarts.",[14,1046,1047,1048,485,1051,1054],{},"The JavaScript SDK uses an in-memory queue with best-effort delivery via ",[49,1049,1050],{},"fetch",[49,1052,1053],{},"keepalive"," on page unload. Events are buffered while the tab is open but do not persist across page reloads.",[18,1056,1058],{"id":1057},"next-steps","Next Steps",[279,1060,1061,1071,1077],{},[282,1062,1063,1064,1066,1067,1066,1069],{},"Read the SDK guide for your platform: ",[31,1065,643],{"href":536}," | ",[31,1068,658],{"href":542},[31,1070,674],{"href":548},[282,1072,1073,1074,1076],{},"Review the ",[31,1075,5],{"href":573}," for direct API integration",[282,1078,1079,1080,1084],{},"See ",[31,1081,1083],{"href":1082},"\u002Fbeacon\u002Fpricing","pricing"," for plan details",[551,1086,1087],{},"html pre.shiki code .s95oV, html code.shiki .s95oV{--shiki-default:#E1E4E8}html pre.shiki code .svObZ, html code.shiki .svObZ{--shiki-default:#B392F0}html pre.shiki code .snl16, html code.shiki .snl16{--shiki-default:#F97583}html pre.shiki code .sU2Wk, html code.shiki .sU2Wk{--shiki-default:#9ECBFF}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html pre.shiki code .sDLfK, html code.shiki .sDLfK{--shiki-default:#79B8FF}",{"title":59,"searchDepth":87,"depth":87,"links":1089},[1090,1091,1098,1099,1100],{"id":593,"depth":87,"text":594},{"id":613,"depth":87,"text":614,"children":1092},[1093,1094,1095,1096,1097],{"id":617,"depth":98,"text":618},{"id":687,"depth":98,"text":688},{"id":876,"depth":98,"text":877},{"id":914,"depth":98,"text":915},{"id":979,"depth":98,"text":980},{"id":986,"depth":87,"text":987},{"id":1040,"depth":87,"text":1041},{"id":1057,"depth":87,"text":1058},"Get up and running with Beacon product analytics in under 30 minutes.",{},"\u002Fbeacon\u002Fdocs\u002Fgetting-started","Overview",{"title":581,"description":1101},"beacon\u002Fdocs\u002Fgetting-started","o6q3Bj1EMLJi2p_IF-_7B4ceVSbAVKDZhrAbgvzQrHU",{"id":1109,"title":537,"body":1110,"description":2395,"extension":569,"meta":2396,"navigation":571,"order":147,"path":536,"published":571,"section":526,"seo":2397,"stem":2398,"__hash__":2399},"beaconDocs\u002Fbeacon\u002Fdocs\u002Fsdk\u002Fdotnet.md",{"type":7,"value":1111,"toc":2369},[1112,1116,1119,1123,1126,1145,1148,1162,1166,1177,1181,1185,1192,1256,1260,1270,1340,1344,1562,1566,1569,1586,1598,1602,1611,1615,1670,1674,1728,1732,1743,1747,1750,1809,1813,1816,1884,1894,1897,1903,1909,1913,1922,1940,1943,1961,1965,1972,1985,1989,1992,2011,2015,2020,2024,2036,2066,2070,2347,2349,2366],[10,1113,1115],{"id":1114},"beacon-net-sdk","Beacon .NET SDK",[14,1117,1118],{},"The Beacon .NET SDK provides native integration for desktop (WPF, WinForms, MAUI), server (ASP.NET Core, Windows Services), and console applications.",[18,1120,1122],{"id":1121},"installation","Installation",[14,1124,1125],{},"Install via NuGet:",[54,1127,1129],{"className":56,"code":1128,"language":58,"meta":59,"style":59},"dotnet add package SoftAgility.Beacon\n",[49,1130,1131],{"__ignoreMap":59},[63,1132,1133,1136,1139,1142],{"class":65,"line":66},[63,1134,1135],{"class":69},"dotnet",[63,1137,1138],{"class":77}," add",[63,1140,1141],{"class":77}," package",[63,1143,1144],{"class":77}," SoftAgility.Beacon\n",[14,1146,1147],{},"Or via the Package Manager Console:",[54,1149,1153],{"className":1150,"code":1151,"language":1152,"meta":59,"style":59},"language-powershell shiki shiki-themes github-dark","Install-Package SoftAgility.Beacon\n","powershell",[49,1154,1155],{"__ignoreMap":59},[63,1156,1157,1160],{"class":65,"line":66},[63,1158,1159],{"class":73},"Install-Package",[63,1161,1144],{"class":703},[266,1163,1165],{"id":1164},"system-requirements","System Requirements",[279,1167,1168,1171,1174],{},[282,1169,1170],{},".NET 8.0 or later",[282,1172,1173],{},"Windows, Linux, or macOS",[282,1175,1176],{},"No additional dependencies",[18,1178,1180],{"id":1179},"configuration","Configuration",[266,1182,1184],{"id":1183},"aspnet-core-host-builder","ASP.NET Core \u002F Host Builder",[14,1186,1187,1188,1191],{},"Register Beacon with dependency injection to resolve ",[49,1189,1190],{},"IBeaconTracker",":",[54,1193,1194],{"className":694,"code":695,"language":696,"meta":59,"style":59},[49,1195,1196,1208,1212,1222,1232,1242,1252],{"__ignoreMap":59},[63,1197,1198,1200,1202,1204,1206],{"class":65,"line":66},[63,1199,704],{"class":703},[63,1201,707],{"class":69},[63,1203,710],{"class":703},[63,1205,713],{"class":69},[63,1207,717],{"class":716},[63,1209,1210],{"class":65,"line":87},[63,1211,722],{"class":703},[63,1213,1214,1216,1218,1220],{"class":65,"line":98},[63,1215,727],{"class":703},[63,1217,730],{"class":716},[63,1219,733],{"class":77},[63,1221,736],{"class":703},[63,1223,1224,1226,1228,1230],{"class":65,"line":108},[63,1225,741],{"class":703},[63,1227,730],{"class":716},[63,1229,746],{"class":77},[63,1231,736],{"class":703},[63,1233,1234,1236,1238,1240],{"class":65,"line":117},[63,1235,753],{"class":703},[63,1237,730],{"class":716},[63,1239,758],{"class":77},[63,1241,736],{"class":703},[63,1243,1244,1246,1248,1250],{"class":65,"line":123},[63,1245,765],{"class":703},[63,1247,730],{"class":716},[63,1249,770],{"class":77},[63,1251,736],{"class":703},[63,1253,1254],{"class":65,"line":129},[63,1255,777],{"class":703},[266,1257,1259],{"id":1258},"manual-initialization","Manual Initialization",[14,1261,1262,1263,1265,1266,1269],{},"For applications without dependency injection, use the static ",[49,1264,802],{}," method. This creates a singleton ",[49,1267,1268],{},"BeaconTracker"," instance:",[54,1271,1272],{"className":694,"code":783,"language":696,"meta":59,"style":59},[49,1273,1274,1292,1296,1306,1316,1326,1336],{"__ignoreMap":59},[63,1275,1276,1278,1280,1282,1284,1286,1288,1290],{"class":65,"line":66},[63,1277,790],{"class":716},[63,1279,793],{"class":69},[63,1281,796],{"class":716},[63,1283,799],{"class":703},[63,1285,802],{"class":69},[63,1287,710],{"class":703},[63,1289,713],{"class":69},[63,1291,717],{"class":716},[63,1293,1294],{"class":65,"line":87},[63,1295,722],{"class":703},[63,1297,1298,1300,1302,1304],{"class":65,"line":98},[63,1299,727],{"class":703},[63,1301,730],{"class":716},[63,1303,733],{"class":77},[63,1305,736],{"class":703},[63,1307,1308,1310,1312,1314],{"class":65,"line":108},[63,1309,741],{"class":703},[63,1311,730],{"class":716},[63,1313,746],{"class":77},[63,1315,736],{"class":703},[63,1317,1318,1320,1322,1324],{"class":65,"line":117},[63,1319,753],{"class":703},[63,1321,730],{"class":716},[63,1323,758],{"class":77},[63,1325,736],{"class":703},[63,1327,1328,1330,1332,1334],{"class":65,"line":123},[63,1329,765],{"class":703},[63,1331,730],{"class":716},[63,1333,770],{"class":77},[63,1335,736],{"class":703},[63,1337,1338],{"class":65,"line":129},[63,1339,777],{"class":703},[266,1341,1343],{"id":1342},"configuration-options","Configuration Options",[186,1345,1346,1361],{},[189,1347,1348],{},[192,1349,1350,1353,1356,1359],{},[195,1351,1352],{},"Option",[195,1354,1355],{},"Type",[195,1357,1358],{},"Default",[195,1360,203],{},[205,1362,1363,1381,1397,1413,1429,1449,1469,1488,1507,1525,1542],{},[192,1364,1365,1370,1375,1378],{},[210,1366,1367],{},[49,1368,1369],{},"ApiKey",[210,1371,1372],{},[49,1373,1374],{},"string",[210,1376,1377],{},"—",[210,1379,1380],{},"Your Beacon API key (required)",[192,1382,1383,1388,1392,1394],{},[210,1384,1385],{},[49,1386,1387],{},"ApiBaseUrl",[210,1389,1390],{},[49,1391,1374],{},[210,1393,1377],{},[210,1395,1396],{},"Beacon API base URL (required)",[192,1398,1399,1404,1408,1410],{},[210,1400,1401],{},[49,1402,1403],{},"AppName",[210,1405,1406],{},[49,1407,1374],{},[210,1409,1377],{},[210,1411,1412],{},"Your application name, max 128 chars (required)",[192,1414,1415,1420,1424,1426],{},[210,1416,1417],{},[49,1418,1419],{},"AppVersion",[210,1421,1422],{},[49,1423,1374],{},[210,1425,1377],{},[210,1427,1428],{},"Your application version, max 256 chars (required)",[192,1430,1431,1436,1441,1446],{},[210,1432,1433],{},[49,1434,1435],{},"Enabled",[210,1437,1438],{},[49,1439,1440],{},"bool",[210,1442,1443],{},[49,1444,1445],{},"true",[210,1447,1448],{},"Enable or disable tracking globally",[192,1450,1451,1456,1461,1466],{},[210,1452,1453],{},[49,1454,1455],{},"FlushIntervalSeconds",[210,1457,1458],{},[49,1459,1460],{},"int",[210,1462,1463],{},[49,1464,1465],{},"60",[210,1467,1468],{},"How often to send batched events (1-3600)",[192,1470,1471,1476,1480,1485],{},[210,1472,1473],{},[49,1474,1475],{},"MaxBatchSize",[210,1477,1478],{},[49,1479,1460],{},[210,1481,1482],{},[49,1483,1484],{},"25",[210,1486,1487],{},"Events per batch, clamped to 1-1000",[192,1489,1490,1495,1499,1504],{},[210,1491,1492],{},[49,1493,1494],{},"MaxQueueSizeMb",[210,1496,1497],{},[49,1498,1460],{},[210,1500,1501],{},[49,1502,1503],{},"10",[210,1505,1506],{},"Maximum offline queue size in MB (1-1000)",[192,1508,1509,1514,1518,1522],{},[210,1510,1511],{},[49,1512,1513],{},"MaxBreadcrumbs",[210,1515,1516],{},[49,1517,1460],{},[210,1519,1520],{},[49,1521,1484],{},[210,1523,1524],{},"Breadcrumb ring buffer size (0-200)",[192,1526,1527,1532,1537,1539],{},[210,1528,1529],{},[49,1530,1531],{},"Events",[210,1533,1534],{},[49,1535,1536],{},"EventDefinitionBuilder",[210,1538,1377],{},[210,1540,1541],{},"Builder for registering known events",[192,1543,1544,1549,1554,1559],{},[210,1545,1546],{},[49,1547,1548],{},"Logger",[210,1550,1551],{},[49,1552,1553],{},"ILogger?",[210,1555,1556],{},[49,1557,1558],{},"null",[210,1560,1561],{},"Optional logger for SDK diagnostics",[18,1563,1565],{"id":1564},"identifying-users","Identifying Users",[14,1567,1568],{},"Before tracking events or sessions, identify the current actor (user or device):",[54,1570,1572],{"className":694,"code":1571,"language":696,"meta":59,"style":59},"tracker.Identify(\"user-123\");\n",[49,1573,1574],{"__ignoreMap":59},[63,1575,1576,1578,1580,1582,1584],{"class":65,"line":66},[63,1577,890],{"class":703},[63,1579,893],{"class":69},[63,1581,710],{"class":703},[63,1583,898],{"class":77},[63,1585,901],{"class":703},[14,1587,1588,1589,391,1591,1593,1594,1597],{},"Actor IDs can be up to 512 characters. Once identified, all subsequent ",[49,1590,930],{},[49,1592,908],{},", and ",[49,1595,1596],{},"TrackException"," calls use this actor. You can also pass an explicit actor ID to any tracking method.",[18,1599,1601],{"id":1600},"tracking-events","Tracking Events",[14,1603,1604,1605,1607,1608,1610],{},"Events are organized by ",[28,1606,292],{}," and ",[28,1609,298],{},", with optional properties.",[266,1612,1614],{"id":1613},"basic-event","Basic Event",[54,1616,1618],{"className":694,"code":1617,"language":696,"meta":59,"style":59},"tracker.Track(\"ui\", \"button_clicked\", new\n{\n    button_name = \"export\",\n    screen = \"dashboard\"\n});\n",[49,1619,1620,1640,1644,1656,1666],{"__ignoreMap":59},[63,1621,1622,1624,1626,1628,1631,1633,1636,1638],{"class":65,"line":66},[63,1623,890],{"class":703},[63,1625,930],{"class":69},[63,1627,710],{"class":703},[63,1629,1630],{"class":77},"\"ui\"",[63,1632,391],{"class":703},[63,1634,1635],{"class":77},"\"button_clicked\"",[63,1637,391],{"class":703},[63,1639,945],{"class":716},[63,1641,1642],{"class":65,"line":87},[63,1643,722],{"class":703},[63,1645,1646,1649,1651,1654],{"class":65,"line":98},[63,1647,1648],{"class":703},"    button_name ",[63,1650,730],{"class":716},[63,1652,1653],{"class":77}," \"export\"",[63,1655,962],{"class":703},[63,1657,1658,1661,1663],{"class":65,"line":108},[63,1659,1660],{"class":703},"    screen ",[63,1662,730],{"class":716},[63,1664,1665],{"class":77}," \"dashboard\"\n",[63,1667,1668],{"class":65,"line":117},[63,1669,777],{"class":703},[266,1671,1673],{"id":1672},"with-explicit-actor","With Explicit Actor",[54,1675,1677],{"className":694,"code":1676,"language":696,"meta":59,"style":59},"tracker.Track(\"reports\", \"report_exported\", \"user-456\", new\n{\n    format = \"pdf\",\n    row_count = 1500\n});\n",[49,1678,1679,1702,1706,1716,1724],{"__ignoreMap":59},[63,1680,1681,1683,1685,1687,1689,1691,1693,1695,1698,1700],{"class":65,"line":66},[63,1682,890],{"class":703},[63,1684,930],{"class":69},[63,1686,710],{"class":703},[63,1688,935],{"class":77},[63,1690,391],{"class":703},[63,1692,940],{"class":77},[63,1694,391],{"class":703},[63,1696,1697],{"class":77},"\"user-456\"",[63,1699,391],{"class":703},[63,1701,945],{"class":716},[63,1703,1704],{"class":65,"line":87},[63,1705,722],{"class":703},[63,1707,1708,1710,1712,1714],{"class":65,"line":98},[63,1709,954],{"class":703},[63,1711,730],{"class":716},[63,1713,959],{"class":77},[63,1715,962],{"class":703},[63,1717,1718,1720,1722],{"class":65,"line":108},[63,1719,967],{"class":703},[63,1721,730],{"class":716},[63,1723,972],{"class":73},[63,1725,1726],{"class":65,"line":117},[63,1727,777],{"class":703},[266,1729,1731],{"id":1730},"event-limits","Event Limits",[279,1733,1734,1737,1740],{},[282,1735,1736],{},"Category: max 128 characters",[282,1738,1739],{},"Name: max 256 characters",[282,1741,1742],{},"Actor ID: max 512 characters",[18,1744,1746],{"id":1745},"session-management","Session Management",[14,1748,1749],{},"Sessions group related events and track duration.",[54,1751,1753],{"className":694,"code":1752,"language":696,"meta":59,"style":59},"\u002F\u002F Start a session (uses the identified actor)\ntracker.StartSession();\n\n\u002F\u002F Or start with an explicit actor ID\ntracker.StartSession(\"user-123\");\n\n\u002F\u002F End the current session\ntracker.EndSession();\n",[49,1754,1755,1761,1769,1774,1779,1791,1795,1800],{"__ignoreMap":59},[63,1756,1757],{"class":65,"line":66},[63,1758,1760],{"class":1759},"sAwPA","\u002F\u002F Start a session (uses the identified actor)\n",[63,1762,1763,1765,1767],{"class":65,"line":87},[63,1764,890],{"class":703},[63,1766,908],{"class":69},[63,1768,911],{"class":703},[63,1770,1771],{"class":65,"line":98},[63,1772,1773],{"emptyLinePlaceholder":571},"\n",[63,1775,1776],{"class":65,"line":108},[63,1777,1778],{"class":1759},"\u002F\u002F Or start with an explicit actor ID\n",[63,1780,1781,1783,1785,1787,1789],{"class":65,"line":117},[63,1782,890],{"class":703},[63,1784,908],{"class":69},[63,1786,710],{"class":703},[63,1788,898],{"class":77},[63,1790,901],{"class":703},[63,1792,1793],{"class":65,"line":123},[63,1794,1773],{"emptyLinePlaceholder":571},[63,1796,1797],{"class":65,"line":129},[63,1798,1799],{"class":1759},"\u002F\u002F End the current session\n",[63,1801,1802,1804,1807],{"class":65,"line":135},[63,1803,890],{"class":703},[63,1805,1806],{"class":69},"EndSession",[63,1808,911],{"class":703},[18,1810,1812],{"id":1811},"exception-tracking","Exception Tracking",[14,1814,1815],{},"Track handled or unhandled exceptions with full stack traces. Beacon automatically fingerprints exceptions by type and stack trace for grouping.",[54,1817,1819],{"className":694,"code":1818,"language":696,"meta":59,"style":59},"try\n{\n    ProcessOrder(order);\n}\ncatch (Exception ex)\n{\n    tracker.TrackException(ex, ExceptionSeverity.NonFatal);\n    throw;\n}\n",[49,1820,1821,1826,1830,1838,1843,1859,1863,1873,1880],{"__ignoreMap":59},[63,1822,1823],{"class":65,"line":66},[63,1824,1825],{"class":716},"try\n",[63,1827,1828],{"class":65,"line":87},[63,1829,722],{"class":703},[63,1831,1832,1835],{"class":65,"line":98},[63,1833,1834],{"class":69},"    ProcessOrder",[63,1836,1837],{"class":703},"(order);\n",[63,1839,1840],{"class":65,"line":108},[63,1841,1842],{"class":703},"}\n",[63,1844,1845,1848,1850,1853,1856],{"class":65,"line":117},[63,1846,1847],{"class":716},"catch",[63,1849,440],{"class":703},[63,1851,1852],{"class":69},"Exception",[63,1854,1855],{"class":69}," ex",[63,1857,1858],{"class":703},")\n",[63,1860,1861],{"class":65,"line":123},[63,1862,722],{"class":703},[63,1864,1865,1868,1870],{"class":65,"line":129},[63,1866,1867],{"class":703},"    tracker.",[63,1869,1596],{"class":69},[63,1871,1872],{"class":703},"(ex, ExceptionSeverity.NonFatal);\n",[63,1874,1875,1878],{"class":65,"line":135},[63,1876,1877],{"class":716},"    throw",[63,1879,736],{"class":703},[63,1881,1882],{"class":65,"line":141},[63,1883,1842],{"class":703},[14,1885,1886,1887,1607,1890,1893],{},"Severity options are ",[49,1888,1889],{},"ExceptionSeverity.Fatal",[49,1891,1892],{},"ExceptionSeverity.NonFatal",". Recent tracking calls are automatically attached as breadcrumbs to provide context.",[18,1895,1896],{"id":472},"Breadcrumbs",[14,1898,1899,1900,1902],{},"The SDK maintains a circular ring buffer of recent ",[49,1901,930],{}," calls. When an exception is reported, these breadcrumbs are attached automatically, giving you a timeline of what happened before the error.",[14,1904,1905,1906,1908],{},"Configure the buffer size with ",[49,1907,1513],{}," (default 25, max 200). Set to 0 to disable.",[18,1910,1912],{"id":1911},"flushing-events","Flushing Events",[14,1914,1915,1916,1918,1919,1921],{},"Events are batched and sent on a timer (",[49,1917,1455],{},") or when the batch reaches ",[49,1920,1475],{},". To flush manually:",[54,1923,1925],{"className":694,"code":1924,"language":696,"meta":59,"style":59},"await tracker.FlushAsync();\n",[49,1926,1927],{"__ignoreMap":59},[63,1928,1929,1932,1935,1938],{"class":65,"line":66},[63,1930,1931],{"class":716},"await",[63,1933,1934],{"class":703}," tracker.",[63,1936,1937],{"class":69},"FlushAsync",[63,1939,911],{"class":703},[14,1941,1942],{},"Check the last flush result:",[54,1944,1946],{"className":694,"code":1945,"language":696,"meta":59,"style":59},"FlushStatus status = tracker.LastFlushStatus;\n",[49,1947,1948],{"__ignoreMap":59},[63,1949,1950,1953,1956,1958],{"class":65,"line":66},[63,1951,1952],{"class":69},"FlushStatus",[63,1954,1955],{"class":69}," status",[63,1957,796],{"class":716},[63,1959,1960],{"class":703}," tracker.LastFlushStatus;\n",[18,1962,1964],{"id":1963},"offline-persistence","Offline Persistence",[14,1966,1967,1968,1971],{},"The SDK queues events in a local SQLite database at ",[49,1969,1970],{},"%LOCALAPPDATA%\\SoftAgility\\Beacon\\{AppName}\\queue.db",". Events persist across application restarts and sync automatically when connectivity returns.",[279,1973,1974,1979,1982],{},[282,1975,1976,1977,604],{},"FIFO queue with configurable maximum size (",[49,1978,1494],{},[282,1980,1981],{},"No data is lost during transient network failures",[282,1983,1984],{},"Background timer handles automatic flushing",[18,1986,1988],{"id":1987},"event-manifest","Event Manifest",[14,1990,1991],{},"Export a JSON manifest of your registered events for import into the Beacon portal's allowlist page:",[54,1993,1995],{"className":694,"code":1994,"language":696,"meta":59,"style":59},"tracker.ExportEventManifest(\"events.json\");\n",[49,1996,1997],{"__ignoreMap":59},[63,1998,1999,2001,2004,2006,2009],{"class":65,"line":66},[63,2000,890],{"class":703},[63,2002,2003],{"class":69},"ExportEventManifest",[63,2005,710],{"class":703},[63,2007,2008],{"class":77},"\"events.json\"",[63,2010,901],{"class":703},[18,2012,2014],{"id":2013},"thread-safety","Thread Safety",[14,2016,2017,2019],{},[49,2018,1268],{}," is fully thread-safe. A single instance can be shared across your application and called from any thread.",[18,2021,2023],{"id":2022},"disposal","Disposal",[14,2025,2026,2028,2029,1607,2032,2035],{},[49,2027,1268],{}," implements both ",[49,2030,2031],{},"IDisposable",[49,2033,2034],{},"IAsyncDisposable",". Dispose when your application shuts down to flush pending events:",[54,2037,2039],{"className":694,"code":2038,"language":696,"meta":59,"style":59},"tracker.Dispose();\n\u002F\u002F or\nawait tracker.DisposeAsync();\n",[49,2040,2041,2050,2055],{"__ignoreMap":59},[63,2042,2043,2045,2048],{"class":65,"line":66},[63,2044,890],{"class":703},[63,2046,2047],{"class":69},"Dispose",[63,2049,911],{"class":703},[63,2051,2052],{"class":65,"line":87},[63,2053,2054],{"class":1759},"\u002F\u002F or\n",[63,2056,2057,2059,2061,2064],{"class":65,"line":98},[63,2058,1931],{"class":716},[63,2060,1934],{"class":703},[63,2062,2063],{"class":69},"DisposeAsync",[63,2065,911],{"class":703},[18,2067,2069],{"id":2068},"wpf-example","WPF Example",[54,2071,2073],{"className":694,"code":2072,"language":696,"meta":59,"style":59},"public partial class App : Application\n{\n    private IBeaconTracker _tracker;\n\n    protected override void OnStartup(StartupEventArgs e)\n    {\n        base.OnStartup(e);\n\n        _tracker = BeaconTracker.Configure(options =>\n        {\n            options.ApiKey = \"your-api-key\";\n            options.ApiBaseUrl = \"https:\u002F\u002Fapi.beacon.softagility.com\";\n            options.AppName = \"MyDesktopApp\";\n            options.AppVersion = \"2.1.0\";\n        });\n\n        _tracker.Identify(\"device-\" + Environment.MachineName);\n        _tracker.StartSession();\n    }\n\n    protected override void OnExit(ExitEventArgs e)\n    {\n        _tracker.EndSession();\n        _tracker.Dispose();\n        base.OnExit(e);\n    }\n}\n",[49,2074,2075,2095,2099,2112,2116,2140,2145,2159,2163,2180,2185,2196,2207,2219,2232,2238,2243,2262,2271,2277,2281,2302,2307,2316,2325,2337,2342],{"__ignoreMap":59},[63,2076,2077,2080,2083,2086,2089,2092],{"class":65,"line":66},[63,2078,2079],{"class":716},"public",[63,2081,2082],{"class":716}," partial",[63,2084,2085],{"class":716}," class",[63,2087,2088],{"class":69}," App",[63,2090,2091],{"class":703}," : ",[63,2093,2094],{"class":69},"Application\n",[63,2096,2097],{"class":65,"line":87},[63,2098,722],{"class":703},[63,2100,2101,2104,2107,2110],{"class":65,"line":98},[63,2102,2103],{"class":716},"    private",[63,2105,2106],{"class":69}," IBeaconTracker",[63,2108,2109],{"class":69}," _tracker",[63,2111,736],{"class":703},[63,2113,2114],{"class":65,"line":108},[63,2115,1773],{"emptyLinePlaceholder":571},[63,2117,2118,2121,2124,2127,2130,2132,2135,2138],{"class":65,"line":117},[63,2119,2120],{"class":716},"    protected",[63,2122,2123],{"class":716}," override",[63,2125,2126],{"class":716}," void",[63,2128,2129],{"class":69}," OnStartup",[63,2131,710],{"class":703},[63,2133,2134],{"class":69},"StartupEventArgs",[63,2136,2137],{"class":69}," e",[63,2139,1858],{"class":703},[63,2141,2142],{"class":65,"line":123},[63,2143,2144],{"class":703},"    {\n",[63,2146,2147,2150,2153,2156],{"class":65,"line":129},[63,2148,2149],{"class":73},"        base",[63,2151,2152],{"class":703},".",[63,2154,2155],{"class":69},"OnStartup",[63,2157,2158],{"class":703},"(e);\n",[63,2160,2161],{"class":65,"line":135},[63,2162,1773],{"emptyLinePlaceholder":571},[63,2164,2165,2168,2170,2172,2174,2176,2178],{"class":65,"line":141},[63,2166,2167],{"class":703},"        _tracker ",[63,2169,730],{"class":716},[63,2171,799],{"class":703},[63,2173,802],{"class":69},[63,2175,710],{"class":703},[63,2177,713],{"class":69},[63,2179,717],{"class":716},[63,2181,2182],{"class":65,"line":147},[63,2183,2184],{"class":703},"        {\n",[63,2186,2187,2190,2192,2194],{"class":65,"line":153},[63,2188,2189],{"class":703},"            options.ApiKey ",[63,2191,730],{"class":716},[63,2193,733],{"class":77},[63,2195,736],{"class":703},[63,2197,2198,2201,2203,2205],{"class":65,"line":159},[63,2199,2200],{"class":703},"            options.ApiBaseUrl ",[63,2202,730],{"class":716},[63,2204,746],{"class":77},[63,2206,736],{"class":703},[63,2208,2209,2212,2214,2217],{"class":65,"line":165},[63,2210,2211],{"class":703},"            options.AppName ",[63,2213,730],{"class":716},[63,2215,2216],{"class":77}," \"MyDesktopApp\"",[63,2218,736],{"class":703},[63,2220,2222,2225,2227,2230],{"class":65,"line":2221},14,[63,2223,2224],{"class":703},"            options.AppVersion ",[63,2226,730],{"class":716},[63,2228,2229],{"class":77}," \"2.1.0\"",[63,2231,736],{"class":703},[63,2233,2235],{"class":65,"line":2234},15,[63,2236,2237],{"class":703},"        });\n",[63,2239,2241],{"class":65,"line":2240},16,[63,2242,1773],{"emptyLinePlaceholder":571},[63,2244,2246,2249,2251,2253,2256,2259],{"class":65,"line":2245},17,[63,2247,2248],{"class":703},"        _tracker.",[63,2250,893],{"class":69},[63,2252,710],{"class":703},[63,2254,2255],{"class":77},"\"device-\"",[63,2257,2258],{"class":716}," +",[63,2260,2261],{"class":703}," Environment.MachineName);\n",[63,2263,2265,2267,2269],{"class":65,"line":2264},18,[63,2266,2248],{"class":703},[63,2268,908],{"class":69},[63,2270,911],{"class":703},[63,2272,2274],{"class":65,"line":2273},19,[63,2275,2276],{"class":703},"    }\n",[63,2278,2279],{"class":65,"line":572},[63,2280,1773],{"emptyLinePlaceholder":571},[63,2282,2284,2286,2288,2290,2293,2295,2298,2300],{"class":65,"line":2283},21,[63,2285,2120],{"class":716},[63,2287,2123],{"class":716},[63,2289,2126],{"class":716},[63,2291,2292],{"class":69}," OnExit",[63,2294,710],{"class":703},[63,2296,2297],{"class":69},"ExitEventArgs",[63,2299,2137],{"class":69},[63,2301,1858],{"class":703},[63,2303,2305],{"class":65,"line":2304},22,[63,2306,2144],{"class":703},[63,2308,2310,2312,2314],{"class":65,"line":2309},23,[63,2311,2248],{"class":703},[63,2313,1806],{"class":69},[63,2315,911],{"class":703},[63,2317,2319,2321,2323],{"class":65,"line":2318},24,[63,2320,2248],{"class":703},[63,2322,2047],{"class":69},[63,2324,911],{"class":703},[63,2326,2328,2330,2332,2335],{"class":65,"line":2327},25,[63,2329,2149],{"class":73},[63,2331,2152],{"class":703},[63,2333,2334],{"class":69},"OnExit",[63,2336,2158],{"class":703},[63,2338,2340],{"class":65,"line":2339},26,[63,2341,2276],{"class":703},[63,2343,2345],{"class":65,"line":2344},27,[63,2346,1842],{"class":703},[18,2348,1058],{"id":1057},[279,2350,2351,2356,2361],{},[282,2352,2353,2355],{},[31,2354,581],{"href":1103}," for a general overview",[282,2357,2358,2360],{},[31,2359,5],{"href":573}," for direct HTTP integration",[282,2362,2363,1084],{},[31,2364,2365],{"href":1082},"Pricing",[551,2367,2368],{},"html pre.shiki code .svObZ, html code.shiki .svObZ{--shiki-default:#B392F0}html pre.shiki code .sU2Wk, html code.shiki .sU2Wk{--shiki-default:#9ECBFF}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html pre.shiki code .s95oV, html code.shiki .s95oV{--shiki-default:#E1E4E8}html pre.shiki code .snl16, html code.shiki .snl16{--shiki-default:#F97583}html pre.shiki code .sDLfK, html code.shiki .sDLfK{--shiki-default:#79B8FF}html pre.shiki code .sAwPA, html code.shiki .sAwPA{--shiki-default:#6A737D}",{"title":59,"searchDepth":87,"depth":87,"links":2370},[2371,2374,2379,2380,2385,2386,2387,2388,2389,2390,2391,2392,2393,2394],{"id":1121,"depth":87,"text":1122,"children":2372},[2373],{"id":1164,"depth":98,"text":1165},{"id":1179,"depth":87,"text":1180,"children":2375},[2376,2377,2378],{"id":1183,"depth":98,"text":1184},{"id":1258,"depth":98,"text":1259},{"id":1342,"depth":98,"text":1343},{"id":1564,"depth":87,"text":1565},{"id":1600,"depth":87,"text":1601,"children":2381},[2382,2383,2384],{"id":1613,"depth":98,"text":1614},{"id":1672,"depth":98,"text":1673},{"id":1730,"depth":98,"text":1731},{"id":1745,"depth":87,"text":1746},{"id":1811,"depth":87,"text":1812},{"id":472,"depth":87,"text":1896},{"id":1911,"depth":87,"text":1912},{"id":1963,"depth":87,"text":1964},{"id":1987,"depth":87,"text":1988},{"id":2013,"depth":87,"text":2014},{"id":2022,"depth":87,"text":2023},{"id":2068,"depth":87,"text":2069},{"id":1057,"depth":87,"text":1058},"Integrate Beacon product analytics into .NET desktop, server, and cloud applications.",{},{"title":537,"description":2395},"beacon\u002Fdocs\u002Fsdk\u002Fdotnet","Dx55dovfMBMMODJsAcTeP63T1EDDDcqAHgyw7fpnspw",{"id":2401,"title":543,"body":2402,"description":3229,"extension":569,"meta":3230,"navigation":571,"order":153,"path":542,"published":571,"section":526,"seo":3231,"stem":3232,"__hash__":3233},"beaconDocs\u002Fbeacon\u002Fdocs\u002Fsdk\u002Fcpp.md",{"type":7,"value":2403,"toc":3206},[2404,2408,2411,2413,2417,2423,2473,2477,2529,2532,2534,2548,2550,2646,2653,2692,2694,2878,2880,2883,2892,2895,2897,2903,2905,2929,2931,2955,2957,2997,2999,3006,3051,3060,3062,3065,3074,3076,3085,3087,3090,3101,3105,3112,3121,3128,3130,3136,3140,3147,3187,3189,3203],[10,2405,2407],{"id":2406},"beacon-c-sdk","Beacon C++ SDK",[14,2409,2410],{},"The Beacon C++ SDK provides native integration for Windows desktop applications, server processes, and cross-platform C++ projects.",[18,2412,1122],{"id":1121},[266,2414,2416],{"id":2415},"cmake-fetchcontent-recommended","CMake FetchContent (recommended)",[14,2418,2419,2420,1191],{},"Add Beacon to your ",[49,2421,2422],{},"CMakeLists.txt",[54,2424,2428],{"className":2425,"code":2426,"language":2427,"meta":59,"style":59},"language-cmake shiki shiki-themes github-dark","include(FetchContent)\nFetchContent_Declare(\n  beacon_sdk\n  GIT_REPOSITORY https:\u002F\u002Fgithub.com\u002Fsoftagility\u002Fbeacon-sdk-cpp.git\n  GIT_TAG        v1.0.0\n)\nFetchContent_MakeAvailable(beacon_sdk)\n\ntarget_link_libraries(your_app PRIVATE beacon_sdk)\n","cmake",[49,2429,2430,2435,2440,2445,2450,2455,2459,2464,2468],{"__ignoreMap":59},[63,2431,2432],{"class":65,"line":66},[63,2433,2434],{},"include(FetchContent)\n",[63,2436,2437],{"class":65,"line":87},[63,2438,2439],{},"FetchContent_Declare(\n",[63,2441,2442],{"class":65,"line":98},[63,2443,2444],{},"  beacon_sdk\n",[63,2446,2447],{"class":65,"line":108},[63,2448,2449],{},"  GIT_REPOSITORY https:\u002F\u002Fgithub.com\u002Fsoftagility\u002Fbeacon-sdk-cpp.git\n",[63,2451,2452],{"class":65,"line":117},[63,2453,2454],{},"  GIT_TAG        v1.0.0\n",[63,2456,2457],{"class":65,"line":123},[63,2458,1858],{},[63,2460,2461],{"class":65,"line":129},[63,2462,2463],{},"FetchContent_MakeAvailable(beacon_sdk)\n",[63,2465,2466],{"class":65,"line":135},[63,2467,1773],{"emptyLinePlaceholder":571},[63,2469,2470],{"class":65,"line":141},[63,2471,2472],{},"target_link_libraries(your_app PRIVATE beacon_sdk)\n",[266,2474,2476],{"id":2475},"build-from-source","Build from Source",[54,2478,2480],{"className":56,"code":2479,"language":58,"meta":59,"style":59},"git clone https:\u002F\u002Fgithub.com\u002Fsoftagility\u002Fbeacon-sdk-cpp.git\ncd beacon-sdk-cpp\ncmake -B build -DCMAKE_BUILD_TYPE=Release\ncmake --build build --config Release\n",[49,2481,2482,2493,2501,2514],{"__ignoreMap":59},[63,2483,2484,2487,2490],{"class":65,"line":66},[63,2485,2486],{"class":69},"git",[63,2488,2489],{"class":77}," clone",[63,2491,2492],{"class":77}," https:\u002F\u002Fgithub.com\u002Fsoftagility\u002Fbeacon-sdk-cpp.git\n",[63,2494,2495,2498],{"class":65,"line":87},[63,2496,2497],{"class":73},"cd",[63,2499,2500],{"class":77}," beacon-sdk-cpp\n",[63,2502,2503,2505,2508,2511],{"class":65,"line":98},[63,2504,2427],{"class":69},[63,2506,2507],{"class":73}," -B",[63,2509,2510],{"class":77}," build",[63,2512,2513],{"class":73}," -DCMAKE_BUILD_TYPE=Release\n",[63,2515,2516,2518,2521,2523,2526],{"class":65,"line":108},[63,2517,2427],{"class":69},[63,2519,2520],{"class":73}," --build",[63,2522,2510],{"class":77},[63,2524,2525],{"class":73}," --config",[63,2527,2528],{"class":77}," Release\n",[14,2530,2531],{},"Dependencies (libcurl, nlohmann_json, SQLite3) are fetched automatically via CMake FetchContent if not found on the system.",[266,2533,1165],{"id":1164},[279,2535,2536,2539,2542,2545],{},[282,2537,2538],{},"C++17 or later",[282,2540,2541],{},"Windows 10+, Linux (glibc 2.28+), or macOS 12+",[282,2543,2544],{},"CMake 3.25+",[282,2546,2547],{},"Dependencies resolved automatically (libcurl, nlohmann_json, SQLite3)",[18,2549,1180],{"id":1179},[54,2551,2555],{"className":2552,"code":2553,"language":2554,"meta":59,"style":59},"language-cpp shiki shiki-themes github-dark","#include \u003Cbeacon\u002Fbeacon.hpp>\n\nint main()\n{\n    auto tracker = beacon::Tracker::configure([](beacon::Options& opts) {\n        opts.api_key = \"your-api-key\";\n        opts.api_base_url = \"https:\u002F\u002Fapi.beacon.softagility.com\";\n        opts.app_name = \"MyApp\";\n        opts.app_version = \"1.2.0\";\n    });\n\n    tracker->identify(\"user-123\");\n    tracker->startSession();\n\n    \u002F\u002F Your application code here...\n\n    tracker->endSession();\n    return 0;\n}\n","cpp",[49,2556,2557,2562,2566,2571,2575,2580,2585,2590,2595,2600,2605,2609,2614,2619,2623,2628,2632,2637,2642],{"__ignoreMap":59},[63,2558,2559],{"class":65,"line":66},[63,2560,2561],{},"#include \u003Cbeacon\u002Fbeacon.hpp>\n",[63,2563,2564],{"class":65,"line":87},[63,2565,1773],{"emptyLinePlaceholder":571},[63,2567,2568],{"class":65,"line":98},[63,2569,2570],{},"int main()\n",[63,2572,2573],{"class":65,"line":108},[63,2574,722],{},[63,2576,2577],{"class":65,"line":117},[63,2578,2579],{},"    auto tracker = beacon::Tracker::configure([](beacon::Options& opts) {\n",[63,2581,2582],{"class":65,"line":123},[63,2583,2584],{},"        opts.api_key = \"your-api-key\";\n",[63,2586,2587],{"class":65,"line":129},[63,2588,2589],{},"        opts.api_base_url = \"https:\u002F\u002Fapi.beacon.softagility.com\";\n",[63,2591,2592],{"class":65,"line":135},[63,2593,2594],{},"        opts.app_name = \"MyApp\";\n",[63,2596,2597],{"class":65,"line":141},[63,2598,2599],{},"        opts.app_version = \"1.2.0\";\n",[63,2601,2602],{"class":65,"line":147},[63,2603,2604],{},"    });\n",[63,2606,2607],{"class":65,"line":153},[63,2608,1773],{"emptyLinePlaceholder":571},[63,2610,2611],{"class":65,"line":159},[63,2612,2613],{},"    tracker->identify(\"user-123\");\n",[63,2615,2616],{"class":65,"line":165},[63,2617,2618],{},"    tracker->startSession();\n",[63,2620,2621],{"class":65,"line":2221},[63,2622,1773],{"emptyLinePlaceholder":571},[63,2624,2625],{"class":65,"line":2234},[63,2626,2627],{},"    \u002F\u002F Your application code here...\n",[63,2629,2630],{"class":65,"line":2240},[63,2631,1773],{"emptyLinePlaceholder":571},[63,2633,2634],{"class":65,"line":2245},[63,2635,2636],{},"    tracker->endSession();\n",[63,2638,2639],{"class":65,"line":2264},[63,2640,2641],{},"    return 0;\n",[63,2643,2644],{"class":65,"line":2273},[63,2645,1842],{},[14,2647,2648,2649,2652],{},"You can also pass an ",[49,2650,2651],{},"Options"," struct directly:",[54,2654,2656],{"className":2552,"code":2655,"language":2554,"meta":59,"style":59},"beacon::Options opts;\nopts.api_key = \"your-api-key\";\nopts.api_base_url = \"https:\u002F\u002Fapi.beacon.softagility.com\";\nopts.app_name = \"MyApp\";\nopts.app_version = \"1.2.0\";\n\nauto tracker = beacon::Tracker::configure(opts);\n",[49,2657,2658,2663,2668,2673,2678,2683,2687],{"__ignoreMap":59},[63,2659,2660],{"class":65,"line":66},[63,2661,2662],{},"beacon::Options opts;\n",[63,2664,2665],{"class":65,"line":87},[63,2666,2667],{},"opts.api_key = \"your-api-key\";\n",[63,2669,2670],{"class":65,"line":98},[63,2671,2672],{},"opts.api_base_url = \"https:\u002F\u002Fapi.beacon.softagility.com\";\n",[63,2674,2675],{"class":65,"line":108},[63,2676,2677],{},"opts.app_name = \"MyApp\";\n",[63,2679,2680],{"class":65,"line":117},[63,2681,2682],{},"opts.app_version = \"1.2.0\";\n",[63,2684,2685],{"class":65,"line":123},[63,2686,1773],{"emptyLinePlaceholder":571},[63,2688,2689],{"class":65,"line":129},[63,2690,2691],{},"auto tracker = beacon::Tracker::configure(opts);\n",[266,2693,1343],{"id":1342},[186,2695,2696,2708],{},[189,2697,2698],{},[192,2699,2700,2702,2704,2706],{},[195,2701,1352],{},[195,2703,1355],{},[195,2705,1358],{},[195,2707,203],{},[205,2709,2710,2726,2741,2757,2773,2790,2808,2825,2842,2859],{},[192,2711,2712,2717,2722,2724],{},[210,2713,2714],{},[49,2715,2716],{},"api_key",[210,2718,2719],{},[49,2720,2721],{},"std::string",[210,2723,1377],{},[210,2725,1380],{},[192,2727,2728,2733,2737,2739],{},[210,2729,2730],{},[49,2731,2732],{},"api_base_url",[210,2734,2735],{},[49,2736,2721],{},[210,2738,1377],{},[210,2740,1396],{},[192,2742,2743,2748,2752,2754],{},[210,2744,2745],{},[49,2746,2747],{},"app_name",[210,2749,2750],{},[49,2751,2721],{},[210,2753,1377],{},[210,2755,2756],{},"Your application name (required)",[192,2758,2759,2764,2768,2770],{},[210,2760,2761],{},[49,2762,2763],{},"app_version",[210,2765,2766],{},[49,2767,2721],{},[210,2769,1377],{},[210,2771,2772],{},"Your application version (required)",[192,2774,2775,2780,2784,2788],{},[210,2776,2777],{},[49,2778,2779],{},"enabled",[210,2781,2782],{},[49,2783,1440],{},[210,2785,2786],{},[49,2787,1445],{},[210,2789,1448],{},[192,2791,2792,2797,2801,2805],{},[210,2793,2794],{},[49,2795,2796],{},"flush_interval_seconds",[210,2798,2799],{},[49,2800,1460],{},[210,2802,2803],{},[49,2804,1465],{},[210,2806,2807],{},"Batch send interval in seconds (1-3600)",[192,2809,2810,2815,2819,2823],{},[210,2811,2812],{},[49,2813,2814],{},"max_batch_size",[210,2816,2817],{},[49,2818,1460],{},[210,2820,2821],{},[49,2822,1484],{},[210,2824,1487],{},[192,2826,2827,2832,2836,2840],{},[210,2828,2829],{},[49,2830,2831],{},"max_queue_size_mb",[210,2833,2834],{},[49,2835,1460],{},[210,2837,2838],{},[49,2839,1503],{},[210,2841,1506],{},[192,2843,2844,2849,2853,2857],{},[210,2845,2846],{},[49,2847,2848],{},"max_breadcrumbs",[210,2850,2851],{},[49,2852,1460],{},[210,2854,2855],{},[49,2856,1484],{},[210,2858,1524],{},[192,2860,2861,2866,2871,2876],{},[210,2862,2863],{},[49,2864,2865],{},"logger",[210,2867,2868],{},[49,2869,2870],{},"std::shared_ptr\u003CILogger>",[210,2872,2873],{},[49,2874,2875],{},"nullptr",[210,2877,1561],{},[18,2879,1565],{"id":1564},[14,2881,2882],{},"Before tracking events or sessions, identify the current actor:",[54,2884,2886],{"className":2552,"code":2885,"language":2554,"meta":59,"style":59},"tracker->identify(\"user-123\");\n",[49,2887,2888],{"__ignoreMap":59},[63,2889,2890],{"class":65,"line":66},[63,2891,2885],{},[14,2893,2894],{},"Once identified, all subsequent calls use this actor. You can also pass an explicit actor ID to tracking methods.",[18,2896,1601],{"id":1600},[14,2898,1604,2899,1607,2901,1610],{},[28,2900,292],{},[28,2902,298],{},[266,2904,1614],{"id":1613},[54,2906,2908],{"className":2552,"code":2907,"language":2554,"meta":59,"style":59},"tracker->track(\"ui\", \"button_clicked\", {\n    {\"button_name\", \"export\"},\n    {\"screen\", \"dashboard\"}\n});\n",[49,2909,2910,2915,2920,2925],{"__ignoreMap":59},[63,2911,2912],{"class":65,"line":66},[63,2913,2914],{},"tracker->track(\"ui\", \"button_clicked\", {\n",[63,2916,2917],{"class":65,"line":87},[63,2918,2919],{},"    {\"button_name\", \"export\"},\n",[63,2921,2922],{"class":65,"line":98},[63,2923,2924],{},"    {\"screen\", \"dashboard\"}\n",[63,2926,2927],{"class":65,"line":108},[63,2928,777],{},[266,2930,1673],{"id":1672},[54,2932,2934],{"className":2552,"code":2933,"language":2554,"meta":59,"style":59},"tracker->track(\"reports\", \"report_exported\", \"user-456\", {\n    {\"format\", \"pdf\"},\n    {\"row_count\", \"1500\"}\n});\n",[49,2935,2936,2941,2946,2951],{"__ignoreMap":59},[63,2937,2938],{"class":65,"line":66},[63,2939,2940],{},"tracker->track(\"reports\", \"report_exported\", \"user-456\", {\n",[63,2942,2943],{"class":65,"line":87},[63,2944,2945],{},"    {\"format\", \"pdf\"},\n",[63,2947,2948],{"class":65,"line":98},[63,2949,2950],{},"    {\"row_count\", \"1500\"}\n",[63,2952,2953],{"class":65,"line":108},[63,2954,777],{},[18,2956,1746],{"id":1745},[54,2958,2960],{"className":2552,"code":2959,"language":2554,"meta":59,"style":59},"\u002F\u002F Start a session (uses the identified actor)\ntracker->startSession();\n\n\u002F\u002F Or start with an explicit actor ID\ntracker->startSession(\"user-123\");\n\n\u002F\u002F End the current session\ntracker->endSession();\n",[49,2961,2962,2966,2971,2975,2979,2984,2988,2992],{"__ignoreMap":59},[63,2963,2964],{"class":65,"line":66},[63,2965,1760],{},[63,2967,2968],{"class":65,"line":87},[63,2969,2970],{},"tracker->startSession();\n",[63,2972,2973],{"class":65,"line":98},[63,2974,1773],{"emptyLinePlaceholder":571},[63,2976,2977],{"class":65,"line":108},[63,2978,1778],{},[63,2980,2981],{"class":65,"line":117},[63,2982,2983],{},"tracker->startSession(\"user-123\");\n",[63,2985,2986],{"class":65,"line":123},[63,2987,1773],{"emptyLinePlaceholder":571},[63,2989,2990],{"class":65,"line":129},[63,2991,1799],{},[63,2993,2994],{"class":65,"line":135},[63,2995,2996],{},"tracker->endSession();\n",[18,2998,1812],{"id":1811},[14,3000,3001,3002,3005],{},"Track exceptions with severity levels. Breadcrumbs from recent ",[49,3003,3004],{},"track()"," calls are attached automatically.",[54,3007,3009],{"className":2552,"code":3008,"language":2554,"meta":59,"style":59},"try\n{\n    process_order(order);\n}\ncatch (const std::exception& ex)\n{\n    tracker->trackException(ex, beacon::ExceptionSeverity::NonFatal);\n    throw;\n}\n",[49,3010,3011,3015,3019,3024,3028,3033,3037,3042,3047],{"__ignoreMap":59},[63,3012,3013],{"class":65,"line":66},[63,3014,1825],{},[63,3016,3017],{"class":65,"line":87},[63,3018,722],{},[63,3020,3021],{"class":65,"line":98},[63,3022,3023],{},"    process_order(order);\n",[63,3025,3026],{"class":65,"line":108},[63,3027,1842],{},[63,3029,3030],{"class":65,"line":117},[63,3031,3032],{},"catch (const std::exception& ex)\n",[63,3034,3035],{"class":65,"line":123},[63,3036,722],{},[63,3038,3039],{"class":65,"line":129},[63,3040,3041],{},"    tracker->trackException(ex, beacon::ExceptionSeverity::NonFatal);\n",[63,3043,3044],{"class":65,"line":135},[63,3045,3046],{},"    throw;\n",[63,3048,3049],{"class":65,"line":141},[63,3050,1842],{},[14,3052,3053,3054,1607,3057,2152],{},"Severity options: ",[49,3055,3056],{},"beacon::ExceptionSeverity::Fatal",[49,3058,3059],{},"beacon::ExceptionSeverity::NonFatal",[18,3061,1912],{"id":1911},[14,3063,3064],{},"Events are batched and sent on a timer or when the batch size is reached. To flush manually:",[54,3066,3068],{"className":2552,"code":3067,"language":2554,"meta":59,"style":59},"bool success = tracker->flush(); \u002F\u002F Blocks up to 30 seconds\n",[49,3069,3070],{"__ignoreMap":59},[63,3071,3072],{"class":65,"line":66},[63,3073,3067],{},[14,3075,1942],{},[54,3077,3079],{"className":2552,"code":3078,"language":2554,"meta":59,"style":59},"beacon::FlushStatus status = tracker->last_flush_status();\n",[49,3080,3081],{"__ignoreMap":59},[63,3082,3083],{"class":65,"line":66},[63,3084,3078],{},[18,3086,1964],{"id":1963},[14,3088,3089],{},"Events are persisted to a local SQLite database when the network is unavailable. The queue syncs automatically when connectivity returns.",[279,3091,3092,3095,3098],{},[282,3093,3094],{},"Persists across application restarts",[282,3096,3097],{},"Thread-safe queue with configurable size limit",[282,3099,3100],{},"Zero data loss during transient failures",[18,3102,3104],{"id":3103},"singleton-access","Singleton Access",[14,3106,3107,3108,3111],{},"After calling ",[49,3109,3110],{},"configure()",", retrieve the tracker instance anywhere with:",[54,3113,3115],{"className":2552,"code":3114,"language":2554,"meta":59,"style":59},"auto tracker = beacon::Tracker::instance();\n",[49,3116,3117],{"__ignoreMap":59},[63,3118,3119],{"class":65,"line":66},[63,3120,3114],{},[14,3122,3123,3124,3127],{},"Call ",[49,3125,3126],{},"beacon::Tracker::reset_for_testing()"," in test teardown to clear the singleton.",[18,3129,2014],{"id":2013},[14,3131,3132,3135],{},[49,3133,3134],{},"beacon::Tracker"," is fully thread-safe. Share a single instance across threads.",[18,3137,3139],{"id":3138},"raii-lifetime-management","RAII Lifetime Management",[14,3141,3142,3143,3146],{},"The SDK follows RAII conventions. When the ",[49,3144,3145],{},"Tracker"," shared_ptr reference count reaches zero, pending events are flushed and the active session is ended:",[54,3148,3150],{"className":2552,"code":3149,"language":2554,"meta":59,"style":59},"{\n    auto tracker = beacon::Tracker::configure(configurator);\n    tracker->identify(\"user-123\");\n    tracker->startSession();\n\n    \u002F\u002F Track events...\n\n} \u002F\u002F Session ended, events flushed, resources released\n",[49,3151,3152,3156,3161,3165,3169,3173,3178,3182],{"__ignoreMap":59},[63,3153,3154],{"class":65,"line":66},[63,3155,722],{},[63,3157,3158],{"class":65,"line":87},[63,3159,3160],{},"    auto tracker = beacon::Tracker::configure(configurator);\n",[63,3162,3163],{"class":65,"line":98},[63,3164,2613],{},[63,3166,3167],{"class":65,"line":108},[63,3168,2618],{},[63,3170,3171],{"class":65,"line":117},[63,3172,1773],{"emptyLinePlaceholder":571},[63,3174,3175],{"class":65,"line":123},[63,3176,3177],{},"    \u002F\u002F Track events...\n",[63,3179,3180],{"class":65,"line":129},[63,3181,1773],{"emptyLinePlaceholder":571},[63,3183,3184],{"class":65,"line":135},[63,3185,3186],{},"} \u002F\u002F Session ended, events flushed, resources released\n",[18,3188,1058],{"id":1057},[279,3190,3191,3195,3199],{},[282,3192,3193,2355],{},[31,3194,581],{"href":1103},[282,3196,3197,2360],{},[31,3198,5],{"href":573},[282,3200,3201,1084],{},[31,3202,2365],{"href":1082},[551,3204,3205],{},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html pre.shiki code .svObZ, html code.shiki .svObZ{--shiki-default:#B392F0}html pre.shiki code .sU2Wk, html code.shiki .sU2Wk{--shiki-default:#9ECBFF}html pre.shiki code .sDLfK, html code.shiki .sDLfK{--shiki-default:#79B8FF}",{"title":59,"searchDepth":87,"depth":87,"links":3207},[3208,3213,3216,3217,3221,3222,3223,3224,3225,3226,3227,3228],{"id":1121,"depth":87,"text":1122,"children":3209},[3210,3211,3212],{"id":2415,"depth":98,"text":2416},{"id":2475,"depth":98,"text":2476},{"id":1164,"depth":98,"text":1165},{"id":1179,"depth":87,"text":1180,"children":3214},[3215],{"id":1342,"depth":98,"text":1343},{"id":1564,"depth":87,"text":1565},{"id":1600,"depth":87,"text":1601,"children":3218},[3219,3220],{"id":1613,"depth":98,"text":1614},{"id":1672,"depth":98,"text":1673},{"id":1745,"depth":87,"text":1746},{"id":1811,"depth":87,"text":1812},{"id":1911,"depth":87,"text":1912},{"id":1963,"depth":87,"text":1964},{"id":3103,"depth":87,"text":3104},{"id":2013,"depth":87,"text":2014},{"id":3138,"depth":87,"text":3139},{"id":1057,"depth":87,"text":1058},"Integrate Beacon product analytics into native C++ desktop and server applications.",{},{"title":543,"description":3229},"beacon\u002Fdocs\u002Fsdk\u002Fcpp","pZH0WIjTkxZn0eF0NsqxxLOQdUawhjo3-7gg56ynH_U",{"id":3235,"title":3236,"body":3237,"description":4198,"extension":569,"meta":4199,"navigation":571,"order":159,"path":548,"published":571,"section":526,"seo":4200,"stem":4201,"__hash__":4202},"beaconDocs\u002Fbeacon\u002Fdocs\u002Fsdk\u002Fjavascript.md","JavaScript \u002F TypeScript SDK",{"type":7,"value":3238,"toc":4174},[3239,3243,3246,3248,3251,3267,3270,3324,3326,3334,3336,3434,3436,3649,3651,3654,3671,3676,3678,3684,3686,3735,3737,3753,3757,3767,3811,3818,3822,3827,3886,3894,3896,3909,3912,3934,3936,3947,3950,3966,3970,3973,4010,4013,4017,4020,4033,4036,4040,4043,4104,4108,4111,4124,4126,4129,4142,4145,4149,4155,4157,4171],[10,3240,3242],{"id":3241},"beacon-javascript-typescript-sdk","Beacon JavaScript \u002F TypeScript SDK",[14,3244,3245],{},"The Beacon JavaScript \u002F TypeScript SDK provides lightweight, browser-native integration for web applications. Under 5 KB gzipped, it includes automatic page view tracking, session management, and error tracking with full TypeScript definitions.",[18,3247,1122],{"id":1121},[14,3249,3250],{},"Install via npm:",[54,3252,3254],{"className":56,"code":3253,"language":58,"meta":59,"style":59},"npm install @softagility\u002Fbeacon-js\n",[49,3255,3256],{"__ignoreMap":59},[63,3257,3258,3261,3264],{"class":65,"line":66},[63,3259,3260],{"class":69},"npm",[63,3262,3263],{"class":77}," install",[63,3265,3266],{"class":77}," @softagility\u002Fbeacon-js\n",[14,3268,3269],{},"The package ships ESM, CommonJS, and UMD builds:",[186,3271,3272,3282],{},[189,3273,3274],{},[192,3275,3276,3279],{},[195,3277,3278],{},"Format",[195,3280,3281],{},"Entry",[205,3283,3284,3294,3304,3314],{},[192,3285,3286,3289],{},[210,3287,3288],{},"ESM",[210,3290,3291],{},[49,3292,3293],{},"dist\u002Fbeacon.esm.js",[192,3295,3296,3299],{},[210,3297,3298],{},"CommonJS",[210,3300,3301],{},[49,3302,3303],{},"dist\u002Fbeacon.cjs.js",[192,3305,3306,3309],{},[210,3307,3308],{},"UMD (browser)",[210,3310,3311],{},[49,3312,3313],{},"dist\u002Fbeacon.umd.js",[192,3315,3316,3319],{},[210,3317,3318],{},"Types",[210,3320,3321],{},[49,3322,3323],{},"dist\u002Fbeacon.d.ts",[266,3325,1165],{"id":1164},[279,3327,3328,3331],{},[282,3329,3330],{},"Any modern browser (Chrome, Firefox, Safari, Edge)",[282,3332,3333],{},"No dependencies",[18,3335,1180],{"id":1179},[54,3337,3341],{"className":3338,"code":3339,"language":3340,"meta":59,"style":59},"language-typescript shiki shiki-themes github-dark","import { Beacon } from '@softagility\u002Fbeacon-js'\n\nconst beacon = Beacon.init({\n  apiKey: 'your-api-key',\n  sourceApp: 'MyWebApp',\n  sourceVersion: '1.2.0',\n})\n\nbeacon.identify('user-123')\n","typescript",[49,3342,3343,3357,3361,3380,3390,3400,3410,3415,3419],{"__ignoreMap":59},[63,3344,3345,3348,3351,3354],{"class":65,"line":66},[63,3346,3347],{"class":716},"import",[63,3349,3350],{"class":703}," { Beacon } ",[63,3352,3353],{"class":716},"from",[63,3355,3356],{"class":77}," '@softagility\u002Fbeacon-js'\n",[63,3358,3359],{"class":65,"line":87},[63,3360,1773],{"emptyLinePlaceholder":571},[63,3362,3363,3366,3369,3371,3374,3377],{"class":65,"line":98},[63,3364,3365],{"class":716},"const",[63,3367,3368],{"class":73}," beacon",[63,3370,796],{"class":716},[63,3372,3373],{"class":703}," Beacon.",[63,3375,3376],{"class":69},"init",[63,3378,3379],{"class":703},"({\n",[63,3381,3382,3385,3388],{"class":65,"line":108},[63,3383,3384],{"class":703},"  apiKey: ",[63,3386,3387],{"class":77},"'your-api-key'",[63,3389,962],{"class":703},[63,3391,3392,3395,3398],{"class":65,"line":117},[63,3393,3394],{"class":703},"  sourceApp: ",[63,3396,3397],{"class":77},"'MyWebApp'",[63,3399,962],{"class":703},[63,3401,3402,3405,3408],{"class":65,"line":123},[63,3403,3404],{"class":703},"  sourceVersion: ",[63,3406,3407],{"class":77},"'1.2.0'",[63,3409,962],{"class":703},[63,3411,3412],{"class":65,"line":129},[63,3413,3414],{"class":703},"})\n",[63,3416,3417],{"class":65,"line":135},[63,3418,1773],{"emptyLinePlaceholder":571},[63,3420,3421,3424,3427,3429,3432],{"class":65,"line":141},[63,3422,3423],{"class":703},"beacon.",[63,3425,3426],{"class":69},"identify",[63,3428,710],{"class":703},[63,3430,3431],{"class":77},"'user-123'",[63,3433,1858],{"class":703},[266,3435,1343],{"id":1342},[186,3437,3438,3450],{},[189,3439,3440],{},[192,3441,3442,3444,3446,3448],{},[195,3443,1352],{},[195,3445,1355],{},[195,3447,1358],{},[195,3449,203],{},[205,3451,3452,3467,3482,3497,3516,3536,3555,3574,3593,3612,3630],{},[192,3453,3454,3459,3463,3465],{},[210,3455,3456],{},[49,3457,3458],{},"apiKey",[210,3460,3461],{},[49,3462,1374],{},[210,3464,1377],{},[210,3466,1380],{},[192,3468,3469,3474,3478,3480],{},[210,3470,3471],{},[49,3472,3473],{},"sourceApp",[210,3475,3476],{},[49,3477,1374],{},[210,3479,1377],{},[210,3481,1412],{},[192,3483,3484,3489,3493,3495],{},[210,3485,3486],{},[49,3487,3488],{},"sourceVersion",[210,3490,3491],{},[49,3492,1374],{},[210,3494,1377],{},[210,3496,1428],{},[192,3498,3499,3504,3508,3513],{},[210,3500,3501],{},[49,3502,3503],{},"endpoint",[210,3505,3506],{},[49,3507,1374],{},[210,3509,3510],{},[49,3511,3512],{},"https:\u002F\u002Fbeacon.softagility.com",[210,3514,3515],{},"API base URL override",[192,3517,3518,3523,3528,3533],{},[210,3519,3520],{},[49,3521,3522],{},"sessionTimeoutMinutes",[210,3524,3525],{},[49,3526,3527],{},"number",[210,3529,3530],{},[49,3531,3532],{},"30",[210,3534,3535],{},"Inactivity timeout before session rotates (1-1440)",[192,3537,3538,3543,3548,3552],{},[210,3539,3540],{},[49,3541,3542],{},"autoPageViews",[210,3544,3545],{},[49,3546,3547],{},"boolean",[210,3549,3550],{},[49,3551,1445],{},[210,3553,3554],{},"Auto-track page views on route changes",[192,3556,3557,3562,3566,3571],{},[210,3558,3559],{},[49,3560,3561],{},"flushIntervalMs",[210,3563,3564],{},[49,3565,3527],{},[210,3567,3568],{},[49,3569,3570],{},"10000",[210,3572,3573],{},"Flush interval in milliseconds (1000-300000)",[192,3575,3576,3581,3585,3590],{},[210,3577,3578],{},[49,3579,3580],{},"maxBatchSize",[210,3582,3583],{},[49,3584,3527],{},[210,3586,3587],{},[49,3588,3589],{},"50",[210,3591,3592],{},"Events per flush batch (1-1000)",[192,3594,3595,3600,3604,3609],{},[210,3596,3597],{},[49,3598,3599],{},"maxQueueSize",[210,3601,3602],{},[49,3603,3527],{},[210,3605,3606],{},[49,3607,3608],{},"5000",[210,3610,3611],{},"Maximum in-memory queue depth (100-10000)",[192,3613,3614,3619,3623,3627],{},[210,3615,3616],{},[49,3617,3618],{},"maxBreadcrumbs",[210,3620,3621],{},[49,3622,3527],{},[210,3624,3625],{},[49,3626,1484],{},[210,3628,3629],{},"Breadcrumb ring buffer size (0-200, 0 disables)",[192,3631,3632,3637,3641,3646],{},[210,3633,3634],{},[49,3635,3636],{},"debug",[210,3638,3639],{},[49,3640,3547],{},[210,3642,3643],{},[49,3644,3645],{},"false",[210,3647,3648],{},"Log SDK actions to console",[18,3650,1565],{"id":1564},[14,3652,3653],{},"Identify the current user to associate events with an actor:",[54,3655,3657],{"className":3338,"code":3656,"language":3340,"meta":59,"style":59},"beacon.identify('user-123')\n",[49,3658,3659],{"__ignoreMap":59},[63,3660,3661,3663,3665,3667,3669],{"class":65,"line":66},[63,3662,3423],{"class":703},[63,3664,3426],{"class":69},[63,3666,710],{"class":703},[63,3668,3431],{"class":77},[63,3670,1858],{"class":703},[14,3672,3123,3673,3675],{},[49,3674,3426],{}," before or after tracking events. Once set, all subsequent calls use this actor. If not called, the SDK generates an anonymous device ID that persists in localStorage.",[18,3677,1601],{"id":1600},[14,3679,1604,3680,1607,3682,1610],{},[28,3681,292],{},[28,3683,298],{},[266,3685,1614],{"id":1613},[54,3687,3689],{"className":3338,"code":3688,"language":3340,"meta":59,"style":59},"beacon.track('ui', 'button_clicked', {\n  button_name: 'export',\n  screen: 'dashboard',\n})\n",[49,3690,3691,3711,3721,3731],{"__ignoreMap":59},[63,3692,3693,3695,3698,3700,3703,3705,3708],{"class":65,"line":66},[63,3694,3423],{"class":703},[63,3696,3697],{"class":69},"track",[63,3699,710],{"class":703},[63,3701,3702],{"class":77},"'ui'",[63,3704,391],{"class":703},[63,3706,3707],{"class":77},"'button_clicked'",[63,3709,3710],{"class":703},", {\n",[63,3712,3713,3716,3719],{"class":65,"line":87},[63,3714,3715],{"class":703},"  button_name: ",[63,3717,3718],{"class":77},"'export'",[63,3720,962],{"class":703},[63,3722,3723,3726,3729],{"class":65,"line":98},[63,3724,3725],{"class":703},"  screen: ",[63,3727,3728],{"class":77},"'dashboard'",[63,3730,962],{"class":703},[63,3732,3733],{"class":65,"line":108},[63,3734,3414],{"class":703},[266,3736,1731],{"id":1730},[279,3738,3739,3741,3743,3746],{},[282,3740,1736],{},[282,3742,1739],{},[282,3744,3745],{},"Properties: max 20 per event, keys max 64 chars, string values max 256 chars",[282,3747,3748,3749,3752],{},"Categories starting with ",[49,3750,3751],{},"_"," are reserved and will be ignored",[18,3754,3756],{"id":3755},"page-view-tracking","Page View Tracking",[14,3758,3759,3760,1607,3763,3766],{},"Page views are tracked automatically by default when the URL changes (via ",[49,3761,3762],{},"pushState",[49,3764,3765],{},"popstate","). You can also track manually:",[54,3768,3770],{"className":3338,"code":3769,"language":3340,"meta":59,"style":59},"beacon.pageView()\n\n\u002F\u002F Or with a custom URL and properties\nbeacon.pageView('\u002Fcustom-path', { section: 'reports' })\n",[49,3771,3772,3782,3786,3791],{"__ignoreMap":59},[63,3773,3774,3776,3779],{"class":65,"line":66},[63,3775,3423],{"class":703},[63,3777,3778],{"class":69},"pageView",[63,3780,3781],{"class":703},"()\n",[63,3783,3784],{"class":65,"line":87},[63,3785,1773],{"emptyLinePlaceholder":571},[63,3787,3788],{"class":65,"line":98},[63,3789,3790],{"class":1759},"\u002F\u002F Or with a custom URL and properties\n",[63,3792,3793,3795,3797,3799,3802,3805,3808],{"class":65,"line":108},[63,3794,3423],{"class":703},[63,3796,3778],{"class":69},[63,3798,710],{"class":703},[63,3800,3801],{"class":77},"'\u002Fcustom-path'",[63,3803,3804],{"class":703},", { section: ",[63,3806,3807],{"class":77},"'reports'",[63,3809,3810],{"class":703}," })\n",[14,3812,3813,3814,3817],{},"Disable auto-tracking with ",[49,3815,3816],{},"autoPageViews: false"," in the config.",[18,3819,3821],{"id":3820},"error-tracking","Error Tracking",[14,3823,3824,3825,3005],{},"Track JavaScript errors with severity levels. Breadcrumbs from recent ",[49,3826,3004],{},[54,3828,3830],{"className":3338,"code":3829,"language":3340,"meta":59,"style":59},"try {\n  processOrder(order)\n} catch (err) {\n  beacon.trackError(err, 'non_fatal')\n  throw err\n}\n",[49,3831,3832,3840,3848,3858,3874,3882],{"__ignoreMap":59},[63,3833,3834,3837],{"class":65,"line":66},[63,3835,3836],{"class":716},"try",[63,3838,3839],{"class":703}," {\n",[63,3841,3842,3845],{"class":65,"line":87},[63,3843,3844],{"class":69},"  processOrder",[63,3846,3847],{"class":703},"(order)\n",[63,3849,3850,3853,3855],{"class":65,"line":98},[63,3851,3852],{"class":703},"} ",[63,3854,1847],{"class":716},[63,3856,3857],{"class":703}," (err) {\n",[63,3859,3860,3863,3866,3869,3872],{"class":65,"line":108},[63,3861,3862],{"class":703},"  beacon.",[63,3864,3865],{"class":69},"trackError",[63,3867,3868],{"class":703},"(err, ",[63,3870,3871],{"class":77},"'non_fatal'",[63,3873,1858],{"class":703},[63,3875,3876,3879],{"class":65,"line":117},[63,3877,3878],{"class":716},"  throw",[63,3880,3881],{"class":703}," err\n",[63,3883,3884],{"class":65,"line":123},[63,3885,1842],{"class":703},[14,3887,3053,3888,1607,3891,3893],{},[49,3889,3890],{},"'fatal'",[49,3892,3871],{}," (default).",[18,3895,1746],{"id":1745},[14,3897,3898,3899,3901,3902,1607,3905,3908],{},"Sessions are managed automatically based on user activity. A new session starts on the first event and rotates after ",[49,3900,3522],{}," of inactivity. The SDK handles ",[49,3903,3904],{},"visibilitychange",[49,3906,3907],{},"beforeunload"," events to end sessions when the user leaves.",[14,3910,3911],{},"Get the current session ID:",[54,3913,3915],{"className":3338,"code":3914,"language":3340,"meta":59,"style":59},"const sessionId = beacon.getSessionId()\n",[49,3916,3917],{"__ignoreMap":59},[63,3918,3919,3921,3924,3926,3929,3932],{"class":65,"line":66},[63,3920,3365],{"class":716},[63,3922,3923],{"class":73}," sessionId",[63,3925,796],{"class":716},[63,3927,3928],{"class":703}," beacon.",[63,3930,3931],{"class":69},"getSessionId",[63,3933,3781],{"class":703},[18,3935,1912],{"id":1911},[14,3937,1915,3938,3940,3941,485,3943,3946],{},[49,3939,3561],{},") or when the batch size is reached. On page unload, the SDK uses ",[49,3942,1050],{},[49,3944,3945],{},"keepalive: true"," to deliver remaining events.",[14,3948,3949],{},"To flush manually:",[54,3951,3953],{"className":3338,"code":3952,"language":3340,"meta":59,"style":59},"await beacon.flush()\n",[49,3954,3955],{"__ignoreMap":59},[63,3956,3957,3959,3961,3964],{"class":65,"line":66},[63,3958,1931],{"class":716},[63,3960,3928],{"class":703},[63,3962,3963],{"class":69},"flush",[63,3965,3781],{"class":703},[18,3967,3969],{"id":3968},"privacy-controls","Privacy Controls",[14,3971,3972],{},"The SDK supports opt-out and opt-in for user consent:",[54,3974,3976],{"className":3338,"code":3975,"language":3340,"meta":59,"style":59},"\u002F\u002F Opt out — stops tracking, clears queue\nbeacon.optOut()\n\n\u002F\u002F Opt back in — resumes tracking\nbeacon.optIn()\n",[49,3977,3978,3983,3992,3996,4001],{"__ignoreMap":59},[63,3979,3980],{"class":65,"line":66},[63,3981,3982],{"class":1759},"\u002F\u002F Opt out — stops tracking, clears queue\n",[63,3984,3985,3987,3990],{"class":65,"line":87},[63,3986,3423],{"class":703},[63,3988,3989],{"class":69},"optOut",[63,3991,3781],{"class":703},[63,3993,3994],{"class":65,"line":98},[63,3995,1773],{"emptyLinePlaceholder":571},[63,3997,3998],{"class":65,"line":108},[63,3999,4000],{"class":1759},"\u002F\u002F Opt back in — resumes tracking\n",[63,4002,4003,4005,4008],{"class":65,"line":117},[63,4004,3423],{"class":703},[63,4006,4007],{"class":69},"optIn",[63,4009,3781],{"class":703},[14,4011,4012],{},"Opt-out state persists in localStorage across sessions.",[18,4014,4016],{"id":4015},"reset","Reset",[14,4018,4019],{},"Clear all state (session, queue, breadcrumbs, actor ID) and generate a new anonymous ID:",[54,4021,4023],{"className":3338,"code":4022,"language":3340,"meta":59,"style":59},"beacon.reset()\n",[49,4024,4025],{"__ignoreMap":59},[63,4026,4027,4029,4031],{"class":65,"line":66},[63,4028,3423],{"class":703},[63,4030,4015],{"class":69},[63,4032,3781],{"class":703},[14,4034,4035],{},"Use this on logout to separate user sessions.",[18,4037,4039],{"id":4038},"event-definitions","Event Definitions",[14,4041,4042],{},"Register known events for import into the Beacon portal's allowlist:",[54,4044,4046],{"className":3338,"code":4045,"language":3340,"meta":59,"style":59},"beacon.events.define('reports', 'report_exported')\nbeacon.events.define('ui', 'button_clicked')\n\nconst manifest = beacon.events.exportManifest()\n",[49,4047,4048,4067,4083,4087],{"__ignoreMap":59},[63,4049,4050,4053,4056,4058,4060,4062,4065],{"class":65,"line":66},[63,4051,4052],{"class":703},"beacon.events.",[63,4054,4055],{"class":69},"define",[63,4057,710],{"class":703},[63,4059,3807],{"class":77},[63,4061,391],{"class":703},[63,4063,4064],{"class":77},"'report_exported'",[63,4066,1858],{"class":703},[63,4068,4069,4071,4073,4075,4077,4079,4081],{"class":65,"line":87},[63,4070,4052],{"class":703},[63,4072,4055],{"class":69},[63,4074,710],{"class":703},[63,4076,3702],{"class":77},[63,4078,391],{"class":703},[63,4080,3707],{"class":77},[63,4082,1858],{"class":703},[63,4084,4085],{"class":65,"line":98},[63,4086,1773],{"emptyLinePlaceholder":571},[63,4088,4089,4091,4094,4096,4099,4102],{"class":65,"line":108},[63,4090,3365],{"class":716},[63,4092,4093],{"class":73}," manifest",[63,4095,796],{"class":716},[63,4097,4098],{"class":703}," beacon.events.",[63,4100,4101],{"class":69},"exportManifest",[63,4103,3781],{"class":703},[18,4105,4107],{"id":4106},"destroy","Destroy",[14,4109,4110],{},"Tear down the SDK instance, flush pending events, and remove event listeners:",[54,4112,4114],{"className":3338,"code":4113,"language":3340,"meta":59,"style":59},"beacon.destroy()\n",[49,4115,4116],{"__ignoreMap":59},[63,4117,4118,4120,4122],{"class":65,"line":66},[63,4119,3423],{"class":703},[63,4121,4106],{"class":69},[63,4123,3781],{"class":703},[18,4125,987],{"id":986},[14,4127,4128],{},"The SDK automatically collects browser environment data and sends it as a header with each request:",[279,4130,4131,4133,4135,4137,4140],{},[282,4132,1022],{},[282,4134,1025],{},[282,4136,1028],{},[282,4138,4139],{},"Device type (desktop\u002Fmobile\u002Ftablet)",[282,4141,1034],{},[14,4143,4144],{},"No PII is collected.",[18,4146,4148],{"id":4147},"singleton-pattern","Singleton Pattern",[14,4150,4151,4154],{},[49,4152,4153],{},"Beacon.init()"," returns a singleton. Calling it again returns the existing instance. If the SDK is loaded in a non-browser environment (SSR), it returns a safe no-op instance.",[18,4156,1058],{"id":1057},[279,4158,4159,4163,4167],{},[282,4160,4161,2355],{},[31,4162,581],{"href":1103},[282,4164,4165,2360],{},[31,4166,5],{"href":573},[282,4168,4169,1084],{},[31,4170,2365],{"href":1082},[551,4172,4173],{},"html pre.shiki code .svObZ, html code.shiki .svObZ{--shiki-default:#B392F0}html pre.shiki code .sU2Wk, html code.shiki .sU2Wk{--shiki-default:#9ECBFF}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html pre.shiki code .snl16, html code.shiki .snl16{--shiki-default:#F97583}html pre.shiki code .s95oV, html code.shiki .s95oV{--shiki-default:#E1E4E8}html pre.shiki code .sDLfK, html code.shiki .sDLfK{--shiki-default:#79B8FF}html pre.shiki code .sAwPA, html code.shiki .sAwPA{--shiki-default:#6A737D}",{"title":59,"searchDepth":87,"depth":87,"links":4175},[4176,4179,4182,4183,4187,4188,4189,4190,4191,4192,4193,4194,4195,4196,4197],{"id":1121,"depth":87,"text":1122,"children":4177},[4178],{"id":1164,"depth":98,"text":1165},{"id":1179,"depth":87,"text":1180,"children":4180},[4181],{"id":1342,"depth":98,"text":1343},{"id":1564,"depth":87,"text":1565},{"id":1600,"depth":87,"text":1601,"children":4184},[4185,4186],{"id":1613,"depth":98,"text":1614},{"id":1730,"depth":98,"text":1731},{"id":3755,"depth":87,"text":3756},{"id":3820,"depth":87,"text":3821},{"id":1745,"depth":87,"text":1746},{"id":1911,"depth":87,"text":1912},{"id":3968,"depth":87,"text":3969},{"id":4015,"depth":87,"text":4016},{"id":4038,"depth":87,"text":4039},{"id":4106,"depth":87,"text":4107},{"id":986,"depth":87,"text":987},{"id":4147,"depth":87,"text":4148},{"id":1057,"depth":87,"text":1058},"Integrate Beacon product analytics into browser-based web applications.",{},{"title":3236,"description":4198},"beacon\u002Fdocs\u002Fsdk\u002Fjavascript","SpRUdifHjtIaHwrSbsvwQtv9x0tFfeYjW4O5koDCQPk",{"id":4,"title":5,"body":4204,"description":568,"extension":569,"meta":4580,"navigation":571,"order":572,"path":573,"published":571,"section":574,"seo":4581,"stem":576,"__hash__":577},{"type":7,"value":4205,"toc":4566},[4206,4208,4210,4212,4214,4220,4224,4226,4230,4304,4306,4311,4313,4375,4377,4379,4383,4405,4409,4427,4445,4447,4449,4463,4465,4467,4477,4479,4481,4503,4517,4525,4527,4529,4534,4540,4542,4546,4548,4550,4564],[10,4207,5],{"id":12},[14,4209,16],{},[18,4211,21],{"id":20},[14,4213,24],{},[14,4215,4216],{},[28,4217,4218],{},[31,4219,34],{"href":33},[14,4221,4222],{},[38,4223,40],{},[18,4225,44],{"id":43},[14,4227,47,4228,52],{},[49,4229,51],{},[54,4231,4232],{"className":56,"code":57,"language":58,"meta":59,"style":59},[49,4233,4234,4246,4254,4262,4268,4272,4276,4280,4284,4288,4292,4296,4300],{"__ignoreMap":59},[63,4235,4236,4238,4240,4242,4244],{"class":65,"line":66},[63,4237,70],{"class":69},[63,4239,74],{"class":73},[63,4241,78],{"class":77},[63,4243,81],{"class":77},[63,4245,84],{"class":73},[63,4247,4248,4250,4252],{"class":65,"line":87},[63,4249,90],{"class":73},[63,4251,93],{"class":77},[63,4253,84],{"class":73},[63,4255,4256,4258,4260],{"class":65,"line":98},[63,4257,90],{"class":73},[63,4259,103],{"class":77},[63,4261,84],{"class":73},[63,4263,4264,4266],{"class":65,"line":108},[63,4265,111],{"class":73},[63,4267,114],{"class":77},[63,4269,4270],{"class":65,"line":117},[63,4271,120],{"class":77},[63,4273,4274],{"class":65,"line":123},[63,4275,126],{"class":77},[63,4277,4278],{"class":65,"line":129},[63,4279,132],{"class":77},[63,4281,4282],{"class":65,"line":135},[63,4283,138],{"class":77},[63,4285,4286],{"class":65,"line":141},[63,4287,144],{"class":77},[63,4289,4290],{"class":65,"line":147},[63,4291,150],{"class":77},[63,4293,4294],{"class":65,"line":153},[63,4295,156],{"class":77},[63,4297,4298],{"class":65,"line":159},[63,4299,162],{"class":77},[63,4301,4302],{"class":65,"line":165},[63,4303,168],{"class":77},[18,4305,172],{"id":171},[54,4307,4309],{"className":4308,"code":177,"language":178},[176],[49,4310,177],{"__ignoreMap":59},[18,4312,184],{"id":183},[186,4314,4315,4325],{},[189,4316,4317],{},[192,4318,4319,4321,4323],{},[195,4320,197],{},[195,4322,200],{},[195,4324,203],{},[205,4326,4327,4339,4351,4363],{},[192,4328,4329,4333,4337],{},[210,4330,4331],{},[49,4332,214],{},[210,4334,4335],{},[49,4336,219],{},[210,4338,222],{},[192,4340,4341,4345,4349],{},[210,4342,4343],{},[49,4344,214],{},[210,4346,4347],{},[49,4348,233],{},[210,4350,236],{},[192,4352,4353,4357,4361],{},[210,4354,4355],{},[49,4356,214],{},[210,4358,4359],{},[49,4360,247],{},[210,4362,250],{},[192,4364,4365,4369,4373],{},[210,4366,4367],{},[49,4368,214],{},[210,4370,4371],{},[49,4372,261],{},[210,4374,264],{},[266,4376,269],{"id":268},[14,4378,272],{},[14,4380,4381],{},[28,4382,277],{},[279,4384,4385,4389,4393,4397,4401],{},[282,4386,4387,287],{},[49,4388,286],{},[282,4390,4391,293],{},[49,4392,292],{},[282,4394,4395,299],{},[49,4396,298],{},[282,4398,4399,305],{},[49,4400,304],{},[282,4402,4403,311],{},[49,4404,310],{},[14,4406,4407],{},[28,4408,316],{},[279,4410,4411,4415,4419,4423],{},[282,4412,4413,324],{},[49,4414,323],{},[282,4416,4417,330],{},[49,4418,329],{},[282,4420,4421,336],{},[49,4422,335],{},[282,4424,4425,342],{},[49,4426,341],{},[14,4428,4429,348,4431,352,4433,356,4435,360,4437,364,4439,368,4441,372,4443,376],{},[28,4430,347],{},[49,4432,351],{},[49,4434,355],{},[49,4436,359],{},[49,4438,363],{},[49,4440,367],{},[49,4442,371],{},[49,4444,375],{},[266,4446,380],{"id":379},[14,4448,383],{},[14,4450,4451,348,4453,391,4455,391,4457,391,4459,391,4461],{},[28,4452,388],{},[49,4454,341],{},[49,4456,310],{},[49,4458,323],{},[49,4460,329],{},[49,4462,400],{},[266,4464,404],{"id":403},[14,4466,407],{},[14,4468,4469,348,4471,391,4473,391,4475],{},[28,4470,388],{},[49,4472,341],{},[49,4474,416],{},[49,4476,419],{},[266,4478,423],{"id":422},[14,4480,426],{},[14,4482,4483,348,4485,391,4487,391,4489,440,4491,444,4493,448,4495,391,4497,391,4499,391,4501],{},[28,4484,388],{},[49,4486,433],{},[49,4488,436],{},[49,4490,439],{},[49,4492,443],{},[49,4494,447],{},[49,4496,451],{},[49,4498,310],{},[49,4500,323],{},[49,4502,329],{},[14,4504,4505,348,4507,465,4509,469,4511,473,4513,391,4515],{},[28,4506,316],{},[49,4508,464],{},[49,4510,468],{},[49,4512,472],{},[49,4514,341],{},[49,4516,478],{},[14,4518,4519,348,4521,485,4523],{},[28,4520,347],{},[49,4522,351],{},[49,4524,488],{},[18,4526,492],{"id":491},[14,4528,495],{},[54,4530,4532],{"className":4531,"code":499,"language":178},[176],[49,4533,499],{"__ignoreMap":59},[14,4535,504,4536,507,4538,511],{},[49,4537,375],{},[49,4539,510],{},[18,4541,515],{"id":514},[14,4543,518,4544,522],{},[49,4545,521],{},[18,4547,526],{"id":525},[14,4549,529],{},[279,4551,4552,4556,4560],{},[282,4553,4554],{},[31,4555,537],{"href":536},[282,4557,4558],{},[31,4559,543],{"href":542},[282,4561,4562],{},[31,4563,549],{"href":548},[551,4565,553],{},{"title":59,"searchDepth":87,"depth":87,"links":4567},[4568,4569,4570,4571,4577,4578,4579],{"id":20,"depth":87,"text":21},{"id":43,"depth":87,"text":44},{"id":171,"depth":87,"text":172},{"id":183,"depth":87,"text":184,"children":4572},[4573,4574,4575,4576],{"id":268,"depth":98,"text":269},{"id":379,"depth":98,"text":380},{"id":403,"depth":98,"text":404},{"id":422,"depth":98,"text":423},{"id":491,"depth":87,"text":492},{"id":514,"depth":87,"text":515},{"id":525,"depth":87,"text":526},{},{"title":5,"description":568},1775694617877]