Skip to content
Smartlife Docs
FR
Stored only in this browser (never sent to this server) and reused on every “Test this endpoint” page below.
Scopes granted to this token (see the response received during authentication):
The “Test” buttons below stay disabled until the scope required by the endpoint is ticked here.

PATCH /api/project/{project_id}/state

Required scope: project:write.

PATCH /api/project/{id}/state request with its JSON body and the response
Request and response of the project/{id}/state write endpoint.

The only write endpoint of this API

All the other documented endpoints are read-only. This one really changes the status of the targeted project — use it with a token that has been explicitly granted the project:write scope.

Request body (JSON):
{
  "status": "en_cours"
}
status must be one of these values: en_cours (in progress), termine (completed), suspendu (suspended) or archive (archived). Any other value returns 422.
curl -X PATCH https://construction.my-smartlife.fr/api/project/12/state \
  -H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"status": "termine"}'
Example response:
{
  "project_id": "12",
  "status": { "label": "termine", "legacy_value": 100 }
}

Test this endpoint

This call really changes the targeted project. You will be asked to confirm before it is sent.



Link copied!