> Source: https://developers.terrawallet.us/docs/reference/projects . Terra Wallet developer docs (early access).

<!-- GENERATED by apps/mcp/scripts/build-docs-index.mjs. Do not edit by hand. -->

# Projects and allowed origins

> **Preview.** Generated from `docs/developers/openapi-v1.json` (the exported OpenAPI document, authoritative) and, for operations it does not contain yet, from the v1 build contract (`docs/platform/V1_CONTRACT.md`). Each contract-only operation is marked.

A project groups keys and settings inside an organization. Allowed origins lock publishable keys to your own https sites.

**Authentication:** Dashboard session with the X-Terra-Org header.

**Guide:** [Authentication](https://developers.terrawallet.us/docs/authentication.md)

| Method | Path | Summary |
|---|---|---|
| GET | `/v1/projects` | Projects of the organization |
| POST | `/v1/projects` | Create a project (owner, admin, developer) |
| GET | `/v1/projects/{id}` | One project |
| PATCH | `/v1/projects/{id}` | Rename a project (owner, admin, developer) |
| GET | `/v1/projects/{id}/origins` | Allowed origins for publishable keys |
| PUT | `/v1/projects/{id}/origins` | Replace the allowed origins (exact https origins, at most 20) |

## GET /v1/projects

Projects of the organization

- Operation id: `PlatformProjectsController_list` (contract name: `listProjects`)
- Authentication: Secret key or dashboard session

### Headers

| Name | Type | Required | Notes |
|---|---|---|---|
| `X-Terra-Org` | string | no | Dashboard sessions: the organization to act for (org_...). API keys carry their own. |

### Query parameters

| Name | Type | Required | Notes |
|---|---|---|---|
| `limit` | integer | no |  |
| `starting_after` | string | no |  |

### Response

Status 200.

| Name | Type | Required | Notes |
|---|---|---|---|
| `data` | array of object | yes |  |
| `has_more` | boolean | yes |  |
| `next_cursor` | string | yes |  |

## POST /v1/projects

Create a project (owner, admin, developer)

- Operation id: `PlatformProjectsController_create` (contract name: `createProject`)
- Authentication: Dashboard session
- `Idempotency-Key`: required

### Headers

| Name | Type | Required | Notes |
|---|---|---|---|
| `X-Terra-Org` | string | no | Dashboard sessions: the organization to act for (org_...). API keys carry their own. |
| `Idempotency-Key` | string | yes | 8 to 128 characters, kept 24 hours. |

### Request body

| Name | Type | Required | Notes |
|---|---|---|---|
| `name` | string | yes | length 1 to 80 |

### Response

Status 201.

| Name | Type | Required | Notes |
|---|---|---|---|
| `id` | string | yes |  |
| `object` | string (project) | yes |  |
| `name` | string | yes |  |
| `created_at` | string (date-time) | yes |  |
| `updated_at` | string (date-time) | yes |  |

### Notes

- The request body is not spelled out in the contract yet; the OpenAPI document will define it.

## GET /v1/projects/{id}

One project

- Operation id: `PlatformProjectsController_get` (contract name: `getProject`)
- Authentication: Secret key or dashboard session

### Headers

| Name | Type | Required | Notes |
|---|---|---|---|
| `X-Terra-Org` | string | no | Dashboard sessions: the organization to act for (org_...). API keys carry their own. |

### Path parameters

| Name | Type | Required | Notes |
|---|---|---|---|
| `id` | string | yes | proj_... |

### Response

Status 200.

| Name | Type | Required | Notes |
|---|---|---|---|
| `id` | string | yes |  |
| `object` | string (project) | yes |  |
| `name` | string | yes |  |
| `created_at` | string (date-time) | yes |  |
| `updated_at` | string (date-time) | yes |  |

## PATCH /v1/projects/{id}

Rename a project (owner, admin, developer)

- Operation id: `PlatformProjectsController_update` (contract name: `updateProject`)
- Authentication: Dashboard session

### Headers

| Name | Type | Required | Notes |
|---|---|---|---|
| `X-Terra-Org` | string | no | Dashboard sessions: the organization to act for (org_...). API keys carry their own. |

### Path parameters

| Name | Type | Required | Notes |
|---|---|---|---|
| `id` | string | yes | proj_... |

### Request body

| Name | Type | Required | Notes |
|---|---|---|---|
| `name` | string | yes | length 1 to 80 |

### Response

Status 200.

| Name | Type | Required | Notes |
|---|---|---|---|
| `id` | string | yes |  |
| `object` | string (project) | yes |  |
| `name` | string | yes |  |
| `created_at` | string (date-time) | yes |  |
| `updated_at` | string (date-time) | yes |  |

## GET /v1/projects/{id}/origins

Allowed origins for publishable keys

- Operation id: `PlatformProjectsController_origins` (contract name: `getAllowedOrigins`)
- Authentication: Secret key or dashboard session

### Headers

| Name | Type | Required | Notes |
|---|---|---|---|
| `X-Terra-Org` | string | no | Dashboard sessions: the organization to act for (org_...). API keys carry their own. |

### Path parameters

| Name | Type | Required | Notes |
|---|---|---|---|
| `id` | string | yes | proj_... |

### Response

Status 200.

| Name | Type | Required | Notes |
|---|---|---|---|
| `object` | string (allowed_origins) | yes |  |
| `project_id` | string | yes |  |
| `origins` | array of string | yes |  |

## PUT /v1/projects/{id}/origins

Replace the allowed origins (exact https origins, at most 20)

- Operation id: `PlatformProjectsController_putOrigins` (contract name: `setAllowedOrigins`)
- Authentication: Dashboard session

### Headers

| Name | Type | Required | Notes |
|---|---|---|---|
| `X-Terra-Org` | string | no | Dashboard sessions: the organization to act for (org_...). API keys carry their own. |

### Path parameters

| Name | Type | Required | Notes |
|---|---|---|---|
| `id` | string | yes | proj_... |

### Request body

| Name | Type | Required | Notes |
|---|---|---|---|
| `origins` | array of string | yes |  |

### Response

Status 200.

| Name | Type | Required | Notes |
|---|---|---|---|
| `object` | string (allowed_origins) | yes |  |
| `project_id` | string | yes |  |
| `origins` | array of string | yes |  |

### Notes

- Exact https origins only, for example https://shop.example.com. No wildcards and no paths.
