Skip to main content
Glama

ingestWebsite

Crawls and ingests website content recursively for knowledge base management, with configurable depth, path filtering, and chunking controls.

Instructions

Crawls and ingests content from a website recursively. Supports depth control and path filtering.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
namespaceIdNo
ingestConfigYes
tenantIdNo

Implementation Reference

  • src/index.ts:291-308 (registration)
    MCP tool registration for 'ingestWebsite' using server.tool, including inline handler that delegates to SourceSyncApiClient.ingestWebsite
    server.tool(
      'ingestWebsite',
      'Crawls and ingests content from a website recursively. Supports depth control and path filtering.',
      IngestWebsiteSchema.shape,
      async (params) => {
        return safeApiCall(async () => {
          const { namespaceId, ingestConfig, tenantId } = params
    
          // Create a client with the provided parameters
          const client = createClient({ namespaceId, tenantId })
    
          // Direct passthrough to the API
          return await client.ingestWebsite({
            ingestConfig,
          })
        })
      },
    )
  • Core handler logic in SourceSyncApiClient.ingestWebsite that sends POST request to SourceSync API /v1/ingest/website endpoint
    public async ingestWebsite({
      ingestConfig,
    }: Omit<
      SourceSyncIngestWebsiteRequest,
      'namespaceId'
    >): Promise<SourceSyncIngestResponse> {
      return this.client
        .url('/v1/ingest/website')
        .json({
          namespaceId: this.namespaceId,
          ingestConfig: {
            ...ingestConfig,
            chunkConfig: SourceSyncApiClient.CHUNK_CONFIG,
          },
        } satisfies SourceSyncIngestWebsiteRequest)
        .post()
        .json<SourceSyncIngestResponse>()
    }
  • Zod schema definition for ingestWebsite tool input validation (IngestWebsiteSchema)
    export const IngestWebsiteSchema = z.object({
      namespaceId: namespaceIdSchema.optional(),
      ingestConfig: z.object({
        source: z.literal(SourceSyncIngestionSource.WEBSITE),
        config: z.object({
          url: z.string(),
          maxDepth: z.number().optional(),
          maxLinks: z.number().optional(),
          includePaths: z.array(z.string()).optional(),
          excludePaths: z.array(z.string()).optional(),
          metadata: z.record(z.union([z.string(), z.array(z.string())])).optional(),
        }),
        chunkConfig: chunkConfigSchema.optional(),
      }),
      tenantId: tenantIdSchema,
    })
  • TypeScript type definition for the SourceSync API request (SourceSyncIngestWebsiteRequest) used by ingestWebsite
    export type SourceSyncIngestWebsiteRequest = {
      namespaceId: string
      ingestConfig: {
        source: SourceSyncIngestionSource.WEBSITE
        config: {
          url: string
          maxDepth?: number
          maxLinks?: number
          includePaths?: string[]
          excludePaths?: string[]
          scrapeOptions?: SourceSyncScrapeOptions
          metadata?: Record<string, any>
        }
        chunkConfig?: SourceSyncChunkConfig
      }
    }
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions 'crawls and ingests' (implying a write/mutation operation) and 'recursively' (suggesting traversal behavior), but lacks critical details: required permissions, rate limits, whether it's asynchronous (e.g., job-based), what 'ingests' entails (e.g., storing in a namespace), or error handling. This is inadequate for a complex ingestion tool.

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 highly concise and front-loaded: two sentences that directly state the core functionality and key features. Every word earns its place, with no redundancy or fluff. It efficiently communicates the essence without unnecessary elaboration.

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

Completeness2/5

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

Given the tool's complexity (recursive crawling, ingestion, multiple parameters), lack of annotations, and no output schema, the description is incomplete. It omits crucial context: what 'ingests' means operationally (e.g., where content goes), whether it's a long-running job, how to monitor progress (sibling 'getIngestJobRunStatus' hints at this), or what the return value is. This leaves significant gaps for an AI agent.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate for undocumented parameters. It only vaguely references 'depth control and path filtering,' which maps to 'maxDepth', 'includePaths', and 'excludePaths' in the schema, but ignores other key parameters like 'namespaceId', 'chunkConfig', 'tenantId', and 'metadata'. With 3 top-level parameters and nested objects, this leaves most semantics unexplained.

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: 'Crawls and ingests content from a website recursively.' It specifies the verb ('crawls and ingests'), resource ('content from a website'), and scope ('recursively'). However, it doesn't explicitly differentiate from sibling tools like 'ingestUrls' or 'fetchUrlContent', which prevents a perfect score.

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 minimal usage guidance. It mentions 'Supports depth control and path filtering,' which hints at when to use it for recursive crawling with filters, but offers no explicit when-to-use vs. alternatives like 'ingestUrls' (for specific URLs) or 'ingestSitemap' (for sitemap-based ingestion). No prerequisites or exclusions are stated.

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/sitegpt/sourcesyncai-mcp'

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