> ## Documentation Index
> Fetch the complete documentation index at: https://docs.botcadence.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Upload URLs

> Add knowledge-base sources from one or more page URLs

Adds URL sources to the project knowledge base and queues crawling/indexing. Returns `201 Created`.

## Authentication

<ParamField header="X-API-Key" type="string" required>
  Project API key for this organization and project. Format: `bot_live_…`
</ParamField>

## Path parameters

<ParamField path="organization_id" type="string" required>
  Organization ID. Must match the API key.
</ParamField>

<ParamField path="project_id" type="string" required>
  Project ID. Must match the API key.
</ParamField>

## Body

<ParamField body="urls" type="array" required>
  List of page URLs to ingest.
</ParamField>

<ParamField body="crawler" type="string" default="crawl4ai">
  Crawler engine: `crawl4ai` or `apify`.
</ParamField>

## Response

Success message confirming URLs were queued. `data` is typically `null`.

## Errors

<ResponseField name="401" type="Unauthorized">
  Missing, invalid, or revoked API key.
</ResponseField>

<ResponseField name="403" type="Forbidden">
  API key is not authorized, or link quota exceeded.
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST "https://backend.botcadence.com/organizations/ORG_ID/projects/PROJECT_ID/sources/urls" \
    -H "X-API-Key: bot_live_YOUR_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "urls": [
        "https://example.com/docs/getting-started",
        "https://example.com/docs/pricing"
      ],
      "crawler": "crawl4ai"
    }'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch(
    `https://backend.botcadence.com/organizations/${organizationId}/projects/${projectId}/sources/urls`,
    {
      method: "POST",
      headers: {
        "X-API-Key": process.env.BOTCADENCE_API_KEY,
        "Content-Type": "application/json",
      },
      body: JSON.stringify({
        urls: [
          "https://example.com/docs/getting-started",
          "https://example.com/docs/pricing",
        ],
        crawler: "crawl4ai",
      }),
    }
  );
  ```

  ```python Python theme={null}
  import os
  import requests

  response = requests.post(
      f"https://backend.botcadence.com/organizations/{organization_id}/projects/{project_id}/sources/urls",
      headers={
          "X-API-Key": os.environ["BOTCADENCE_API_KEY"],
          "Content-Type": "application/json",
      },
      json={
          "urls": [
              "https://example.com/docs/getting-started",
              "https://example.com/docs/pricing",
          ],
          "crawler": "crawl4ai",
      },
  )
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  {
    "status": "success",
    "message": "URLs added successfully",
    "data": null,
    "status_code": 201
  }
  ```
</ResponseExample>
