Catalogue›Adjust a territory's details or its boundary
Adjust a territory's details or its boundary
Edits a service area in place, keeping its id and every technician already assigned to it. Partial update: omit a field to keep it, send "" to clear an optional text field; `name` rejects "". `boundary` is the one to watch: omitting it KEEPS the stored polygon, while sending one REPLACES it outright (no partial merge of geometry). This tool cannot remove a polygon once set. A boundary or postal/city change takes effect for every NEW matching decision (quote checks, confirm, reassign, board moves, slot pickers), including for jobs already on the calendar when they are next re-planned. Jobs already assigned are not re-evaluated automatically, so after moving an edge, re-check listCrewCandidates on upcoming jobs near it.
Arguments
idstringpathrequis
Service Area ID
boundaryobjectbodyoptionnel
GeoJSON polygon boundary. Omit to KEEP the stored polygon; send one to replace it.
citystringbodyoptionnel
countrystringbodyoptionnel
countystringbodyoptionnel
descriptionstringbodyoptionnel
nil = keep; "" clears it.
districtstringbodyoptionnel
namestringbodyoptionnel
nil = keep; min=1 rejects an explicit "".
postal_codestringbodyoptionnel
state_provincestringbodyoptionnel
PUT/v1/service-areas/{id}
curl -X PUT "https://api.crisphive.com/v1/service-areas/9b2f6c3e-1a4d-4f0a-8f2e-7c5d1b3a9e01" \ -H "Authorization: Bearer chsk_test_4eC8xQ9mZ2pL7Ka0rT" \ -H "Content-Type: application/json" \ -d '{ "boundary": {}, "city": "Los Angeles", "country": "United States", "county": "Los Angeles County", "description": "Updated description", "district": "Hollywood", "name": "Updated Area Name", "postal_code": "10002", "state_province": "California" }'
Corps de la requête
{
"boundary": {
},
"city": ,
"country": ,
"county": ,
"description": ,
"district": ,
"name": ,
"postal_code": ,
"state_province":
}
Bearer