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

# Update Sector

> Updates the data of a specific sector.

## Endpoint

`PUT https://gateway.orkeia.ai/sectors/{id}`

**Authentication**\
Requires header `authorization:  <your_token>`.

## Path Parameters

| Name | Type   | Required | Description                      | Example       |
| ---- | ------ | -------- | -------------------------------- | ------------- |
| id   | string | Yes      | Unique identifier of the sector. | SECTOR\_12345 |

## Request Body (JSON)

> The service receives a **wrapper** with the property `sector`. (The `environment` is handled on the server.)

```json theme={null}
{
  "sector": {
    "name": "Updated Sector",
    "description": "New description"
  }
}
```

## Example (cURL)

```bash theme={null}
curl -X PUT "https://gateway.orkeia.ai/sectors/SECTOR_12345" \
  -H "authorization:  <your_token>" \
  -H "Content-Type: application/json" \
  -d '{
    "sector": {
      "name": "Updated Sector",
      "description": "New description"
    }
  }'
```

## Responses

### Response - Success

```json response theme={null}
{
  "status": "OK",
  "data": {
    "id": "SECTOR_12345",
    "name": "Updated Sector",
    "description": "New description"
  }
}
```

### 500 — Server Error

```json theme={null}
{
  "status": "ERROR",
  "code": "server/error",
  "data": null
}
```

### 400 — Client Error

```json theme={null}
{
  "status": "ERROR",
  "code": "client/error",
  "data": null
}
```
