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