# `add_content_source`

_Content & calendar_

`write` `idempotent` `30/day`

Attach an article URL, raw text (200, 150000 characters), or uploaded PDF and start AI extraction in the background. Maximum 5 sources including 3 PDFs per card. Poll get_content_source; generate_scripts uses the extracted source. Reattaching the same source returns its existing ID. PDF URLs must be downloaded by the agent and uploaded first.

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `brandId` | `string` | no |  |
| `contentId` | `string` | yes |  |
| `source` | `object \| object \| object` | yes | Choose a source shape: {"kind":"url","url":"https://..."}, {"kind":"text","title":"Interview","text":"..."}, or {"kind":"pdf","pdfPath":"path from create_content_source_upload","fileName":"report.pdf"}. |

## Example

### Prompt

```text
Ground this script in my article.
```

### JSON-RPC

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "add_content_source",
    "arguments": {
      "contentId": "3f6c2a4e-8b1d-4c7a-9e2f-5a1b0c9d8e7f",
      "source": {
        "kind": "url",
        "url": "https://example.com/research/article"
      }
    }
  }
}
```

### curl

```bash
curl -X POST https://app.usedalea.ai/api/mcp/mcp \
  -H "Authorization: Bearer dalea_mcp_..." \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"add_content_source","arguments":{"contentId":"3f6c2a4e-8b1d-4c7a-9e2f-5a1b0c9d8e7f","source":{"kind":"url","url":"https://example.com/research/article"}}}}'
```
