github VoltAgent/voltagent @voltagent/server-hono@1.2.11

14 hours ago

Patch Changes

  • #883 9320326 Thanks @omeraplak! - feat: add authNext and deprecate legacy auth

    Add a new authNext policy that splits routes into public, console, and user access. All routes are protected by default; use publicRoutes to opt out.

    AuthNext example:

    import { jwtAuth } from "@voltagent/server-core";
    import { honoServer } from "@voltagent/server-hono";
    
    const server = honoServer({
      authNext: {
        provider: jwtAuth({ secret: process.env.JWT_SECRET! }),
        publicRoutes: ["GET /health"],
      },
    });

    Behavior summary:

    • When authNext is set, all routes are private by default.
    • Console endpoints (agents, workflows, tools, docs, observability, updates) require a Console Access Key.
    • Execution endpoints require a user token (JWT).

    Console access uses VOLTAGENT_CONSOLE_ACCESS_KEY:

    VOLTAGENT_CONSOLE_ACCESS_KEY=your-console-key
    curl http://localhost:3141/agents \
      -H "x-console-access-key: your-console-key"

    Legacy auth remains supported but is deprecated. Use authNext for new integrations.

  • Updated dependencies [9320326]:

    • @voltagent/server-core@1.0.36

Don't miss a new voltagent release

NewReleases is sending notifications on new releases.