# Update a project

Canonical page: https://docs.ovok.com/api/slim/project/update-a-project

`PUT /v1/slim/project/{id}`

Updates a project's name, address, contact and settings, and returns the updated project. Use it to edit your project or one of its child projects.

**Auth:** Bearer token of a project admin (`ProjectMembership.admin`).
**Scope:** The project in the path. It must be the caller's project (from the token) or a direct child of it.

## Behaviour

- Sets the project `name` and replaces the organization stored inside the project with one built from `name`, `address`, `contact` and `settings`. This is a full replace, not a merge:
  - an omitted `address` or `contact` clears it;
  - an omitted `settings.timeZone` resets the time zone to `Europe/Berlin`;
  - an omitted `settings.trendsPeriod` removes the stored trends period, so reads fall back to the default.
- `id` and `extension` in the body are ignored. The project comes from the path.
- `settings.trendsPeriod.start` must be `HH:MM:SS`.
- The response has the shape of `GET /v1/slim/project/{id}`.


## Example

```bash
curl -X PUT 'https://api.sandbox.ovok.com/v1/slim/project/c3499c27-2973-0a7f-807e-fb8676a92dcb' \
  -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE3NjcyNjg4MDAsImV4cCI6MTc2NzI3MjQwMH0.Ql3B_ztDvctlyZ2z0vp4sl3ExXRQGkzmxdmTAqxNzZk' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "My Medical Project",
    "address": [{ "line": ["Hauptstrasse 1"], "city": "Berlin", "postalCode": "10115", "country": "DE" }],
    "settings": { "timeZone": "Europe/Berlin", "trendsPeriod": { "start": "09:00:00", "durationSeconds": 86400 } }
  }'
```
