Skip to main content
Glama

anytype_get_object

Retrieve a specific object by its ID using the Anytype MCP Server. Input the space ID and object ID to access detailed object information.

Instructions

Obtiene un objeto específico por su ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
object_idYesID del objeto
space_idYesID del espacio

Implementation Reference

  • The main handler function `handleGetObject` that implements the core logic for the `anytype_get_object` tool by making an API request to retrieve the object details from Anytype.
    /** * Get a specific object */ export async function handleGetObject(args: any) { const { space_id, object_id } = args; const response = await makeRequest(`/v1/spaces/${space_id}/objects/${object_id}`); return { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] }; }
  • Defines the input schema, description, and name for the `anytype_get_object` tool, including required parameters `space_id` and `object_id`.
    { name: 'anytype_get_object', description: 'Obtiene un objeto específico por su ID', inputSchema: { type: 'object', properties: { space_id: { type: 'string', description: 'ID del espacio' }, object_id: { type: 'string', description: 'ID del objeto' }, }, required: ['space_id', 'object_id'], }, },
  • src/index.ts:126-127 (registration)
    Registers the tool handler in the MCP server's request handler switch statement, dispatching `anytype_get_object` calls to `handleGetObject`.
    case 'anytype_get_object': return await handleGetObject(args);
  • src/index.ts:85-93 (registration)
    Combines all tool definitions including `objectTools` (which contains `anytype_get_object`) into the tools list provided to the MCP ListToolsRequestHandler.
    const tools = [ ...spaceTools, ...objectTools, ...propertyTools, ...typeTools, ...tagTools, ...templateTools, ...listTools, ];
  • src/index.ts:16-16 (registration)
    Imports the `objectTools` array from tools/objects.ts, which includes the `anytype_get_object` tool definition.
    import { objectTools } from './tools/objects.js';

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/cryptonahue/mcp-anytype'

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