[{"data":1,"prerenderedAt":2108},["ShallowReactive",2],{"navigation_docs":3,"-frameworks-custom-integration":238,"-frameworks-custom-integration-surround":2103},[4,30,110,154,208,224],{"title":5,"path":6,"stem":7,"children":8,"page":29},"Getting Started","\u002Fgetting-started","1.getting-started",[9,14,19,24],{"title":10,"path":11,"stem":12,"icon":13},"Introduction","\u002Fgetting-started\u002Fintroduction","1.getting-started\u002F1.introduction","i-lucide-info",{"title":15,"path":16,"stem":17,"icon":18},"Installation","\u002Fgetting-started\u002Finstallation","1.getting-started\u002F2.installation","i-lucide-download",{"title":20,"path":21,"stem":22,"icon":23},"Quick Start","\u002Fgetting-started\u002Fquick-start","1.getting-started\u002F3.quick-start","i-lucide-zap",{"title":25,"path":26,"stem":27,"icon":28},"Agent Skills","\u002Fgetting-started\u002Fagent-skills","1.getting-started\u002F4.agent-skills","i-lucide-sparkles",false,{"title":31,"path":32,"stem":33,"children":34,"page":29},"Frameworks","\u002Fframeworks","2.frameworks",[35,40,45,50,55,60,65,70,75,80,85,90,95,100,105],{"title":36,"path":37,"stem":38,"icon":39},"Overview","\u002Fframeworks\u002Foverview","2.frameworks\u002F00.overview","i-lucide-layout-grid",{"title":41,"path":42,"stem":43,"icon":44},"Nuxt","\u002Fframeworks\u002Fnuxt","2.frameworks\u002F01.nuxt","i-simple-icons-nuxtdotjs",{"title":46,"path":47,"stem":48,"icon":49},"Next.js","\u002Fframeworks\u002Fnextjs","2.frameworks\u002F02.nextjs","i-simple-icons-nextdotjs",{"title":51,"path":52,"stem":53,"icon":54},"SvelteKit","\u002Fframeworks\u002Fsveltekit","2.frameworks\u002F03.sveltekit","i-simple-icons-svelte",{"title":56,"path":57,"stem":58,"icon":59},"Nitro","\u002Fframeworks\u002Fnitro","2.frameworks\u002F04.nitro","i-custom-nitro",{"title":61,"path":62,"stem":63,"icon":64},"TanStack Start","\u002Fframeworks\u002Ftanstack-start","2.frameworks\u002F05.tanstack-start","i-custom-tanstack",{"title":66,"path":67,"stem":68,"icon":69},"NestJS","\u002Fframeworks\u002Fnestjs","2.frameworks\u002F06.nestjs","i-simple-icons-nestjs",{"title":71,"path":72,"stem":73,"icon":74},"Express","\u002Fframeworks\u002Fexpress","2.frameworks\u002F07.express","i-simple-icons-express",{"title":76,"path":77,"stem":78,"icon":79},"Hono","\u002Fframeworks\u002Fhono","2.frameworks\u002F08.hono","i-simple-icons-hono",{"title":81,"path":82,"stem":83,"icon":84},"Fastify","\u002Fframeworks\u002Ffastify","2.frameworks\u002F09.fastify","i-simple-icons-fastify",{"title":86,"path":87,"stem":88,"icon":89},"Elysia","\u002Fframeworks\u002Felysia","2.frameworks\u002F10.elysia","i-custom-elysia",{"title":91,"path":92,"stem":93,"icon":94},"Cloudflare Workers","\u002Fframeworks\u002Fcloudflare-workers","2.frameworks\u002F11.cloudflare-workers","i-simple-icons-cloudflare",{"title":96,"path":97,"stem":98,"icon":99},"Standalone","\u002Fframeworks\u002Fstandalone","2.frameworks\u002F12.standalone","i-simple-icons-typescript",{"title":101,"path":102,"stem":103,"icon":104},"Astro","\u002Fframeworks\u002Fastro","2.frameworks\u002F13.astro","i-simple-icons-astro",{"title":106,"path":107,"stem":108,"icon":109},"Custom Integration","\u002Fframeworks\u002Fcustom-integration","2.frameworks\u002F14.custom-integration","i-lucide-puzzle",{"title":111,"path":112,"stem":113,"children":114,"page":29},"Core Concepts","\u002Fcore-concepts","3.core-concepts",[115,120,125,130,135,139,144,149],{"title":116,"path":117,"stem":118,"icon":119},"Request Lifecycle","\u002Fcore-concepts\u002Flifecycle","3.core-concepts\u002F0.lifecycle","i-lucide-arrow-right-left",{"title":121,"path":122,"stem":123,"icon":124},"Wide Events","\u002Fcore-concepts\u002Fwide-events","3.core-concepts\u002F1.wide-events","i-lucide-layers",{"title":126,"path":127,"stem":128,"icon":129},"Structured Errors","\u002Fcore-concepts\u002Fstructured-errors","3.core-concepts\u002F2.structured-errors","i-lucide-shield-alert",{"title":131,"path":132,"stem":133,"icon":134},"Best Practices","\u002Fcore-concepts\u002Fbest-practices","3.core-concepts\u002F3.best-practices","i-lucide-shield-check",{"title":136,"path":137,"stem":138,"icon":99},"Typed Fields","\u002Fcore-concepts\u002Ftyped-fields","3.core-concepts\u002F4.typed-fields",{"title":140,"path":141,"stem":142,"icon":143},"Sampling","\u002Fcore-concepts\u002Fsampling","3.core-concepts\u002F5.sampling","i-lucide-filter",{"title":145,"path":146,"stem":147,"icon":148},"Client Logging","\u002Fcore-concepts\u002Fclient-logging","3.core-concepts\u002F6.client-logging","i-lucide-monitor",{"title":150,"path":151,"stem":152,"icon":153},"Configuration","\u002Fcore-concepts\u002Fconfiguration","3.core-concepts\u002F7.configuration","i-lucide-settings",{"title":155,"path":156,"stem":157,"children":158,"page":29},"Adapters","\u002Fadapters","4.adapters",[159,163,168,173,178,183,188,193,198,203],{"title":36,"path":160,"stem":161,"icon":162},"\u002Fadapters\u002Foverview","4.adapters\u002F1.overview","i-custom-plug",{"title":164,"path":165,"stem":166,"icon":167},"Browser","\u002Fadapters\u002Fbrowser","4.adapters\u002F10.browser","i-lucide-globe",{"title":169,"path":170,"stem":171,"icon":172},"Axiom","\u002Fadapters\u002Faxiom","4.adapters\u002F2.axiom","i-custom-axiom",{"title":174,"path":175,"stem":176,"icon":177},"OTLP","\u002Fadapters\u002Fotlp","4.adapters\u002F3.otlp","i-simple-icons-opentelemetry",{"title":179,"path":180,"stem":181,"icon":182},"PostHog","\u002Fadapters\u002Fposthog","4.adapters\u002F4.posthog","i-simple-icons-posthog",{"title":184,"path":185,"stem":186,"icon":187},"Sentry","\u002Fadapters\u002Fsentry","4.adapters\u002F5.sentry","i-simple-icons-sentry",{"title":189,"path":190,"stem":191,"icon":192},"Better Stack","\u002Fadapters\u002Fbetter-stack","4.adapters\u002F6.better-stack","i-simple-icons-betterstack",{"title":194,"path":195,"stem":196,"icon":197},"File System","\u002Fadapters\u002Ffs","4.adapters\u002F7.fs","i-lucide-hard-drive",{"title":199,"path":200,"stem":201,"icon":202},"Custom Adapters","\u002Fadapters\u002Fcustom","4.adapters\u002F8.custom","i-lucide-code",{"title":204,"path":205,"stem":206,"icon":207},"Pipeline","\u002Fadapters\u002Fpipeline","4.adapters\u002F9.pipeline","i-lucide-workflow",{"title":209,"path":210,"stem":211,"children":212,"page":29},"Enrichers","\u002Fenrichers","5.enrichers",[213,216,220],{"title":36,"path":214,"stem":215,"icon":28},"\u002Fenrichers\u002Foverview","5.enrichers\u002F1.overview",{"title":217,"path":218,"stem":219,"icon":109},"Built-in","\u002Fenrichers\u002Fbuilt-in","5.enrichers\u002F2.built-in",{"title":221,"path":222,"stem":223,"icon":202},"Custom","\u002Fenrichers\u002Fcustom","5.enrichers\u002F3.custom",{"title":225,"path":226,"stem":227,"children":228,"page":29},"NuxtHub","\u002Fnuxthub","6.nuxthub",[229,233],{"title":36,"path":230,"stem":231,"icon":232},"\u002Fnuxthub\u002Foverview","6.nuxthub\u002F1.overview","i-lucide-database",{"title":234,"path":235,"stem":236,"icon":237},"Retention","\u002Fnuxthub\u002Fretention","6.nuxthub\u002F2.retention","i-lucide-clock",{"id":239,"title":106,"body":240,"description":2096,"extension":2097,"links":2098,"meta":2099,"navigation":2100,"path":107,"seo":2101,"stem":108,"__hash__":2102},"docs\u002F2.frameworks\u002F14.custom-integration.md",{"type":241,"value":242,"toc":2087},"minimark",[243,252,263,268,325,329,509,533,537,540,548,618,624,628,631,1352,1359,1363,1468,1472,1475,1948,1952,1955,2072,2083],[244,245,246,247,251],"p",{},"Don't see your framework listed? The ",[248,249,250],"code",{},"evlog\u002Ftoolkit"," package exposes the same building blocks that power every built-in integration (Hono, Express, Fastify, Elysia, NestJS, SvelteKit). Build a full-featured evlog middleware for any HTTP framework in ~50 lines of code.",[253,254,257,258,262],"callout",{"color":255,"icon":256},"warning","i-lucide-flask-conical","The toolkit API is marked as ",[259,260,261],"strong",{},"beta",". The surface is stable (used by all built-in integrations) but may evolve based on community feedback.",[264,265,267],"h2",{"id":266},"install","Install",[269,270,271,296,311],"code-group",{},[272,273,279],"pre",{"className":274,"code":275,"filename":276,"language":277,"meta":278,"style":278},"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","pnpm add evlog\n","pnpm","bash","",[248,280,281],{"__ignoreMap":278},[282,283,286,289,293],"span",{"class":284,"line":285},"line",1,[282,287,276],{"class":288},"sBMFI",[282,290,292],{"class":291},"sfazB"," add",[282,294,295],{"class":291}," evlog\n",[272,297,300],{"className":274,"code":298,"filename":299,"language":277,"meta":278,"style":278},"npm install evlog\n","npm",[248,301,302],{"__ignoreMap":278},[282,303,304,306,309],{"class":284,"line":285},[282,305,299],{"class":288},[282,307,308],{"class":291}," install",[282,310,295],{"class":291},[272,312,315],{"className":274,"code":313,"filename":314,"language":277,"meta":278,"style":278},"bun add evlog\n","bun",[248,316,317],{"__ignoreMap":278},[282,318,319,321,323],{"class":284,"line":285},[282,320,314],{"class":288},[282,322,292],{"class":291},[282,324,295],{"class":291},[264,326,328],{"id":327},"whats-in-the-toolkit","What's in the Toolkit",[330,331,332,345],"table",{},[333,334,335],"thead",{},[336,337,338,342],"tr",{},[339,340,341],"th",{},"Export",[339,343,344],{},"Purpose",[346,347,348,359,388,413,426,440,454,471,489,499],"tbody",{},[336,349,350,356],{},[351,352,353],"td",{},[248,354,355],{},"createMiddlewareLogger(opts)",[351,357,358],{},"Full pipeline: logger creation, route filtering, tail sampling, emit, enrich, drain",[336,360,361,366],{},[351,362,363],{},[248,364,365],{},"BaseEvlogOptions",[351,367,368,369,372,373,372,376,372,379,372,382,372,385],{},"Base user-facing options type with ",[248,370,371],{},"drain",", ",[248,374,375],{},"enrich",[248,377,378],{},"keep",[248,380,381],{},"include",[248,383,384],{},"exclude",[248,386,387],{},"routes",[336,389,390,395],{},[351,391,392],{},[248,393,394],{},"MiddlewareLoggerOptions",[351,396,397,398,400,401,372,404,372,407,372,410],{},"Internal options extending ",[248,399,365],{}," with ",[248,402,403],{},"method",[248,405,406],{},"path",[248,408,409],{},"requestId",[248,411,412],{},"headers",[336,414,415,420],{},[351,416,417],{},[248,418,419],{},"MiddlewareLoggerResult",[351,421,422,423],{},"Return type: ",[248,424,425],{},"{ logger, finish, skipped }",[336,427,428,433],{},[351,429,430],{},[248,431,432],{},"extractSafeHeaders(headers)",[351,434,435,436,439],{},"Filter sensitive headers from a Web API ",[248,437,438],{},"Headers"," object (Hono, Elysia, Deno, Bun)",[336,441,442,447],{},[351,443,444],{},[248,445,446],{},"extractSafeNodeHeaders(headers)",[351,448,449,450,453],{},"Filter sensitive headers from Node.js ",[248,451,452],{},"IncomingHttpHeaders"," (Express, Fastify, NestJS)",[336,455,456,461],{},[351,457,458],{},[248,459,460],{},"createLoggerStorage(hint)",[351,462,463,464,467,468],{},"Factory returning ",[248,465,466],{},"{ storage, useLogger }"," backed by ",[248,469,470],{},"AsyncLocalStorage",[336,472,473,478],{},[351,474,475],{},[248,476,477],{},"extractErrorStatus(error)",[351,479,480,481,484,485,488],{},"Extract HTTP status from any error shape (",[248,482,483],{},"status"," or ",[248,486,487],{},"statusCode",")",[336,490,491,496],{},[351,492,493],{},[248,494,495],{},"shouldLog(path, include, exclude)",[351,497,498],{},"Route filtering logic (glob patterns)",[336,500,501,506],{},[351,502,503],{},[248,504,505],{},"getServiceForPath(path, routes)",[351,507,508],{},"Resolve per-route service name",[244,510,511,512,372,515,372,518,372,521,524,525,528,529,532],{},"Types like ",[248,513,514],{},"RequestLogger",[248,516,517],{},"DrainContext",[248,519,520],{},"EnrichContext",[248,522,523],{},"WideEvent",", and ",[248,526,527],{},"TailSamplingContext"," are exported from the main ",[248,530,531],{},"evlog"," package.",[264,534,536],{"id":535},"architecture","Architecture",[244,538,539],{},"Every evlog framework integration follows the same 5-step pattern:",[272,541,546],{"className":542,"code":544,"language":545},[543],"language-text","Request → createMiddlewareLogger() → store logger → handle request → finish()\n","text",[248,547,544],{"__ignoreMap":278},[549,550,551,567,576,589,606],"ol",{},[552,553,554,557,558,372,560,372,562,524,564,566],"li",{},[259,555,556],{},"Extract"," ",[248,559,403],{},[248,561,406],{},[248,563,409],{},[248,565,412],{}," from the framework request",[552,568,569,557,572,575],{},[259,570,571],{},"Call",[248,573,574],{},"createMiddlewareLogger()"," with those fields + user options",[552,577,578,557,581,584,585,588],{},[259,579,580],{},"Check",[248,582,583],{},"skipped"," - if ",[248,586,587],{},"true",", the route is filtered out, skip to next middleware",[552,590,591,594,595,598,599,372,602,605],{},[259,592,593],{},"Store"," the ",[248,596,597],{},"logger"," in the framework's idiomatic context (",[248,600,601],{},"req.log",[248,603,604],{},"c.set('log')",", etc.)",[552,607,608,557,610,613,614,617],{},[259,609,571],{},[248,611,612],{},"finish({ status })"," on success or ",[248,615,616],{},"finish({ error })"," on failure",[244,619,620,623],{},[248,621,622],{},"createMiddlewareLogger"," handles everything else: route filtering, service overrides, duration tracking, tail sampling, event emission, enrichment, and draining.",[264,625,627],{"id":626},"minimal-example","Minimal Example",[244,629,630],{},"Here's a complete integration for a generic Node.js HTTP framework:",[272,632,637],{"className":633,"code":634,"filename":635,"language":636,"meta":278,"style":278},"language-typescript shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import type { IncomingMessage, ServerResponse } from 'node:http'\nimport type { RequestLogger } from 'evlog'\nimport {\n  createMiddlewareLogger,\n  extractSafeNodeHeaders,\n  createLoggerStorage,\n  type BaseEvlogOptions,\n} from 'evlog\u002Ftoolkit'\n\nexport type MyFrameworkEvlogOptions = BaseEvlogOptions\n\nconst { storage, useLogger } = createLoggerStorage(\n  'middleware context. Make sure evlog middleware is registered before your routes.',\n)\n\nexport { useLogger }\n\nexport function evlog(options: MyFrameworkEvlogOptions = {}) {\n  return async (req: IncomingMessage, res: ServerResponse, next: () => Promise\u003Cvoid>) => {\n    const { logger, finish, skipped } = createMiddlewareLogger({\n      method: req.method || 'GET',\n      path: req.url || '\u002F',\n      requestId: (req.headers['x-request-id'] as string) || crypto.randomUUID(),\n      headers: extractSafeNodeHeaders(req.headers),\n      ...options,\n    })\n\n    if (skipped) {\n      await next()\n      return\n    }\n\n    ;(req as IncomingMessage & { log: RequestLogger }).log = logger\n\n    try {\n      await storage.run(logger, () => next())\n      await finish({ status: res.statusCode })\n    } catch (error) {\n      await finish({ error: error as Error })\n      throw error\n    }\n  }\n}\n","my-framework-evlog.ts","typescript",[248,638,639,677,699,707,716,724,732,743,757,764,782,787,814,828,834,839,852,857,887,944,978,1006,1032,1086,1109,1119,1127,1132,1146,1157,1163,1169,1174,1215,1220,1228,1255,1282,1299,1326,1335,1340,1346],{"__ignoreMap":278},[282,640,641,645,648,652,656,659,662,665,668,671,674],{"class":284,"line":285},[282,642,644],{"class":643},"s7zQu","import",[282,646,647],{"class":643}," type",[282,649,651],{"class":650},"sMK4o"," {",[282,653,655],{"class":654},"sTEyZ"," IncomingMessage",[282,657,658],{"class":650},",",[282,660,661],{"class":654}," ServerResponse",[282,663,664],{"class":650}," }",[282,666,667],{"class":643}," from",[282,669,670],{"class":650}," '",[282,672,673],{"class":291},"node:http",[282,675,676],{"class":650},"'\n",[282,678,680,682,684,686,689,691,693,695,697],{"class":284,"line":679},2,[282,681,644],{"class":643},[282,683,647],{"class":643},[282,685,651],{"class":650},[282,687,688],{"class":654}," RequestLogger",[282,690,664],{"class":650},[282,692,667],{"class":643},[282,694,670],{"class":650},[282,696,531],{"class":291},[282,698,676],{"class":650},[282,700,702,704],{"class":284,"line":701},3,[282,703,644],{"class":643},[282,705,706],{"class":650}," {\n",[282,708,710,713],{"class":284,"line":709},4,[282,711,712],{"class":654},"  createMiddlewareLogger",[282,714,715],{"class":650},",\n",[282,717,719,722],{"class":284,"line":718},5,[282,720,721],{"class":654},"  extractSafeNodeHeaders",[282,723,715],{"class":650},[282,725,727,730],{"class":284,"line":726},6,[282,728,729],{"class":654},"  createLoggerStorage",[282,731,715],{"class":650},[282,733,735,738,741],{"class":284,"line":734},7,[282,736,737],{"class":643},"  type",[282,739,740],{"class":654}," BaseEvlogOptions",[282,742,715],{"class":650},[282,744,746,749,751,753,755],{"class":284,"line":745},8,[282,747,748],{"class":650},"}",[282,750,667],{"class":643},[282,752,670],{"class":650},[282,754,250],{"class":291},[282,756,676],{"class":650},[282,758,760],{"class":284,"line":759},9,[282,761,763],{"emptyLinePlaceholder":762},true,"\n",[282,765,767,770,773,776,779],{"class":284,"line":766},10,[282,768,769],{"class":643},"export",[282,771,647],{"class":772},"spNyl",[282,774,775],{"class":288}," MyFrameworkEvlogOptions",[282,777,778],{"class":650}," =",[282,780,781],{"class":288}," BaseEvlogOptions\n",[282,783,785],{"class":284,"line":784},11,[282,786,763],{"emptyLinePlaceholder":762},[282,788,790,793,795,798,800,803,805,807,811],{"class":284,"line":789},12,[282,791,792],{"class":772},"const",[282,794,651],{"class":650},[282,796,797],{"class":654}," storage",[282,799,658],{"class":650},[282,801,802],{"class":654}," useLogger ",[282,804,748],{"class":650},[282,806,778],{"class":650},[282,808,810],{"class":809},"s2Zo4"," createLoggerStorage",[282,812,813],{"class":654},"(\n",[282,815,817,820,823,826],{"class":284,"line":816},13,[282,818,819],{"class":650},"  '",[282,821,822],{"class":291},"middleware context. Make sure evlog middleware is registered before your routes.",[282,824,825],{"class":650},"'",[282,827,715],{"class":650},[282,829,831],{"class":284,"line":830},14,[282,832,833],{"class":654},")\n",[282,835,837],{"class":284,"line":836},15,[282,838,763],{"emptyLinePlaceholder":762},[282,840,842,844,846,849],{"class":284,"line":841},16,[282,843,769],{"class":643},[282,845,651],{"class":650},[282,847,848],{"class":654}," useLogger",[282,850,851],{"class":650}," }\n",[282,853,855],{"class":284,"line":854},17,[282,856,763],{"emptyLinePlaceholder":762},[282,858,860,862,865,868,871,875,878,880,882,885],{"class":284,"line":859},18,[282,861,769],{"class":643},[282,863,864],{"class":772}," function",[282,866,867],{"class":809}," evlog",[282,869,870],{"class":650},"(",[282,872,874],{"class":873},"sHdIc","options",[282,876,877],{"class":650},":",[282,879,775],{"class":288},[282,881,778],{"class":650},[282,883,884],{"class":650}," {})",[282,886,706],{"class":650},[282,888,890,893,896,899,902,904,906,908,911,913,915,917,920,922,925,928,931,934,937,940,942],{"class":284,"line":889},19,[282,891,892],{"class":643},"  return",[282,894,895],{"class":772}," async",[282,897,898],{"class":650}," (",[282,900,901],{"class":873},"req",[282,903,877],{"class":650},[282,905,655],{"class":288},[282,907,658],{"class":650},[282,909,910],{"class":873}," res",[282,912,877],{"class":650},[282,914,661],{"class":288},[282,916,658],{"class":650},[282,918,919],{"class":809}," next",[282,921,877],{"class":650},[282,923,924],{"class":650}," ()",[282,926,927],{"class":772}," =>",[282,929,930],{"class":288}," Promise",[282,932,933],{"class":650},"\u003C",[282,935,936],{"class":288},"void",[282,938,939],{"class":650},">)",[282,941,927],{"class":772},[282,943,706],{"class":650},[282,945,947,950,952,955,957,960,962,965,967,969,972,975],{"class":284,"line":946},20,[282,948,949],{"class":772},"    const",[282,951,651],{"class":650},[282,953,954],{"class":654}," logger",[282,956,658],{"class":650},[282,958,959],{"class":654}," finish",[282,961,658],{"class":650},[282,963,964],{"class":654}," skipped",[282,966,664],{"class":650},[282,968,778],{"class":650},[282,970,971],{"class":809}," createMiddlewareLogger",[282,973,870],{"class":974},"swJcz",[282,976,977],{"class":650},"{\n",[282,979,981,984,986,989,992,994,997,999,1002,1004],{"class":284,"line":980},21,[282,982,983],{"class":974},"      method",[282,985,877],{"class":650},[282,987,988],{"class":654}," req",[282,990,991],{"class":650},".",[282,993,403],{"class":654},[282,995,996],{"class":650}," ||",[282,998,670],{"class":650},[282,1000,1001],{"class":291},"GET",[282,1003,825],{"class":650},[282,1005,715],{"class":650},[282,1007,1009,1012,1014,1016,1018,1021,1023,1025,1028,1030],{"class":284,"line":1008},22,[282,1010,1011],{"class":974},"      path",[282,1013,877],{"class":650},[282,1015,988],{"class":654},[282,1017,991],{"class":650},[282,1019,1020],{"class":654},"url",[282,1022,996],{"class":650},[282,1024,670],{"class":650},[282,1026,1027],{"class":291},"\u002F",[282,1029,825],{"class":650},[282,1031,715],{"class":650},[282,1033,1035,1038,1040,1042,1044,1046,1048,1051,1053,1056,1058,1061,1064,1067,1070,1073,1076,1078,1081,1084],{"class":284,"line":1034},23,[282,1036,1037],{"class":974},"      requestId",[282,1039,877],{"class":650},[282,1041,898],{"class":974},[282,1043,901],{"class":654},[282,1045,991],{"class":650},[282,1047,412],{"class":654},[282,1049,1050],{"class":974},"[",[282,1052,825],{"class":650},[282,1054,1055],{"class":291},"x-request-id",[282,1057,825],{"class":650},[282,1059,1060],{"class":974},"] ",[282,1062,1063],{"class":643},"as",[282,1065,1066],{"class":288}," string",[282,1068,1069],{"class":974},") ",[282,1071,1072],{"class":650},"||",[282,1074,1075],{"class":654}," crypto",[282,1077,991],{"class":650},[282,1079,1080],{"class":809},"randomUUID",[282,1082,1083],{"class":974},"()",[282,1085,715],{"class":650},[282,1087,1089,1092,1094,1097,1099,1101,1103,1105,1107],{"class":284,"line":1088},24,[282,1090,1091],{"class":974},"      headers",[282,1093,877],{"class":650},[282,1095,1096],{"class":809}," extractSafeNodeHeaders",[282,1098,870],{"class":974},[282,1100,901],{"class":654},[282,1102,991],{"class":650},[282,1104,412],{"class":654},[282,1106,488],{"class":974},[282,1108,715],{"class":650},[282,1110,1112,1115,1117],{"class":284,"line":1111},25,[282,1113,1114],{"class":650},"      ...",[282,1116,874],{"class":654},[282,1118,715],{"class":650},[282,1120,1122,1125],{"class":284,"line":1121},26,[282,1123,1124],{"class":650},"    }",[282,1126,833],{"class":974},[282,1128,1130],{"class":284,"line":1129},27,[282,1131,763],{"emptyLinePlaceholder":762},[282,1133,1135,1138,1140,1142,1144],{"class":284,"line":1134},28,[282,1136,1137],{"class":643},"    if",[282,1139,898],{"class":974},[282,1141,583],{"class":654},[282,1143,1069],{"class":974},[282,1145,977],{"class":650},[282,1147,1149,1152,1154],{"class":284,"line":1148},29,[282,1150,1151],{"class":643},"      await",[282,1153,919],{"class":809},[282,1155,1156],{"class":974},"()\n",[282,1158,1160],{"class":284,"line":1159},30,[282,1161,1162],{"class":643},"      return\n",[282,1164,1166],{"class":284,"line":1165},31,[282,1167,1168],{"class":650},"    }\n",[282,1170,1172],{"class":284,"line":1171},32,[282,1173,763],{"emptyLinePlaceholder":762},[282,1175,1177,1180,1182,1184,1187,1189,1192,1194,1197,1199,1201,1203,1205,1207,1210,1212],{"class":284,"line":1176},33,[282,1178,1179],{"class":650},"    ;",[282,1181,870],{"class":974},[282,1183,901],{"class":654},[282,1185,1186],{"class":643}," as",[282,1188,655],{"class":288},[282,1190,1191],{"class":650}," &",[282,1193,651],{"class":650},[282,1195,1196],{"class":974}," log",[282,1198,877],{"class":650},[282,1200,688],{"class":288},[282,1202,664],{"class":650},[282,1204,488],{"class":974},[282,1206,991],{"class":650},[282,1208,1209],{"class":654},"log",[282,1211,778],{"class":650},[282,1213,1214],{"class":654}," logger\n",[282,1216,1218],{"class":284,"line":1217},34,[282,1219,763],{"emptyLinePlaceholder":762},[282,1221,1223,1226],{"class":284,"line":1222},35,[282,1224,1225],{"class":643},"    try",[282,1227,706],{"class":650},[282,1229,1231,1233,1235,1237,1240,1242,1244,1246,1248,1250,1252],{"class":284,"line":1230},36,[282,1232,1151],{"class":643},[282,1234,797],{"class":654},[282,1236,991],{"class":650},[282,1238,1239],{"class":809},"run",[282,1241,870],{"class":974},[282,1243,597],{"class":654},[282,1245,658],{"class":650},[282,1247,924],{"class":650},[282,1249,927],{"class":772},[282,1251,919],{"class":809},[282,1253,1254],{"class":974},"())\n",[282,1256,1258,1260,1262,1264,1267,1270,1272,1274,1276,1278,1280],{"class":284,"line":1257},37,[282,1259,1151],{"class":643},[282,1261,959],{"class":809},[282,1263,870],{"class":974},[282,1265,1266],{"class":650},"{",[282,1268,1269],{"class":974}," status",[282,1271,877],{"class":650},[282,1273,910],{"class":654},[282,1275,991],{"class":650},[282,1277,487],{"class":654},[282,1279,664],{"class":650},[282,1281,833],{"class":974},[282,1283,1285,1287,1290,1292,1295,1297],{"class":284,"line":1284},38,[282,1286,1124],{"class":650},[282,1288,1289],{"class":643}," catch",[282,1291,898],{"class":974},[282,1293,1294],{"class":654},"error",[282,1296,1069],{"class":974},[282,1298,977],{"class":650},[282,1300,1302,1304,1306,1308,1310,1313,1315,1317,1319,1322,1324],{"class":284,"line":1301},39,[282,1303,1151],{"class":643},[282,1305,959],{"class":809},[282,1307,870],{"class":974},[282,1309,1266],{"class":650},[282,1311,1312],{"class":974}," error",[282,1314,877],{"class":650},[282,1316,1312],{"class":654},[282,1318,1186],{"class":643},[282,1320,1321],{"class":288}," Error",[282,1323,664],{"class":650},[282,1325,833],{"class":974},[282,1327,1329,1332],{"class":284,"line":1328},40,[282,1330,1331],{"class":643},"      throw",[282,1333,1334],{"class":654}," error\n",[282,1336,1338],{"class":284,"line":1337},41,[282,1339,1168],{"class":650},[282,1341,1343],{"class":284,"line":1342},42,[282,1344,1345],{"class":650},"  }\n",[282,1347,1349],{"class":284,"line":1348},43,[282,1350,1351],{"class":650},"}\n",[244,1353,1354,1355,1358],{},"That's it. This middleware gets ",[259,1356,1357],{},"every feature"," for free: route filtering, drain adapters, enrichers, tail sampling, error capture, and duration tracking.",[264,1360,1362],{"id":1361},"key-rules","Key Rules",[549,1364,1365,1377,1397,1417,1435,1444,1453],{},[552,1366,1367,1372,1373,1376],{},[259,1368,1369,1370],{},"Always use ",[248,1371,622],{}," - never call ",[248,1374,1375],{},"createRequestLogger"," directly",[552,1378,1379,1382,1383,1386,1387,1389,1390,1393,1394,1396],{},[259,1380,1381],{},"Use the right header extractor"," - ",[248,1384,1385],{},"extractSafeHeaders"," for Web API ",[248,1388,438],{}," (Hono, Elysia, Deno), ",[248,1391,1392],{},"extractSafeNodeHeaders"," for Node.js ",[248,1395,452],{}," (Express, Fastify)",[552,1398,1399,1382,1402,1405,1406,372,1408,372,1410,372,1412,372,1414,1416],{},[259,1400,1401],{},"Spread user options",[248,1403,1404],{},"...options"," passes ",[248,1407,371],{},[248,1409,375],{},[248,1411,378],{},[248,1413,381],{},[248,1415,384],{}," to the pipeline automatically",[552,1418,1419,1426,1427,1430,1431,1434],{},[259,1420,1421,1422,1425],{},"Call ",[248,1423,1424],{},"finish()"," in both paths"," - success (",[248,1428,1429],{},"{ status }",") and error (",[248,1432,1433],{},"{ error }",") - it handles emit + enrich + drain",[552,1436,1437,1440,1441,1443],{},[259,1438,1439],{},"Re-throw errors"," after ",[248,1442,1424],{}," so framework error handlers still work",[552,1445,1446,1452],{},[259,1447,1448,1449],{},"Export ",[248,1450,1451],{},"useLogger()"," - consumers expect it for accessing the logger from service functions",[552,1454,1455,1458,1459,1461,1462,372,1464,372,1466],{},[259,1456,1457],{},"Export your options type"," extending ",[248,1460,365],{}," - for IDE completion on ",[248,1463,371],{},[248,1465,375],{},[248,1467,378],{},[264,1469,1471],{"id":1470},"usage","Usage",[244,1473,1474],{},"Once built, your integration is used like any other:",[272,1476,1478],{"className":633,"code":1477,"language":636,"meta":278,"style":278},"import { initLogger } from 'evlog'\nimport { evlog, useLogger } from '.\u002Fmy-framework-evlog'\nimport { createAxiomDrain } from 'evlog\u002Faxiom'\n\ninitLogger({ env: { service: 'my-api' } })\n\napp.use(evlog({\n  include: ['\u002Fapi\u002F**'],\n  drain: createAxiomDrain(),\n  enrich: (ctx) => {\n    ctx.event.region = process.env.FLY_REGION\n  },\n  keep: (ctx) => {\n    if (ctx.duration && ctx.duration > 2000) ctx.shouldKeep = true\n  },\n}))\n\napp.get('\u002Fapi\u002Fusers', (req, res) => {\n  req.log.set({ users: { count: 42 } })\n  res.json({ users: [] })\n})\n\n\u002F\u002F Access logger from anywhere in the call stack\nfunction findUsers() {\n  const log = useLogger()\n  log.set({ db: { query: 'SELECT * FROM users' } })\n}\n",[248,1479,1480,1499,1522,1542,1546,1580,1584,1602,1624,1637,1655,1685,1690,1707,1752,1756,1763,1767,1801,1840,1865,1871,1875,1881,1893,1906,1944],{"__ignoreMap":278},[282,1481,1482,1484,1486,1489,1491,1493,1495,1497],{"class":284,"line":285},[282,1483,644],{"class":643},[282,1485,651],{"class":650},[282,1487,1488],{"class":654}," initLogger",[282,1490,664],{"class":650},[282,1492,667],{"class":643},[282,1494,670],{"class":650},[282,1496,531],{"class":291},[282,1498,676],{"class":650},[282,1500,1501,1503,1505,1507,1509,1511,1513,1515,1517,1520],{"class":284,"line":679},[282,1502,644],{"class":643},[282,1504,651],{"class":650},[282,1506,867],{"class":654},[282,1508,658],{"class":650},[282,1510,848],{"class":654},[282,1512,664],{"class":650},[282,1514,667],{"class":643},[282,1516,670],{"class":650},[282,1518,1519],{"class":291},".\u002Fmy-framework-evlog",[282,1521,676],{"class":650},[282,1523,1524,1526,1528,1531,1533,1535,1537,1540],{"class":284,"line":701},[282,1525,644],{"class":643},[282,1527,651],{"class":650},[282,1529,1530],{"class":654}," createAxiomDrain",[282,1532,664],{"class":650},[282,1534,667],{"class":643},[282,1536,670],{"class":650},[282,1538,1539],{"class":291},"evlog\u002Faxiom",[282,1541,676],{"class":650},[282,1543,1544],{"class":284,"line":709},[282,1545,763],{"emptyLinePlaceholder":762},[282,1547,1548,1551,1553,1555,1558,1560,1562,1565,1567,1569,1572,1574,1576,1578],{"class":284,"line":718},[282,1549,1550],{"class":809},"initLogger",[282,1552,870],{"class":654},[282,1554,1266],{"class":650},[282,1556,1557],{"class":974}," env",[282,1559,877],{"class":650},[282,1561,651],{"class":650},[282,1563,1564],{"class":974}," service",[282,1566,877],{"class":650},[282,1568,670],{"class":650},[282,1570,1571],{"class":291},"my-api",[282,1573,825],{"class":650},[282,1575,664],{"class":650},[282,1577,664],{"class":650},[282,1579,833],{"class":654},[282,1581,1582],{"class":284,"line":726},[282,1583,763],{"emptyLinePlaceholder":762},[282,1585,1586,1589,1591,1594,1596,1598,1600],{"class":284,"line":734},[282,1587,1588],{"class":654},"app",[282,1590,991],{"class":650},[282,1592,1593],{"class":809},"use",[282,1595,870],{"class":654},[282,1597,531],{"class":809},[282,1599,870],{"class":654},[282,1601,977],{"class":650},[282,1603,1604,1607,1609,1612,1614,1617,1619,1622],{"class":284,"line":745},[282,1605,1606],{"class":974},"  include",[282,1608,877],{"class":650},[282,1610,1611],{"class":654}," [",[282,1613,825],{"class":650},[282,1615,1616],{"class":291},"\u002Fapi\u002F**",[282,1618,825],{"class":650},[282,1620,1621],{"class":654},"]",[282,1623,715],{"class":650},[282,1625,1626,1629,1631,1633,1635],{"class":284,"line":759},[282,1627,1628],{"class":974},"  drain",[282,1630,877],{"class":650},[282,1632,1530],{"class":809},[282,1634,1083],{"class":654},[282,1636,715],{"class":650},[282,1638,1639,1642,1644,1646,1649,1651,1653],{"class":284,"line":766},[282,1640,1641],{"class":809},"  enrich",[282,1643,877],{"class":650},[282,1645,898],{"class":650},[282,1647,1648],{"class":873},"ctx",[282,1650,488],{"class":650},[282,1652,927],{"class":772},[282,1654,706],{"class":650},[282,1656,1657,1660,1662,1665,1667,1670,1672,1675,1677,1680,1682],{"class":284,"line":784},[282,1658,1659],{"class":654},"    ctx",[282,1661,991],{"class":650},[282,1663,1664],{"class":654},"event",[282,1666,991],{"class":650},[282,1668,1669],{"class":654},"region",[282,1671,778],{"class":650},[282,1673,1674],{"class":654}," process",[282,1676,991],{"class":650},[282,1678,1679],{"class":654},"env",[282,1681,991],{"class":650},[282,1683,1684],{"class":654},"FLY_REGION\n",[282,1686,1687],{"class":284,"line":789},[282,1688,1689],{"class":650},"  },\n",[282,1691,1692,1695,1697,1699,1701,1703,1705],{"class":284,"line":816},[282,1693,1694],{"class":809},"  keep",[282,1696,877],{"class":650},[282,1698,898],{"class":650},[282,1700,1648],{"class":873},[282,1702,488],{"class":650},[282,1704,927],{"class":772},[282,1706,706],{"class":650},[282,1708,1709,1711,1713,1715,1717,1720,1723,1726,1728,1730,1733,1737,1739,1741,1743,1746,1748],{"class":284,"line":830},[282,1710,1137],{"class":643},[282,1712,898],{"class":974},[282,1714,1648],{"class":654},[282,1716,991],{"class":650},[282,1718,1719],{"class":654},"duration",[282,1721,1722],{"class":650}," &&",[282,1724,1725],{"class":654}," ctx",[282,1727,991],{"class":650},[282,1729,1719],{"class":654},[282,1731,1732],{"class":650}," >",[282,1734,1736],{"class":1735},"sbssI"," 2000",[282,1738,1069],{"class":974},[282,1740,1648],{"class":654},[282,1742,991],{"class":650},[282,1744,1745],{"class":654},"shouldKeep",[282,1747,778],{"class":650},[282,1749,1751],{"class":1750},"sfNiH"," true\n",[282,1753,1754],{"class":284,"line":836},[282,1755,1689],{"class":650},[282,1757,1758,1760],{"class":284,"line":841},[282,1759,748],{"class":650},[282,1761,1762],{"class":654},"))\n",[282,1764,1765],{"class":284,"line":854},[282,1766,763],{"emptyLinePlaceholder":762},[282,1768,1769,1771,1773,1776,1778,1780,1783,1785,1787,1789,1791,1793,1795,1797,1799],{"class":284,"line":859},[282,1770,1588],{"class":654},[282,1772,991],{"class":650},[282,1774,1775],{"class":809},"get",[282,1777,870],{"class":654},[282,1779,825],{"class":650},[282,1781,1782],{"class":291},"\u002Fapi\u002Fusers",[282,1784,825],{"class":650},[282,1786,658],{"class":650},[282,1788,898],{"class":650},[282,1790,901],{"class":873},[282,1792,658],{"class":650},[282,1794,910],{"class":873},[282,1796,488],{"class":650},[282,1798,927],{"class":772},[282,1800,706],{"class":650},[282,1802,1803,1806,1808,1810,1812,1815,1817,1819,1822,1824,1826,1829,1831,1834,1836,1838],{"class":284,"line":889},[282,1804,1805],{"class":654},"  req",[282,1807,991],{"class":650},[282,1809,1209],{"class":654},[282,1811,991],{"class":650},[282,1813,1814],{"class":809},"set",[282,1816,870],{"class":974},[282,1818,1266],{"class":650},[282,1820,1821],{"class":974}," users",[282,1823,877],{"class":650},[282,1825,651],{"class":650},[282,1827,1828],{"class":974}," count",[282,1830,877],{"class":650},[282,1832,1833],{"class":1735}," 42",[282,1835,664],{"class":650},[282,1837,664],{"class":650},[282,1839,833],{"class":974},[282,1841,1842,1845,1847,1850,1852,1854,1856,1858,1861,1863],{"class":284,"line":946},[282,1843,1844],{"class":654},"  res",[282,1846,991],{"class":650},[282,1848,1849],{"class":809},"json",[282,1851,870],{"class":974},[282,1853,1266],{"class":650},[282,1855,1821],{"class":974},[282,1857,877],{"class":650},[282,1859,1860],{"class":974}," [] ",[282,1862,748],{"class":650},[282,1864,833],{"class":974},[282,1866,1867,1869],{"class":284,"line":980},[282,1868,748],{"class":650},[282,1870,833],{"class":654},[282,1872,1873],{"class":284,"line":1008},[282,1874,763],{"emptyLinePlaceholder":762},[282,1876,1877],{"class":284,"line":1034},[282,1878,1880],{"class":1879},"sHwdD","\u002F\u002F Access logger from anywhere in the call stack\n",[282,1882,1883,1886,1889,1891],{"class":284,"line":1088},[282,1884,1885],{"class":772},"function",[282,1887,1888],{"class":809}," findUsers",[282,1890,1083],{"class":650},[282,1892,706],{"class":650},[282,1894,1895,1898,1900,1902,1904],{"class":284,"line":1111},[282,1896,1897],{"class":772},"  const",[282,1899,1196],{"class":654},[282,1901,778],{"class":650},[282,1903,848],{"class":809},[282,1905,1156],{"class":974},[282,1907,1908,1911,1913,1915,1917,1919,1922,1924,1926,1929,1931,1933,1936,1938,1940,1942],{"class":284,"line":1121},[282,1909,1910],{"class":654},"  log",[282,1912,991],{"class":650},[282,1914,1814],{"class":809},[282,1916,870],{"class":974},[282,1918,1266],{"class":650},[282,1920,1921],{"class":974}," db",[282,1923,877],{"class":650},[282,1925,651],{"class":650},[282,1927,1928],{"class":974}," query",[282,1930,877],{"class":650},[282,1932,670],{"class":650},[282,1934,1935],{"class":291},"SELECT * FROM users",[282,1937,825],{"class":650},[282,1939,664],{"class":650},[282,1941,664],{"class":650},[282,1943,833],{"class":974},[282,1945,1946],{"class":284,"line":1129},[282,1947,1351],{"class":650},[264,1949,1951],{"id":1950},"reference-implementations","Reference Implementations",[244,1953,1954],{},"Study these built-in integrations for framework-specific patterns:",[330,1956,1957,1973],{},[333,1958,1959],{},[336,1960,1961,1964,1967,1970],{},[339,1962,1963],{},"Framework",[339,1965,1966],{},"Lines",[339,1968,1969],{},"Pattern",[339,1971,1972],{},"Source",[346,1974,1975,1998,2020,2046],{},[336,1976,1977,1979,1982,1989],{},[351,1978,76],{},[351,1980,1981],{},"~40",[351,1983,1984,1985,1988],{},"Web API Headers, ",[248,1986,1987],{},"c.set()",", try\u002Fcatch",[351,1990,1991],{},[1992,1993,1997],"a",{"href":1994,"rel":1995},"https:\u002F\u002Fgithub.com\u002FHugoRCD\u002Fevlog\u002Fblob\u002Fmain\u002Fpackages\u002Fevlog\u002Fsrc\u002Fhono\u002Findex.ts",[1996],"nofollow","hono\u002Findex.ts",[336,1999,2000,2002,2005,2013],{},[351,2001,71],{},[351,2003,2004],{},"~60",[351,2006,2007,2008,372,2010],{},"Node.js headers, ",[248,2009,601],{},[248,2011,2012],{},"res.on('finish')",[351,2014,2015],{},[1992,2016,2019],{"href":2017,"rel":2018},"https:\u002F\u002Fgithub.com\u002FHugoRCD\u002Fevlog\u002Fblob\u002Fmain\u002Fpackages\u002Fevlog\u002Fsrc\u002Fexpress\u002Findex.ts",[1996],"express\u002Findex.ts",[336,2021,2022,2024,2027,2039],{},[351,2023,86],{},[351,2025,2026],{},"~70",[351,2028,2029,2030,372,2033,1027,2036],{},"Plugin API, ",[248,2031,2032],{},"derive()",[248,2034,2035],{},"onAfterHandle",[248,2037,2038],{},"onError",[351,2040,2041],{},[1992,2042,2045],{"href":2043,"rel":2044},"https:\u002F\u002Fgithub.com\u002FHugoRCD\u002Fevlog\u002Fblob\u002Fmain\u002Fpackages\u002Fevlog\u002Fsrc\u002Felysia\u002Findex.ts",[1996],"elysia\u002Findex.ts",[336,2047,2048,2050,2052,2065],{},[351,2049,81],{},[351,2051,2026],{},[351,2053,2054,2055,372,2058,1027,2061,2064],{},"Plugin, ",[248,2056,2057],{},"decorateRequest",[248,2059,2060],{},"onRequest",[248,2062,2063],{},"onResponse"," hooks",[351,2066,2067],{},[1992,2068,2071],{"href":2069,"rel":2070},"https:\u002F\u002Fgithub.com\u002FHugoRCD\u002Fevlog\u002Fblob\u002Fmain\u002Fpackages\u002Fevlog\u002Fsrc\u002Ffastify\u002Findex.ts",[1996],"fastify\u002Findex.ts",[253,2073,2076,2077,2082],{"color":2074,"icon":2075},"neutral","i-lucide-heart","Built an integration for a framework we don't support? ",[1992,2078,2081],{"href":2079,"rel":2080},"https:\u002F\u002Fgithub.com\u002FHugoRCD\u002Fevlog\u002Fpulls",[1996],"Open a PR"," - the community will thank you.",[2084,2085,2086],"style",{},"html pre.shiki code .sBMFI, html code.shiki .sBMFI{--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}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 .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .s7zQu, html code.shiki .s7zQu{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic}html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .sTEyZ, html code.shiki .sTEyZ{--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8}html pre.shiki code .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .sHdIc, html code.shiki .sHdIc{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#EEFFFF;--shiki-default-font-style:italic;--shiki-dark:#BABED8;--shiki-dark-font-style:italic}html pre.shiki code .swJcz, html code.shiki .swJcz{--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178}html pre.shiki code .sbssI, html code.shiki .sbssI{--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C}html pre.shiki code .sfNiH, html code.shiki .sfNiH{--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC}html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}",{"title":278,"searchDepth":679,"depth":679,"links":2088},[2089,2090,2091,2092,2093,2094,2095],{"id":266,"depth":679,"text":267},{"id":327,"depth":679,"text":328},{"id":535,"depth":679,"text":536},{"id":626,"depth":679,"text":627},{"id":1361,"depth":679,"text":1362},{"id":1470,"depth":679,"text":1471},{"id":1950,"depth":679,"text":1951},"Build your own evlog framework integration using the toolkit API with createMiddlewareLogger, header extraction, AsyncLocalStorage, and the full drain\u002Fenrich\u002Fkeep pipeline.","md",null,{},{"title":106,"icon":109},{"title":106,"description":2096},"J_vkuY-H0ws0wKRBRmj1TIMQJY11nXf--s6Xyggd59M",[2104,2106],{"title":101,"path":102,"stem":103,"description":2105,"icon":104,"children":-1},"Wide events and structured errors in Astro server middleware.",{"title":116,"path":117,"stem":118,"description":2107,"icon":119,"children":-1},"Understand the full lifecycle of a request in evlog, from creation to drain. Every step from logger creation, context accumulation, sampling, enrichment, to external delivery.",1773504119851]