> For the complete documentation index, see [llms.txt](https://docs.autocontentapi.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.autocontentapi.com/quick-start/tools/create-project.md).

# Create a Project (Brand Assets)

Projects let you save a reusable **brand package** (description, logo, and optional colors) and apply it to future outputs by passing the project ID in the `projects` array.

## Before You Begin

* Have your API token ready (`Authorization: Bearer ...`).
* Prepare a project **name** and either a **description** or a **website URL**.
* (Optional) Prepare a logo image as either a public URL (PNG/JPG) or a base64-encoded PNG/JPG.
* (Optional) Pick brand colors as hex values like `#111827`.

## Step 1: Create the Project

Create a project by calling `POST /projects`.

```bash
curl -X POST "https://api.autocontentapi.com/projects" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "AI Startup Launch",
    "description": "Brand kit and positioning for our launch assets.",
    "imageUrl": "https://cdn.example.com/brand/logo.png",
    "textColor": "#111827",
    "backgroundColor": "#F9FAFB",
    "brandColor": "#4338CA",
    "accentColor": "#7C72EF"
  }'
```

The response includes the full project record, including its `id`:

```json
{
  "success": true,
  "project": {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "name": "AI Startup Launch",
    "description": "Brand kit and positioning for our launch assets.",
    "imageUrl": "https://autocontentapi.com/uploads/projects/123e.../logo-200x50.png",
    "brandColor": "#4338CA",
    "accentColor": "#7C72EF",
    "createdOn": "2024-01-01T12:00:00Z",
    "updatedOn": "2024-01-02T14:30:00Z",
    "active": true
  }
}
```

## Step 2: Request Parameters (All Fields)

The request body follows `CreateProjectRequest`:

| Field             | Required | Type   | Notes                                                                                                                                                                               |
| ----------------- | -------- | ------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `name`            | ✅        | string | Project name (max 200 characters).                                                                                                                                                  |
| `description`     | ✅\*      | string | Human-written project description. Markdown is supported. Either `description` or `url` must be provided.                                                                           |
| `url`             | ✅\*      | string | Website URL for the project. If you provide `url` without `description`, the API fetches the site and generates a description automatically.                                        |
| `imageData`       | Optional | string | Base64-encoded PNG/JPG for the brand image. Any dimensions accepted; the API resizes it to **200x50** and stores the hosted copy as `imageUrl`. Cannot be combined with `imageUrl`. |
| `imageUrl`        | Optional | string | Public HTTP/HTTPS URL to a PNG/JPG brand image. The API downloads it, resizes to **200x50**, and hosts the optimized copy. Cannot be combined with `imageData`.                     |
| `textColor`       | Optional | string | Hex color `#RRGGBB` used for branded text when applicable.                                                                                                                          |
| `backgroundColor` | Optional | string | Hex color `#RRGGBB` used for branded backgrounds when applicable.                                                                                                                   |
| `brandColor`      | Optional | string | Hex color `#RRGGBB` used as the primary branding accent in supported outputs.                                                                                                       |
| `accentColor`     | Optional | string | Hex color `#RRGGBB` used as the secondary accent in supported outputs.                                                                                                              |

\* Either `description` or `url` is required.

### Uploading a logo via `imageData`

If you prefer to avoid hosting a logo yourself, send it as base64:

```bash
curl -X POST "https://api.autocontentapi.com/projects" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "AI Startup Launch",
    "description": "Brand kit and positioning for our launch assets.",
    "imageData": "iVBORw0KGgoAAAANSUhEUgAA..."
  }'
```

## Step 3: Use the Project ID in Content Generation

Once created, apply the saved brand assets by including the project ID in `projects` when calling `/content/Create`:

```bash
curl -X POST "https://api.autocontentapi.com/content/Create" \
  -H "Authorization: Bearer YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "outputType": "video",
    "projects": ["123e4567-e89b-12d3-a456-426614174000"],
    "resources": [{ "type": "text", "content": "Announce our product launch." }],
    "text": "Keep this under 90 seconds with a clear CTA."
  }'
```

Examples:

* Explainer videos: [Apply Brand Logo with `projectId`](/quick-start/explainer-videos/brand-with-project-id.md)
* Infographics: [Apply Brand Settings with `projectId`](/quick-start/infographics/brand-with-project-id.md)
* Slide decks: [Apply Brand Logo with `projectId`](/quick-start/slide-decks/brand-with-project-id.md)

## Related Endpoints

* `POST /projects` – Create a project and store brand assets.
* `GET /projects` – List your active projects.
* `GET /projects/{id}` – Fetch a project by ID.
* `POST /projects/{id}/update` – Update a project (including swapping/removing image and colors).
* `POST /projects/{id}/delete` – Soft-delete a project (marks it inactive).

## What's Next?

* Apply branding to a video via [Apply Brand Logo with `projectId`](/quick-start/explainer-videos/brand-with-project-id.md).
* Generate a branded one-pager via [Infographic Scenario Examples](/quick-start/infographics/infographic-examples.md).
* Build a branded deck via [Slide Deck Scenario Examples](/quick-start/slide-decks/slide-deck-examples.md).
