Skip to main content
Glama
riker-t

Ramp Developer MCP Server

by riker-t

search_documentation

Search Ramp API documentation using natural language queries to find relevant guides, authentication methods, implementation examples, and troubleshooting solutions for developers building integrations.

Instructions

šŸ” SMART DOCUMENTATION SEARCH - Finds the most relevant Ramp API documentation for your query.

What this does: • šŸŽÆ Detects your intent from natural language queries • šŸ“š Searches through all Ramp documentation and guides • 🧠 Reasons about which content is most relevant • šŸ“‹ Returns clean, actionable markdown chunks

Perfect for: • Getting started with authentication • Understanding specific API workflows • Finding implementation examples • Troubleshooting integration issues

Usage: Just describe what you're trying to do naturally. Examples: "building an integration", "setting up OAuth", "bill payment workflow", "webhook events"

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesYour question or what you're trying to accomplish. Use natural language - e.g., 'building an integration', 'OAuth setup', 'bill payments'

Implementation Reference

  • The main handler function that executes the search_documentation tool logic: processes the query, detects intent, finds relevant guides, extracts content, and returns formatted TextContent.
    async def execute(self, arguments: Dict[str, Any]) -> List[TextContent]:
        """Search documentation and return most relevant content"""
        query = arguments.get("query", "").strip()
        
        if not query:
            return [TextContent(
                type="text",
                text="āŒ Please provide a search query describing what you're looking for."
            )]
        
        try:
            # Step 1: Detect intent from user query
            detected_cluster = self.knowledge_base.detect_intent(query)
            
            # Step 2: Find and rank relevant documentation files
            relevant_guides = self._find_relevant_guides(query, detected_cluster)
            
            if not relevant_guides:
                return [TextContent(
                    type="text",
                    text=f"ā„¹ļø No specific documentation found for '{query}'. Try more specific keywords like 'authentication', 'bill payments', 'webhooks', or 'card management'."
                )]
            
            # Step 3: Extract and return the most relevant content
            content = self._extract_relevant_content(relevant_guides[0], query, detected_cluster)
            
            return [TextContent(type="text", text=content)]
            
        except Exception as e:
            return [TextContent(
                type="text",
                text=f"āŒ Error searching documentation: {str(e)}"
            )]
  • Defines the input schema for the tool, requiring a 'query' string parameter.
    def input_schema(self) -> Dict[str, Any]:
        return {
            "type": "object",
            "properties": {
                "query": {
                    "type": "string",
                    "description": "Your question or what you're trying to accomplish. Use natural language - e.g., 'building an integration', 'OAuth setup', 'bill payments'"
                }
            },
            "required": ["query"]
        }
  • src/server.py:46-51 (registration)
    Registers the SearchDocumentationTool by instantiating it with the knowledge_base and adding to the server's tools list.
    tools = [
        PingTool(),
        SearchDocumentationTool(knowledge_base),
        SubmitFeedbackTool(),
        GetEndpointSchemaTool(knowledge_base)
    ]
  • Defines the tool name as 'search_documentation' used for registration and invocation.
    def name(self) -> str:
        return "search_documentation"
  • Helper method to find and rank relevant documentation guides based on query and detected intent cluster.
    def _find_relevant_guides(self, query: str, detected_cluster: str) -> List[Dict[str, Any]]:
        """Find and rank relevant documentation files"""
        relevant_guides = []
        
        # If we detected a cluster, prioritize its guides
        if detected_cluster and detected_cluster in self.knowledge_base.use_case_clusters:
            cluster_data = self.knowledge_base.use_case_clusters[detected_cluster]
            guide_filenames = cluster_data.get("guides", [])
            
            for guide_filename in guide_filenames:
                guide_content = self.knowledge_base._find_guide_by_filename(guide_filename)
                if guide_content:
                    relevance_score = self._calculate_relevance(query, guide_content, guide_filename)
                    relevant_guides.append({
                        'filename': guide_filename,
                        'content': guide_content,
                        'cluster': detected_cluster,
                        'score': relevance_score
                    })
        
        # Also search all guides for keyword matches
        query_keywords = query.lower().split()
        
        for guide_path, guide_obj in self.knowledge_base.guides.items():
            if not any(guide['filename'] in guide_path for guide in relevant_guides):
                relevance_score = self._calculate_relevance(query, guide_obj.content, guide_path)
                if relevance_score > 0.1:  # Only include if somewhat relevant
                    relevant_guides.append({
                        'filename': str(guide_path),
                        'content': guide_obj.content,
                        'cluster': 'general',
                        'score': relevance_score
                    })
        
        # Sort by relevance score (highest first)
        relevant_guides.sort(key=lambda x: x['score'], reverse=True)
        
        return relevant_guides
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It discloses key behavioral traits: it processes natural language queries, searches documentation, reasons about relevance, and returns markdown chunks. However, it lacks details on limitations (e.g., search scope, accuracy, rate limits) or output specifics (e.g., format details, error handling). For a tool with no annotations, this is adequate but not comprehensive.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is appropriately sized and front-loaded with a clear purpose statement. Sections like 'What this does' and 'Perfect for' are well-structured, but some elements (e.g., emojis, bullet points) add minor visual clutter without essential information. Overall, it's efficient with minimal waste, though it could be slightly more streamlined.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (natural language search with reasoning) and lack of annotations/output schema, the description is reasonably complete. It covers purpose, usage, parameters, and behavioral aspects. However, it could improve by addressing potential limitations or output details more explicitly, which would enhance completeness for a tool with no structured support.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, with the query parameter well-documented. The description adds value by elaborating on the parameter's semantics: it emphasizes natural language usage, provides intent detection context, and gives concrete examples ('building an integration', 'OAuth setup'). This goes beyond the schema's basic description, though it doesn't introduce new parameter details.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose with specific verbs ('finds', 'searches', 'detects', 'reasons about') and resources ('Ramp API documentation', 'documentation and guides'). It distinguishes itself from sibling tools like get_endpoint_schema (which likely retrieves schema details) and ping/submit_feedback (which are unrelated to documentation search). The title 'SMART DOCUMENTATION SEARCH' reinforces this specificity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit guidance on when to use this tool through the 'Perfect for' section, listing specific scenarios like authentication, API workflows, examples, and troubleshooting. It also distinguishes usage from alternatives by implying this is for natural language queries about documentation, unlike get_endpoint_schema which might handle structured schema retrieval. The 'Usage' section reinforces this with examples.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/riker-t/ramp-dev-mcp'

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