API referenceEndpoints
Correct a commercial unit
Replaces the name, area and surface while preserving the unit identity and its conventions. **Required permission:** `referential.commercial-unit:write`
PUT
/referential/v1/commercial-units/{id}Replaces the name, area and surface while preserving the unit identity and its conventions.
Required permission: referential.commercial-unit:write
Authorization
oauth2 AuthorizationBearer <token>
In: header
Path Parameters
id*string
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
body*CorrectCommercialUnitRequest
Response Body
*/*
*/*
curl -X PUT "https://example.com/referential/v1/commercial-units/string" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "station_area_id": "string", "surface_m2": 0 }'{ "corrected_at": "2019-08-24T14:15:22Z", "corrected_by": "string", "created_at": "2019-08-24T14:15:22Z", "id": "string", "name": "string", "retired_at": "2019-08-24T14:15:22Z", "retired_by": "string", "station_area_id": "string", "station_id": "string", "status": "ACTIVE", "surface_m2": 0}Get commercial-unit
Returns the record, including retired records. **Required permission:** `referential.commercial-unit:read`
Retire a commercial unit
Retires a unit with no current or future convention; retains its audit and historical references. **Required permission:** `referential.commercial-unit:write`