Skip to main content
Glama
moneyforward-i

Admina MCP Server

bulk_update_identities

Bulk update multiple user identities in a single request. Provide identity IDs and optional field updates to apply changes efficiently.

Instructions

Bulk update multiple identities in a single request. Provide a list of identity IDs (1-50) and a set of field updates to apply to all of them. All identity update fields are optional.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
identityIdsYesArray of identity IDs to update (1-50 items)
identityUpdatesYesIdentity updates to apply to all selected identities. All fields are optional.

Implementation Reference

  • Handler function that collects defined identity field updates and sends a PATCH request to /identity/bulk endpoint.
    export async function bulkUpdateIdentities(params: BulkUpdateIdentitiesParams) {
      const client = getClient();
    
      const { identityUpdates } = params;
    
      const updates: Record<string, unknown> = {};
      if (identityUpdates.employeeStatus !== undefined) updates.employeeStatus = identityUpdates.employeeStatus;
      if (identityUpdates.employeeType !== undefined) updates.employeeType = identityUpdates.employeeType;
      if (identityUpdates.managementType !== undefined) updates.managementType = identityUpdates.managementType;
      if (identityUpdates.displayName !== undefined) updates.displayName = identityUpdates.displayName;
      if (identityUpdates.firstName !== undefined) updates.firstName = identityUpdates.firstName;
      if (identityUpdates.lastName !== undefined) updates.lastName = identityUpdates.lastName;
      if (identityUpdates.primaryEmail !== undefined) updates.primaryEmail = identityUpdates.primaryEmail;
      if (identityUpdates.secondaryEmails !== undefined) updates.secondaryEmails = identityUpdates.secondaryEmails;
      if (identityUpdates.companyName !== undefined) updates.companyName = identityUpdates.companyName;
      if (identityUpdates.workLocation !== undefined) updates.workLocation = identityUpdates.workLocation;
      if (identityUpdates.department !== undefined) updates.department = identityUpdates.department;
      if (identityUpdates.jobTitle !== undefined) updates.jobTitle = identityUpdates.jobTitle;
      if (identityUpdates.employeeId !== undefined) updates.employeeId = identityUpdates.employeeId;
      if (identityUpdates.lifecycle !== undefined) updates.lifecycle = identityUpdates.lifecycle;
      if (identityUpdates.note !== undefined) updates.note = identityUpdates.note;
      if (identityUpdates.customFields !== undefined) updates.customFields = identityUpdates.customFields;
      if (identityUpdates.manager !== undefined) updates.manager = identityUpdates.manager;
    
      const body: Record<string, unknown> = {
        identityIds: params.identityIds,
        identityUpdates: updates,
      };
    
      return client.makePatchApiCall("/identity/bulk", body);
    }
  • Input schema for bulk_update_identities: requires identityIds (1-50 items) and identityUpdates (all optional fields mirroring BulkIdentityDto).
    export const BulkUpdateIdentitiesSchema = z.object({
      identityIds: z.array(z.string().min(1)).min(1).max(50).describe("Array of identity IDs to update (1-50 items)"),
      identityUpdates: IdentityUpdatesSchema.describe(
        "Identity updates to apply to all selected identities. All fields are optional.",
      ),
    });
  • Inner schema defining all optional identity fields that can be bulk-updated.
    const IdentityUpdatesSchema = z.object({
      employeeStatus: EmployeeStatusEnum.optional().describe("Extended status of the employee"),
      employeeType: EmployeeTypeEnum.optional().describe("Type of the employee"),
      managementType: ManagementTypeEnum.nullable().optional().describe("Management type of the employee"),
      displayName: z.string().nullable().optional().describe("Display name of the employee"),
      firstName: z.string().nullable().optional().describe("First name of the employee"),
      lastName: z.string().nullable().optional().describe("Last name of the employee"),
      primaryEmail: z.string().nullable().optional().describe("Primary email of the employee"),
      secondaryEmails: z.array(z.string()).nullable().optional().describe("Secondary emails of the employee"),
      companyName: z.string().nullable().optional().describe("Company name of the employee"),
      workLocation: z.string().nullable().optional().describe("Work location of the employee"),
      department: DepartmentSchema.nullable().optional().describe("Department of the employee"),
      jobTitle: z.string().nullable().optional().describe("Job title of the employee"),
      employeeId: z.string().nullable().optional().describe("Employee ID of the employee"),
      lifecycle: LifecycleSchema.optional().describe("Lifecycle of the employee"),
      note: z.string().nullable().optional().describe("Notes of the employee"),
      customFields: z.record(z.string(), z.unknown()).optional().describe("Custom fields of the employee"),
      manager: ManagerSchema.optional().describe("Manager of the employee"),
    });
  • src/index.ts:249-253 (registration)
    Registration of the 'bulk_update_identities' tool in the ListToolsRequestSchema handler.
      name: "bulk_update_identities",
      description:
        "Bulk update multiple identities in a single request. Provide a list of identity IDs (1-50) and a set of field updates to apply to all of them. All identity update fields are optional.",
      inputSchema: zodToJsonSchema(BulkUpdateIdentitiesSchema),
    },
  • src/index.ts:324-324 (registration)
    Tool handler registration mapping the 'bulk_update_identities' name to the bulkUpdateIdentities function.
    bulk_update_identities: async (input) => bulkUpdateIdentities(BulkUpdateIdentitiesSchema.parse(input)),
Behavior2/5

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

No annotations exist, so description must cover behavioral traits. It lacks details on idempotency, error handling (e.g., partial success), rate limits, or result feedback. Only states 'bulk update' without further safety or side-effect information.

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?

Three sentences, front-loaded with key action and scope. No redundant information. Efficient use of words.

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?

Despite schema richness, the description is too brief for a complex bulk mutation. Lacks explanation of return values (no output schema), error scenarios, atomicity, or validation behavior. An agent cannot anticipate failure modes or response format.

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 coverage is 100%, so baseline is 3. Description reiterates schema info (identity IDs limit 1-50, updates apply uniformly, all optional) adding little incremental value. Does not explain complex nested fields beyond schema.

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

Purpose5/5

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

The description clearly states it is for bulk updating multiple identities, using verb 'update' and specifying 'multiple identities'. It distinguishes from sibling 'update_identity' which handles a single identity.

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

Usage Guidelines3/5

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

The description implies usage for identical updates across multiple identities, but does not explicitly state when to avoid or compare to alternatives like 'update_identity' for per-identity updates or 'merge_identities' for merging. No fallback guidance provided.

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

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/moneyforward-i/admina-mcp-server'

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