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

> ## Agent Instructions
> Start with /introduction/getting-started. Use the Direct Query API (POST /api/lens/query) with the Newton Fusion model (text, image, and video reasoning) or the Newton Omega encoder (time-series embeddings). ATAI_API_ENDPOINT is the base URL https://platform.u1.archetypeai.app with no version path; every endpoint path begins with /api. Pages whose descriptions are marked (Archived) document the legacy Lens runtime — do not use them for new projects.

# Update Project

> Change a project's name or description

Requires [version 2.0.0](https://docs.archetypeai.app/release-notes/2.0.x.md#v2-0-0) or later of the Archetype platform.

## Overview

This endpoint changes a project's name, its description, or both. Fields you leave out keep their
value, and a body with only the project ID specified changes nothing.

## Request

**project\_id** `string` *required*

Project `prj_` ID.

**name** `string`

New display name, under the same rules as at creation: at most 128 characters once leading and
trailing whitespace is dropped, not blank, and different, ignoring case, from the names of the
creator's other projects.

**description** `string`

New description, at most 512 characters. An empty string clears it.

## Response

Returns `200 OK` with the updated project.

**id** `string` *required*

The project's `prj_` id.

**name** `string` *required*

Display name.

**description** `string` *required*

Description; empty when none was given.

**created\_by** `string` *required*

Who created the project: a user's `usr_` id, or the `key_` id of the service-account API key it
was created with. Never changes.

**created\_at** `string` *required*

When the project was created (date-time).

**updated\_at** `string` *required*

When the project's name or description last changed (date-time); its creation time until then.

```bash cURL theme={"system"}
curl -X PATCH "$ATAI_API_URL/api/projects/prj_01jcd4m8t2vq6xn3r7k5hbzw9e" \
  -H "Authorization: Bearer $ATAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name": "Line 3 and 4 pump monitoring"}'
```

```python Python theme={"system"}
import os
import requests

base_url = os.environ["ATAI_API_URL"]
api_key = os.environ["ATAI_API_KEY"]

response = requests.patch(
    f"{base_url}/api/projects/prj_01jcd4m8t2vq6xn3r7k5hbzw9e",
    headers={"Authorization": f"Bearer {api_key}"},
    json={"name": "Line 3 and 4 pump monitoring"},
)

if response.status_code == 200:
    project = response.json()
    print(f"Renamed to {project['name']}")
else:
    print(f"Error: {response.json()['errors']}")
```

```javascript JavaScript theme={"system"}
const response = await fetch(
  `${process.env.ATAI_API_URL}/api/projects/prj_01jcd4m8t2vq6xn3r7k5hbzw9e`,
  {
    method: 'PATCH',
    headers: {
      'Authorization': `Bearer ${process.env.ATAI_API_KEY}`,
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({ name: 'Line 3 and 4 pump monitoring' })
  }
);

const body = await response.json();

if (response.ok) {
  console.log(`Renamed to ${body.name}`);
} else {
  console.error('Error:', body.errors);
}
```

```json 200 - Success theme={"system"}
{
  "id": "prj_01jcd4m8t2vq6xn3r7k5hbzw9e",
  "name": "Line 3 and 4 pump monitoring",
  "description": "Rare-event detection for the line 3 pumps.",
  "created_by": "usr_01jc7x2n5k8vq3m6t9r4hdzb1s",
  "created_at": "2026-10-28T09:12:44Z",
  "updated_at": "2026-10-29T15:03:10Z"
}
```

```json 400 - Invalid name or description theme={"system"}
{
  "errors": [
    {
      "code": "<error_code>",
      "message": "Invalid name or description.",
      "suggestion": null,
      "error_uid": "err-xxxxxxxx"
    }
  ]
}
```

```json 403 - The caller is read-only theme={"system"}
{
  "errors": [
    {
      "code": "<error_code>",
      "message": "The caller is read-only.",
      "suggestion": null,
      "error_uid": "err-xxxxxxxx"
    }
  ]
}
```

```json 404 - Project not found theme={"system"}
{
  "errors": [
    {
      "code": "<error_code>",
      "message": "Project not found.",
      "suggestion": null,
      "error_uid": "err-xxxxxxxx"
    }
  ]
}
```

```json 409 - A project of that name already exists theme={"system"}
{
  "errors": [
    {
      "code": "<error_code>",
      "message": "A project of that name already exists.",
      "suggestion": null,
      "error_uid": "err-xxxxxxxx"
    }
  ]
}
```

## Important Notes

> [!NOTE]
>
> * `400` means `name` is blank or too long, or `description` is too long.
> * `403` means the caller has the read-only `viewer` role.
> * `404` means the project does not exist or is not visible to you.
> * `409` means the project's creator already has another project of the new name, ignoring case.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.