Skip to main content
Glama
Infisical

Infisical MCP Server

Official
by Infisical

invite-members-to-project

Add users to an Infisical project by specifying emails or usernames, assigning roles, and linking them to a specific project ID.

Instructions

Invite members to a project in Infisical

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
emailsNoThe emails of the members to invite. Either usernames or emails must be provided.
projectIdYesThe ID of the project to invite members to (required)
roleSlugsNoThe role slugs of the members to invite. If not provided, the default role 'member' will be used. Ask the user to confirm the role they want to use if not explicitly specified.
usernamesNoThe usernames of the members to invite. Either usernames or emails must be provided.

Implementation Reference

  • Handler for the 'invite-members-to-project' tool: validates arguments using Zod schema, invokes infisicalSdk.projects().inviteMembers() with projectId, emails, usernames, and roleSlugs, and returns the result as text content.
    if (name === AvailableTools.InviteMembersToProject) {
    	const data = inviteMembersToProjectSchema.zod.parse(args);
    
    	const projectMemberships = await infisicalSdk.projects().inviteMembers({
    		projectId: data.projectId,
    		emails: data.emails,
    		usernames: data.usernames,
    		roleSlugs: data.roleSlugs
    	});
    
    	return {
    		content: [
    			{
    				type: "text",
    				text: `Members successfully invited to project: ${JSON.stringify(projectMemberships, null, 3)}`
    			}
    		]
    	};
    }
  • Schema definition including Zod validator and JSON schema for tool inputs: requires projectId, optional arrays for emails, usernames, and roleSlugs.
    const inviteMembersToProjectSchema = {
    	zod: z.object({
    		projectId: z.string(),
    		emails: z.array(z.string()).optional(),
    		usernames: z.array(z.string()).optional(),
    		roleSlugs: z.array(z.string()).optional()
    	}),
    	capability: {
    		name: AvailableTools.InviteMembersToProject,
    		description: "Invite members to a project in Infisical",
    		inputSchema: {
    			type: "object",
    			properties: {
    				projectId: {
    					type: "string",
    					description: "The ID of the project to invite members to (required)"
    				},
    				emails: {
    					type: "array",
    					description: "The emails of the members to invite. Either usernames or emails must be provided."
    				},
    				usernames: {
    					type: "array",
    					description: "The usernames of the members to invite. Either usernames or emails must be provided."
    				},
    				roleSlugs: {
    					type: "array",
    					description:
    						"The role slugs of the members to invite. If not provided, the default role 'member' will be used. Ask the user to confirm the role they want to use if not explicitly specified."
    				}
    			},
    			required: ["projectId"]
    		}
    	}
    };
  • src/index.ts:452-467 (registration)
    Registration of all tools including 'invite-members-to-project' via the ListToolsRequestSchema handler, exposing the capability.
    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
    		]
    	};
    });
  • src/index.ts:57-68 (registration)
    Enum defining the tool name constant 'InviteMembersToProject = "invite-members-to-project"' used throughout.
    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"
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden for behavioral disclosure but only states the basic action. It doesn't mention permission requirements, whether invitations are revocable, how members are notified, rate limits, or what happens if emails/usernames are invalid. For a mutation tool with zero annotation coverage, this leaves significant behavioral gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that states the core purpose without any fluff. It's appropriately sized and front-loaded with the essential information, making it easy to parse quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a mutation tool with 4 parameters and no annotations or output schema, the description is insufficiently complete. It doesn't explain what the tool returns (success/failure indicators, invitation IDs), error conditions, or behavioral constraints. The agent would need to guess about many operational aspects.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents all parameters thoroughly. The description adds no additional parameter semantics beyond what's in the schema. The baseline of 3 is appropriate when the schema does all the parameter documentation work.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('invite') and resource ('members to a project in Infisical'), making the purpose immediately understandable. However, it doesn't differentiate this tool from potential sibling tools like 'create-project' or 'create-environment' that might also involve project management operations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. There's no mention of prerequisites (e.g., needing admin permissions), when not to use it, or how it relates to sibling tools like 'create-project' or 'update-secret' in the project management workflow.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

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