[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-encore-encore-code-review":3,"mdc-gqzeyv-key":34,"related-org-encore-encore-code-review":2834,"related-repo-encore-encore-code-review":3003},{"slug":4,"name":4,"fn":5,"description":6,"org":7,"tags":12,"stars":21,"repoUrl":22,"updatedAt":23,"license":24,"forks":25,"topics":26,"repo":29,"sourceUrl":32,"mdContent":33},"encore-code-review","review Encore.ts code","Review existing Encore.ts code for best practices and common anti-patterns.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},"encore","Encore","https:\u002F\u002Fpexgzepcugksgbtrxkhf.supabase.co\u002Fstorage\u002Fv1\u002Fobject\u002Fpublic\u002Forg-logos\u002Fencore.png","encoredev",[13,17,20],{"name":14,"slug":15,"type":16},"Code Review","code-review","tag",{"name":18,"slug":19,"type":16},"TypeScript","typescript",{"name":9,"slug":8,"type":16},26,"https:\u002F\u002Fgithub.com\u002Fencoredev\u002Fskills","2026-04-06T18:10:01.123999",null,5,[27,28],"claude-code","skills",{"repoUrl":22,"stars":21,"forks":25,"topics":30,"description":31},[27,28],"Agent Skills for development with Encore.","https:\u002F\u002Fgithub.com\u002Fencoredev\u002Fskills\u002Ftree\u002FHEAD\u002Fencore\u002Fcode-review","---\nname: encore-code-review\ndescription: Review existing Encore.ts code for best practices and common anti-patterns.\nwhen_to_use: >-\n  User is reviewing a pull request, auditing existing code, or checking for Encore-specific anti-patterns before merging — infrastructure declared inside functions, missing service files, wrong import paths, raw `Error` thrown instead of `APIError`, untyped APIs. SKIP for greenfield code being actively written. Trigger phrases: \"audit\", \"review\", \"before merge\", \"PR review\", \"anti-patterns\", \"code smell\", \"lint this\".\n---\n\n# Encore Code Review\n\n## Instructions\n\nWhen reviewing Encore.ts code, check for these common issues:\n\n## Critical Issues\n\n### 1. Infrastructure Inside Functions\n\n```typescript\n\u002F\u002F WRONG: Infrastructure declared inside function\nasync function setup() {\n  const db = new SQLDatabase(\"mydb\", { migrations: \".\u002Fmigrations\" });\n  const topic = new Topic\u003CEvent>(\"events\", { deliveryGuarantee: \"at-least-once\" });\n}\n\n\u002F\u002F CORRECT: Package level declaration\nconst db = new SQLDatabase(\"mydb\", { migrations: \".\u002Fmigrations\" });\nconst topic = new Topic\u003CEvent>(\"events\", { deliveryGuarantee: \"at-least-once\" });\n```\n\n### 2. Using require() Instead of import\n\n```typescript\n\u002F\u002F WRONG\nconst { api } = require(\"encore.dev\u002Fapi\");\n\n\u002F\u002F CORRECT\nimport { api } from \"encore.dev\u002Fapi\";\n```\n\n### 3. Wrong Service Import Pattern\n\n```typescript\n\u002F\u002F WRONG: Direct import from another service\nimport { getUser } from \"..\u002Fuser\u002Fapi\";\n\n\u002F\u002F CORRECT: Use ~encore\u002Fclients\nimport { user } from \"~encore\u002Fclients\";\nconst result = await user.getUser({ id });\n```\n\n### 4. Missing Error Handling\n\n```typescript\n\u002F\u002F WRONG: Returning null for not found\nconst user = await db.queryRow`SELECT * FROM users WHERE id = ${id}`;\nif (!user) return null;\n\n\u002F\u002F CORRECT: Throw APIError\nimport { APIError } from \"encore.dev\u002Fapi\";\n\nconst user = await db.queryRow`SELECT * FROM users WHERE id = ${id}`;\nif (!user) {\n  throw APIError.notFound(\"user not found\");\n}\n```\n\n### 5. SQL Injection Risk\n\n```typescript\n\u002F\u002F WRONG: String concatenation\nawait db.query(`SELECT * FROM users WHERE email = '${email}'`);\n\n\u002F\u002F CORRECT: Template literal with automatic escaping\nawait db.queryRow`SELECT * FROM users WHERE email = ${email}`;\n```\n\n## Warning Issues\n\n### 6. Missing Type Annotations\n\n```typescript\n\u002F\u002F WEAK: No explicit types\nexport const getUser = api(\n  { method: \"GET\", path: \"\u002Fusers\u002F:id\", expose: true },\n  async ({ id }) => {\n    return await findUser(id);\n  }\n);\n\n\u002F\u002F BETTER: Explicit request\u002Fresponse types\ninterface GetUserRequest { id: string; }\ninterface User { id: string; email: string; name: string; }\n\nexport const getUser = api(\n  { method: \"GET\", path: \"\u002Fusers\u002F:id\", expose: true },\n  async ({ id }: GetUserRequest): Promise\u003CUser> => {\n    return await findUser(id);\n  }\n);\n```\n\n### 7. Exposed Internal Endpoints\n\n```typescript\n\u002F\u002F CHECK: Should this cron endpoint be exposed?\nexport const cleanupJob = api(\n  { expose: true },  \u002F\u002F Probably should be false\n  async () => { \u002F* ... *\u002F }\n);\n```\n\n### 8. Non-Idempotent Subscription Handlers\n\n```typescript\n\u002F\u002F RISKY: Not idempotent (pubsub has at-least-once delivery)\nconst _ = new Subscription(orderCreated, \"process-order\", {\n  handler: async (event) => {\n    await chargeCustomer(event.orderId);  \u002F\u002F Could charge twice!\n  },\n});\n\n\u002F\u002F SAFER: Check before processing\nconst _ = new Subscription(orderCreated, \"process-order\", {\n  handler: async (event) => {\n    const order = await getOrder(event.orderId);\n    if (order.status !== \"pending\") return;  \u002F\u002F Already processed\n    await chargeCustomer(event.orderId);\n  },\n});\n```\n\n### 9. Secrets Called at Module Level\n\n```typescript\n\u002F\u002F WRONG: Secret accessed at startup\nconst stripeKey = secret(\"StripeKey\");\nconst client = new Stripe(stripeKey());  \u002F\u002F Called during import\n\n\u002F\u002F CORRECT: Access inside functions\nconst stripeKey = secret(\"StripeKey\");\n\nasync function charge() {\n  const client = new Stripe(stripeKey());  \u002F\u002F Called at runtime\n}\n```\n\n## Review Checklist\n\n- [ ] All infrastructure at package level\n- [ ] Using ES6 imports, not require()\n- [ ] Cross-service calls use `~encore\u002Fclients`\n- [ ] Proper error handling with APIError\n- [ ] SQL uses template literals\n- [ ] Request\u002Fresponse types defined\n- [ ] Internal endpoints have `expose: false`\n- [ ] Subscription handlers are idempotent\n- [ ] Secrets accessed inside functions, not at import time\n- [ ] Migrations follow naming convention (001_name.up.sql)\n\n## Output Format\n\nWhen reviewing, report issues as:\n\n```\n[CRITICAL] [file:line] Description of issue\n[WARNING] [file:line] Description of concern  \n[GOOD] Notable good practice observed\n```\n",{"data":35,"body":37},{"name":4,"description":6,"when_to_use":36},"User is reviewing a pull request, auditing existing code, or checking for Encore-specific anti-patterns before merging — infrastructure declared inside functions, missing service files, wrong import paths, raw `Error` thrown instead of `APIError`, untyped APIs. SKIP for greenfield code being actively written. Trigger phrases: \"audit\", \"review\", \"before merge\", \"PR review\", \"anti-patterns\", \"code smell\", \"lint this\".",{"type":38,"children":39},"root",[40,48,55,61,67,74,533,539,667,673,846,852,1158,1164,1302,1308,1314,1866,1872,1984,1990,2434,2440,2690,2696,2807,2813,2818,2828],{"type":41,"tag":42,"props":43,"children":44},"element","h1",{"id":4},[45],{"type":46,"value":47},"text","Encore Code Review",{"type":41,"tag":49,"props":50,"children":52},"h2",{"id":51},"instructions",[53],{"type":46,"value":54},"Instructions",{"type":41,"tag":56,"props":57,"children":58},"p",{},[59],{"type":46,"value":60},"When reviewing Encore.ts code, check for these common issues:",{"type":41,"tag":49,"props":62,"children":64},{"id":63},"critical-issues",[65],{"type":46,"value":66},"Critical Issues",{"type":41,"tag":68,"props":69,"children":71},"h3",{"id":70},"_1-infrastructure-inside-functions",[72],{"type":46,"value":73},"1. Infrastructure Inside Functions",{"type":41,"tag":75,"props":76,"children":80},"pre",{"className":77,"code":78,"language":19,"meta":79,"style":79},"language-typescript shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","\u002F\u002F WRONG: Infrastructure declared inside function\nasync function setup() {\n  const db = new SQLDatabase(\"mydb\", { migrations: \".\u002Fmigrations\" });\n  const topic = new Topic\u003CEvent>(\"events\", { deliveryGuarantee: \"at-least-once\" });\n}\n\n\u002F\u002F CORRECT: Package level declaration\nconst db = new SQLDatabase(\"mydb\", { migrations: \".\u002Fmigrations\" });\nconst topic = new Topic\u003CEvent>(\"events\", { deliveryGuarantee: \"at-least-once\" });\n","",[81],{"type":41,"tag":82,"props":83,"children":84},"code",{"__ignoreMap":79},[85,97,129,229,330,338,348,357,440],{"type":41,"tag":86,"props":87,"children":90},"span",{"class":88,"line":89},"line",1,[91],{"type":41,"tag":86,"props":92,"children":94},{"style":93},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic",[95],{"type":46,"value":96},"\u002F\u002F WRONG: Infrastructure declared inside function\n",{"type":41,"tag":86,"props":98,"children":100},{"class":88,"line":99},2,[101,107,112,118,124],{"type":41,"tag":86,"props":102,"children":104},{"style":103},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[105],{"type":46,"value":106},"async",{"type":41,"tag":86,"props":108,"children":109},{"style":103},[110],{"type":46,"value":111}," function",{"type":41,"tag":86,"props":113,"children":115},{"style":114},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[116],{"type":46,"value":117}," setup",{"type":41,"tag":86,"props":119,"children":121},{"style":120},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[122],{"type":46,"value":123},"()",{"type":41,"tag":86,"props":125,"children":126},{"style":120},[127],{"type":46,"value":128}," {\n",{"type":41,"tag":86,"props":130,"children":132},{"class":88,"line":131},3,[133,138,144,149,154,159,165,170,176,180,185,190,195,200,205,210,214,219,224],{"type":41,"tag":86,"props":134,"children":135},{"style":103},[136],{"type":46,"value":137},"  const",{"type":41,"tag":86,"props":139,"children":141},{"style":140},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[142],{"type":46,"value":143}," db",{"type":41,"tag":86,"props":145,"children":146},{"style":120},[147],{"type":46,"value":148}," =",{"type":41,"tag":86,"props":150,"children":151},{"style":120},[152],{"type":46,"value":153}," new",{"type":41,"tag":86,"props":155,"children":156},{"style":114},[157],{"type":46,"value":158}," SQLDatabase",{"type":41,"tag":86,"props":160,"children":162},{"style":161},"--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178",[163],{"type":46,"value":164},"(",{"type":41,"tag":86,"props":166,"children":167},{"style":120},[168],{"type":46,"value":169},"\"",{"type":41,"tag":86,"props":171,"children":173},{"style":172},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[174],{"type":46,"value":175},"mydb",{"type":41,"tag":86,"props":177,"children":178},{"style":120},[179],{"type":46,"value":169},{"type":41,"tag":86,"props":181,"children":182},{"style":120},[183],{"type":46,"value":184},",",{"type":41,"tag":86,"props":186,"children":187},{"style":120},[188],{"type":46,"value":189}," {",{"type":41,"tag":86,"props":191,"children":192},{"style":161},[193],{"type":46,"value":194}," migrations",{"type":41,"tag":86,"props":196,"children":197},{"style":120},[198],{"type":46,"value":199},":",{"type":41,"tag":86,"props":201,"children":202},{"style":120},[203],{"type":46,"value":204}," \"",{"type":41,"tag":86,"props":206,"children":207},{"style":172},[208],{"type":46,"value":209},".\u002Fmigrations",{"type":41,"tag":86,"props":211,"children":212},{"style":120},[213],{"type":46,"value":169},{"type":41,"tag":86,"props":215,"children":216},{"style":120},[217],{"type":46,"value":218}," }",{"type":41,"tag":86,"props":220,"children":221},{"style":161},[222],{"type":46,"value":223},")",{"type":41,"tag":86,"props":225,"children":226},{"style":120},[227],{"type":46,"value":228},";\n",{"type":41,"tag":86,"props":230,"children":232},{"class":88,"line":231},4,[233,237,242,246,250,255,260,266,271,275,279,284,288,292,296,301,305,309,314,318,322,326],{"type":41,"tag":86,"props":234,"children":235},{"style":103},[236],{"type":46,"value":137},{"type":41,"tag":86,"props":238,"children":239},{"style":140},[240],{"type":46,"value":241}," topic",{"type":41,"tag":86,"props":243,"children":244},{"style":120},[245],{"type":46,"value":148},{"type":41,"tag":86,"props":247,"children":248},{"style":120},[249],{"type":46,"value":153},{"type":41,"tag":86,"props":251,"children":252},{"style":114},[253],{"type":46,"value":254}," Topic",{"type":41,"tag":86,"props":256,"children":257},{"style":120},[258],{"type":46,"value":259},"\u003C",{"type":41,"tag":86,"props":261,"children":263},{"style":262},"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B",[264],{"type":46,"value":265},"Event",{"type":41,"tag":86,"props":267,"children":268},{"style":120},[269],{"type":46,"value":270},">",{"type":41,"tag":86,"props":272,"children":273},{"style":161},[274],{"type":46,"value":164},{"type":41,"tag":86,"props":276,"children":277},{"style":120},[278],{"type":46,"value":169},{"type":41,"tag":86,"props":280,"children":281},{"style":172},[282],{"type":46,"value":283},"events",{"type":41,"tag":86,"props":285,"children":286},{"style":120},[287],{"type":46,"value":169},{"type":41,"tag":86,"props":289,"children":290},{"style":120},[291],{"type":46,"value":184},{"type":41,"tag":86,"props":293,"children":294},{"style":120},[295],{"type":46,"value":189},{"type":41,"tag":86,"props":297,"children":298},{"style":161},[299],{"type":46,"value":300}," deliveryGuarantee",{"type":41,"tag":86,"props":302,"children":303},{"style":120},[304],{"type":46,"value":199},{"type":41,"tag":86,"props":306,"children":307},{"style":120},[308],{"type":46,"value":204},{"type":41,"tag":86,"props":310,"children":311},{"style":172},[312],{"type":46,"value":313},"at-least-once",{"type":41,"tag":86,"props":315,"children":316},{"style":120},[317],{"type":46,"value":169},{"type":41,"tag":86,"props":319,"children":320},{"style":120},[321],{"type":46,"value":218},{"type":41,"tag":86,"props":323,"children":324},{"style":161},[325],{"type":46,"value":223},{"type":41,"tag":86,"props":327,"children":328},{"style":120},[329],{"type":46,"value":228},{"type":41,"tag":86,"props":331,"children":332},{"class":88,"line":25},[333],{"type":41,"tag":86,"props":334,"children":335},{"style":120},[336],{"type":46,"value":337},"}\n",{"type":41,"tag":86,"props":339,"children":341},{"class":88,"line":340},6,[342],{"type":41,"tag":86,"props":343,"children":345},{"emptyLinePlaceholder":344},true,[346],{"type":46,"value":347},"\n",{"type":41,"tag":86,"props":349,"children":351},{"class":88,"line":350},7,[352],{"type":41,"tag":86,"props":353,"children":354},{"style":93},[355],{"type":46,"value":356},"\u002F\u002F CORRECT: Package level declaration\n",{"type":41,"tag":86,"props":358,"children":360},{"class":88,"line":359},8,[361,366,371,376,380,384,388,392,396,400,404,408,412,416,420,424,428,432,436],{"type":41,"tag":86,"props":362,"children":363},{"style":103},[364],{"type":46,"value":365},"const",{"type":41,"tag":86,"props":367,"children":368},{"style":140},[369],{"type":46,"value":370}," db ",{"type":41,"tag":86,"props":372,"children":373},{"style":120},[374],{"type":46,"value":375},"=",{"type":41,"tag":86,"props":377,"children":378},{"style":120},[379],{"type":46,"value":153},{"type":41,"tag":86,"props":381,"children":382},{"style":114},[383],{"type":46,"value":158},{"type":41,"tag":86,"props":385,"children":386},{"style":140},[387],{"type":46,"value":164},{"type":41,"tag":86,"props":389,"children":390},{"style":120},[391],{"type":46,"value":169},{"type":41,"tag":86,"props":393,"children":394},{"style":172},[395],{"type":46,"value":175},{"type":41,"tag":86,"props":397,"children":398},{"style":120},[399],{"type":46,"value":169},{"type":41,"tag":86,"props":401,"children":402},{"style":120},[403],{"type":46,"value":184},{"type":41,"tag":86,"props":405,"children":406},{"style":120},[407],{"type":46,"value":189},{"type":41,"tag":86,"props":409,"children":410},{"style":161},[411],{"type":46,"value":194},{"type":41,"tag":86,"props":413,"children":414},{"style":120},[415],{"type":46,"value":199},{"type":41,"tag":86,"props":417,"children":418},{"style":120},[419],{"type":46,"value":204},{"type":41,"tag":86,"props":421,"children":422},{"style":172},[423],{"type":46,"value":209},{"type":41,"tag":86,"props":425,"children":426},{"style":120},[427],{"type":46,"value":169},{"type":41,"tag":86,"props":429,"children":430},{"style":120},[431],{"type":46,"value":218},{"type":41,"tag":86,"props":433,"children":434},{"style":140},[435],{"type":46,"value":223},{"type":41,"tag":86,"props":437,"children":438},{"style":120},[439],{"type":46,"value":228},{"type":41,"tag":86,"props":441,"children":443},{"class":88,"line":442},9,[444,448,453,457,461,465,469,473,477,481,485,489,493,497,501,505,509,513,517,521,525,529],{"type":41,"tag":86,"props":445,"children":446},{"style":103},[447],{"type":46,"value":365},{"type":41,"tag":86,"props":449,"children":450},{"style":140},[451],{"type":46,"value":452}," topic ",{"type":41,"tag":86,"props":454,"children":455},{"style":120},[456],{"type":46,"value":375},{"type":41,"tag":86,"props":458,"children":459},{"style":120},[460],{"type":46,"value":153},{"type":41,"tag":86,"props":462,"children":463},{"style":114},[464],{"type":46,"value":254},{"type":41,"tag":86,"props":466,"children":467},{"style":120},[468],{"type":46,"value":259},{"type":41,"tag":86,"props":470,"children":471},{"style":262},[472],{"type":46,"value":265},{"type":41,"tag":86,"props":474,"children":475},{"style":120},[476],{"type":46,"value":270},{"type":41,"tag":86,"props":478,"children":479},{"style":140},[480],{"type":46,"value":164},{"type":41,"tag":86,"props":482,"children":483},{"style":120},[484],{"type":46,"value":169},{"type":41,"tag":86,"props":486,"children":487},{"style":172},[488],{"type":46,"value":283},{"type":41,"tag":86,"props":490,"children":491},{"style":120},[492],{"type":46,"value":169},{"type":41,"tag":86,"props":494,"children":495},{"style":120},[496],{"type":46,"value":184},{"type":41,"tag":86,"props":498,"children":499},{"style":120},[500],{"type":46,"value":189},{"type":41,"tag":86,"props":502,"children":503},{"style":161},[504],{"type":46,"value":300},{"type":41,"tag":86,"props":506,"children":507},{"style":120},[508],{"type":46,"value":199},{"type":41,"tag":86,"props":510,"children":511},{"style":120},[512],{"type":46,"value":204},{"type":41,"tag":86,"props":514,"children":515},{"style":172},[516],{"type":46,"value":313},{"type":41,"tag":86,"props":518,"children":519},{"style":120},[520],{"type":46,"value":169},{"type":41,"tag":86,"props":522,"children":523},{"style":120},[524],{"type":46,"value":218},{"type":41,"tag":86,"props":526,"children":527},{"style":140},[528],{"type":46,"value":223},{"type":41,"tag":86,"props":530,"children":531},{"style":120},[532],{"type":46,"value":228},{"type":41,"tag":68,"props":534,"children":536},{"id":535},"_2-using-require-instead-of-import",[537],{"type":46,"value":538},"2. Using require() Instead of import",{"type":41,"tag":75,"props":540,"children":542},{"className":77,"code":541,"language":19,"meta":79,"style":79},"\u002F\u002F WRONG\nconst { api } = require(\"encore.dev\u002Fapi\");\n\n\u002F\u002F CORRECT\nimport { api } from \"encore.dev\u002Fapi\";\n",[543],{"type":41,"tag":82,"props":544,"children":545},{"__ignoreMap":79},[546,554,609,616,624],{"type":41,"tag":86,"props":547,"children":548},{"class":88,"line":89},[549],{"type":41,"tag":86,"props":550,"children":551},{"style":93},[552],{"type":46,"value":553},"\u002F\u002F WRONG\n",{"type":41,"tag":86,"props":555,"children":556},{"class":88,"line":99},[557,561,565,570,575,579,584,588,592,597,601,605],{"type":41,"tag":86,"props":558,"children":559},{"style":103},[560],{"type":46,"value":365},{"type":41,"tag":86,"props":562,"children":563},{"style":120},[564],{"type":46,"value":189},{"type":41,"tag":86,"props":566,"children":567},{"style":140},[568],{"type":46,"value":569}," api ",{"type":41,"tag":86,"props":571,"children":572},{"style":120},[573],{"type":46,"value":574},"}",{"type":41,"tag":86,"props":576,"children":577},{"style":120},[578],{"type":46,"value":148},{"type":41,"tag":86,"props":580,"children":581},{"style":114},[582],{"type":46,"value":583}," require",{"type":41,"tag":86,"props":585,"children":586},{"style":140},[587],{"type":46,"value":164},{"type":41,"tag":86,"props":589,"children":590},{"style":120},[591],{"type":46,"value":169},{"type":41,"tag":86,"props":593,"children":594},{"style":172},[595],{"type":46,"value":596},"encore.dev\u002Fapi",{"type":41,"tag":86,"props":598,"children":599},{"style":120},[600],{"type":46,"value":169},{"type":41,"tag":86,"props":602,"children":603},{"style":140},[604],{"type":46,"value":223},{"type":41,"tag":86,"props":606,"children":607},{"style":120},[608],{"type":46,"value":228},{"type":41,"tag":86,"props":610,"children":611},{"class":88,"line":131},[612],{"type":41,"tag":86,"props":613,"children":614},{"emptyLinePlaceholder":344},[615],{"type":46,"value":347},{"type":41,"tag":86,"props":617,"children":618},{"class":88,"line":231},[619],{"type":41,"tag":86,"props":620,"children":621},{"style":93},[622],{"type":46,"value":623},"\u002F\u002F CORRECT\n",{"type":41,"tag":86,"props":625,"children":626},{"class":88,"line":25},[627,633,637,642,646,651,655,659,663],{"type":41,"tag":86,"props":628,"children":630},{"style":629},"--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic",[631],{"type":46,"value":632},"import",{"type":41,"tag":86,"props":634,"children":635},{"style":120},[636],{"type":46,"value":189},{"type":41,"tag":86,"props":638,"children":639},{"style":140},[640],{"type":46,"value":641}," api",{"type":41,"tag":86,"props":643,"children":644},{"style":120},[645],{"type":46,"value":218},{"type":41,"tag":86,"props":647,"children":648},{"style":629},[649],{"type":46,"value":650}," from",{"type":41,"tag":86,"props":652,"children":653},{"style":120},[654],{"type":46,"value":204},{"type":41,"tag":86,"props":656,"children":657},{"style":172},[658],{"type":46,"value":596},{"type":41,"tag":86,"props":660,"children":661},{"style":120},[662],{"type":46,"value":169},{"type":41,"tag":86,"props":664,"children":665},{"style":120},[666],{"type":46,"value":228},{"type":41,"tag":68,"props":668,"children":670},{"id":669},"_3-wrong-service-import-pattern",[671],{"type":46,"value":672},"3. Wrong Service Import Pattern",{"type":41,"tag":75,"props":674,"children":676},{"className":77,"code":675,"language":19,"meta":79,"style":79},"\u002F\u002F WRONG: Direct import from another service\nimport { getUser } from \"..\u002Fuser\u002Fapi\";\n\n\u002F\u002F CORRECT: Use ~encore\u002Fclients\nimport { user } from \"~encore\u002Fclients\";\nconst result = await user.getUser({ id });\n",[677],{"type":41,"tag":82,"props":678,"children":679},{"__ignoreMap":79},[680,688,729,736,744,785],{"type":41,"tag":86,"props":681,"children":682},{"class":88,"line":89},[683],{"type":41,"tag":86,"props":684,"children":685},{"style":93},[686],{"type":46,"value":687},"\u002F\u002F WRONG: Direct import from another service\n",{"type":41,"tag":86,"props":689,"children":690},{"class":88,"line":99},[691,695,699,704,708,712,716,721,725],{"type":41,"tag":86,"props":692,"children":693},{"style":629},[694],{"type":46,"value":632},{"type":41,"tag":86,"props":696,"children":697},{"style":120},[698],{"type":46,"value":189},{"type":41,"tag":86,"props":700,"children":701},{"style":140},[702],{"type":46,"value":703}," getUser",{"type":41,"tag":86,"props":705,"children":706},{"style":120},[707],{"type":46,"value":218},{"type":41,"tag":86,"props":709,"children":710},{"style":629},[711],{"type":46,"value":650},{"type":41,"tag":86,"props":713,"children":714},{"style":120},[715],{"type":46,"value":204},{"type":41,"tag":86,"props":717,"children":718},{"style":172},[719],{"type":46,"value":720},"..\u002Fuser\u002Fapi",{"type":41,"tag":86,"props":722,"children":723},{"style":120},[724],{"type":46,"value":169},{"type":41,"tag":86,"props":726,"children":727},{"style":120},[728],{"type":46,"value":228},{"type":41,"tag":86,"props":730,"children":731},{"class":88,"line":131},[732],{"type":41,"tag":86,"props":733,"children":734},{"emptyLinePlaceholder":344},[735],{"type":46,"value":347},{"type":41,"tag":86,"props":737,"children":738},{"class":88,"line":231},[739],{"type":41,"tag":86,"props":740,"children":741},{"style":93},[742],{"type":46,"value":743},"\u002F\u002F CORRECT: Use ~encore\u002Fclients\n",{"type":41,"tag":86,"props":745,"children":746},{"class":88,"line":25},[747,751,755,760,764,768,772,777,781],{"type":41,"tag":86,"props":748,"children":749},{"style":629},[750],{"type":46,"value":632},{"type":41,"tag":86,"props":752,"children":753},{"style":120},[754],{"type":46,"value":189},{"type":41,"tag":86,"props":756,"children":757},{"style":140},[758],{"type":46,"value":759}," user",{"type":41,"tag":86,"props":761,"children":762},{"style":120},[763],{"type":46,"value":218},{"type":41,"tag":86,"props":765,"children":766},{"style":629},[767],{"type":46,"value":650},{"type":41,"tag":86,"props":769,"children":770},{"style":120},[771],{"type":46,"value":204},{"type":41,"tag":86,"props":773,"children":774},{"style":172},[775],{"type":46,"value":776},"~encore\u002Fclients",{"type":41,"tag":86,"props":778,"children":779},{"style":120},[780],{"type":46,"value":169},{"type":41,"tag":86,"props":782,"children":783},{"style":120},[784],{"type":46,"value":228},{"type":41,"tag":86,"props":786,"children":787},{"class":88,"line":340},[788,792,797,801,806,810,815,820,824,829,834,838,842],{"type":41,"tag":86,"props":789,"children":790},{"style":103},[791],{"type":46,"value":365},{"type":41,"tag":86,"props":793,"children":794},{"style":140},[795],{"type":46,"value":796}," result ",{"type":41,"tag":86,"props":798,"children":799},{"style":120},[800],{"type":46,"value":375},{"type":41,"tag":86,"props":802,"children":803},{"style":629},[804],{"type":46,"value":805}," await",{"type":41,"tag":86,"props":807,"children":808},{"style":140},[809],{"type":46,"value":759},{"type":41,"tag":86,"props":811,"children":812},{"style":120},[813],{"type":46,"value":814},".",{"type":41,"tag":86,"props":816,"children":817},{"style":114},[818],{"type":46,"value":819},"getUser",{"type":41,"tag":86,"props":821,"children":822},{"style":140},[823],{"type":46,"value":164},{"type":41,"tag":86,"props":825,"children":826},{"style":120},[827],{"type":46,"value":828},"{",{"type":41,"tag":86,"props":830,"children":831},{"style":140},[832],{"type":46,"value":833}," id ",{"type":41,"tag":86,"props":835,"children":836},{"style":120},[837],{"type":46,"value":574},{"type":41,"tag":86,"props":839,"children":840},{"style":140},[841],{"type":46,"value":223},{"type":41,"tag":86,"props":843,"children":844},{"style":120},[845],{"type":46,"value":228},{"type":41,"tag":68,"props":847,"children":849},{"id":848},"_4-missing-error-handling",[850],{"type":46,"value":851},"4. Missing Error Handling",{"type":41,"tag":75,"props":853,"children":855},{"className":77,"code":854,"language":19,"meta":79,"style":79},"\u002F\u002F WRONG: Returning null for not found\nconst user = await db.queryRow`SELECT * FROM users WHERE id = ${id}`;\nif (!user) return null;\n\n\u002F\u002F CORRECT: Throw APIError\nimport { APIError } from \"encore.dev\u002Fapi\";\n\nconst user = await db.queryRow`SELECT * FROM users WHERE id = ${id}`;\nif (!user) {\n  throw APIError.notFound(\"user not found\");\n}\n",[856],{"type":41,"tag":82,"props":857,"children":858},{"__ignoreMap":79},[859,867,929,962,969,977,1017,1024,1079,1103,1150],{"type":41,"tag":86,"props":860,"children":861},{"class":88,"line":89},[862],{"type":41,"tag":86,"props":863,"children":864},{"style":93},[865],{"type":46,"value":866},"\u002F\u002F WRONG: Returning null for not found\n",{"type":41,"tag":86,"props":868,"children":869},{"class":88,"line":99},[870,874,879,883,887,891,895,900,905,910,915,920,925],{"type":41,"tag":86,"props":871,"children":872},{"style":103},[873],{"type":46,"value":365},{"type":41,"tag":86,"props":875,"children":876},{"style":140},[877],{"type":46,"value":878}," user ",{"type":41,"tag":86,"props":880,"children":881},{"style":120},[882],{"type":46,"value":375},{"type":41,"tag":86,"props":884,"children":885},{"style":629},[886],{"type":46,"value":805},{"type":41,"tag":86,"props":888,"children":889},{"style":140},[890],{"type":46,"value":143},{"type":41,"tag":86,"props":892,"children":893},{"style":120},[894],{"type":46,"value":814},{"type":41,"tag":86,"props":896,"children":897},{"style":114},[898],{"type":46,"value":899},"queryRow",{"type":41,"tag":86,"props":901,"children":902},{"style":120},[903],{"type":46,"value":904},"`",{"type":41,"tag":86,"props":906,"children":907},{"style":172},[908],{"type":46,"value":909},"SELECT * FROM users WHERE id = ",{"type":41,"tag":86,"props":911,"children":912},{"style":120},[913],{"type":46,"value":914},"${",{"type":41,"tag":86,"props":916,"children":917},{"style":140},[918],{"type":46,"value":919},"id",{"type":41,"tag":86,"props":921,"children":922},{"style":120},[923],{"type":46,"value":924},"}`",{"type":41,"tag":86,"props":926,"children":927},{"style":120},[928],{"type":46,"value":228},{"type":41,"tag":86,"props":930,"children":931},{"class":88,"line":131},[932,937,942,947,952,957],{"type":41,"tag":86,"props":933,"children":934},{"style":629},[935],{"type":46,"value":936},"if",{"type":41,"tag":86,"props":938,"children":939},{"style":140},[940],{"type":46,"value":941}," (",{"type":41,"tag":86,"props":943,"children":944},{"style":120},[945],{"type":46,"value":946},"!",{"type":41,"tag":86,"props":948,"children":949},{"style":140},[950],{"type":46,"value":951},"user) ",{"type":41,"tag":86,"props":953,"children":954},{"style":629},[955],{"type":46,"value":956},"return",{"type":41,"tag":86,"props":958,"children":959},{"style":120},[960],{"type":46,"value":961}," null;\n",{"type":41,"tag":86,"props":963,"children":964},{"class":88,"line":231},[965],{"type":41,"tag":86,"props":966,"children":967},{"emptyLinePlaceholder":344},[968],{"type":46,"value":347},{"type":41,"tag":86,"props":970,"children":971},{"class":88,"line":25},[972],{"type":41,"tag":86,"props":973,"children":974},{"style":93},[975],{"type":46,"value":976},"\u002F\u002F CORRECT: Throw APIError\n",{"type":41,"tag":86,"props":978,"children":979},{"class":88,"line":340},[980,984,988,993,997,1001,1005,1009,1013],{"type":41,"tag":86,"props":981,"children":982},{"style":629},[983],{"type":46,"value":632},{"type":41,"tag":86,"props":985,"children":986},{"style":120},[987],{"type":46,"value":189},{"type":41,"tag":86,"props":989,"children":990},{"style":140},[991],{"type":46,"value":992}," APIError",{"type":41,"tag":86,"props":994,"children":995},{"style":120},[996],{"type":46,"value":218},{"type":41,"tag":86,"props":998,"children":999},{"style":629},[1000],{"type":46,"value":650},{"type":41,"tag":86,"props":1002,"children":1003},{"style":120},[1004],{"type":46,"value":204},{"type":41,"tag":86,"props":1006,"children":1007},{"style":172},[1008],{"type":46,"value":596},{"type":41,"tag":86,"props":1010,"children":1011},{"style":120},[1012],{"type":46,"value":169},{"type":41,"tag":86,"props":1014,"children":1015},{"style":120},[1016],{"type":46,"value":228},{"type":41,"tag":86,"props":1018,"children":1019},{"class":88,"line":350},[1020],{"type":41,"tag":86,"props":1021,"children":1022},{"emptyLinePlaceholder":344},[1023],{"type":46,"value":347},{"type":41,"tag":86,"props":1025,"children":1026},{"class":88,"line":359},[1027,1031,1035,1039,1043,1047,1051,1055,1059,1063,1067,1071,1075],{"type":41,"tag":86,"props":1028,"children":1029},{"style":103},[1030],{"type":46,"value":365},{"type":41,"tag":86,"props":1032,"children":1033},{"style":140},[1034],{"type":46,"value":878},{"type":41,"tag":86,"props":1036,"children":1037},{"style":120},[1038],{"type":46,"value":375},{"type":41,"tag":86,"props":1040,"children":1041},{"style":629},[1042],{"type":46,"value":805},{"type":41,"tag":86,"props":1044,"children":1045},{"style":140},[1046],{"type":46,"value":143},{"type":41,"tag":86,"props":1048,"children":1049},{"style":120},[1050],{"type":46,"value":814},{"type":41,"tag":86,"props":1052,"children":1053},{"style":114},[1054],{"type":46,"value":899},{"type":41,"tag":86,"props":1056,"children":1057},{"style":120},[1058],{"type":46,"value":904},{"type":41,"tag":86,"props":1060,"children":1061},{"style":172},[1062],{"type":46,"value":909},{"type":41,"tag":86,"props":1064,"children":1065},{"style":120},[1066],{"type":46,"value":914},{"type":41,"tag":86,"props":1068,"children":1069},{"style":140},[1070],{"type":46,"value":919},{"type":41,"tag":86,"props":1072,"children":1073},{"style":120},[1074],{"type":46,"value":924},{"type":41,"tag":86,"props":1076,"children":1077},{"style":120},[1078],{"type":46,"value":228},{"type":41,"tag":86,"props":1080,"children":1081},{"class":88,"line":442},[1082,1086,1090,1094,1098],{"type":41,"tag":86,"props":1083,"children":1084},{"style":629},[1085],{"type":46,"value":936},{"type":41,"tag":86,"props":1087,"children":1088},{"style":140},[1089],{"type":46,"value":941},{"type":41,"tag":86,"props":1091,"children":1092},{"style":120},[1093],{"type":46,"value":946},{"type":41,"tag":86,"props":1095,"children":1096},{"style":140},[1097],{"type":46,"value":951},{"type":41,"tag":86,"props":1099,"children":1100},{"style":120},[1101],{"type":46,"value":1102},"{\n",{"type":41,"tag":86,"props":1104,"children":1106},{"class":88,"line":1105},10,[1107,1112,1116,1120,1125,1129,1133,1138,1142,1146],{"type":41,"tag":86,"props":1108,"children":1109},{"style":629},[1110],{"type":46,"value":1111},"  throw",{"type":41,"tag":86,"props":1113,"children":1114},{"style":140},[1115],{"type":46,"value":992},{"type":41,"tag":86,"props":1117,"children":1118},{"style":120},[1119],{"type":46,"value":814},{"type":41,"tag":86,"props":1121,"children":1122},{"style":114},[1123],{"type":46,"value":1124},"notFound",{"type":41,"tag":86,"props":1126,"children":1127},{"style":161},[1128],{"type":46,"value":164},{"type":41,"tag":86,"props":1130,"children":1131},{"style":120},[1132],{"type":46,"value":169},{"type":41,"tag":86,"props":1134,"children":1135},{"style":172},[1136],{"type":46,"value":1137},"user not found",{"type":41,"tag":86,"props":1139,"children":1140},{"style":120},[1141],{"type":46,"value":169},{"type":41,"tag":86,"props":1143,"children":1144},{"style":161},[1145],{"type":46,"value":223},{"type":41,"tag":86,"props":1147,"children":1148},{"style":120},[1149],{"type":46,"value":228},{"type":41,"tag":86,"props":1151,"children":1153},{"class":88,"line":1152},11,[1154],{"type":41,"tag":86,"props":1155,"children":1156},{"style":120},[1157],{"type":46,"value":337},{"type":41,"tag":68,"props":1159,"children":1161},{"id":1160},"_5-sql-injection-risk",[1162],{"type":46,"value":1163},"5. SQL Injection Risk",{"type":41,"tag":75,"props":1165,"children":1167},{"className":77,"code":1166,"language":19,"meta":79,"style":79},"\u002F\u002F WRONG: String concatenation\nawait db.query(`SELECT * FROM users WHERE email = '${email}'`);\n\n\u002F\u002F CORRECT: Template literal with automatic escaping\nawait db.queryRow`SELECT * FROM users WHERE email = ${email}`;\n",[1168],{"type":41,"tag":82,"props":1169,"children":1170},{"__ignoreMap":79},[1171,1179,1243,1250,1258],{"type":41,"tag":86,"props":1172,"children":1173},{"class":88,"line":89},[1174],{"type":41,"tag":86,"props":1175,"children":1176},{"style":93},[1177],{"type":46,"value":1178},"\u002F\u002F WRONG: String concatenation\n",{"type":41,"tag":86,"props":1180,"children":1181},{"class":88,"line":99},[1182,1187,1191,1195,1200,1204,1208,1213,1217,1222,1226,1231,1235,1239],{"type":41,"tag":86,"props":1183,"children":1184},{"style":629},[1185],{"type":46,"value":1186},"await",{"type":41,"tag":86,"props":1188,"children":1189},{"style":140},[1190],{"type":46,"value":143},{"type":41,"tag":86,"props":1192,"children":1193},{"style":120},[1194],{"type":46,"value":814},{"type":41,"tag":86,"props":1196,"children":1197},{"style":114},[1198],{"type":46,"value":1199},"query",{"type":41,"tag":86,"props":1201,"children":1202},{"style":140},[1203],{"type":46,"value":164},{"type":41,"tag":86,"props":1205,"children":1206},{"style":120},[1207],{"type":46,"value":904},{"type":41,"tag":86,"props":1209,"children":1210},{"style":172},[1211],{"type":46,"value":1212},"SELECT * FROM users WHERE email = '",{"type":41,"tag":86,"props":1214,"children":1215},{"style":120},[1216],{"type":46,"value":914},{"type":41,"tag":86,"props":1218,"children":1219},{"style":140},[1220],{"type":46,"value":1221},"email",{"type":41,"tag":86,"props":1223,"children":1224},{"style":120},[1225],{"type":46,"value":574},{"type":41,"tag":86,"props":1227,"children":1228},{"style":172},[1229],{"type":46,"value":1230},"'",{"type":41,"tag":86,"props":1232,"children":1233},{"style":120},[1234],{"type":46,"value":904},{"type":41,"tag":86,"props":1236,"children":1237},{"style":140},[1238],{"type":46,"value":223},{"type":41,"tag":86,"props":1240,"children":1241},{"style":120},[1242],{"type":46,"value":228},{"type":41,"tag":86,"props":1244,"children":1245},{"class":88,"line":131},[1246],{"type":41,"tag":86,"props":1247,"children":1248},{"emptyLinePlaceholder":344},[1249],{"type":46,"value":347},{"type":41,"tag":86,"props":1251,"children":1252},{"class":88,"line":231},[1253],{"type":41,"tag":86,"props":1254,"children":1255},{"style":93},[1256],{"type":46,"value":1257},"\u002F\u002F CORRECT: Template literal with automatic escaping\n",{"type":41,"tag":86,"props":1259,"children":1260},{"class":88,"line":25},[1261,1265,1269,1273,1277,1281,1286,1290,1294,1298],{"type":41,"tag":86,"props":1262,"children":1263},{"style":629},[1264],{"type":46,"value":1186},{"type":41,"tag":86,"props":1266,"children":1267},{"style":140},[1268],{"type":46,"value":143},{"type":41,"tag":86,"props":1270,"children":1271},{"style":120},[1272],{"type":46,"value":814},{"type":41,"tag":86,"props":1274,"children":1275},{"style":114},[1276],{"type":46,"value":899},{"type":41,"tag":86,"props":1278,"children":1279},{"style":120},[1280],{"type":46,"value":904},{"type":41,"tag":86,"props":1282,"children":1283},{"style":172},[1284],{"type":46,"value":1285},"SELECT * FROM users WHERE email = ",{"type":41,"tag":86,"props":1287,"children":1288},{"style":120},[1289],{"type":46,"value":914},{"type":41,"tag":86,"props":1291,"children":1292},{"style":140},[1293],{"type":46,"value":1221},{"type":41,"tag":86,"props":1295,"children":1296},{"style":120},[1297],{"type":46,"value":924},{"type":41,"tag":86,"props":1299,"children":1300},{"style":120},[1301],{"type":46,"value":228},{"type":41,"tag":49,"props":1303,"children":1305},{"id":1304},"warning-issues",[1306],{"type":46,"value":1307},"Warning Issues",{"type":41,"tag":68,"props":1309,"children":1311},{"id":1310},"_6-missing-type-annotations",[1312],{"type":46,"value":1313},"6. Missing Type Annotations",{"type":41,"tag":75,"props":1315,"children":1317},{"className":77,"code":1316,"language":19,"meta":79,"style":79},"\u002F\u002F WEAK: No explicit types\nexport const getUser = api(\n  { method: \"GET\", path: \"\u002Fusers\u002F:id\", expose: true },\n  async ({ id }) => {\n    return await findUser(id);\n  }\n);\n\n\u002F\u002F BETTER: Explicit request\u002Fresponse types\ninterface GetUserRequest { id: string; }\ninterface User { id: string; email: string; name: string; }\n\nexport const getUser = api(\n  { method: \"GET\", path: \"\u002Fusers\u002F:id\", expose: true },\n  async ({ id }: GetUserRequest): Promise\u003CUser> => {\n    return await findUser(id);\n  }\n);\n",[1318],{"type":41,"tag":82,"props":1319,"children":1320},{"__ignoreMap":79},[1321,1329,1360,1440,1473,1506,1514,1525,1532,1540,1580,1650,1658,1686,1758,1814,1846,1854],{"type":41,"tag":86,"props":1322,"children":1323},{"class":88,"line":89},[1324],{"type":41,"tag":86,"props":1325,"children":1326},{"style":93},[1327],{"type":46,"value":1328},"\u002F\u002F WEAK: No explicit types\n",{"type":41,"tag":86,"props":1330,"children":1331},{"class":88,"line":99},[1332,1337,1342,1347,1351,1355],{"type":41,"tag":86,"props":1333,"children":1334},{"style":629},[1335],{"type":46,"value":1336},"export",{"type":41,"tag":86,"props":1338,"children":1339},{"style":103},[1340],{"type":46,"value":1341}," const",{"type":41,"tag":86,"props":1343,"children":1344},{"style":140},[1345],{"type":46,"value":1346}," getUser ",{"type":41,"tag":86,"props":1348,"children":1349},{"style":120},[1350],{"type":46,"value":375},{"type":41,"tag":86,"props":1352,"children":1353},{"style":114},[1354],{"type":46,"value":641},{"type":41,"tag":86,"props":1356,"children":1357},{"style":140},[1358],{"type":46,"value":1359},"(\n",{"type":41,"tag":86,"props":1361,"children":1362},{"class":88,"line":131},[1363,1368,1373,1377,1381,1386,1390,1394,1399,1403,1407,1412,1416,1420,1425,1429,1435],{"type":41,"tag":86,"props":1364,"children":1365},{"style":120},[1366],{"type":46,"value":1367},"  {",{"type":41,"tag":86,"props":1369,"children":1370},{"style":161},[1371],{"type":46,"value":1372}," method",{"type":41,"tag":86,"props":1374,"children":1375},{"style":120},[1376],{"type":46,"value":199},{"type":41,"tag":86,"props":1378,"children":1379},{"style":120},[1380],{"type":46,"value":204},{"type":41,"tag":86,"props":1382,"children":1383},{"style":172},[1384],{"type":46,"value":1385},"GET",{"type":41,"tag":86,"props":1387,"children":1388},{"style":120},[1389],{"type":46,"value":169},{"type":41,"tag":86,"props":1391,"children":1392},{"style":120},[1393],{"type":46,"value":184},{"type":41,"tag":86,"props":1395,"children":1396},{"style":161},[1397],{"type":46,"value":1398}," path",{"type":41,"tag":86,"props":1400,"children":1401},{"style":120},[1402],{"type":46,"value":199},{"type":41,"tag":86,"props":1404,"children":1405},{"style":120},[1406],{"type":46,"value":204},{"type":41,"tag":86,"props":1408,"children":1409},{"style":172},[1410],{"type":46,"value":1411},"\u002Fusers\u002F:id",{"type":41,"tag":86,"props":1413,"children":1414},{"style":120},[1415],{"type":46,"value":169},{"type":41,"tag":86,"props":1417,"children":1418},{"style":120},[1419],{"type":46,"value":184},{"type":41,"tag":86,"props":1421,"children":1422},{"style":161},[1423],{"type":46,"value":1424}," expose",{"type":41,"tag":86,"props":1426,"children":1427},{"style":120},[1428],{"type":46,"value":199},{"type":41,"tag":86,"props":1430,"children":1432},{"style":1431},"--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC",[1433],{"type":46,"value":1434}," true",{"type":41,"tag":86,"props":1436,"children":1437},{"style":120},[1438],{"type":46,"value":1439}," },\n",{"type":41,"tag":86,"props":1441,"children":1442},{"class":88,"line":231},[1443,1448,1453,1459,1464,1469],{"type":41,"tag":86,"props":1444,"children":1445},{"style":103},[1446],{"type":46,"value":1447},"  async",{"type":41,"tag":86,"props":1449,"children":1450},{"style":120},[1451],{"type":46,"value":1452}," ({",{"type":41,"tag":86,"props":1454,"children":1456},{"style":1455},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#EEFFFF;--shiki-default-font-style:italic;--shiki-dark:#BABED8;--shiki-dark-font-style:italic",[1457],{"type":46,"value":1458}," id",{"type":41,"tag":86,"props":1460,"children":1461},{"style":120},[1462],{"type":46,"value":1463}," })",{"type":41,"tag":86,"props":1465,"children":1466},{"style":103},[1467],{"type":46,"value":1468}," =>",{"type":41,"tag":86,"props":1470,"children":1471},{"style":120},[1472],{"type":46,"value":128},{"type":41,"tag":86,"props":1474,"children":1475},{"class":88,"line":25},[1476,1481,1485,1490,1494,1498,1502],{"type":41,"tag":86,"props":1477,"children":1478},{"style":629},[1479],{"type":46,"value":1480},"    return",{"type":41,"tag":86,"props":1482,"children":1483},{"style":629},[1484],{"type":46,"value":805},{"type":41,"tag":86,"props":1486,"children":1487},{"style":114},[1488],{"type":46,"value":1489}," findUser",{"type":41,"tag":86,"props":1491,"children":1492},{"style":161},[1493],{"type":46,"value":164},{"type":41,"tag":86,"props":1495,"children":1496},{"style":140},[1497],{"type":46,"value":919},{"type":41,"tag":86,"props":1499,"children":1500},{"style":161},[1501],{"type":46,"value":223},{"type":41,"tag":86,"props":1503,"children":1504},{"style":120},[1505],{"type":46,"value":228},{"type":41,"tag":86,"props":1507,"children":1508},{"class":88,"line":340},[1509],{"type":41,"tag":86,"props":1510,"children":1511},{"style":120},[1512],{"type":46,"value":1513},"  }\n",{"type":41,"tag":86,"props":1515,"children":1516},{"class":88,"line":350},[1517,1521],{"type":41,"tag":86,"props":1518,"children":1519},{"style":140},[1520],{"type":46,"value":223},{"type":41,"tag":86,"props":1522,"children":1523},{"style":120},[1524],{"type":46,"value":228},{"type":41,"tag":86,"props":1526,"children":1527},{"class":88,"line":359},[1528],{"type":41,"tag":86,"props":1529,"children":1530},{"emptyLinePlaceholder":344},[1531],{"type":46,"value":347},{"type":41,"tag":86,"props":1533,"children":1534},{"class":88,"line":442},[1535],{"type":41,"tag":86,"props":1536,"children":1537},{"style":93},[1538],{"type":46,"value":1539},"\u002F\u002F BETTER: Explicit request\u002Fresponse types\n",{"type":41,"tag":86,"props":1541,"children":1542},{"class":88,"line":1105},[1543,1548,1553,1557,1561,1565,1570,1575],{"type":41,"tag":86,"props":1544,"children":1545},{"style":103},[1546],{"type":46,"value":1547},"interface",{"type":41,"tag":86,"props":1549,"children":1550},{"style":262},[1551],{"type":46,"value":1552}," GetUserRequest",{"type":41,"tag":86,"props":1554,"children":1555},{"style":120},[1556],{"type":46,"value":189},{"type":41,"tag":86,"props":1558,"children":1559},{"style":161},[1560],{"type":46,"value":1458},{"type":41,"tag":86,"props":1562,"children":1563},{"style":120},[1564],{"type":46,"value":199},{"type":41,"tag":86,"props":1566,"children":1567},{"style":262},[1568],{"type":46,"value":1569}," string",{"type":41,"tag":86,"props":1571,"children":1572},{"style":120},[1573],{"type":46,"value":1574},";",{"type":41,"tag":86,"props":1576,"children":1577},{"style":120},[1578],{"type":46,"value":1579}," }\n",{"type":41,"tag":86,"props":1581,"children":1582},{"class":88,"line":1152},[1583,1587,1592,1596,1600,1604,1608,1612,1617,1621,1625,1629,1634,1638,1642,1646],{"type":41,"tag":86,"props":1584,"children":1585},{"style":103},[1586],{"type":46,"value":1547},{"type":41,"tag":86,"props":1588,"children":1589},{"style":262},[1590],{"type":46,"value":1591}," User",{"type":41,"tag":86,"props":1593,"children":1594},{"style":120},[1595],{"type":46,"value":189},{"type":41,"tag":86,"props":1597,"children":1598},{"style":161},[1599],{"type":46,"value":1458},{"type":41,"tag":86,"props":1601,"children":1602},{"style":120},[1603],{"type":46,"value":199},{"type":41,"tag":86,"props":1605,"children":1606},{"style":262},[1607],{"type":46,"value":1569},{"type":41,"tag":86,"props":1609,"children":1610},{"style":120},[1611],{"type":46,"value":1574},{"type":41,"tag":86,"props":1613,"children":1614},{"style":161},[1615],{"type":46,"value":1616}," email",{"type":41,"tag":86,"props":1618,"children":1619},{"style":120},[1620],{"type":46,"value":199},{"type":41,"tag":86,"props":1622,"children":1623},{"style":262},[1624],{"type":46,"value":1569},{"type":41,"tag":86,"props":1626,"children":1627},{"style":120},[1628],{"type":46,"value":1574},{"type":41,"tag":86,"props":1630,"children":1631},{"style":161},[1632],{"type":46,"value":1633}," name",{"type":41,"tag":86,"props":1635,"children":1636},{"style":120},[1637],{"type":46,"value":199},{"type":41,"tag":86,"props":1639,"children":1640},{"style":262},[1641],{"type":46,"value":1569},{"type":41,"tag":86,"props":1643,"children":1644},{"style":120},[1645],{"type":46,"value":1574},{"type":41,"tag":86,"props":1647,"children":1648},{"style":120},[1649],{"type":46,"value":1579},{"type":41,"tag":86,"props":1651,"children":1653},{"class":88,"line":1652},12,[1654],{"type":41,"tag":86,"props":1655,"children":1656},{"emptyLinePlaceholder":344},[1657],{"type":46,"value":347},{"type":41,"tag":86,"props":1659,"children":1661},{"class":88,"line":1660},13,[1662,1666,1670,1674,1678,1682],{"type":41,"tag":86,"props":1663,"children":1664},{"style":629},[1665],{"type":46,"value":1336},{"type":41,"tag":86,"props":1667,"children":1668},{"style":103},[1669],{"type":46,"value":1341},{"type":41,"tag":86,"props":1671,"children":1672},{"style":140},[1673],{"type":46,"value":1346},{"type":41,"tag":86,"props":1675,"children":1676},{"style":120},[1677],{"type":46,"value":375},{"type":41,"tag":86,"props":1679,"children":1680},{"style":114},[1681],{"type":46,"value":641},{"type":41,"tag":86,"props":1683,"children":1684},{"style":140},[1685],{"type":46,"value":1359},{"type":41,"tag":86,"props":1687,"children":1689},{"class":88,"line":1688},14,[1690,1694,1698,1702,1706,1710,1714,1718,1722,1726,1730,1734,1738,1742,1746,1750,1754],{"type":41,"tag":86,"props":1691,"children":1692},{"style":120},[1693],{"type":46,"value":1367},{"type":41,"tag":86,"props":1695,"children":1696},{"style":161},[1697],{"type":46,"value":1372},{"type":41,"tag":86,"props":1699,"children":1700},{"style":120},[1701],{"type":46,"value":199},{"type":41,"tag":86,"props":1703,"children":1704},{"style":120},[1705],{"type":46,"value":204},{"type":41,"tag":86,"props":1707,"children":1708},{"style":172},[1709],{"type":46,"value":1385},{"type":41,"tag":86,"props":1711,"children":1712},{"style":120},[1713],{"type":46,"value":169},{"type":41,"tag":86,"props":1715,"children":1716},{"style":120},[1717],{"type":46,"value":184},{"type":41,"tag":86,"props":1719,"children":1720},{"style":161},[1721],{"type":46,"value":1398},{"type":41,"tag":86,"props":1723,"children":1724},{"style":120},[1725],{"type":46,"value":199},{"type":41,"tag":86,"props":1727,"children":1728},{"style":120},[1729],{"type":46,"value":204},{"type":41,"tag":86,"props":1731,"children":1732},{"style":172},[1733],{"type":46,"value":1411},{"type":41,"tag":86,"props":1735,"children":1736},{"style":120},[1737],{"type":46,"value":169},{"type":41,"tag":86,"props":1739,"children":1740},{"style":120},[1741],{"type":46,"value":184},{"type":41,"tag":86,"props":1743,"children":1744},{"style":161},[1745],{"type":46,"value":1424},{"type":41,"tag":86,"props":1747,"children":1748},{"style":120},[1749],{"type":46,"value":199},{"type":41,"tag":86,"props":1751,"children":1752},{"style":1431},[1753],{"type":46,"value":1434},{"type":41,"tag":86,"props":1755,"children":1756},{"style":120},[1757],{"type":46,"value":1439},{"type":41,"tag":86,"props":1759,"children":1761},{"class":88,"line":1760},15,[1762,1766,1770,1774,1779,1783,1788,1793,1797,1802,1806,1810],{"type":41,"tag":86,"props":1763,"children":1764},{"style":103},[1765],{"type":46,"value":1447},{"type":41,"tag":86,"props":1767,"children":1768},{"style":120},[1769],{"type":46,"value":1452},{"type":41,"tag":86,"props":1771,"children":1772},{"style":1455},[1773],{"type":46,"value":1458},{"type":41,"tag":86,"props":1775,"children":1776},{"style":120},[1777],{"type":46,"value":1778}," }:",{"type":41,"tag":86,"props":1780,"children":1781},{"style":262},[1782],{"type":46,"value":1552},{"type":41,"tag":86,"props":1784,"children":1785},{"style":120},[1786],{"type":46,"value":1787},"):",{"type":41,"tag":86,"props":1789,"children":1790},{"style":262},[1791],{"type":46,"value":1792}," Promise",{"type":41,"tag":86,"props":1794,"children":1795},{"style":120},[1796],{"type":46,"value":259},{"type":41,"tag":86,"props":1798,"children":1799},{"style":262},[1800],{"type":46,"value":1801},"User",{"type":41,"tag":86,"props":1803,"children":1804},{"style":120},[1805],{"type":46,"value":270},{"type":41,"tag":86,"props":1807,"children":1808},{"style":103},[1809],{"type":46,"value":1468},{"type":41,"tag":86,"props":1811,"children":1812},{"style":120},[1813],{"type":46,"value":128},{"type":41,"tag":86,"props":1815,"children":1817},{"class":88,"line":1816},16,[1818,1822,1826,1830,1834,1838,1842],{"type":41,"tag":86,"props":1819,"children":1820},{"style":629},[1821],{"type":46,"value":1480},{"type":41,"tag":86,"props":1823,"children":1824},{"style":629},[1825],{"type":46,"value":805},{"type":41,"tag":86,"props":1827,"children":1828},{"style":114},[1829],{"type":46,"value":1489},{"type":41,"tag":86,"props":1831,"children":1832},{"style":161},[1833],{"type":46,"value":164},{"type":41,"tag":86,"props":1835,"children":1836},{"style":140},[1837],{"type":46,"value":919},{"type":41,"tag":86,"props":1839,"children":1840},{"style":161},[1841],{"type":46,"value":223},{"type":41,"tag":86,"props":1843,"children":1844},{"style":120},[1845],{"type":46,"value":228},{"type":41,"tag":86,"props":1847,"children":1849},{"class":88,"line":1848},17,[1850],{"type":41,"tag":86,"props":1851,"children":1852},{"style":120},[1853],{"type":46,"value":1513},{"type":41,"tag":86,"props":1855,"children":1857},{"class":88,"line":1856},18,[1858,1862],{"type":41,"tag":86,"props":1859,"children":1860},{"style":140},[1861],{"type":46,"value":223},{"type":41,"tag":86,"props":1863,"children":1864},{"style":120},[1865],{"type":46,"value":228},{"type":41,"tag":68,"props":1867,"children":1869},{"id":1868},"_7-exposed-internal-endpoints",[1870],{"type":46,"value":1871},"7. Exposed Internal Endpoints",{"type":41,"tag":75,"props":1873,"children":1875},{"className":77,"code":1874,"language":19,"meta":79,"style":79},"\u002F\u002F CHECK: Should this cron endpoint be exposed?\nexport const cleanupJob = api(\n  { expose: true },  \u002F\u002F Probably should be false\n  async () => { \u002F* ... *\u002F }\n);\n",[1876],{"type":41,"tag":82,"props":1877,"children":1878},{"__ignoreMap":79},[1879,1887,1915,1944,1973],{"type":41,"tag":86,"props":1880,"children":1881},{"class":88,"line":89},[1882],{"type":41,"tag":86,"props":1883,"children":1884},{"style":93},[1885],{"type":46,"value":1886},"\u002F\u002F CHECK: Should this cron endpoint be exposed?\n",{"type":41,"tag":86,"props":1888,"children":1889},{"class":88,"line":99},[1890,1894,1898,1903,1907,1911],{"type":41,"tag":86,"props":1891,"children":1892},{"style":629},[1893],{"type":46,"value":1336},{"type":41,"tag":86,"props":1895,"children":1896},{"style":103},[1897],{"type":46,"value":1341},{"type":41,"tag":86,"props":1899,"children":1900},{"style":140},[1901],{"type":46,"value":1902}," cleanupJob ",{"type":41,"tag":86,"props":1904,"children":1905},{"style":120},[1906],{"type":46,"value":375},{"type":41,"tag":86,"props":1908,"children":1909},{"style":114},[1910],{"type":46,"value":641},{"type":41,"tag":86,"props":1912,"children":1913},{"style":140},[1914],{"type":46,"value":1359},{"type":41,"tag":86,"props":1916,"children":1917},{"class":88,"line":131},[1918,1922,1926,1930,1934,1939],{"type":41,"tag":86,"props":1919,"children":1920},{"style":120},[1921],{"type":46,"value":1367},{"type":41,"tag":86,"props":1923,"children":1924},{"style":161},[1925],{"type":46,"value":1424},{"type":41,"tag":86,"props":1927,"children":1928},{"style":120},[1929],{"type":46,"value":199},{"type":41,"tag":86,"props":1931,"children":1932},{"style":1431},[1933],{"type":46,"value":1434},{"type":41,"tag":86,"props":1935,"children":1936},{"style":120},[1937],{"type":46,"value":1938}," },",{"type":41,"tag":86,"props":1940,"children":1941},{"style":93},[1942],{"type":46,"value":1943},"  \u002F\u002F Probably should be false\n",{"type":41,"tag":86,"props":1945,"children":1946},{"class":88,"line":231},[1947,1951,1956,1960,1964,1969],{"type":41,"tag":86,"props":1948,"children":1949},{"style":103},[1950],{"type":46,"value":1447},{"type":41,"tag":86,"props":1952,"children":1953},{"style":120},[1954],{"type":46,"value":1955}," ()",{"type":41,"tag":86,"props":1957,"children":1958},{"style":103},[1959],{"type":46,"value":1468},{"type":41,"tag":86,"props":1961,"children":1962},{"style":120},[1963],{"type":46,"value":189},{"type":41,"tag":86,"props":1965,"children":1966},{"style":93},[1967],{"type":46,"value":1968}," \u002F* ... *\u002F",{"type":41,"tag":86,"props":1970,"children":1971},{"style":120},[1972],{"type":46,"value":1579},{"type":41,"tag":86,"props":1974,"children":1975},{"class":88,"line":25},[1976,1980],{"type":41,"tag":86,"props":1977,"children":1978},{"style":140},[1979],{"type":46,"value":223},{"type":41,"tag":86,"props":1981,"children":1982},{"style":120},[1983],{"type":46,"value":228},{"type":41,"tag":68,"props":1985,"children":1987},{"id":1986},"_8-non-idempotent-subscription-handlers",[1988],{"type":46,"value":1989},"8. Non-Idempotent Subscription Handlers",{"type":41,"tag":75,"props":1991,"children":1993},{"className":77,"code":1992,"language":19,"meta":79,"style":79},"\u002F\u002F RISKY: Not idempotent (pubsub has at-least-once delivery)\nconst _ = new Subscription(orderCreated, \"process-order\", {\n  handler: async (event) => {\n    await chargeCustomer(event.orderId);  \u002F\u002F Could charge twice!\n  },\n});\n\n\u002F\u002F SAFER: Check before processing\nconst _ = new Subscription(orderCreated, \"process-order\", {\n  handler: async (event) => {\n    const order = await getOrder(event.orderId);\n    if (order.status !== \"pending\") return;  \u002F\u002F Already processed\n    await chargeCustomer(event.orderId);\n  },\n});\n",[1994],{"type":41,"tag":82,"props":1995,"children":1996},{"__ignoreMap":79},[1997,2005,2060,2098,2141,2149,2164,2171,2179,2230,2265,2315,2377,2412,2419],{"type":41,"tag":86,"props":1998,"children":1999},{"class":88,"line":89},[2000],{"type":41,"tag":86,"props":2001,"children":2002},{"style":93},[2003],{"type":46,"value":2004},"\u002F\u002F RISKY: Not idempotent (pubsub has at-least-once delivery)\n",{"type":41,"tag":86,"props":2006,"children":2007},{"class":88,"line":99},[2008,2012,2017,2021,2025,2030,2035,2039,2043,2048,2052,2056],{"type":41,"tag":86,"props":2009,"children":2010},{"style":103},[2011],{"type":46,"value":365},{"type":41,"tag":86,"props":2013,"children":2014},{"style":140},[2015],{"type":46,"value":2016}," _ ",{"type":41,"tag":86,"props":2018,"children":2019},{"style":120},[2020],{"type":46,"value":375},{"type":41,"tag":86,"props":2022,"children":2023},{"style":120},[2024],{"type":46,"value":153},{"type":41,"tag":86,"props":2026,"children":2027},{"style":114},[2028],{"type":46,"value":2029}," Subscription",{"type":41,"tag":86,"props":2031,"children":2032},{"style":140},[2033],{"type":46,"value":2034},"(orderCreated",{"type":41,"tag":86,"props":2036,"children":2037},{"style":120},[2038],{"type":46,"value":184},{"type":41,"tag":86,"props":2040,"children":2041},{"style":120},[2042],{"type":46,"value":204},{"type":41,"tag":86,"props":2044,"children":2045},{"style":172},[2046],{"type":46,"value":2047},"process-order",{"type":41,"tag":86,"props":2049,"children":2050},{"style":120},[2051],{"type":46,"value":169},{"type":41,"tag":86,"props":2053,"children":2054},{"style":120},[2055],{"type":46,"value":184},{"type":41,"tag":86,"props":2057,"children":2058},{"style":120},[2059],{"type":46,"value":128},{"type":41,"tag":86,"props":2061,"children":2062},{"class":88,"line":131},[2063,2068,2072,2077,2081,2086,2090,2094],{"type":41,"tag":86,"props":2064,"children":2065},{"style":114},[2066],{"type":46,"value":2067},"  handler",{"type":41,"tag":86,"props":2069,"children":2070},{"style":120},[2071],{"type":46,"value":199},{"type":41,"tag":86,"props":2073,"children":2074},{"style":103},[2075],{"type":46,"value":2076}," async",{"type":41,"tag":86,"props":2078,"children":2079},{"style":120},[2080],{"type":46,"value":941},{"type":41,"tag":86,"props":2082,"children":2083},{"style":1455},[2084],{"type":46,"value":2085},"event",{"type":41,"tag":86,"props":2087,"children":2088},{"style":120},[2089],{"type":46,"value":223},{"type":41,"tag":86,"props":2091,"children":2092},{"style":103},[2093],{"type":46,"value":1468},{"type":41,"tag":86,"props":2095,"children":2096},{"style":120},[2097],{"type":46,"value":128},{"type":41,"tag":86,"props":2099,"children":2100},{"class":88,"line":231},[2101,2106,2111,2115,2119,2123,2128,2132,2136],{"type":41,"tag":86,"props":2102,"children":2103},{"style":629},[2104],{"type":46,"value":2105},"    await",{"type":41,"tag":86,"props":2107,"children":2108},{"style":114},[2109],{"type":46,"value":2110}," chargeCustomer",{"type":41,"tag":86,"props":2112,"children":2113},{"style":161},[2114],{"type":46,"value":164},{"type":41,"tag":86,"props":2116,"children":2117},{"style":140},[2118],{"type":46,"value":2085},{"type":41,"tag":86,"props":2120,"children":2121},{"style":120},[2122],{"type":46,"value":814},{"type":41,"tag":86,"props":2124,"children":2125},{"style":140},[2126],{"type":46,"value":2127},"orderId",{"type":41,"tag":86,"props":2129,"children":2130},{"style":161},[2131],{"type":46,"value":223},{"type":41,"tag":86,"props":2133,"children":2134},{"style":120},[2135],{"type":46,"value":1574},{"type":41,"tag":86,"props":2137,"children":2138},{"style":93},[2139],{"type":46,"value":2140},"  \u002F\u002F Could charge twice!\n",{"type":41,"tag":86,"props":2142,"children":2143},{"class":88,"line":25},[2144],{"type":41,"tag":86,"props":2145,"children":2146},{"style":120},[2147],{"type":46,"value":2148},"  },\n",{"type":41,"tag":86,"props":2150,"children":2151},{"class":88,"line":340},[2152,2156,2160],{"type":41,"tag":86,"props":2153,"children":2154},{"style":120},[2155],{"type":46,"value":574},{"type":41,"tag":86,"props":2157,"children":2158},{"style":140},[2159],{"type":46,"value":223},{"type":41,"tag":86,"props":2161,"children":2162},{"style":120},[2163],{"type":46,"value":228},{"type":41,"tag":86,"props":2165,"children":2166},{"class":88,"line":350},[2167],{"type":41,"tag":86,"props":2168,"children":2169},{"emptyLinePlaceholder":344},[2170],{"type":46,"value":347},{"type":41,"tag":86,"props":2172,"children":2173},{"class":88,"line":359},[2174],{"type":41,"tag":86,"props":2175,"children":2176},{"style":93},[2177],{"type":46,"value":2178},"\u002F\u002F SAFER: Check before processing\n",{"type":41,"tag":86,"props":2180,"children":2181},{"class":88,"line":442},[2182,2186,2190,2194,2198,2202,2206,2210,2214,2218,2222,2226],{"type":41,"tag":86,"props":2183,"children":2184},{"style":103},[2185],{"type":46,"value":365},{"type":41,"tag":86,"props":2187,"children":2188},{"style":140},[2189],{"type":46,"value":2016},{"type":41,"tag":86,"props":2191,"children":2192},{"style":120},[2193],{"type":46,"value":375},{"type":41,"tag":86,"props":2195,"children":2196},{"style":120},[2197],{"type":46,"value":153},{"type":41,"tag":86,"props":2199,"children":2200},{"style":114},[2201],{"type":46,"value":2029},{"type":41,"tag":86,"props":2203,"children":2204},{"style":140},[2205],{"type":46,"value":2034},{"type":41,"tag":86,"props":2207,"children":2208},{"style":120},[2209],{"type":46,"value":184},{"type":41,"tag":86,"props":2211,"children":2212},{"style":120},[2213],{"type":46,"value":204},{"type":41,"tag":86,"props":2215,"children":2216},{"style":172},[2217],{"type":46,"value":2047},{"type":41,"tag":86,"props":2219,"children":2220},{"style":120},[2221],{"type":46,"value":169},{"type":41,"tag":86,"props":2223,"children":2224},{"style":120},[2225],{"type":46,"value":184},{"type":41,"tag":86,"props":2227,"children":2228},{"style":120},[2229],{"type":46,"value":128},{"type":41,"tag":86,"props":2231,"children":2232},{"class":88,"line":1105},[2233,2237,2241,2245,2249,2253,2257,2261],{"type":41,"tag":86,"props":2234,"children":2235},{"style":114},[2236],{"type":46,"value":2067},{"type":41,"tag":86,"props":2238,"children":2239},{"style":120},[2240],{"type":46,"value":199},{"type":41,"tag":86,"props":2242,"children":2243},{"style":103},[2244],{"type":46,"value":2076},{"type":41,"tag":86,"props":2246,"children":2247},{"style":120},[2248],{"type":46,"value":941},{"type":41,"tag":86,"props":2250,"children":2251},{"style":1455},[2252],{"type":46,"value":2085},{"type":41,"tag":86,"props":2254,"children":2255},{"style":120},[2256],{"type":46,"value":223},{"type":41,"tag":86,"props":2258,"children":2259},{"style":103},[2260],{"type":46,"value":1468},{"type":41,"tag":86,"props":2262,"children":2263},{"style":120},[2264],{"type":46,"value":128},{"type":41,"tag":86,"props":2266,"children":2267},{"class":88,"line":1152},[2268,2273,2278,2282,2286,2291,2295,2299,2303,2307,2311],{"type":41,"tag":86,"props":2269,"children":2270},{"style":103},[2271],{"type":46,"value":2272},"    const",{"type":41,"tag":86,"props":2274,"children":2275},{"style":140},[2276],{"type":46,"value":2277}," order",{"type":41,"tag":86,"props":2279,"children":2280},{"style":120},[2281],{"type":46,"value":148},{"type":41,"tag":86,"props":2283,"children":2284},{"style":629},[2285],{"type":46,"value":805},{"type":41,"tag":86,"props":2287,"children":2288},{"style":114},[2289],{"type":46,"value":2290}," getOrder",{"type":41,"tag":86,"props":2292,"children":2293},{"style":161},[2294],{"type":46,"value":164},{"type":41,"tag":86,"props":2296,"children":2297},{"style":140},[2298],{"type":46,"value":2085},{"type":41,"tag":86,"props":2300,"children":2301},{"style":120},[2302],{"type":46,"value":814},{"type":41,"tag":86,"props":2304,"children":2305},{"style":140},[2306],{"type":46,"value":2127},{"type":41,"tag":86,"props":2308,"children":2309},{"style":161},[2310],{"type":46,"value":223},{"type":41,"tag":86,"props":2312,"children":2313},{"style":120},[2314],{"type":46,"value":228},{"type":41,"tag":86,"props":2316,"children":2317},{"class":88,"line":1652},[2318,2323,2327,2332,2336,2341,2346,2350,2355,2359,2364,2368,2372],{"type":41,"tag":86,"props":2319,"children":2320},{"style":629},[2321],{"type":46,"value":2322},"    if",{"type":41,"tag":86,"props":2324,"children":2325},{"style":161},[2326],{"type":46,"value":941},{"type":41,"tag":86,"props":2328,"children":2329},{"style":140},[2330],{"type":46,"value":2331},"order",{"type":41,"tag":86,"props":2333,"children":2334},{"style":120},[2335],{"type":46,"value":814},{"type":41,"tag":86,"props":2337,"children":2338},{"style":140},[2339],{"type":46,"value":2340},"status",{"type":41,"tag":86,"props":2342,"children":2343},{"style":120},[2344],{"type":46,"value":2345}," !==",{"type":41,"tag":86,"props":2347,"children":2348},{"style":120},[2349],{"type":46,"value":204},{"type":41,"tag":86,"props":2351,"children":2352},{"style":172},[2353],{"type":46,"value":2354},"pending",{"type":41,"tag":86,"props":2356,"children":2357},{"style":120},[2358],{"type":46,"value":169},{"type":41,"tag":86,"props":2360,"children":2361},{"style":161},[2362],{"type":46,"value":2363},") ",{"type":41,"tag":86,"props":2365,"children":2366},{"style":629},[2367],{"type":46,"value":956},{"type":41,"tag":86,"props":2369,"children":2370},{"style":120},[2371],{"type":46,"value":1574},{"type":41,"tag":86,"props":2373,"children":2374},{"style":93},[2375],{"type":46,"value":2376},"  \u002F\u002F Already processed\n",{"type":41,"tag":86,"props":2378,"children":2379},{"class":88,"line":1660},[2380,2384,2388,2392,2396,2400,2404,2408],{"type":41,"tag":86,"props":2381,"children":2382},{"style":629},[2383],{"type":46,"value":2105},{"type":41,"tag":86,"props":2385,"children":2386},{"style":114},[2387],{"type":46,"value":2110},{"type":41,"tag":86,"props":2389,"children":2390},{"style":161},[2391],{"type":46,"value":164},{"type":41,"tag":86,"props":2393,"children":2394},{"style":140},[2395],{"type":46,"value":2085},{"type":41,"tag":86,"props":2397,"children":2398},{"style":120},[2399],{"type":46,"value":814},{"type":41,"tag":86,"props":2401,"children":2402},{"style":140},[2403],{"type":46,"value":2127},{"type":41,"tag":86,"props":2405,"children":2406},{"style":161},[2407],{"type":46,"value":223},{"type":41,"tag":86,"props":2409,"children":2410},{"style":120},[2411],{"type":46,"value":228},{"type":41,"tag":86,"props":2413,"children":2414},{"class":88,"line":1688},[2415],{"type":41,"tag":86,"props":2416,"children":2417},{"style":120},[2418],{"type":46,"value":2148},{"type":41,"tag":86,"props":2420,"children":2421},{"class":88,"line":1760},[2422,2426,2430],{"type":41,"tag":86,"props":2423,"children":2424},{"style":120},[2425],{"type":46,"value":574},{"type":41,"tag":86,"props":2427,"children":2428},{"style":140},[2429],{"type":46,"value":223},{"type":41,"tag":86,"props":2431,"children":2432},{"style":120},[2433],{"type":46,"value":228},{"type":41,"tag":68,"props":2435,"children":2437},{"id":2436},"_9-secrets-called-at-module-level",[2438],{"type":46,"value":2439},"9. Secrets Called at Module Level",{"type":41,"tag":75,"props":2441,"children":2443},{"className":77,"code":2442,"language":19,"meta":79,"style":79},"\u002F\u002F WRONG: Secret accessed at startup\nconst stripeKey = secret(\"StripeKey\");\nconst client = new Stripe(stripeKey());  \u002F\u002F Called during import\n\n\u002F\u002F CORRECT: Access inside functions\nconst stripeKey = secret(\"StripeKey\");\n\nasync function charge() {\n  const client = new Stripe(stripeKey());  \u002F\u002F Called at runtime\n}\n",[2444],{"type":41,"tag":82,"props":2445,"children":2446},{"__ignoreMap":79},[2447,2455,2501,2549,2556,2564,2607,2614,2638,2683],{"type":41,"tag":86,"props":2448,"children":2449},{"class":88,"line":89},[2450],{"type":41,"tag":86,"props":2451,"children":2452},{"style":93},[2453],{"type":46,"value":2454},"\u002F\u002F WRONG: Secret accessed at startup\n",{"type":41,"tag":86,"props":2456,"children":2457},{"class":88,"line":99},[2458,2462,2467,2471,2476,2480,2484,2489,2493,2497],{"type":41,"tag":86,"props":2459,"children":2460},{"style":103},[2461],{"type":46,"value":365},{"type":41,"tag":86,"props":2463,"children":2464},{"style":140},[2465],{"type":46,"value":2466}," stripeKey ",{"type":41,"tag":86,"props":2468,"children":2469},{"style":120},[2470],{"type":46,"value":375},{"type":41,"tag":86,"props":2472,"children":2473},{"style":114},[2474],{"type":46,"value":2475}," secret",{"type":41,"tag":86,"props":2477,"children":2478},{"style":140},[2479],{"type":46,"value":164},{"type":41,"tag":86,"props":2481,"children":2482},{"style":120},[2483],{"type":46,"value":169},{"type":41,"tag":86,"props":2485,"children":2486},{"style":172},[2487],{"type":46,"value":2488},"StripeKey",{"type":41,"tag":86,"props":2490,"children":2491},{"style":120},[2492],{"type":46,"value":169},{"type":41,"tag":86,"props":2494,"children":2495},{"style":140},[2496],{"type":46,"value":223},{"type":41,"tag":86,"props":2498,"children":2499},{"style":120},[2500],{"type":46,"value":228},{"type":41,"tag":86,"props":2502,"children":2503},{"class":88,"line":131},[2504,2508,2513,2517,2521,2526,2530,2535,2540,2544],{"type":41,"tag":86,"props":2505,"children":2506},{"style":103},[2507],{"type":46,"value":365},{"type":41,"tag":86,"props":2509,"children":2510},{"style":140},[2511],{"type":46,"value":2512}," client ",{"type":41,"tag":86,"props":2514,"children":2515},{"style":120},[2516],{"type":46,"value":375},{"type":41,"tag":86,"props":2518,"children":2519},{"style":120},[2520],{"type":46,"value":153},{"type":41,"tag":86,"props":2522,"children":2523},{"style":114},[2524],{"type":46,"value":2525}," Stripe",{"type":41,"tag":86,"props":2527,"children":2528},{"style":140},[2529],{"type":46,"value":164},{"type":41,"tag":86,"props":2531,"children":2532},{"style":114},[2533],{"type":46,"value":2534},"stripeKey",{"type":41,"tag":86,"props":2536,"children":2537},{"style":140},[2538],{"type":46,"value":2539},"())",{"type":41,"tag":86,"props":2541,"children":2542},{"style":120},[2543],{"type":46,"value":1574},{"type":41,"tag":86,"props":2545,"children":2546},{"style":93},[2547],{"type":46,"value":2548},"  \u002F\u002F Called during import\n",{"type":41,"tag":86,"props":2550,"children":2551},{"class":88,"line":231},[2552],{"type":41,"tag":86,"props":2553,"children":2554},{"emptyLinePlaceholder":344},[2555],{"type":46,"value":347},{"type":41,"tag":86,"props":2557,"children":2558},{"class":88,"line":25},[2559],{"type":41,"tag":86,"props":2560,"children":2561},{"style":93},[2562],{"type":46,"value":2563},"\u002F\u002F CORRECT: Access inside functions\n",{"type":41,"tag":86,"props":2565,"children":2566},{"class":88,"line":340},[2567,2571,2575,2579,2583,2587,2591,2595,2599,2603],{"type":41,"tag":86,"props":2568,"children":2569},{"style":103},[2570],{"type":46,"value":365},{"type":41,"tag":86,"props":2572,"children":2573},{"style":140},[2574],{"type":46,"value":2466},{"type":41,"tag":86,"props":2576,"children":2577},{"style":120},[2578],{"type":46,"value":375},{"type":41,"tag":86,"props":2580,"children":2581},{"style":114},[2582],{"type":46,"value":2475},{"type":41,"tag":86,"props":2584,"children":2585},{"style":140},[2586],{"type":46,"value":164},{"type":41,"tag":86,"props":2588,"children":2589},{"style":120},[2590],{"type":46,"value":169},{"type":41,"tag":86,"props":2592,"children":2593},{"style":172},[2594],{"type":46,"value":2488},{"type":41,"tag":86,"props":2596,"children":2597},{"style":120},[2598],{"type":46,"value":169},{"type":41,"tag":86,"props":2600,"children":2601},{"style":140},[2602],{"type":46,"value":223},{"type":41,"tag":86,"props":2604,"children":2605},{"style":120},[2606],{"type":46,"value":228},{"type":41,"tag":86,"props":2608,"children":2609},{"class":88,"line":350},[2610],{"type":41,"tag":86,"props":2611,"children":2612},{"emptyLinePlaceholder":344},[2613],{"type":46,"value":347},{"type":41,"tag":86,"props":2615,"children":2616},{"class":88,"line":359},[2617,2621,2625,2630,2634],{"type":41,"tag":86,"props":2618,"children":2619},{"style":103},[2620],{"type":46,"value":106},{"type":41,"tag":86,"props":2622,"children":2623},{"style":103},[2624],{"type":46,"value":111},{"type":41,"tag":86,"props":2626,"children":2627},{"style":114},[2628],{"type":46,"value":2629}," charge",{"type":41,"tag":86,"props":2631,"children":2632},{"style":120},[2633],{"type":46,"value":123},{"type":41,"tag":86,"props":2635,"children":2636},{"style":120},[2637],{"type":46,"value":128},{"type":41,"tag":86,"props":2639,"children":2640},{"class":88,"line":442},[2641,2645,2650,2654,2658,2662,2666,2670,2674,2678],{"type":41,"tag":86,"props":2642,"children":2643},{"style":103},[2644],{"type":46,"value":137},{"type":41,"tag":86,"props":2646,"children":2647},{"style":140},[2648],{"type":46,"value":2649}," client",{"type":41,"tag":86,"props":2651,"children":2652},{"style":120},[2653],{"type":46,"value":148},{"type":41,"tag":86,"props":2655,"children":2656},{"style":120},[2657],{"type":46,"value":153},{"type":41,"tag":86,"props":2659,"children":2660},{"style":114},[2661],{"type":46,"value":2525},{"type":41,"tag":86,"props":2663,"children":2664},{"style":161},[2665],{"type":46,"value":164},{"type":41,"tag":86,"props":2667,"children":2668},{"style":114},[2669],{"type":46,"value":2534},{"type":41,"tag":86,"props":2671,"children":2672},{"style":161},[2673],{"type":46,"value":2539},{"type":41,"tag":86,"props":2675,"children":2676},{"style":120},[2677],{"type":46,"value":1574},{"type":41,"tag":86,"props":2679,"children":2680},{"style":93},[2681],{"type":46,"value":2682},"  \u002F\u002F Called at runtime\n",{"type":41,"tag":86,"props":2684,"children":2685},{"class":88,"line":1105},[2686],{"type":41,"tag":86,"props":2687,"children":2688},{"style":120},[2689],{"type":46,"value":337},{"type":41,"tag":49,"props":2691,"children":2693},{"id":2692},"review-checklist",[2694],{"type":46,"value":2695},"Review Checklist",{"type":41,"tag":2697,"props":2698,"children":2701},"ul",{"className":2699},[2700],"contains-task-list",[2702,2715,2724,2738,2747,2756,2765,2780,2789,2798],{"type":41,"tag":2703,"props":2704,"children":2707},"li",{"className":2705},[2706],"task-list-item",[2708,2713],{"type":41,"tag":2709,"props":2710,"children":2712},"input",{"disabled":344,"type":2711},"checkbox",[],{"type":46,"value":2714}," All infrastructure at package level",{"type":41,"tag":2703,"props":2716,"children":2718},{"className":2717},[2706],[2719,2722],{"type":41,"tag":2709,"props":2720,"children":2721},{"disabled":344,"type":2711},[],{"type":46,"value":2723}," Using ES6 imports, not require()",{"type":41,"tag":2703,"props":2725,"children":2727},{"className":2726},[2706],[2728,2731,2733],{"type":41,"tag":2709,"props":2729,"children":2730},{"disabled":344,"type":2711},[],{"type":46,"value":2732}," Cross-service calls use ",{"type":41,"tag":82,"props":2734,"children":2736},{"className":2735},[],[2737],{"type":46,"value":776},{"type":41,"tag":2703,"props":2739,"children":2741},{"className":2740},[2706],[2742,2745],{"type":41,"tag":2709,"props":2743,"children":2744},{"disabled":344,"type":2711},[],{"type":46,"value":2746}," Proper error handling with APIError",{"type":41,"tag":2703,"props":2748,"children":2750},{"className":2749},[2706],[2751,2754],{"type":41,"tag":2709,"props":2752,"children":2753},{"disabled":344,"type":2711},[],{"type":46,"value":2755}," SQL uses template literals",{"type":41,"tag":2703,"props":2757,"children":2759},{"className":2758},[2706],[2760,2763],{"type":41,"tag":2709,"props":2761,"children":2762},{"disabled":344,"type":2711},[],{"type":46,"value":2764}," Request\u002Fresponse types defined",{"type":41,"tag":2703,"props":2766,"children":2768},{"className":2767},[2706],[2769,2772,2774],{"type":41,"tag":2709,"props":2770,"children":2771},{"disabled":344,"type":2711},[],{"type":46,"value":2773}," Internal endpoints have ",{"type":41,"tag":82,"props":2775,"children":2777},{"className":2776},[],[2778],{"type":46,"value":2779},"expose: false",{"type":41,"tag":2703,"props":2781,"children":2783},{"className":2782},[2706],[2784,2787],{"type":41,"tag":2709,"props":2785,"children":2786},{"disabled":344,"type":2711},[],{"type":46,"value":2788}," Subscription handlers are idempotent",{"type":41,"tag":2703,"props":2790,"children":2792},{"className":2791},[2706],[2793,2796],{"type":41,"tag":2709,"props":2794,"children":2795},{"disabled":344,"type":2711},[],{"type":46,"value":2797}," Secrets accessed inside functions, not at import time",{"type":41,"tag":2703,"props":2799,"children":2801},{"className":2800},[2706],[2802,2805],{"type":41,"tag":2709,"props":2803,"children":2804},{"disabled":344,"type":2711},[],{"type":46,"value":2806}," Migrations follow naming convention (001_name.up.sql)",{"type":41,"tag":49,"props":2808,"children":2810},{"id":2809},"output-format",[2811],{"type":46,"value":2812},"Output Format",{"type":41,"tag":56,"props":2814,"children":2815},{},[2816],{"type":46,"value":2817},"When reviewing, report issues as:",{"type":41,"tag":75,"props":2819,"children":2823},{"className":2820,"code":2822,"language":46},[2821],"language-text","[CRITICAL] [file:line] Description of issue\n[WARNING] [file:line] Description of concern  \n[GOOD] Notable good practice observed\n",[2824],{"type":41,"tag":82,"props":2825,"children":2826},{"__ignoreMap":79},[2827],{"type":46,"value":2822},{"type":41,"tag":2829,"props":2830,"children":2831},"style",{},[2832],{"type":46,"value":2833},"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);}",{"items":2835,"total":3002},[2836,2848,2860,2878,2894,2900,2916,2931,2948,2965,2977,2988],{"slug":2837,"name":2837,"fn":2838,"description":2839,"org":2840,"tags":2841,"stars":21,"repoUrl":22,"updatedAt":2847},"encore-api","build type-safe APIs with Encore","Define typed API endpoints in Encore.ts using `api(...)` from `encore.dev\u002Fapi`. Covers typed request\u002Fresponse interfaces, path\u002Fquery\u002Fheader\u002Fcookie params, request validation, and `APIError`. For raw endpoints (`api.raw()`) and inbound webhooks, use `encore-webhook` instead.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2842,2845,2846],{"name":2843,"slug":2844,"type":16},"API Development","api-development",{"name":9,"slug":8,"type":16},{"name":18,"slug":19,"type":16},"2026-04-06T18:09:46.044101",{"slug":2849,"name":2849,"fn":2850,"description":2851,"org":2852,"tags":2853,"stars":21,"repoUrl":22,"updatedAt":2859},"encore-auth","implement Encore.ts authentication","Protect Encore.ts endpoints with authentication and authorize callers. Covers `authHandler`, `Gateway`, `getAuthData`, and `auth: true`.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2854,2857,2858],{"name":2855,"slug":2856,"type":16},"Auth","auth",{"name":9,"slug":8,"type":16},{"name":18,"slug":19,"type":16},"2026-04-06T18:09:47.336322",{"slug":2861,"name":2861,"fn":2862,"description":2863,"org":2864,"tags":2865,"stars":21,"repoUrl":22,"updatedAt":2877},"encore-bucket","store files in Encore.ts buckets","Store unstructured files in Encore.ts using `Bucket` from `encore.dev\u002Fstorage\u002Fobjects` — uploads, images, documents, blobs.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2866,2869,2870,2873,2876],{"name":2867,"slug":2868,"type":16},"Backend","backend",{"name":9,"slug":8,"type":16},{"name":2871,"slug":2872,"type":16},"File Storage","file-storage",{"name":2874,"slug":2875,"type":16},"File Uploads","file-uploads",{"name":18,"slug":19,"type":16},"2026-05-16T05:59:52.813772",{"slug":2879,"name":2879,"fn":2880,"description":2881,"org":2882,"tags":2883,"stars":21,"repoUrl":22,"updatedAt":2893},"encore-cache","cache data in Redis with Encore.ts","Cache data in Redis from Encore.ts using `CacheCluster` and typed keyspaces from `encore.dev\u002Fstorage\u002Fcache`. Type-safe key\u002Fvalue access with TTLs, atomic increments, and per-keyspace data shapes.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2884,2885,2888,2889,2892],{"name":2867,"slug":2868,"type":16},{"name":2886,"slug":2887,"type":16},"Caching","caching",{"name":9,"slug":8,"type":16},{"name":2890,"slug":2891,"type":16},"Redis","redis",{"name":18,"slug":19,"type":16},"2026-05-16T05:59:56.808328",{"slug":4,"name":4,"fn":5,"description":6,"org":2895,"tags":2896,"stars":21,"repoUrl":22,"updatedAt":23},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2897,2898,2899],{"name":14,"slug":15,"type":16},{"name":9,"slug":8,"type":16},{"name":18,"slug":19,"type":16},{"slug":2901,"name":2901,"fn":2902,"description":2903,"org":2904,"tags":2905,"stars":21,"repoUrl":22,"updatedAt":2915},"encore-cron","schedule recurring jobs in Encore.ts","Schedule periodic \u002F recurring work in Encore.ts using `CronJob` from `encore.dev\u002Fcron`. Covers `every: \"1h\"` interval syntax and `schedule: \"0 9 * * 1\"` cron expressions.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2906,2909,2910,2911,2914],{"name":2907,"slug":2908,"type":16},"Automation","automation",{"name":2867,"slug":2868,"type":16},{"name":9,"slug":8,"type":16},{"name":2912,"slug":2913,"type":16},"Scheduling","scheduling",{"name":18,"slug":19,"type":16},"2026-05-16T05:59:54.146651",{"slug":2917,"name":2917,"fn":2918,"description":2919,"org":2920,"tags":2921,"stars":21,"repoUrl":22,"updatedAt":2930},"encore-database","build Encore databases","Work with PostgreSQL in Encore.ts using `SQLDatabase` from `encore.dev\u002Fstorage\u002Fsqldb` — schema migrations and SQL queries.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2922,2925,2926,2929],{"name":2923,"slug":2924,"type":16},"Database","database",{"name":9,"slug":8,"type":16},{"name":2927,"slug":2928,"type":16},"ORM","orm",{"name":18,"slug":19,"type":16},"2026-04-06T18:09:54.823017",{"slug":2932,"name":2932,"fn":2933,"description":2934,"org":2935,"tags":2936,"stars":21,"repoUrl":22,"updatedAt":2947},"encore-frontend","connect frontend to Encore backend","Connect a frontend application (React, Next.js, Vue, Svelte, etc.) to an Encore.ts backend.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2937,2938,2941,2944],{"name":9,"slug":8,"type":16},{"name":2939,"slug":2940,"type":16},"Frontend","frontend",{"name":2942,"slug":2943,"type":16},"Next.js","next-js",{"name":2945,"slug":2946,"type":16},"React","react","2026-04-06T18:09:56.091006",{"slug":2949,"name":2949,"fn":2950,"description":2951,"org":2952,"tags":2953,"stars":21,"repoUrl":22,"updatedAt":2964},"encore-getting-started","build and run applications with Encore.ts","Bootstrap a brand-new Encore.ts project from zero. Only for first-time CLI install and `encore app create` — not for architecture or feature questions.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2954,2955,2956,2957,2960,2961],{"name":2843,"slug":2844,"type":16},{"name":2867,"slug":2868,"type":16},{"name":9,"slug":8,"type":16},{"name":2958,"slug":2959,"type":16},"Local Development","local-development",{"name":18,"slug":19,"type":16},{"name":2962,"slug":2963,"type":16},"Web Development","web-development","2026-04-06T18:10:04.885446",{"slug":2966,"name":2966,"fn":2967,"description":2968,"org":2969,"tags":2970,"stars":21,"repoUrl":22,"updatedAt":2976},"encore-go-api","build APIs with Encore Go","Define typed API endpoints in Encore Go using `\u002F\u002Fencore:api` annotations. Covers typed request\u002Fresponse structs, path\u002Fquery\u002Fheader\u002Fcookie params, and error returns. For raw endpoints (`\u002F\u002Fencore:api raw`) and inbound webhooks, use `encore-go-webhook` instead.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2971,2972,2973],{"name":2843,"slug":2844,"type":16},{"name":9,"slug":8,"type":16},{"name":2974,"slug":2975,"type":16},"Go","go","2026-04-06T18:09:48.578781",{"slug":2978,"name":2978,"fn":2979,"description":2980,"org":2981,"tags":2982,"stars":21,"repoUrl":22,"updatedAt":2987},"encore-go-auth","implement authentication with Encore Go","Protect Encore Go endpoints with authentication and authorize callers. Covers `auth.AuthHandler`, `auth.UserID`, the `Authorization` header, and `\u002F\u002Fencore:api auth`.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2983,2984,2985,2986],{"name":2855,"slug":2856,"type":16},{"name":2867,"slug":2868,"type":16},{"name":9,"slug":8,"type":16},{"name":2974,"slug":2975,"type":16},"2026-04-06T18:09:51.065102",{"slug":2989,"name":2989,"fn":2990,"description":2991,"org":2992,"tags":2993,"stars":21,"repoUrl":22,"updatedAt":3001},"encore-go-bucket","store files in Encore Go buckets","Store unstructured files in Encore Go using `objects.NewBucket` from `encore.dev\u002Fstorage\u002Fobjects` — uploads, images, documents, blobs.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[2994,2995,2996,2997,2998],{"name":2867,"slug":2868,"type":16},{"name":9,"slug":8,"type":16},{"name":2871,"slug":2872,"type":16},{"name":2974,"slug":2975,"type":16},{"name":2999,"slug":3000,"type":16},"Storage","storage","2026-05-16T06:00:03.633918",28,{"items":3004,"total":3002},[3005,3011,3017,3025,3033,3039,3047],{"slug":2837,"name":2837,"fn":2838,"description":2839,"org":3006,"tags":3007,"stars":21,"repoUrl":22,"updatedAt":2847},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3008,3009,3010],{"name":2843,"slug":2844,"type":16},{"name":9,"slug":8,"type":16},{"name":18,"slug":19,"type":16},{"slug":2849,"name":2849,"fn":2850,"description":2851,"org":3012,"tags":3013,"stars":21,"repoUrl":22,"updatedAt":2859},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3014,3015,3016],{"name":2855,"slug":2856,"type":16},{"name":9,"slug":8,"type":16},{"name":18,"slug":19,"type":16},{"slug":2861,"name":2861,"fn":2862,"description":2863,"org":3018,"tags":3019,"stars":21,"repoUrl":22,"updatedAt":2877},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3020,3021,3022,3023,3024],{"name":2867,"slug":2868,"type":16},{"name":9,"slug":8,"type":16},{"name":2871,"slug":2872,"type":16},{"name":2874,"slug":2875,"type":16},{"name":18,"slug":19,"type":16},{"slug":2879,"name":2879,"fn":2880,"description":2881,"org":3026,"tags":3027,"stars":21,"repoUrl":22,"updatedAt":2893},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3028,3029,3030,3031,3032],{"name":2867,"slug":2868,"type":16},{"name":2886,"slug":2887,"type":16},{"name":9,"slug":8,"type":16},{"name":2890,"slug":2891,"type":16},{"name":18,"slug":19,"type":16},{"slug":4,"name":4,"fn":5,"description":6,"org":3034,"tags":3035,"stars":21,"repoUrl":22,"updatedAt":23},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3036,3037,3038],{"name":14,"slug":15,"type":16},{"name":9,"slug":8,"type":16},{"name":18,"slug":19,"type":16},{"slug":2901,"name":2901,"fn":2902,"description":2903,"org":3040,"tags":3041,"stars":21,"repoUrl":22,"updatedAt":2915},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3042,3043,3044,3045,3046],{"name":2907,"slug":2908,"type":16},{"name":2867,"slug":2868,"type":16},{"name":9,"slug":8,"type":16},{"name":2912,"slug":2913,"type":16},{"name":18,"slug":19,"type":16},{"slug":2917,"name":2917,"fn":2918,"description":2919,"org":3048,"tags":3049,"stars":21,"repoUrl":22,"updatedAt":2930},{"slug":8,"name":9,"logoUrl":10,"githubOrg":11},[3050,3051,3052,3053],{"name":2923,"slug":2924,"type":16},{"name":9,"slug":8,"type":16},{"name":2927,"slug":2928,"type":16},{"name":18,"slug":19,"type":16}]