eve 0.34.0 → 0.35.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (261) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/README.md +3 -3
  3. package/dist/src/chunks/{use-eve-agent-BNdcle_M.js → use-eve-agent-COmP-H8R.js} +6 -3
  4. package/dist/src/chunks/{use-eve-agent-FJkEMXYk.js → use-eve-agent-CnppTEFk.js} +6 -3
  5. package/dist/src/cli/commands/info.js +1 -1
  6. package/dist/src/cli/commands/trace-detail.d.ts +3 -2
  7. package/dist/src/cli/commands/trace-detail.js +1 -1
  8. package/dist/src/cli/dev/tui/traces/trace-conversation.d.ts +4 -6
  9. package/dist/src/cli/dev/tui/traces/trace-conversation.js +1 -2
  10. package/dist/src/client/agent-info-schema.d.ts +12 -4
  11. package/dist/src/client/agent-info-schema.js +1 -1
  12. package/dist/src/client/index.d.ts +1 -1
  13. package/dist/src/compiled/.vendor-stamp.json +3 -3
  14. package/dist/src/compiled/@chat-adapter/slack/index.js +1 -1
  15. package/dist/src/compiled/@workflow/core/index.js +1 -1
  16. package/dist/src/compiled/@workflow/core/runtime.js +3 -3
  17. package/dist/src/compiled/@workflow/core/workflow.js +1 -1
  18. package/dist/src/compiled/@workflow/world/env-config.d.ts +1 -0
  19. package/dist/src/compiled/@workflow/world/events.d.ts +92 -35
  20. package/dist/src/compiled/@workflow/world/index.d.ts +3 -2
  21. package/dist/src/compiled/@workflow/world/interfaces.d.ts +25 -23
  22. package/dist/src/compiled/@workflow/world/queue.d.ts +4 -0
  23. package/dist/src/compiled/@workflow/world/runs.d.ts +4 -0
  24. package/dist/src/compiled/@workflow/world/slot-identity.d.ts +53 -0
  25. package/dist/src/compiled/@workflow/world/spec-version.d.ts +36 -1
  26. package/dist/src/compiled/@workflow/world/steps.d.ts +4 -0
  27. package/dist/src/compiled/@workflow/world/ulid.d.ts +6 -0
  28. package/dist/src/compiled/@workflow/world-local/index.js +4 -4
  29. package/dist/src/compiled/@workflow/world-vercel/index.js +13 -17
  30. package/dist/src/compiled/_chunks/workflow/{attribute-changes-6OqdYdi4.js → attribute-changes-BoH7JsWp.js} +3 -3
  31. package/dist/src/compiled/_chunks/workflow/dist-DlFv0aHY.js +40 -0
  32. package/dist/src/compiled/_chunks/workflow/env-config-DxamfI7T.js +1 -0
  33. package/dist/src/compiled/_chunks/workflow/frames-CTpeJYEQ.js +3 -0
  34. package/dist/src/compiled/_chunks/workflow/{functions-CXb61C6h.js → functions-CeeNvKsq.js} +1 -1
  35. package/dist/src/compiled/_chunks/workflow/resume-hook-BPQHjeY5.js +1 -0
  36. package/dist/src/compiled/_chunks/workflow/run-DQ5dOyjm.js +1 -0
  37. package/dist/src/compiled/_chunks/workflow/run-id-BdE0MZz9.js +1 -0
  38. package/dist/src/compiled/_chunks/workflow/sleep-CzdoBiqy.js +1 -0
  39. package/dist/src/compiled/_chunks/workflow/spec-version-DBUVfF_R.js +1 -0
  40. package/dist/src/compiled/_chunks/workflow/undici-CUIybhQ2.js +95 -0
  41. package/dist/src/compiled/_chunks/workflow/wait-until-DK2lnH6U.js +15 -0
  42. package/dist/src/compiled/_chunks/workflow/{wrapper-CDq65xJV.js → wrapper-CMGju7QA.js} +1 -1
  43. package/dist/src/compiled/_chunks/workflow/ws-transport-Csi6Cydc.js +1 -0
  44. package/dist/src/compiler/extension-compatibility.d.ts +10 -10
  45. package/dist/src/compiler/extension-compatibility.js +1 -1
  46. package/dist/src/compiler/manifest.d.ts +8 -8
  47. package/dist/src/compiler/manifest.js +1 -1
  48. package/dist/src/compiler/normalize-extension.d.ts +3 -3
  49. package/dist/src/compiler/normalize-extension.js +1 -1
  50. package/dist/src/compiler/normalize-instructions.d.ts +1 -1
  51. package/dist/src/compiler/normalize-instructions.js +1 -1
  52. package/dist/src/compiler/normalize-manifest.js +1 -3
  53. package/dist/src/context/dynamic-instruction-lifecycle.d.ts +5 -1
  54. package/dist/src/context/dynamic-instruction-lifecycle.js +1 -1
  55. package/dist/src/context/keys.d.ts +6 -2
  56. package/dist/src/context/keys.js +1 -1
  57. package/dist/src/discover/manifest.d.ts +1 -1
  58. package/dist/src/discover/manifest.js +1 -1
  59. package/dist/src/evals/index.d.ts +2 -2
  60. package/dist/src/evals/reporters/index.d.ts +1 -1
  61. package/dist/src/evals/runner/artifacts.js +1 -1
  62. package/dist/src/evals/runner/execute-eval.d.ts +5 -0
  63. package/dist/src/evals/runner/execute-eval.js +1 -1
  64. package/dist/src/evals/runner/execute-task.d.ts +3 -0
  65. package/dist/src/evals/runner/execute-task.js +1 -1
  66. package/dist/src/evals/runner/reporters/braintrust.js +1 -1
  67. package/dist/src/evals/runner/reporters/types.d.ts +28 -2
  68. package/dist/src/evals/runner/run-evals.js +1 -1
  69. package/dist/src/evals/session.d.ts +11 -2
  70. package/dist/src/evals/session.js +1 -1
  71. package/dist/src/evals/target.js +1 -1
  72. package/dist/src/evals/types.d.ts +10 -1
  73. package/dist/src/execution/node-step.js +1 -1
  74. package/dist/src/execution/session.js +1 -1
  75. package/dist/src/execution/settle-cancelled-turn-step.js +1 -1
  76. package/dist/src/execution/workflow-steps.js +1 -1
  77. package/dist/src/execution/workflow-trace-context.d.ts +11 -0
  78. package/dist/src/execution/workflow-trace-context.js +1 -0
  79. package/dist/src/harness/ai-sdk-hook-bridge.d.ts +1 -1
  80. package/dist/src/harness/ai-sdk-hook-bridge.js +1 -1
  81. package/dist/src/harness/channel-delivery-instrumentation.d.ts +1 -1
  82. package/dist/src/harness/channel-delivery-instrumentation.js +1 -1
  83. package/dist/src/harness/emission.d.ts +2 -2
  84. package/dist/src/harness/emission.js +1 -1
  85. package/dist/src/harness/instrumentation/config.js +1 -0
  86. package/dist/src/harness/{instrumentation-content.d.ts → instrumentation/content.d.ts} +1 -1
  87. package/dist/src/harness/{instrumentation-dispatch.d.ts → instrumentation/dispatch.d.ts} +1 -1
  88. package/dist/src/harness/{instrumentation-dispatch.js → instrumentation/dispatch.js} +1 -1
  89. package/dist/src/harness/{instrumentation-lifecycle.d.ts → instrumentation/lifecycle.d.ts} +3 -6
  90. package/dist/src/harness/{instrumentation-lifecycle.js → instrumentation/lifecycle.js} +1 -1
  91. package/dist/src/harness/{instrumentation-native-events.d.ts → instrumentation/native-events.d.ts} +1 -1
  92. package/dist/src/harness/{instrumentation-native-events.js → instrumentation/native-events.js} +1 -1
  93. package/dist/src/harness/{instrumentation-providers.d.ts → instrumentation/providers.d.ts} +1 -1
  94. package/dist/src/harness/{instrumentation-providers.js → instrumentation/providers.js} +1 -1
  95. package/dist/src/harness/{instrumentation-runtime.d.ts → instrumentation/runtime.d.ts} +4 -2
  96. package/dist/src/harness/{instrumentation-state.d.ts → instrumentation/state.d.ts} +1 -1
  97. package/dist/src/harness/parent-lineage.d.ts +1 -1
  98. package/dist/src/harness/prepare-trace-context.d.ts +16 -0
  99. package/dist/src/harness/prepare-trace-context.js +1 -0
  100. package/dist/src/harness/tool-loop.js +2 -2
  101. package/dist/src/harness/types.d.ts +1 -1
  102. package/dist/src/internal/application/compiled-artifacts.js +2 -2
  103. package/dist/src/internal/application/package.js +1 -1
  104. package/dist/src/internal/authored-definition/core.d.ts +3 -3
  105. package/dist/src/internal/authored-definition/core.js +1 -1
  106. package/dist/src/internal/authored-package-boundary.js +1 -1
  107. package/dist/src/internal/helpers/markdown.js +1 -1
  108. package/dist/src/internal/instrumentation.d.ts +1 -1
  109. package/dist/src/internal/nitro/host/build-vercel-agent-summary.js +1 -1
  110. package/dist/src/internal/nitro/routes/agent-info/build-agent-info-response-from-manifest.js +1 -1
  111. package/dist/src/internal/nitro/routes/agent-info/build-agent-info-response.d.ts +4 -3
  112. package/dist/src/internal/nitro/routes/agent-info/build-agent-info-response.js +1 -1
  113. package/dist/src/internal/nitro/routes/channel-request-instrumentation.js +1 -1
  114. package/dist/src/internal/vercel/project-link.d.ts +1 -1
  115. package/dist/src/internal/vercel/project-link.js +1 -1
  116. package/dist/src/internal/vercel-agent-summary.d.ts +10 -9
  117. package/dist/src/internal/vercel-agent-summary.js +1 -1
  118. package/dist/src/internal/workflow/development-world-client.js +1 -1
  119. package/dist/src/protocol/message.d.ts +15 -1
  120. package/dist/src/protocol/message.js +1 -1
  121. package/dist/src/public/channels/github/auth.d.ts +30 -0
  122. package/dist/src/public/channels/github/auth.js +2 -2
  123. package/dist/src/public/channels/github/defaults.d.ts +4 -4
  124. package/dist/src/public/channels/github/defaults.js +1 -1
  125. package/dist/src/public/channels/github/dispatch.d.ts +3 -2
  126. package/dist/src/public/channels/github/dispatch.js +1 -1
  127. package/dist/src/public/channels/github/githubChannel.d.ts +7 -2
  128. package/dist/src/public/channels/github/githubChannel.js +1 -1
  129. package/dist/src/public/channels/github/index.d.ts +1 -1
  130. package/dist/src/public/definitions/instructions.d.ts +14 -4
  131. package/dist/src/public/definitions/instructions.js +1 -1
  132. package/dist/src/public/definitions/tool.d.ts +5 -8
  133. package/dist/src/public/instructions/index.d.ts +1 -2
  134. package/dist/src/public/instructions/index.js +1 -1
  135. package/dist/src/public/instrumentation/index.d.ts +4 -3
  136. package/dist/src/public/instrumentation/otel.d.ts +5 -4
  137. package/dist/src/public/instrumentation/provider.d.ts +2 -2
  138. package/dist/src/runtime/agent/bootstrap.d.ts +2 -0
  139. package/dist/src/runtime/agent/bootstrap.js +1 -1
  140. package/dist/src/runtime/prompt/compose.d.ts +1 -1
  141. package/dist/src/runtime/prompt/compose.js +3 -1
  142. package/dist/src/runtime/resolve-agent.js +1 -1
  143. package/dist/src/runtime/types.d.ts +4 -3
  144. package/dist/src/setup/project-resolution.d.ts +3 -3
  145. package/dist/src/setup/scaffold/create/project.js +1 -1
  146. package/dist/src/setup/slack-connect-lifecycle.d.ts +0 -9
  147. package/dist/src/setup/slack-connect-lifecycle.js +1 -1
  148. package/dist/src/setup/slackbot.d.ts +2 -1
  149. package/dist/src/setup/slackbot.js +1 -1
  150. package/dist/src/shared/dynamic-tool-definition.d.ts +3 -4
  151. package/dist/src/shared/instructions-definition.d.ts +15 -11
  152. package/dist/src/svelte/index.js +1 -1
  153. package/dist/src/svelte/use-eve-agent.js +1 -1
  154. package/dist/src/tracing/agent-action-instrumentation.d.ts +1 -1
  155. package/dist/src/tracing/agent-action-instrumentation.js +1 -1
  156. package/dist/src/tracing/agent-approval-instrumentation.d.ts +1 -1
  157. package/dist/src/tracing/agent-channel-delivery-instrumentation.d.ts +1 -1
  158. package/dist/src/tracing/agent-channel-delivery-instrumentation.js +1 -1
  159. package/dist/src/tracing/agent-otel-provider.d.ts +4 -2
  160. package/dist/src/tracing/agent-otel-provider.js +2 -2
  161. package/dist/src/tracing/agent-otel-session-context.d.ts +17 -0
  162. package/dist/src/tracing/agent-otel-session-context.js +1 -0
  163. package/dist/src/tracing/agent-otel-usage.d.ts +1 -1
  164. package/dist/src/tracing/agent-tool-instrumentation.d.ts +1 -1
  165. package/dist/src/tracing/agent-tool-instrumentation.js +1 -1
  166. package/dist/src/tracing/agent-trace-state.d.ts +1 -1
  167. package/dist/src/tracing/install-instrumentation-runtime.d.ts +2 -2
  168. package/dist/src/tracing/install-instrumentation-runtime.js +1 -1
  169. package/dist/src/tracing/local-instrumentation-runtime.d.ts +1 -1
  170. package/dist/src/tracing/local-instrumentation-runtime.js +1 -1
  171. package/dist/src/tracing/local-traces.d.ts +3 -3
  172. package/dist/src/tracing/local-traces.js +1 -1
  173. package/dist/src/tracing/otel-declaration.d.ts +2 -2
  174. package/dist/src/tracing/otel-declaration.js +1 -1
  175. package/dist/src/vue/index.js +1 -1
  176. package/dist/src/vue/use-eve-agent.js +1 -1
  177. package/docs/README.md +18 -20
  178. package/docs/agent-config.md +5 -5
  179. package/docs/channels/eve.mdx +10 -56
  180. package/docs/channels/github.mdx +1 -1
  181. package/docs/channels/meta.json +1 -0
  182. package/docs/concepts/context-control.md +32 -56
  183. package/docs/concepts/default-harness.md +2 -2
  184. package/docs/concepts/execution-model-and-durability.mdx +4 -4
  185. package/docs/concepts/meta.json +3 -1
  186. package/docs/concepts/sessions-runs-and-streaming.md +22 -10
  187. package/docs/{guides → concepts}/state.md +3 -3
  188. package/docs/connections/mcp.mdx +6 -89
  189. package/docs/connections/meta.json +1 -0
  190. package/docs/connections/openapi.mdx +5 -69
  191. package/docs/connections/overview.mdx +29 -3
  192. package/docs/evals/meta.json +1 -0
  193. package/docs/evals/reporters.mdx +14 -4
  194. package/docs/extensions.md +1 -1
  195. package/docs/getting-started.mdx +175 -13
  196. package/docs/guides/auth-and-route-protection.md +3 -18
  197. package/docs/guides/client/meta.json +2 -1
  198. package/docs/guides/client/output-schema.mdx +2 -2
  199. package/docs/guides/client/overview.mdx +1 -1
  200. package/docs/guides/deployment/meta.json +1 -0
  201. package/docs/guides/deployment/overview.md +1 -1
  202. package/docs/guides/deployment/self-hosting.md +3 -3
  203. package/docs/guides/deployment/vercel.mdx +1 -1
  204. package/docs/guides/dev-tui.md +3 -13
  205. package/docs/guides/dynamic-capabilities.md +26 -4
  206. package/docs/guides/frontend/meta.json +2 -1
  207. package/docs/guides/frontend/nextjs.mdx +1 -10
  208. package/docs/guides/frontend/nuxt.mdx +1 -10
  209. package/docs/guides/frontend/overview.mdx +12 -3
  210. package/docs/guides/frontend/sveltekit.mdx +1 -10
  211. package/docs/guides/frontend/use-eve-agent-svelte.mdx +39 -126
  212. package/docs/guides/frontend/use-eve-agent-vue.mdx +40 -139
  213. package/docs/guides/instrumentation.md +15 -15
  214. package/docs/guides/meta.json +1 -5
  215. package/docs/guides/remote-agents.md +9 -9
  216. package/docs/guides/session-context.md +34 -103
  217. package/docs/install-integrations.mdx +1 -1
  218. package/docs/instructions.mdx +45 -12
  219. package/docs/meta.json +24 -13
  220. package/docs/patterns/dynamic-scheduling.md +1 -1
  221. package/docs/patterns/meta.json +1 -0
  222. package/docs/patterns/multi-tenant-approvals.md +1 -1
  223. package/docs/patterns/multi-tenant-auth.md +1 -1
  224. package/docs/patterns/multi-tenant-memory.md +4 -3
  225. package/docs/{guides → protocols}/acp.md +1 -1
  226. package/docs/protocols/meta.json +5 -0
  227. package/docs/reference/cli.md +34 -34
  228. package/docs/reference/meta.json +1 -1
  229. package/docs/reference/typescript-api.md +4 -2
  230. package/docs/{subagents.mdx → subagents/index.mdx} +2 -2
  231. package/docs/subagents/meta.json +5 -0
  232. package/docs/{guides/dynamic-workflows.md → subagents/workflow-tool.md} +6 -6
  233. package/docs/tools/human-in-the-loop.md +1 -1
  234. package/docs/tools/meta.json +1 -0
  235. package/docs/tools/overview.mdx +1 -1
  236. package/docs/tutorial/connect-a-warehouse.mdx +1 -1
  237. package/docs/tutorial/meta.json +1 -0
  238. package/docs/tutorial/remember-definitions.mdx +2 -2
  239. package/docs/tutorial/ship-it.mdx +2 -2
  240. package/package.json +4 -4
  241. package/dist/src/compiled/_chunks/workflow/dist-C8PhDW9B.js +0 -1
  242. package/dist/src/compiled/_chunks/workflow/functions-xMPAeWFr.js +0 -1
  243. package/dist/src/compiled/_chunks/workflow/node-Smb57EnG.js +0 -40
  244. package/dist/src/compiled/_chunks/workflow/resume-hook-BrduAuFX.js +0 -1
  245. package/dist/src/compiled/_chunks/workflow/run-CX7_sJnW.js +0 -1
  246. package/dist/src/compiled/_chunks/workflow/sleep-tsb2HjWK.js +0 -1
  247. package/dist/src/compiled/_chunks/workflow/undici-BNc_0O4m.js +0 -95
  248. package/dist/src/compiled/_chunks/workflow/wait-until-BYKVqrwc.js +0 -15
  249. package/dist/src/harness/instrumentation-config.js +0 -1
  250. package/docs/installation.mdx +0 -66
  251. package/docs/project-structure.mdx +0 -53
  252. package/docs/reference/project-layout.md +0 -123
  253. /package/dist/src/harness/{instrumentation-config.d.ts → instrumentation/config.d.ts} +0 -0
  254. /package/dist/src/harness/{instrumentation-content.js → instrumentation/content.js} +0 -0
  255. /package/dist/src/harness/{instrumentation-runtime-context.d.ts → instrumentation/runtime-context.d.ts} +0 -0
  256. /package/dist/src/harness/{instrumentation-runtime-context.js → instrumentation/runtime-context.js} +0 -0
  257. /package/dist/src/harness/{instrumentation-runtime.js → instrumentation/runtime.js} +0 -0
  258. /package/dist/src/harness/{instrumentation-setup-context.d.ts → instrumentation/setup-context.d.ts} +0 -0
  259. /package/dist/src/harness/{instrumentation-setup-context.js → instrumentation/setup-context.js} +0 -0
  260. /package/dist/src/harness/{instrumentation-state.js → instrumentation/state.js} +0 -0
  261. /package/docs/{guides → protocols}/ucp.mdx +0 -0
@@ -26,68 +26,13 @@ The `url` must speak Streamable HTTP or SSE. Write the `description` for the mod
26
26
 
27
27
  ## Use Vercel Connect for OAuth
28
28
 
29
- For OAuth-backed MCP servers, prefer [Vercel Connect](https://vercel.com/docs/connect). Connect owns the browser consent flow, encrypted token storage, refresh, and project access. The `connect()` helper from `@vercel/connect/eve` plugs that lifecycle into eve's connection auth, so credentials never land in model context or conversation history.
29
+ For OAuth-backed MCP servers, use the shared [Vercel Connect flow](../connections#interactive-oauth-via-vercel-connect), then pass the returned connector UID to `connect()`. Keep the MCP runtime URL and Connect service identifier distinct. For example, Linear uses `https://mcp.linear.app/mcp` as the MCP endpoint and `mcp.linear.app` when creating the connector.
30
30
 
31
- From the Vercel project or agent app that will run the connection:
32
-
33
- ```bash
34
- npm install @vercel/connect
35
- vercel link
36
- vercel connect create mcp.linear.app --name linear
37
- vercel connect attach <connector-uid> --yes
38
- vercel env pull
39
- ```
40
-
41
- Use the connector UID returned by the CLI in `connect("<connector-uid>")`. For Linear, the MCP runtime endpoint is `https://mcp.linear.app/mcp`, while the managed Connect service identifier is `mcp.linear.app`; those are related but not interchangeable.
42
-
43
- By default, `connect("...")` is user-scoped. The first tool call for a new user emits an `authorization.required` event with a URL to visit, parks the turn, and resumes after the callback completes. The active eve session must already have a user principal from route auth or from a platform channel. If there is no authenticated user, the connection fails with `reason: "principal_required"`.
44
-
45
- If the MCP server should act as the agent itself instead of the signed-in user, make the connector app-scoped:
46
-
47
- ```ts title="agent/connections/linear.ts"
48
- import { connect } from "@vercel/connect/eve";
49
- import { defineMcpClientConnection } from "eve/connections";
50
-
51
- export default defineMcpClientConnection({
52
- url: "https://mcp.linear.app/mcp",
53
- description: "Linear workspace: issues, projects, cycles, and comments.",
54
- auth: connect({ connector: "mcp.linear.app/linear", principalType: "app" }),
55
- });
56
- ```
57
-
58
- App-scoped Connect auth is non-interactive. eve asks Connect for one shared app token; if the connector is missing or cannot issue an app token, the tool call fails terminally so an operator can fix setup.
31
+ `connect("...")` is user-scoped by default and requires an authenticated user on the active eve session. Use `connect({ connector, principalType: "app" })` when the server should act as the agent instead. The connections overview covers connector setup, session requirements, app and user scope, callback behavior, and troubleshooting.
59
32
 
60
33
  ## Static tokens and headers
61
34
 
62
- Use `auth.getToken` when you already have a bearer token, API key, service account token, or out-of-band OAuth flow. eve sends the returned token as `Authorization: Bearer <token>`.
63
-
64
- ```ts title="agent/connections/linear.ts"
65
- import { defineMcpClientConnection } from "eve/connections";
66
-
67
- export default defineMcpClientConnection({
68
- url: "https://mcp.linear.app/mcp",
69
- description: "Linear workspace: issues, projects, cycles, and comments.",
70
- auth: {
71
- getToken: async () => ({ token: process.env.LINEAR_API_TOKEN! }),
72
- },
73
- });
74
- ```
75
-
76
- Use `headers` for non-Bearer auth schemes or extra server configuration:
77
-
78
- ```ts title="agent/connections/private-docs.ts"
79
- import { defineMcpClientConnection } from "eve/connections";
80
-
81
- export default defineMcpClientConnection({
82
- url: "https://docs.example.com/mcp",
83
- description: "Internal docs: search pages, owners, and recent changes.",
84
- headers: {
85
- "X-Api-Key": process.env.DOCS_API_KEY!,
86
- },
87
- });
88
- ```
89
-
90
- `auth` and `headers` can also be functions that receive the active session context. Use that when credentials, tenants, or routing depend on the caller.
35
+ MCP connections accept the shared connection `auth` and `headers` options. Use `auth.getToken` for a bearer token, `headers` for another scheme, and resolver functions when credentials or routing depend on the caller. See [Static-token auth](../connections#static-token-auth), [Headers](../connections#headers), and [Per-caller auth and headers](../connections#per-caller-auth-and-headers) for the canonical examples and token-lifecycle behavior.
91
36
 
92
37
  ## Application-provided tool arguments
93
38
 
@@ -119,18 +64,7 @@ eve treats configured keys as application-owned: it removes them from every remo
119
64
 
120
65
  ## No auth
121
66
 
122
- Omit `auth` and `headers` only for intentionally public or local-only servers:
123
-
124
- ```ts title="agent/connections/local.ts"
125
- import { defineMcpClientConnection } from "eve/connections";
126
-
127
- export default defineMcpClientConnection({
128
- url: "http://localhost:3001/mcp",
129
- description: "Local dev MCP server.",
130
- });
131
- ```
132
-
133
- Do not use a no-auth connection for sensitive third-party services unless another layer protects the endpoint.
67
+ Omit `auth` and `headers` only for an intentionally public or loopback MCP server. See [No auth](../connections#no-auth) for the shared connection behavior and security boundary.
134
68
 
135
69
  ## Tool filters
136
70
 
@@ -152,24 +86,7 @@ Prefer `allow` for the smallest safe surface, especially when the server exposes
152
86
 
153
87
  ## Approval gates
154
88
 
155
- For MCP tools that can create, modify, delete, message, transmit, purchase, or access sensitive data, add a human approval gate:
156
-
157
- ```ts title="agent/connections/linear.ts"
158
- import { connect } from "@vercel/connect/eve";
159
- import { defineMcpClientConnection } from "eve/connections";
160
- import { once } from "eve/tools/approval";
161
-
162
- export default defineMcpClientConnection({
163
- url: "https://mcp.linear.app/mcp",
164
- description: "Linear workspace.",
165
- auth: connect("mcp.linear.app/linear"),
166
- approval: once(),
167
- });
168
- ```
169
-
170
- `once()` asks the first time in a session, `always()` asks on every tool call, and `never()` allows calls without approval. Authorization and approval work together: eve records approval before an OAuth park, then resumes without asking again for the same approved call.
171
-
172
- The `once()`, `always()`, and `never()` helpers from `eve/tools/approval` gate every tool the connection serves the same way. See [Connections](/docs/connections#per-connection-approval) for those, and [Human-in-the-loop](/docs/human-in-the-loop) for the full pause-and-resume contract.
89
+ Use the shared `approval` option to gate every tool served by an MCP connection. The [connections overview](../connections#per-connection-approval) defines the `never()`, `once()`, and `always()` helpers; [Human-in-the-loop](../human-in-the-loop#approvals) defines the pause-and-resume contract.
173
90
 
174
91
  ### Gate specific tools by name or input
175
92
 
@@ -233,5 +150,5 @@ When a remote tool returns more data than the model needs, narrow the result at
233
150
 
234
151
  - [Connections](../connections): shared auth, headers, approval, and per-caller patterns.
235
152
  - [OpenAPI connections](./openapi): generate tools from OpenAPI operations.
236
- - [Auth & route protection](../guides/auth-and-route-protection): route auth and the full interactive OAuth lifecycle.
153
+ - [Authentication](../guides/auth-and-route-protection): establish the caller identity required by user-scoped auth.
237
154
  - [Security model](../concepts/security-model): how connection credentials stay out of the model's reach.
@@ -1,4 +1,5 @@
1
1
  {
2
2
  "title": "Connections",
3
+ "defaultOpen": false,
3
4
  "pages": ["overview", "mcp", "openapi"]
4
5
  }
@@ -48,19 +48,7 @@ export default defineOpenAPIConnection({
48
48
 
49
49
  ## Use Vercel Connect for OAuth
50
50
 
51
- For OAuth-backed APIs, prefer [Vercel Connect](https://vercel.com/docs/connect). Connect owns browser consent, encrypted token storage, refresh, and project access. The `connect()` helper from `@vercel/connect/eve` plugs that lifecycle into eve's connection auth, so tokens never reach model context or conversation history.
52
-
53
- Create or attach a connector for the API provider from the Vercel project or agent app that will run the connection:
54
-
55
- ```bash
56
- npm install @vercel/connect
57
- vercel link
58
- vercel connect create github --name github
59
- vercel connect attach <connector-uid> --yes
60
- vercel env pull
61
- ```
62
-
63
- Then use the connector UID returned by the CLI:
51
+ For an OAuth-backed API, follow the shared [Vercel Connect setup](../connections#interactive-oauth-via-vercel-connect), then attach the returned connector UID to the OpenAPI connection:
64
52
 
65
53
  ```ts title="agent/connections/github.ts"
66
54
  import { connect } from "@vercel/connect/eve";
@@ -74,48 +62,11 @@ export default defineOpenAPIConnection({
74
62
  });
75
63
  ```
76
64
 
77
- By default, `connect("...")` is user-scoped. The active eve session must have a user principal from route auth or from a platform channel before the first operation call. If the API should act as the agent itself, make the connector app-scoped:
78
-
79
- ```ts
80
- auth: connect({ connector: "github/github", principalType: "app" });
81
- ```
82
-
83
- Use `tokenParams` on `connect(...)` when the provider requires explicit OAuth scopes, audiences, resource indicators, or authorization details.
65
+ `connect("...")` is user-scoped by default and requires an authenticated user on the active session. Use `connect({ connector, principalType: "app" })` when the API should act as the agent instead. Configure provider-specific scopes, audiences, or authorization details through `tokenParams` on `connect(...)`.
84
66
 
85
67
  ## Static tokens and headers
86
68
 
87
- Use `auth.getToken` when you already have a bearer token, API key, service account token, or out-of-band OAuth flow. eve sends the returned token as `Authorization: Bearer <token>`.
88
-
89
- ```ts title="agent/connections/crm.ts"
90
- import { defineOpenAPIConnection } from "eve/connections";
91
-
92
- export default defineOpenAPIConnection({
93
- spec: "https://api.example.com/openapi.json",
94
- baseUrl: "https://api.example.com",
95
- description: "CRM accounts, contacts, and opportunities.",
96
- auth: {
97
- getToken: async () => ({ token: process.env.CRM_TOKEN! }),
98
- },
99
- });
100
- ```
101
-
102
- Use `headers` for non-Bearer auth schemes, version headers, or tenant routing:
103
-
104
- ```ts title="agent/connections/notion.ts"
105
- import { defineOpenAPIConnection } from "eve/connections";
106
-
107
- export default defineOpenAPIConnection({
108
- spec: "https://developers.notion.com/openapi.json",
109
- baseUrl: "https://api.notion.com",
110
- description: "Notion pages, databases, comments, and users.",
111
- headers: {
112
- Authorization: `Bearer ${process.env.NOTION_API_KEY!}`,
113
- "Notion-Version": "2022-06-28",
114
- },
115
- });
116
- ```
117
-
118
- `auth` and `headers` can also be functions that receive the active session context. Use that when credentials, tenants, or routing depend on the caller.
69
+ OpenAPI connections accept the shared connection `auth` and `headers` options. Use `auth.getToken` for a bearer token, `headers` for another scheme or API version, and resolver functions when credentials or routing depend on the caller. See [Static-token auth](../connections#static-token-auth), [Headers](../connections#headers), and [Per-caller auth and headers](../connections#per-caller-auth-and-headers) for the canonical examples and token-lifecycle behavior.
119
70
 
120
71
  ## Application-provided operation arguments
121
72
 
@@ -201,26 +152,11 @@ The parameter `name` must exactly match the placeholder inside the path. If the
201
152
 
202
153
  ## Approval gates
203
154
 
204
- Generated operation tools can mutate state just like authored tools. Add an approval gate when operations can create, modify, delete, message, transmit, purchase, or access sensitive data:
205
-
206
- ```ts title="agent/connections/crm.ts"
207
- import { defineOpenAPIConnection } from "eve/connections";
208
- import { once } from "eve/tools/approval";
209
-
210
- export default defineOpenAPIConnection({
211
- spec: "https://api.example.com/openapi.json",
212
- baseUrl: "https://api.example.com",
213
- description: "CRM accounts, contacts, and opportunities.",
214
- auth: { getToken: async () => ({ token: process.env.CRM_TOKEN! }) },
215
- approval: once(),
216
- });
217
- ```
218
-
219
- Combine `approval` with `operations.allow` for the smallest practical surface.
155
+ Generated operations can mutate state like authored tools. Use the shared connection `approval` option for human approval, and combine it with `operations.allow` for the smallest practical surface. See [Per-connection approval](../connections#per-connection-approval) for the helpers and [Human-in-the-loop](../human-in-the-loop#approvals) for policy behavior.
220
156
 
221
157
  ## What to read next
222
158
 
223
159
  - [Connections](../connections): shared auth, headers, approval, and per-caller patterns.
224
160
  - [MCP connections](./mcp): connect to remote MCP servers.
225
- - [Auth & route protection](../guides/auth-and-route-protection): route auth and the full interactive OAuth lifecycle.
161
+ - [Authentication](../guides/auth-and-route-protection): establish the caller identity required by user-scoped auth.
226
162
  - [Security model](../concepts/security-model): how connection credentials stay out of the model's reach.
@@ -22,7 +22,21 @@ Read [OpenAPI connections](/docs/connections/openapi) for `defineOpenAPIConnecti
22
22
 
23
23
  ## Static-token auth
24
24
 
25
- `getToken` returns a `TokenResult` (`{ token, expiresAt? }`), and eve sends it as `Authorization: Bearer <token>` on every request. Because it runs on each connection attempt, you can mint a fresh token from wherever you keep secrets, including an env var, a secrets manager, an internal vault, or your own OAuth exchange. If the token has a known TTL, set `expiresAt` (milliseconds since epoch) and eve refreshes ahead of time rather than waiting for a `401`.
25
+ `getToken` returns a `TokenResult` (`{ token, expiresAt? }`), and eve sends it as `Authorization: Bearer <token>` on every request. Because it runs on each connection attempt, you can mint a fresh token from wherever you keep secrets, including an env var, a secrets manager, an internal vault, or your own OAuth exchange:
26
+
27
+ ```ts title="agent/connections/linear.ts"
28
+ import { defineMcpClientConnection } from "eve/connections";
29
+
30
+ export default defineMcpClientConnection({
31
+ url: "https://mcp.linear.app/mcp",
32
+ description: "Linear workspace.",
33
+ auth: {
34
+ getToken: async () => ({ token: process.env.LINEAR_API_TOKEN! }),
35
+ },
36
+ });
37
+ ```
38
+
39
+ If the token has a known TTL, set `expiresAt` (milliseconds since epoch) and eve refreshes ahead of time rather than waiting for a `401`.
26
40
 
27
41
  When `getToken` is the only auth, `principalType` defaults to `"app"`: one shared credential keyed across all sessions. Switch to `principalType: "user"` when each end-user carries their own token.
28
42
 
@@ -123,7 +137,19 @@ For connection tools that can create, modify, delete, transmit, purchase, messag
123
137
 
124
138
  ## Interactive OAuth via Vercel Connect
125
139
 
126
- When the server uses OAuth and you want each end-user to sign in through their own browser, turn on interactive authorization with [Vercel Connect](https://vercel.com/docs/connect). The `connect()` helper from `@vercel/connect/eve` handles consent, encrypted token storage, and refresh, then hooks all of that into eve's authorization flow:
140
+ When the server uses OAuth and you want each end-user to sign in through their own browser, turn on interactive authorization with [Vercel Connect](https://vercel.com/docs/connect). The `connect()` helper from `@vercel/connect/eve` handles consent, encrypted token storage, and refresh, then hooks all of that into eve's authorization flow.
141
+
142
+ Create and attach the connector from the Vercel project or agent app that will use it:
143
+
144
+ ```bash
145
+ npm install @vercel/connect
146
+ vercel link
147
+ vercel connect create <service> --name <name>
148
+ vercel connect attach <connector-uid> --yes
149
+ vercel env pull
150
+ ```
151
+
152
+ Use the connector UID returned by the CLI in `connect("<connector-uid>")`. The service identifier accepted by `vercel connect create` depends on the provider; it is not necessarily the same as an MCP runtime URL or OpenAPI base URL.
127
153
 
128
154
  ```ts title="agent/connections/linear.ts"
129
155
  import { connect } from "@vercel/connect/eve";
@@ -155,7 +181,7 @@ export default defineMcpClientConnection({
155
181
  });
156
182
  ```
157
183
 
158
- App-scoped Connect auth is non-interactive. eve asks Vercel Connect for an app token and does not emit a browser consent challenge; if the connector is not installed or cannot issue an app token, the tool call fails terminally so an operator can fix the connector setup. The full setup (Connect client provisioning, project linking, the runtime consent flow) lives in [Auth & route protection](/docs/guides/auth-and-route-protection).
184
+ App-scoped Connect auth is non-interactive. eve asks Vercel Connect for an app token and does not emit a browser consent challenge; if the connector is not installed or cannot issue an app token, the tool call fails terminally so an operator can fix the connector setup. See [Authentication](/docs/guides/auth-and-route-protection) when a user-scoped connection needs your HTTP channel to establish the caller's identity.
159
185
 
160
186
  ### Troubleshooting Vercel Connect auth
161
187
 
@@ -1,4 +1,5 @@
1
1
  {
2
2
  "title": "Evals",
3
+ "defaultOpen": false,
3
4
  "pages": ["overview", "cases", "assertions", "judge", "targets", "reporters", "running"]
4
5
  }
@@ -38,7 +38,7 @@ export default defineEval({
38
38
  });
39
39
  ```
40
40
 
41
- The reporter config takes an optional `projectName` and `experimentName`, plus a base experiment (by name or id) to diff against. Gate assertions log as binary scores under a `gate:` prefix so experiments diff gate regressions the same way they diff soft-score regressions. Repeated names use `#2`, `#3`, and later suffixes; use `.label(name)` to give them meaningful names. Failed assertion details are stored in the Braintrust metadata under `eveFailedAssertions`.
41
+ The reporter config takes an optional `projectName` and `experimentName`, plus a base experiment (by name or id) to diff against. Gate assertions log as binary scores under a `gate:` prefix so experiments diff gate regressions the same way they diff soft-score regressions. Repeated names use `#2`, `#3`, and later suffixes; use `.label(name)` to give them meaningful names. Failed assertion details are stored in the Braintrust metadata under `eveFailedAssertions`; observed traces are stored under `eveTraceIds` and `eveTraceContexts`.
42
42
 
43
43
  A reporter instance observes the evals that reference it. Share one instance across several evals (the config, a `shared.ts` export, or every entry of a dataset array) and their results land in a single experiment. Listing the same config reporter on an eval too does not double-report it.
44
44
 
@@ -56,17 +56,27 @@ Each eval becomes one `<testcase>` named by its path-derived id; failed gates an
56
56
 
57
57
  ## Custom reporters
58
58
 
59
- A reporter implements the `EvalReporter` interface from `eve/evals/reporters` and receives the same structured results the built-ins do. The runner calls three lifecycle methods, each of which may return a promise for async work like a remote upload:
59
+ A reporter implements the `EvalReporter` interface from `eve/evals/reporters` and receives the same structured results the built-ins do. Every callback may return a promise for async work like a remote upload:
60
60
 
61
61
  ```ts
62
62
  interface EvalReporter {
63
63
  onRunStart(evaluations: readonly EveEval[], target: EveEvalTarget): void | Promise<void>;
64
- onEvalComplete(result: EveEvalResult): void | Promise<void>;
64
+ onEvalStart?(event: EveEvalStartEvent): void | Promise<void>;
65
+ onSessionStart?(event: EveEvalSessionStartEvent): void | Promise<void>;
66
+ onEvalComplete(result: EveEvalResult, context?: EveEvalCompleteContext): void | Promise<void>;
65
67
  onRunComplete(summary: EveEvalRunSummary): void | Promise<void>;
66
68
  }
67
69
  ```
68
70
 
69
- `onRunStart` fires once before any eval runs, `onEvalComplete` fires after each observed eval with its checks, scores, and verdict, and `onRunComplete` fires once with the aggregated summary. Reach for a custom reporter only when a destination isn't covered. The per-run artifacts under `.eve/evals/` already capture everything for ad-hoc inspection.
71
+ `onRunStart` fires once before any eval runs, and `onRunComplete` fires once with the aggregated summary. Within that run:
72
+
73
+ - `onEvalStart` fires when an eval is scheduled. It includes the eval definition, target, and start time.
74
+ - `onSessionStart` fires once for each session after eve receives its first trace context. It includes `sessionId`, `primary`, and `traceContext` with `traceId`, `spanId`, and `traceFlags`.
75
+ - `onEvalComplete` fires with the checks, scores, and verdict. The runner also supplies `context`, including every distinct trace context collected across the eval's sessions. The same list is available as `result.result.traceContexts`.
76
+
77
+ An eval can create several sessions, and a long session can produce several traces, so completion exposes a list instead of a single trace id. `onEvalStart` does not include a trace because the agent session has not started yet. If the target has no tracing configured, `onSessionStart` does not fire and the completed trace list is empty.
78
+
79
+ Reporter callbacks for an eval stay ordered—eval start, traced session starts, then completion—even when several evals run concurrently. Reach for a custom reporter only when a destination isn't covered. The per-run artifacts under `.eve/evals/` retain the trace contexts alongside the result for ad-hoc inspection.
70
80
 
71
81
  ## What to read next
72
82
 
@@ -5,7 +5,7 @@ description: "Package reusable eve capabilities and mount them from npm or a mon
5
5
 
6
6
  Extensions package eve tools, connections, skills, instruction fragments, and hooks. An author builds an extension package; each agent that uses it declares the package as a dependency and mounts it. The package can be published to a package registry or kept private inside a monorepo workspace.
7
7
 
8
- Ready-made extensions can also be distributed through an eve integration registry. See [Install Integrations](./install-integrations) to discover and add one with `eve add`; this page explains how extension packages are authored, mounted, configured, and overridden.
8
+ Ready-made extensions can also be distributed through an eve integration registry. See [Add Integrations](./install-integrations) to discover and add one with `eve add`; this page explains how extension packages are authored, mounted, configured, and overridden.
9
9
 
10
10
  This enables sharing many different capability sets. A browser extension might include several tools for navigating a site. A memory extension could use hooks to capture context and tools to recall it. A self-improving extension could pair hooks with dynamic instructions.
11
11
 
@@ -1,23 +1,185 @@
1
1
  ---
2
2
  title: "Getting Started"
3
- description: "Create an eve project, learn its filesystem layout, and start adding capabilities."
4
- contentType: "Landing"
3
+ description: "Create an eve project, configure a model, understand its filesystem layout, and run your first agent."
4
+ contentType: "How-to"
5
5
  ---
6
6
 
7
- eve agents are TypeScript projects. You describe an agent with files under `agent/`, then eve runs it as a durable service.
7
+ ## Prerequisites
8
8
 
9
- ## Start in order
10
-
11
- 1. [Install eve](/docs/installation): create a project, configure a model credential, and run it locally
12
- 2. [Learn the project structure](/docs/project-structure): see which files eve discovers and where each capability belongs
13
- 3. [Build your first agent](/docs/tutorial/first-agent): add tools, state, and an interface for a useful workflow
14
-
15
- ## What you need
9
+ You need:
16
10
 
17
11
  - Node.js 24 or newer
18
12
  - npm, which Node.js includes
19
- - A model credential for the model your agent uses
13
+ - A credential for the model your agent uses
14
+
15
+ The default scaffolded model routes through the Vercel AI Gateway. Set `AI_GATEWAY_API_KEY`, or link a Vercel project to use `VERCEL_OIDC_TOKEN`. To use a model provider directly, install its AI SDK provider package and set the provider's API key.
16
+
17
+ Choose a model, provider, and channel that meet your data-processing and compliance requirements.
18
+
19
+ ## Create a project
20
+
21
+ Run `eve init` with a project name:
22
+
23
+ ```bash
24
+ npx eve@latest init my-agent
25
+ ```
26
+
27
+ The command creates the project, installs dependencies, and initializes Git. If a supported coding-agent REPL is available, eve offers to start the development server, open the REPL, or exit after scaffolding.
28
+
29
+ Pass an AI Gateway model ID or reasoning effort when you do not want the defaults:
30
+
31
+ ```bash
32
+ npx eve@latest init my-agent --model openai/gpt-5.5 --reasoning high
33
+ ```
34
+
35
+ To add eve to a project that already has a `package.json`, run this command from its root before you create any `agent/` files:
36
+
37
+ ```bash
38
+ npx eve@latest init .
39
+ ```
40
+
41
+ eve adds the missing `eve`, `ai`, and `zod` dependencies without changing files the project already owns.
42
+
43
+ ## Run the agent
44
+
45
+ If the development server is not already running, start it from the project root:
46
+
47
+ ```bash
48
+ npm run dev
49
+ ```
50
+
51
+ The TUI sends messages to your agent. Stop the server with `Ctrl+C` when you need your shell for another command.
52
+
53
+ ## Project layout
54
+
55
+ eve builds an agent by walking the filesystem under `agent/`. Each directory is an authored slot, and the slot a file lands in determines how eve loads it.
56
+
57
+ ### Naming from paths
58
+
59
+ Identity comes from the path. You never write a `name` or `id` field on a `define*` call.
60
+
61
+ | Path | Resolves to |
62
+ | ------------------------------------- | --------------------- |
63
+ | `agent/tools/get_weather.ts` | tool `get_weather` |
64
+ | `agent/connections/linear.ts` | connection `linear` |
65
+ | `agent/skills/summarize.md` | skill `summarize` |
66
+ | `agent/subagents/researcher/agent.ts` | subagent `researcher` |
67
+
68
+ The root agent takes its name from the enclosing `package.json` `name`, falling back to the app-root directory name when `package.json` has no `name`. A subagent takes its name from its directory.
69
+
70
+ ### Recommended layout
71
+
72
+ A minimal agent needs `instructions.md`; `agent.ts` is optional when the defaults are sufficient. Add other slots as the agent needs them:
73
+
74
+ ```text
75
+ my-agent/
76
+ ├── package.json
77
+ ├── tsconfig.json
78
+ ├── agent/
79
+ │ ├── agent.ts
80
+ │ ├── instructions.md
81
+ │ ├── instrumentation.ts
82
+ │ ├── channels/
83
+ │ ├── connections/
84
+ │ ├── hooks/
85
+ │ ├── skills/
86
+ │ ├── lib/
87
+ │ ├── sandbox/
88
+ │ ├── tools/
89
+ │ ├── schedules/
90
+ │ └── subagents/
91
+ └── evals/
92
+ ```
93
+
94
+ Evals live beside `agent/`, not inside it.
95
+
96
+ ### Authored slots
97
+
98
+ The Subagents column states whether a local subagent (`subagents/<id>/`) can author the slot. A declared subagent inherits nothing from the root; it discovers its own slots.
99
+
100
+ | Path | Description | Subagents | Notes |
101
+ | ------------------------------------------------------- | ----------------------------------------- | --------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
102
+ | `agent.ts` | Runtime config | Yes | Model, model options, compaction, build, and experimental settings. See [Agents](./agent-config). |
103
+ | `instructions.md` / `instructions.ts` / `instructions/` | Base system prompt | Optional | A flat file or directory of `.md` and `.ts` files. Static sources compose at build time. Dynamic sources resolve at runtime. Required on the root, optional on subagents. |
104
+ | `instrumentation.ts` | Telemetry config | No | OTel exporter and AI SDK span settings, auto-discovered and run before agent code. Root-only. |
105
+ | `channels/` | HTTP and messaging entry points | No | Root-only. |
106
+ | `connections/` | External MCP and OpenAPI services | Yes | One connection per file; its name comes from the filename. |
107
+ | `hooks/` | Lifecycle and stream-event subscribers | Yes | Module-backed only. Recursive directories are supported. |
108
+ | `skills/` | On-demand procedures and capability packs | Yes | Flat markdown, module-backed skills, or packaged skills. Runtime files are seeded under `$HOME/.agents/skills/`, with `/workspace/skills/` as a fallback. |
109
+ | `lib/` | Shared authored helper code | Yes | Import-only; not mounted into the workspace. |
110
+ | `sandbox.ts` or `sandbox/sandbox.ts` | The agent's single sandbox | Yes | Use `sandbox.ts` for a definition-only override; use `sandbox/sandbox.ts` with `sandbox/workspace/**` to also seed files. The framework default applies when neither is authored. |
111
+ | `sandbox/workspace/**` | Files seeded into the sandbox | Yes | Mirrored into `/workspace/` when a session starts. |
112
+ | `tools/` | Typed executable integrations | Yes | Module-backed only. |
113
+ | `schedules/` | Recurring jobs | No | Each schedule is a default-exported `defineSchedule` module or a markdown prompt with `cron` frontmatter. Recursive nesting is supported. Root-only. |
114
+ | `subagents/` | Specialist child agents | Yes | Each child is a local package under `subagents/<id>/`. Nested subagents are supported. |
115
+
116
+ ### Runtime files and source files
117
+
118
+ eve does not mount the whole authored tree into the runtime sandbox. Files under `agent/sandbox/workspace/**` land in `/workspace/` when a session starts.
119
+
120
+ Skill package files land outside the workspace under `$HOME/.agents/skills/`, with `/workspace/skills/` as a fallback when `$HOME` is unavailable. Everything in `lib/` remains import-only source code.
121
+
122
+ ### Local subagents
123
+
124
+ A local subagent uses the same `agent.ts` shape as the root:
125
+
126
+ ```text
127
+ agent/subagents/researcher/
128
+ ├── agent.ts
129
+ ├── instructions.md
130
+ ├── connections/
131
+ ├── hooks/
132
+ ├── skills/
133
+ ├── lib/
134
+ ├── sandbox/
135
+ ├── tools/
136
+ └── subagents/
137
+ ```
138
+
139
+ A subagent's `agent.ts` is required and must provide a description, while its instructions are optional. Connections, hooks, skills, shared code, sandboxes, tools, and nested subagents are supported. Channels and schedules remain root-only. See [Subagents](./subagents) for inheritance and isolation behavior.
140
+
141
+ ### Flat layout
142
+
143
+ When the app root is also the agent root, eve supports this layout:
144
+
145
+ ```text
146
+ my-agent/
147
+ ├── package.json
148
+ ├── agent.ts
149
+ ├── instructions.md
150
+ ├── tools/
151
+ └── skills/
152
+ ```
153
+
154
+ Prefer the nested layout because it keeps application files separate from the authored agent surface.
155
+
156
+ ### Debug file discovery
157
+
158
+ Run `eve info` when eve does not discover a file. It lists the discovered surface and diagnostics so you can check the authored slot and root-versus-subagent boundary. eve also writes inspectable artifacts under `.eve/`; see [Observability](./guides/instrumentation) and the [CLI](./reference/cli) reference.
159
+
160
+ ## Install manually
161
+
162
+ If you do not want to use the scaffold, install the runtime dependencies:
163
+
164
+ ```bash
165
+ npm install eve@latest ai zod
166
+ ```
167
+
168
+ Declare Node.js 24 in `package.json`, then create `agent/instructions.md` and, when you need runtime configuration, `agent/agent.ts`.
169
+
170
+ ## Continue with the tutorial
171
+
172
+ The [Tutorial](/docs/tutorial/first-agent) builds a data analytics agent step by step. It adds tools, state, sandboxed analysis, reusable skills, and human approval before deploying the result.
173
+
174
+ After the tutorial, continue with the task you need:
20
175
 
21
- ## Choose your next step
176
+ | Goal | Read |
177
+ | ------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- |
178
+ | Give the model an action it can call | [Tools](/docs/tools) |
179
+ | Connect an MCP server or OpenAPI service | [Connections](/docs/connections) |
180
+ | Reach users through Slack, Discord, or another platform | [Channels](/docs/channels/overview) |
181
+ | Build a browser interface | [Frontend Frameworks](/docs/guides/frontend/overview) |
182
+ | Test agent behavior | [Evals](/docs/evals/overview) |
183
+ | Secure and deploy the agent | [Authentication](/docs/guides/auth-and-route-protection), then [Deployment](/docs/guides/deployment/overview) |
22
184
 
23
- Start with [Installation](/docs/installation) when you need a new project. Read [Project structure](/docs/project-structure) when you already have an eve project or want to add a capability.
185
+ Read [Execution Model and Durability](/docs/concepts/execution-model-and-durability) for the mental model behind sessions, turns, durable steps, and parked work.
@@ -1,5 +1,5 @@
1
1
  ---
2
- title: "Auth & Route Protection"
2
+ title: "Authentication"
3
3
  description: "Secure your agent's HTTP routes with an ordered auth walk, verifier helpers, and connection OAuth via Vercel Connect."
4
4
  ---
5
5
 
@@ -12,7 +12,7 @@ Start with route auth.
12
12
 
13
13
  ## Route auth
14
14
 
15
- The route-auth policy lives on the HTTP channel factory (`agent/channels/eve.ts`) and guards three routes:
15
+ The route-auth policy lives on the HTTP channel factory (`agent/channels/eve.ts`) and guards these route groups:
16
16
 
17
17
  - `POST /eve/v1/session`
18
18
  - `POST /eve/v1/session/:sessionId`
@@ -307,22 +307,7 @@ Built-in platform channels that identify a human sender, such as Slack, Discord,
307
307
 
308
308
  ### On a connection
309
309
 
310
- Attach `connect()` from `@vercel/connect/eve` to the connection:
311
-
312
- ```ts title="agent/connections/linear.ts"
313
- import { connect } from "@vercel/connect/eve";
314
- import { defineMcpClientConnection } from "eve/connections";
315
- import { once } from "eve/tools/approval";
316
-
317
- export default defineMcpClientConnection({
318
- url: "https://mcp.linear.app/mcp",
319
- description: "Linear: project management, issue tracking, and team workflows.",
320
- auth: connect("linear/myagent"),
321
- approval: once(),
322
- });
323
- ```
324
-
325
- The first call that needs a user-scoped connection kicks off an OAuth sign-in, surfaced as an authorization challenge (a URL the caller visits). [Vercel Connect](https://vercel.com/docs/connect) brokers the flow and holds the credentials, which are resolved and cached per workflow step, never serialized into history, and never shown to the model. For non-interactive connections, pass a static token or `connect({ connector, principalType: "app" })` in place of user-scoped `connect()`. [Connections](../connections) covers both shapes.
310
+ Set `auth` on an MCP or OpenAPI connection when the external service supplies a family of remote tools. The [connections overview](../connections) owns the shared `connect()` setup, static-token providers, app and user scope, approval interaction, and self-hosted OAuth flow.
326
311
 
327
312
  ### On a single tool
328
313
 
@@ -1,4 +1,5 @@
1
1
  {
2
- "title": "TypeScript SDK",
2
+ "title": "Client SDK",
3
+ "defaultOpen": false,
3
4
  "pages": ["overview", "messages", "continuations", "streaming", "output-schema"]
4
5
  }
@@ -119,10 +119,10 @@ const followUp = await followUpResponse.result();
119
119
  console.log(followUp.data); // undefined unless this turn also requested a schema
120
120
  ```
121
121
 
122
- For task-mode output that belongs to the agent or subagent definition itself, see [`agent.ts`](../../agent-config#outputschema) and [Subagents](../../subagents).
122
+ For task-mode output that belongs to the agent or subagent definition itself, see [`agent.ts`](../../agent-config#other-defineagent-fields) and [Subagents](../../subagents).
123
123
 
124
124
  ## What to read next
125
125
 
126
126
  - [Messages](./messages): send turns with `send()`
127
127
  - [Streaming](./streaming): handle `result.completed` live
128
- - [`agent.ts`](../../agent-config#outputschema): configured task-mode output
128
+ - [`agent.ts`](../../agent-config#other-defineagent-fields): configured task-mode output
@@ -1,5 +1,5 @@
1
1
  ---
2
- title: "TypeScript SDK Overview"
2
+ title: "Client SDK"
3
3
  description: "Call an eve agent from TypeScript with Client, sessions, auth, and health checks."
4
4
  ---
5
5
 
@@ -1,4 +1,5 @@
1
1
  {
2
2
  "title": "Deployment",
3
+ "defaultOpen": false,
3
4
  "pages": ["overview", "vercel", "self-hosting"]
4
5
  }