unmerge_identities
Undo merges of people or identity entities by specifying their IDs. Provide up to 50 peopleIds or identityIds to separate combined records.
Instructions
Unmerge previously merged identity/people entities. Provide peopleIds, identityIds, or both to unmerge (up to 50 items each).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| peopleIds | No | List of people IDs to unmerge (1-50 items). | |
| identityIds | No | List of identity IDs to unmerge (1-50 items). |
Implementation Reference
- src/tools/unmergeIdentities.ts:16-24 (handler)The core handler function that executes the unmerge_identities tool logic. It sends a POST request to /identity/unmerge with peopleIds and/or identityIds.
export async function unmergeIdentities(params: UnmergeIdentitiesParams) { const client = getClient(); const body: Record<string, unknown> = {}; if (params.peopleIds !== undefined) body.peopleIds = params.peopleIds; if (params.identityIds !== undefined) body.identityIds = params.identityIds; return client.makePostApiCall("/identity/unmerge", new URLSearchParams(), body); } - src/tools/unmergeIdentities.ts:4-12 (schema)Zod schema defining the input: peopleIds (array of positive ints, 1-50) and identityIds (array of strings, 1-50), both optional.
export const UnmergeIdentitiesSchema = z.object({ peopleIds: z .array(z.number().int().positive()) .min(1) .max(50) .optional() .describe("List of people IDs to unmerge (1-50 items)."), identityIds: z.array(z.string()).min(1).max(50).optional().describe("List of identity IDs to unmerge (1-50 items)."), }); - src/index.ts:242-246 (registration)Registration of the 'unmerge_identities' tool with its name, description, and inputSchema.
{ name: "unmerge_identities", description: "Unmerge previously merged identity/people entities. Provide peopleIds, identityIds, or both to unmerge (up to 50 items each).", inputSchema: zodToJsonSchema(UnmergeIdentitiesSchema), - src/index.ts:323-323 (registration)Handler mapping that wires the 'unmerge_identities' tool name to the unmergeIdentities function with schema parsing.
unmerge_identities: async (input) => unmergeIdentities(UnmergeIdentitiesSchema.parse(input)), - src/tools/unmergeIdentities.ts:2-2 (helper)Imports getClient from admina-api.js which provides the HTTP client used to make the API call.
import { getClient } from "../admina-api.js";