misp_get_organisation
Retrieve detailed information about a MISP organisation using its unique ID.
Instructions
Get details of a specific MISP organisation
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| orgId | Yes | Organisation ID |
Implementation Reference
- src/tools/organisations.ts:57-82 (handler)Handler for the 'misp_get_organisation' tool. Calls client.getOrganisation(orgId) and returns the organisation details as JSON, or an error message on failure.
// Get organisation details server.tool( "misp_get_organisation", "Get details of a specific MISP organisation", { orgId: z.string().describe("Organisation ID"), }, async ({ orgId }) => { try { const org = await client.getOrganisation(orgId); return { content: [{ type: "text", text: JSON.stringify(org, null, 2) }], }; } catch (err) { return { content: [ { type: "text", text: `Error getting organisation: ${err instanceof Error ? err.message : String(err)}`, }, ], isError: true, }; } } ); - src/tools/organisations.ts:61-63 (schema)Input schema for the tool: accepts 'orgId' (required string) as defined via Zod.
{ orgId: z.string().describe("Organisation ID"), }, - src/client.ts:643-649 (helper)Client method getOrganisation() that performs a GET request to /organisations/view/{orgId} and returns the Organisation object.
async getOrganisation(orgId: string): Promise<MispOrganisation> { const data = await this.request<{ Organisation: MispOrganisation }>( "GET", `/organisations/view/${encodeId(orgId, "orgId")}` ); return data.Organisation; } - src/types.ts:97-106 (helper)MispOrganisation interface defining the shape of the returned organisation object.
export interface MispOrganisation { id: string; name: string; uuid: string; description: string; nationality: string; sector: string; type: string; local: boolean; } - src/index.ts:41-42 (registration)Registration of organisation tools (including misp_get_organisation) via registerOrganisationTools(server, client) in the main entry point.
registerOrganisationTools(server, client); registerServerTools(server, client);