eve 0.13.1 → 0.13.2

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 (80) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/src/chunks/use-eve-agent-B18LYpfZ.js +5765 -0
  3. package/dist/src/chunks/use-eve-agent-BPI1nbo5.js +5795 -0
  4. package/dist/src/cli/dev/tui/provider-picker.d.ts +64 -0
  5. package/dist/src/cli/dev/tui/provider-picker.js +1 -0
  6. package/dist/src/cli/dev/tui/remote-auth-result.d.ts +21 -0
  7. package/dist/src/cli/dev/tui/remote-auth-result.js +1 -0
  8. package/dist/src/cli/dev/tui/remote-connection-probe.d.ts +9 -0
  9. package/dist/src/cli/dev/tui/remote-connection-probe.js +1 -0
  10. package/dist/src/cli/dev/tui/remote-connection-types.d.ts +67 -0
  11. package/dist/src/cli/dev/tui/remote-connection-types.js +1 -0
  12. package/dist/src/cli/dev/tui/remote-connection.d.ts +3 -0
  13. package/dist/src/cli/dev/tui/remote-connection.js +1 -0
  14. package/dist/src/cli/dev/tui/runner.js +1 -1
  15. package/dist/src/cli/dev/tui/setup-commands.d.ts +1 -1
  16. package/dist/src/cli/dev/tui/setup-commands.js +2 -2
  17. package/dist/src/cli/dev/tui/setup-flow.d.ts +3 -0
  18. package/dist/src/cli/dev/tui/setup-issues.d.ts +7 -0
  19. package/dist/src/cli/dev/tui/setup-issues.js +1 -1
  20. package/dist/src/cli/dev/tui/setup-panel.d.ts +25 -12
  21. package/dist/src/cli/dev/tui/setup-panel.js +3 -2
  22. package/dist/src/cli/dev/tui/target.d.ts +2 -0
  23. package/dist/src/cli/dev/tui/target.js +1 -1
  24. package/dist/src/cli/dev/tui/terminal-renderer.js +9 -9
  25. package/dist/src/cli/dev/tui/test/fake-setup-flow-renderer.js +1 -1
  26. package/dist/src/cli/dev/tui/tui.js +1 -1
  27. package/dist/src/cli/dev/tui/vercel-trusted-sources-policy.d.ts +22 -0
  28. package/dist/src/cli/dev/tui/vercel-trusted-sources-policy.js +1 -0
  29. package/dist/src/cli/dev/tui/vercel-trusted-sources.d.ts +48 -0
  30. package/dist/src/cli/dev/tui/vercel-trusted-sources.js +1 -0
  31. package/dist/src/client/agent-info-schema.d.ts +532 -0
  32. package/dist/src/client/agent-info-schema.js +1 -0
  33. package/dist/src/client/client.js +1 -1
  34. package/dist/src/client/types.d.ts +11 -169
  35. package/dist/src/client/types.js +1 -1
  36. package/dist/src/internal/application/package.js +1 -1
  37. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/lib/primitives.js +1 -0
  38. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/lib/schemas.js +1 -0
  39. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/models/aclaction.js +1 -0
  40. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/models/sdkvalidationerror.js +1 -0
  41. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/models/updateprojectprojectsaction.js +1 -0
  42. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/models/updateprojectprojectsoptionsallowlist.js +1 -0
  43. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/types/defaultToZeroValue.js +1 -0
  44. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/types/fp.js +1 -0
  45. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/types/primitives.js +1 -0
  46. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/types/rfcdate.js +1 -0
  47. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/types/smartUnion.js +1 -0
  48. package/dist/src/node_modules/.pnpm/@vercel_sdk@1.28.1/node_modules/@vercel/sdk/esm/types/unrecognized.js +1 -0
  49. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/ZodError.js +1 -0
  50. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/errors.js +1 -0
  51. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/external.js +1 -0
  52. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/helpers/errorUtil.js +1 -0
  53. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/helpers/parseUtil.js +1 -0
  54. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/helpers/typeAliases.js +1 -0
  55. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/helpers/util.js +1 -0
  56. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/index.js +1 -0
  57. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/locales/en.js +1 -0
  58. package/dist/src/node_modules/.pnpm/zod@4.4.3/node_modules/zod/v3/types.js +1 -0
  59. package/dist/src/services/dev-client/client-options.js +1 -1
  60. package/dist/src/services/dev-client/credential-gate.d.ts +11 -6
  61. package/dist/src/services/dev-client/credential-gate.js +1 -1
  62. package/dist/src/services/dev-client/request-headers.d.ts +0 -12
  63. package/dist/src/services/dev-client/request-headers.js +1 -1
  64. package/dist/src/services/dev-client/vercel-auth-error.js +1 -1
  65. package/dist/src/setup/flows/model.d.ts +5 -5
  66. package/dist/src/setup/flows/model.js +1 -1
  67. package/dist/src/setup/flows/provider.d.ts +57 -0
  68. package/dist/src/setup/flows/provider.js +4 -0
  69. package/dist/src/setup/scaffold/create/project.js +1 -1
  70. package/dist/src/svelte/index.js +1 -1
  71. package/dist/src/svelte/use-eve-agent.js +1 -1
  72. package/dist/src/vue/index.js +1 -1
  73. package/dist/src/vue/use-eve-agent.js +1 -1
  74. package/docs/guides/client/overview.mdx +24 -0
  75. package/docs/guides/dev-tui.md +4 -4
  76. package/package.json +2 -1
  77. package/dist/src/chunks/use-eve-agent-DEm_Jg4k.js +0 -1343
  78. package/dist/src/chunks/use-eve-agent-DsXOQMFZ.js +0 -1313
  79. package/dist/src/setup/flows/vercel.d.ts +0 -37
  80. package/dist/src/setup/flows/vercel.js +0 -2
@@ -1,37 +0,0 @@
1
- import { appendEnv } from "../append-env.js";
2
- import type { Prompter } from "../prompter.js";
3
- import { validateGatewayApiKey } from "../validate-gateway-key.js";
4
- import { getVercelAuthStatus } from "../vercel-project.js";
5
- import { runLinkFlow, type LinkFlowResult } from "./link.js";
6
- export declare const PROVIDER_QUESTION = "Which model provider do you want to use?";
7
- export declare const CONNECTION_QUESTION = "How do you want to connect to AI Gateway?";
8
- export declare const EXTERNAL_PROVIDER_INSTRUCTIONS_TITLE = "Using another model provider";
9
- export declare const EXTERNAL_PROVIDER_INSTRUCTIONS: readonly string[];
10
- /** Injected for tests; defaults to the real link flow, env write, and key check. */
11
- export interface VercelFlowDeps {
12
- getVercelAuthStatus: typeof getVercelAuthStatus;
13
- runLinkFlow: typeof runLinkFlow;
14
- appendEnv: typeof appendEnv;
15
- validateGatewayApiKey: typeof validateGatewayApiKey;
16
- }
17
- export type VercelFlowResult = LinkFlowResult | {
18
- kind: "done";
19
- /** The user runs a non-gateway provider; nothing was linked or written. */
20
- outcome: "external-provider";
21
- };
22
- /**
23
- * THE PROVIDER FLOW behind the dev TUI `/model` menu's provider row
24
- * (`eve link` keeps {@link runLinkFlow}'s shape). Two entry questions make
25
- * the provider choice explicit before any link machinery runs: a provider
26
- * gate (AI Gateway, or instructions for everything else) and a connection
27
- * gate (link a project, or paste an `AI_GATEWAY_API_KEY` that lands in
28
- * `.env.local`). The "Connect via a project" branch runs the link flow in
29
- * create-or-link mode (link detection and all), so a project-less agent can
30
- * create its first project rather than dead-end on an empty list.
31
- */
32
- export declare function runVercelFlow(input: {
33
- appRoot: string;
34
- prompter: Prompter;
35
- signal?: AbortSignal;
36
- deps?: Partial<VercelFlowDeps>;
37
- }): Promise<VercelFlowResult>;
@@ -1,2 +0,0 @@
1
- import{__toESM}from"../../_virtual/_rolldown/runtime.js";import{require_picocolors}from"../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js";import{appendEnv}from"../append-env.js";import{AI_GATEWAY_API_KEY_ENV_FILE,AI_GATEWAY_API_KEY_ENV_VAR,writeAiGatewayApiKey}from"../ai-gateway-api-key.js";import{WizardCancelledError}from"../step.js";import{withSpinner}from"../with-spinner.js";import{getVercelAuthStatus}from"../vercel-project.js";import{runLinkFlow}from"./link.js";import{validateGatewayApiKey}from"../validate-gateway-key.js";var import_picocolors=__toESM(require_picocolors(),1);const PROVIDER_QUESTION=`Which model provider do you want to use?`,CONNECTION_QUESTION=`How do you want to connect to AI Gateway?`,EXTERNAL_PROVIDER_INSTRUCTIONS_TITLE=`Using another model provider`,EXTERNAL_PROVIDER_INSTRUCTIONS=[`Set your provider's API key in ${AI_GATEWAY_API_KEY_ENV_FILE} — e.g. ANTHROPIC_API_KEY or OPENAI_API_KEY.`,'In agent/agent.ts, set `model` to a provider-authored model — e.g. `anthropic("claude-opus-4.8")` from `@ai-sdk/anthropic`.',`See https://eve.dev/docs/agent-config for details.`,"A running `eve dev` reloads env files automatically — no restart needed."];function projectConnectionOption(e){let t={value:`project`,label:`Connect via a project`,hint:`vercel link + env pull`};switch(e){case`authenticated`:return t;case`cli-missing`:return{...t,disabled:!0,disabledReason:`Vercel CLI not found, see /vc`,disabledReasonTone:`warning`};case`logged-out`:return{...t,disabled:!0,disabledReason:`Log in to Vercel first, see /login`,disabledReasonTone:`warning`};case`unavailable`:return{...t,disabled:!0,disabledReason:`Couldn't reach Vercel, check your connection`,disabledReasonTone:`warning`};default:return e}}async function runVercelFlow(e){let{appRoot:t,prompter:r,signal:o}=e,s={getVercelAuthStatus,runLinkFlow,appendEnv,validateGatewayApiKey,...e.deps},c,l;try{if(c=await r.select({message:PROVIDER_QUESTION,options:[{value:`gateway`,label:`Vercel AI Gateway`,hint:`one key, every model`},{value:`other`,label:`Something else`,hint:`use your own provider credentials`}],hintLayout:`stacked`}),c===`gateway`){let e=await withSpinner(r,`Checking your Vercel login…`,async()=>{let e=await s.getVercelAuthStatus(t,{signal:o});return o?.throwIfAborted(),e});l=await r.select({message:CONNECTION_QUESTION,options:[projectConnectionOption(e),{value:`own-key`,label:`Use my own key`,hint:`paste an ${AI_GATEWAY_API_KEY_ENV_VAR}`}],hintLayout:`stacked`})}}catch(e){if(e instanceof WizardCancelledError)return{kind:`cancelled`};throw e}if(c===`other`)return r.acknowledge?await r.acknowledge({message:EXTERNAL_PROVIDER_INSTRUCTIONS_TITLE,lines:EXTERNAL_PROVIDER_INSTRUCTIONS}):r.note(EXTERNAL_PROVIDER_INSTRUCTIONS.join(`
2
- `),EXTERNAL_PROVIDER_INSTRUCTIONS_TITLE),{kind:`done`,outcome:`external-provider`};if(l===`own-key`)for(;;){let e;try{e=await r.password({message:`Enter your ${AI_GATEWAY_API_KEY_ENV_VAR}`,validate:e=>e.trim().length===0?`API key cannot be empty.`:void 0})}catch(e){if(e instanceof WizardCancelledError)return{kind:`cancelled`};throw e}o?.throwIfAborted();let n=e.trim(),i=await withSpinner(r,`Validating…`,()=>s.validateGatewayApiKey(n,o));if(o?.throwIfAborted(),i.kind===`invalid`){r.log.error(`${i.message} Check the key and try again, or Esc to cancel.`);continue}i.kind===`inconclusive`?r.log.warning(`Couldn't reach the gateway to validate (${i.message}). Saving the key anyway.`):r.log.success(`${import_picocolors.default.green(`✓`)} ${import_picocolors.default.bold(`Valid key`)}`);let a=await writeAiGatewayApiKey({projectRoot:t,apiKey:n,appendEnv:s.appendEnv});return o?.throwIfAborted(),r.log.success(`Saved ${a.envKey} to ${a.envFile}.`),{kind:`done`,credential:AI_GATEWAY_API_KEY_ENV_VAR}}else return await s.runLinkFlow({appRoot:t,prompter:r,signal:o,projectSelection:`create-or-link`})}export{CONNECTION_QUESTION,EXTERNAL_PROVIDER_INSTRUCTIONS,EXTERNAL_PROVIDER_INSTRUCTIONS_TITLE,PROVIDER_QUESTION,runVercelFlow};