Skip to main content
Glama

search_in_project

Search within a Document360 project version to find relevant articles and categories using the project version ID.

Instructions

Search inside a project version and return related articles/categories in Document360

Args: project_version_id: The project version ID

Returns: List of hits (articles/categories) from the project version search endpoint

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_version_idYes

Implementation Reference

  • Core handler function that executes the tool logic: searches the project version using the Document360 client, extracts hits, and returns them with success flag.
    async def search_in_project(project_version_id: str, ctx: Context) -> Dict[str, Any]: """Search inside a project version and return hits Args: project_version_id: Document360 project version ID (UUID string) ctx: MCP context for logging and error handling Returns: The raw response from /v2/ProjectVersions/{projectVersionId}/{langCode}, typically contains 'data.hits' """ try: await ctx.info(f"Searching in project version: {project_version_id}") result = await client.search_project_version(project_version_id) hits = result.get('data', {}).get('hits', []) await ctx.info(f"Found {len(hits)} hits in project version {project_version_id}") return {'data': hits, 'success': True} except Document360APIError as e: await ctx.error(f"Document360 API error during project search: {e.message}") raise e except Exception as e: await ctx.error(f"Unexpected error during project search: {str(e)}") raise e
  • server.py:74-88 (registration)
    Registers the MCP tool 'search_in_project' with FastMCP using @mcp.tool decorator, defines input schema via pydantic Annotated and Field, and delegates to the core handler in tools.py.
    @mcp.tool async def search_in_project( project_version_id: Annotated[str, Field(description="Document360 project version ID (UUID string)")], ctx: Context ) -> dict: """Search inside a project version and return related articles/categories in Document360 Args: project_version_id: Document360 project version ID (UUID string) ctx: MCP context for logging and error handling Returns: List of hits (articles/categories) from the project version search endpoint """ return await tools.search_in_project(project_version_id, ctx)

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/druellan/document360-mcp'

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