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

# Create a new project (requires write scope)

` POST /orgs/{orgId}/projects `

Create a new project (requires write scope)

## Servers

- ` https://api.rogeriq.com/api/v1 `

## Authentication

The operation accepts these alternatives. Schemes within one alternative are required together.

### Alternative 1

- ` apiKey `: ` apiKey `

  - Credential: ` X-API-Key ` in ` header `

  - API key with `riq_` prefix

## Parameters

### ` orgId ` (path, required)

- ` value `: type ` string `

## Request body (required)

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` name `

  - ` name `: type ` string `

    - maxLength: ` 100 `

  - ` slug `: type ` string `

    - pattern: ` "^[a-z0-9-]+$" `

  - ` domain `: type ` string `

    - maxLength: ` 255 `

## Responses

### ` 201 ` — Project created

Content type: ` application/json `

- ` value `: type ` object `

  - ` data `: type ` object `

    - ` id `: type ` string `

    - ` org_id `: type ` string `

    - ` name `: type ` string `

    - ` slug `: type ` string `

    - ` domain `: type ` string `; nullable

    - ` agent_mode `: type ` string `

      - enum: ` ["autopilot","copilot","assist"] `

    - ` ai_model `: type ` string `; nullable

    - ` created_at `: type ` string `; format ` date-time `

### ` 409 ` — Slug conflict

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` error `, ` code `

  - ` error `: type ` string ` — Human-readable message

  - ` code `: type ` string ` — Stable machine-readable code. Branch on this, not the message. Examples: BAD_REQUEST, UNAUTHORIZED, FORBIDDEN, CONFLICT, RATE_LIMITED, RESOURCE_NOT_FOUND.

  - ` request_id `: type ` string ` — Echoed in X-Request-Id header. Include when reporting issues.

  - ` retry_after `: type ` integer ` — Seconds until next attempt (429 only)

  - ` issues `: type ` array ` — Field-level validation errors (only present on 400 responses)

    - ` array item `: type ` object `

      - ` path `: type ` string `

      - ` message `: type ` string `

## Request examples

### cURL

```curl
curl -X POST 'https://api.rogeriq.com/api/v1/orgs/string/projects' \
  -H 'Authorization: Bearer YOUR_API_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "name": "string",
  "slug": "string",
  "domain": "string"
}'
```

### JavaScript

```javascript
const response = await fetch('https://api.rogeriq.com/api/v1/orgs/string/projects', {
  method: 'POST',
  headers: {
      "Authorization": "Bearer YOUR_API_TOKEN",
      "Content-Type": "application/json"
  },
  body: JSON.stringify({
    "name": "string",
    "slug": "string",
    "domain": "string"
  })
});

const data = await response.json();
console.log(data);
```

### Python

```python
import requests

headers = {
    'Authorization': 'Bearer YOUR_API_TOKEN'
}

response = requests.post('https://api.rogeriq.com/api/v1/orgs/string/projects', headers=headers, json={
  "name": "string",
  "slug": "string",
  "domain": "string"
})
print(response.json())
```