Skip to main content
Glama

setup_better_auth

Install and configure enterprise-grade authentication in your project with secure credential handling. Supports multi-protocol auth setup using project path and configuration details for improved security.

Instructions

Install and configure Better-Auth in the project

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
configYesBetter-Auth configuration options
projectPathYesPath to the project root

Implementation Reference

  • The switch case that handles the execution of the 'setup_better_auth' tool. It extracts arguments, logs the action, stores the auth config globally, and returns a success message with placeholder implementation comment.
    case "setup_better_auth": { const { projectPath, config } = request.params.arguments as { projectPath: string, config: AuthConfig }; logger.info(`Setting up Better-Auth in ${projectPath}`); authConfig = config; // Implementation would install dependencies and configure Better-Auth return { content: [{ type: "text", text: `Better-Auth setup complete in ${projectPath}` }] }; }
  • src/index.ts:75-96 (registration)
    The tool registration object returned by the ListTools handler, defining the name, description, and input schema for 'setup_better_auth'.
    name: "setup_better_auth", description: "Install and configure Better-Auth in the project", inputSchema: { type: "object", properties: { projectPath: { type: "string", description: "Path to the project root" }, config: { type: "object", description: "Better-Auth configuration options", properties: { projectId: { type: "string" }, apiKey: { type: "string" }, environment: { type: "string" } }, required: ["projectId", "apiKey"] } }, required: ["projectPath", "config"] }
  • The input schema defining the expected arguments for the 'setup_better_auth' tool: projectPath and config object with projectId and apiKey required.
    inputSchema: { type: "object", properties: { projectPath: { type: "string", description: "Path to the project root" }, config: { type: "object", description: "Better-Auth configuration options", properties: { projectId: { type: "string" }, apiKey: { type: "string" }, environment: { type: "string" } }, required: ["projectId", "apiKey"] } }, required: ["projectPath", "config"] }
  • TypeScript interface defining the AuthConfig type used in the tool handler for type-casting the config argument.
    interface AuthConfig { projectId?: string; apiKey?: string; environment?: string; }

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nahmanmate/better-auth-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server