Skip to main content
Glama
Infisical

Infisical MCP Server

Official
by Infisical

create-project

Initialize a project in Infisical by specifying its name, type, and optional details like description, slug, and template to streamline secret management configuration.

Instructions

Create a new project in Infisical

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
descriptionNoThe description of the project to create
kmsKeyIdNoThe ID of the KMS key to use for the project. Defaults to Infisical's default KMS
projectNameYesThe name of the project to create (required)
projectTemplateNoThe template of the project to create
slugNoThe slug of the project to create
typeYesThe type of project to create (required). If not specified by the user, ask them to confirm the type they want to use.

Implementation Reference

  • Handler function for the 'create-project' tool. Parses input arguments using the schema, calls infisicalSdk.projects().create() with the provided parameters, and returns the created project details.
    if (name === AvailableTools.CreateProject) { const data = createProjectSchema.zod.parse(args); const project = await infisicalSdk.projects().create({ projectName: data.projectName, projectDescription: data.description, kmsKeyId: data.kmsKeyId, slug: data.slug, template: data.projectTemplate, type: data.type }); return { content: [ { type: "text", text: `Project created successfully: ${JSON.stringify(project, null, 3)}` } ] }; }
  • Zod schema for input validation and capability definition (name, description, inputSchema) for the 'create-project' tool.
    const createProjectSchema = { zod: z.object({ projectName: z.string(), type: z.enum(["secret-manager", "cert-manager", "kms", "ssh"]), description: z.string().optional(), slug: z.string().optional(), projectTemplate: z.string().optional(), kmsKeyId: z.string().optional() }), capability: { name: AvailableTools.CreateProject, description: "Create a new project in Infisical", inputSchema: { type: "object", properties: { projectName: { type: "string", description: "The name of the project to create (required)" }, type: { type: "string", description: "The type of project to create (required). If not specified by the user, ask them to confirm the type they want to use." }, description: { type: "string", description: "The description of the project to create" }, slug: { type: "string", description: "The slug of the project to create" }, projectTemplate: { type: "string", description: "The template of the project to create" }, kmsKeyId: { type: "string", description: "The ID of the KMS key to use for the project. Defaults to Infisical's default KMS" } }, required: ["projectName", "type"] } } };
  • src/index.ts:452-467 (registration)
    Registration of the 'create-project' tool in the list of available tools returned by ListToolsRequestSchema handler.
    server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools: [ createSecretSchema.capability, deleteSecretSchema.capability, updateSecretSchema.capability, listSecretsSchema.capability, getSecretSchema.capability, createProjectSchema.capability, createEnvironmentSchema.capability, createFolderSchema.capability, inviteMembersToProjectSchema.capability, listProjectsSchema.capability ] }; });
  • Enum defining the tool names, including 'create-project' used in handlers and schemas.
    enum AvailableTools { CreateSecret = "create-secret", DeleteSecret = "delete-secret", UpdateSecret = "update-secret", ListSecrets = "list-secrets", GetSecret = "get-secret", CreateProject = "create-project", CreateEnvironment = "create-environment", CreateFolder = "create-folder", InviteMembersToProject = "invite-members-to-project", ListProjects = "list-projects" }

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/Infisical/infisical-mcp-server'

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