delete_dataverse_team
Remove a team from Dataverse permanently. This action cannot be undone and requires verifying the team has no assigned records or security roles before deletion.
Instructions
Permanently deletes a team from Dataverse. WARNING: This action cannot be undone and will fail if the team owns records or has assigned security roles. Ensure the team is not in use before deletion.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| teamId | Yes | ID of the team to delete |
Implementation Reference
- src/tools/team-tools.ts:243-266 (handler)The asynchronous handler function that executes the core logic of deleting the specified Dataverse team using the DataverseClient's delete method.async (params) => { try { await client.delete(`teams(${params.teamId})`); return { content: [ { type: "text", text: `Successfully deleted team.` } ] }; } catch (error) { return { content: [ { type: "text", text: `Error deleting team: ${error instanceof Error ? error.message : 'Unknown error'}` } ], isError: true }; } }
- src/tools/team-tools.ts:240-241 (schema)The input schema defining the required 'teamId' parameter using Zod validation.teamId: z.string().describe("ID of the team to delete") }
- src/tools/team-tools.ts:235-267 (registration)The server.registerTool call that registers the 'delete_dataverse_team' tool, including its schema and inline handler."delete_dataverse_team", { title: "Delete Dataverse Team", description: "Permanently deletes a team from Dataverse. WARNING: This action cannot be undone and will fail if the team owns records or has assigned security roles. Ensure the team is not in use before deletion.", inputSchema: { teamId: z.string().describe("ID of the team to delete") } }, async (params) => { try { await client.delete(`teams(${params.teamId})`); return { content: [ { type: "text", text: `Successfully deleted team.` } ] }; } catch (error) { return { content: [ { type: "text", text: `Error deleting team: ${error instanceof Error ? error.message : 'Unknown error'}` } ], isError: true }; } } );
- src/index.ts:202-202 (registration)The invocation of deleteTeamTool in the main index file, which triggers the tool registration on the MCP server.deleteTeamTool(server, dataverseClient);