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

# Ingestion

> Getting data into Persona

Base URL: `http://localhost:8000/api/v1`

## Ingest Content

```http theme={null}
POST /users/{user_id}/ingest
Content-Type: application/json

{
    "content": "Had a great meeting with Sarah about the Q4 roadmap...",
    "source_type": "conversation"
}
```

**Response:**

```json theme={null}
{
    "message": "Content ingested successfully",
    "memories_created": 3
}
```

## Batch Ingest

For importing historical data or bulk processing:

```http theme={null}
POST /users/{user_id}/ingest/batch
Content-Type: application/json

{
    "items": [
        {"content": "First entry...", "source_type": "notes"},
        {"content": "Second entry...", "source_type": "conversation"}
    ]
}
```

## Source Types

The `source_type` field hints at the content origin:

| Type           | Use Case                    |
| -------------- | --------------------------- |
| `conversation` | Chat transcripts, dialogues |
| `notes`        | Personal notes, journals    |
| `email`        | Email content               |
| `social`       | Social media posts          |

The type is a hint for extraction context. The system works regardless of value.

## User Management

### Create User

```http theme={null}
POST /users/{user_id}

Response: 201 Created
{"message": "User {user_id} created successfully"}
```

### Delete User

```http theme={null}
DELETE /users/{user_id}

Response: 200 OK
{"message": "User {user_id} deleted successfully"}
```
