get-domain
Retrieve domain details by UUID. Optionally specify fields to include and filter by deletion status.
Instructions
Get domain details by UUID
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Domain UUID | |
| fields | No | Comma-separated fields to include | |
| include | No |
Implementation Reference
- src/tools/domains.ts:29-32 (handler)The handler function for the get-domain tool. Extracts the domain UUID from params, calls the OpenMetadata API endpoint GET /domains/{id} with optional query parameters.
export async function getDomain(params: z.infer<typeof getDomainSchema>) { const { id, ...query } = params; return omClient.get(`/domains/${id}`, query); } - src/tools/domains.ts:23-27 (schema)Zod schema for get-domain input validation. Requires 'id' (UUID string), optional 'fields' and 'include' parameters.
export const getDomainSchema = z.object({ id: z.string().describe("Domain UUID"), fields: z.string().optional().describe("Comma-separated fields to include"), include: z.enum(["non-deleted", "deleted", "all"]).optional(), }); - src/index.ts:337-337 (registration)Registers the get-domain tool with the MCP server. Associates the schema and handler, and applies category-based filtering (OM_TOOLS/OM_DISABLE) for the 'domains' category.
tool("get-domain", "Get domain details by UUID", getDomainSchema.shape, wrapToolHandler(getDomain)); - src/index.ts:159-164 (helper)The tool registration helper that wraps each MCP tool registration. It registers the tool in a registry (for category filtering) and conditionally binds it to the MCP server if the current category is enabled.
function tool(name: string, description: string, schema: any, handler: any): void { registry.register(name, description, currentCategory); if (registry.isEnabled(currentCategory)) { server.tool(name, description, schema, handler); } }