Skip to main content
Glama

getting_started

Access installation and setup instructions to begin using the Reacticx React Native library with project dependencies and component references.

Instructions

Get the Reacticx getting started guide with installation and setup instructions.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • src/index.ts:188-212 (registration)
    Tool registration for 'getting_started' - defines the tool name, description, no parameters, and the handler that calls fetchGettingStarted() to fetch and return documentation content.
    // Tool: Get getting started / installation guide
    server.tool(
      "getting_started",
      "Get the Reacticx getting started guide with installation and setup instructions.",
      {},
      async () => {
        try {
          const docs = await fetchGettingStarted();
          return {
            content: [{ type: "text" as const, text: docs }],
          };
        } catch (error) {
          const message =
            error instanceof Error ? error.message : String(error);
          return {
            content: [
              {
                type: "text" as const,
                text: `Error fetching getting started docs: ${message}\n\nBasic installation:\n\`\`\`bash\n# Add a component\nbunx --bun reacticx add <component-name>\n\n# Common dependencies\nnpm install react-native-reanimated @shopify/react-native-skia react-native-gesture-handler\n\`\`\`\n\nDocs: https://www.reacticx.com/docs`,
              },
            ],
          };
        }
      }
    );
  • The fetchGettingStarted function that implements the core logic - checks cache, fetches HTML from https://www.reacticx.com/docs, converts to markdown, caches the result, and returns formatted documentation.
    export async function fetchGettingStarted(): Promise<string> {
      const cached = cache.get("__getting_started__");
      if (cached && Date.now() - cached.timestamp < CACHE_TTL) {
        return cached.content;
      }
    
      try {
        const response = await fetch("https://www.reacticx.com/docs", {
          headers: {
            "User-Agent": "ReacticxMCP/1.0",
            Accept: "text/html",
          },
        });
    
        if (!response.ok) {
          throw new Error(`HTTP ${response.status}`);
        }
    
        const html = await response.text();
        const markdown = htmlToMarkdown(html);
    
        const content = [
          "# Reacticx - Getting Started",
          "Source: https://www.reacticx.com/docs",
          "",
          markdown,
        ].join("\n");
    
        cache.set("__getting_started__", { content, timestamp: Date.now() });
        return content;
      } catch (error) {
        const message =
          error instanceof Error ? error.message : String(error);
        throw new Error(`Failed to fetch getting started docs: ${message}`);
      }
    }
  • Helper function htmlToMarkdown that converts HTML content to markdown format by stripping tags, converting elements like headings, code blocks, links, lists, etc., and cleaning up whitespace.
    function htmlToMarkdown(html: string): string {
      let text = html;
    
      // Remove script and style tags with content
      text = text.replace(/<script[\s\S]*?<\/script>/gi, "");
      text = text.replace(/<style[\s\S]*?<\/style>/gi, "");
      text = text.replace(/<nav[\s\S]*?<\/nav>/gi, "");
      text = text.replace(/<footer[\s\S]*?<\/footer>/gi, "");
      text = text.replace(/<header[\s\S]*?<\/header>/gi, "");
    
      // Extract the main content area if possible
      const mainMatch = text.match(
        /<main[\s\S]*?>([\s\S]*?)<\/main>/i
      );
      const articleMatch = text.match(
        /<article[\s\S]*?>([\s\S]*?)<\/article>/i
      );
      if (articleMatch) {
        text = articleMatch[1];
      } else if (mainMatch) {
        text = mainMatch[1];
      }
    
      // Convert headings
      text = text.replace(/<h1[^>]*>([\s\S]*?)<\/h1>/gi, "\n# $1\n");
      text = text.replace(/<h2[^>]*>([\s\S]*?)<\/h2>/gi, "\n## $1\n");
      text = text.replace(/<h3[^>]*>([\s\S]*?)<\/h3>/gi, "\n### $1\n");
      text = text.replace(/<h4[^>]*>([\s\S]*?)<\/h4>/gi, "\n#### $1\n");
    
      // Convert code blocks - handle <pre><code> combinations
      text = text.replace(
        /<pre[^>]*>\s*<code[^>]*class="[^"]*language-(\w+)"[^>]*>([\s\S]*?)<\/code>\s*<\/pre>/gi,
        "\n```$1\n$2\n```\n"
      );
      text = text.replace(
        /<pre[^>]*>\s*<code[^>]*>([\s\S]*?)<\/code>\s*<\/pre>/gi,
        "\n```\n$1\n```\n"
      );
      text = text.replace(
        /<pre[^>]*>([\s\S]*?)<\/pre>/gi,
        "\n```\n$1\n```\n"
      );
    
      // Convert inline code
      text = text.replace(/<code[^>]*>([\s\S]*?)<\/code>/gi, "`$1`");
    
      // Convert bold and italic
      text = text.replace(/<(strong|b)[^>]*>([\s\S]*?)<\/\1>/gi, "**$2**");
      text = text.replace(/<(em|i)[^>]*>([\s\S]*?)<\/\1>/gi, "*$2*");
    
      // Convert links
      text = text.replace(
        /<a[^>]*href="([^"]*)"[^>]*>([\s\S]*?)<\/a>/gi,
        "[$2]($1)"
      );
    
      // Convert list items
      text = text.replace(/<li[^>]*>([\s\S]*?)<\/li>/gi, "- $1\n");
      text = text.replace(/<\/?[ou]l[^>]*>/gi, "\n");
    
      // Convert table elements
      text = text.replace(/<tr[^>]*>([\s\S]*?)<\/tr>/gi, "$1|\n");
      text = text.replace(/<th[^>]*>([\s\S]*?)<\/th>/gi, "| $1 ");
      text = text.replace(/<td[^>]*>([\s\S]*?)<\/td>/gi, "| $1 ");
      text = text.replace(/<\/?table[^>]*>/gi, "\n");
      text = text.replace(/<\/?thead[^>]*>/gi, "");
      text = text.replace(/<\/?tbody[^>]*>/gi, "");
    
      // Convert paragraphs and breaks
      text = text.replace(/<p[^>]*>([\s\S]*?)<\/p>/gi, "\n$1\n");
      text = text.replace(/<br\s*\/?>/gi, "\n");
      text = text.replace(/<hr\s*\/?>/gi, "\n---\n");
    
      // Convert divs to newlines
      text = text.replace(/<div[^>]*>/gi, "\n");
      text = text.replace(/<\/div>/gi, "\n");
    
      // Remove remaining HTML tags
      text = text.replace(/<[^>]+>/g, "");
    
      // Decode HTML entities
      text = text.replace(/&/g, "&");
      text = text.replace(/</g, "<");
      text = text.replace(/>/g, ">");
      text = text.replace(/"/g, '"');
      text = text.replace(/'/g, "'");
      text = text.replace(/ /g, " ");
      text = text.replace(/&#(\d+);/g, (_, code) =>
        String.fromCharCode(parseInt(code))
      );
    
      // Clean up whitespace
      text = text.replace(/\n{3,}/g, "\n\n");
      text = text.trim();
    
      return text;
    }
Behavior2/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 of behavioral disclosure. It describes a read operation ('Get'), implying it's likely safe and non-destructive, but doesn't specify aspects like authentication requirements, rate limits, or response format. For a tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

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

Conciseness5/5

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

The description is a single, efficient sentence: 'Get the Reacticx getting started guide with installation and setup instructions.' It's front-loaded with the core action and resource, with no wasted words, making it highly concise and well-structured for quick comprehension.

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

Completeness3/5

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

Given the tool's simplicity (0 parameters, no output schema, no annotations), the description is adequate but minimal. It explains what the tool does but lacks details on behavioral traits or usage context. For a straightforward read tool, it meets basic needs but could be more informative to compensate for the absence of annotations.

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 tool has 0 parameters, and schema description coverage is 100%, so there's no need for parameter details in the description. The description appropriately focuses on the tool's purpose without redundant parameter information, earning a baseline score of 4 for zero-parameter tools.

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

Purpose4/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: 'Get the Reacticx getting started guide with installation and setup instructions.' It specifies the verb ('Get') and resource ('Reacticx getting started guide'), making the action and target explicit. However, it doesn't distinguish this from sibling tools like 'get_component_docs' or 'get_dependencies', which limits differentiation.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools or contexts where this is preferred, such as for initial setup versus detailed documentation. Without such guidance, users must infer usage from the tool name and description alone.

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/igorfelipeduca/reacticx-mcp'

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