Update Branch

Update an existing branch. The path parameter id is required. All request body fields are optional; include only the fields you want to change.

Path parameter

  • id The identifier of the branch to update.

Notes

  • If provided, branch.id can be used to change the branch identifier.
  • Coordinates should be valid decimal degrees.
  • delivery_zones accepts GeoJSON FeatureCollection (e.g., Polygon geometry).

Parameters

branch
dictionary
id
string
Required
Path parameter. The identifier of the branch to update.
PUT/v1/branches/{id}
curl https://api.lynxo.ai/v1/branches/{id} \
  -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR....." \
  -H "Content-Type: application/json" \
  -X PUT \
  -d '{"branch":{"name":"Bangalore","id":"BLR","active":true,"coordinates":{"latitude":12.953993,"longitude":77.621002},"formatted_address":"Lower Agaram Road, 560047, Viveka Nagar, Bengaluru, Bengaluru Urban, Karnataka, India","delivery_zones":{"type":"FeatureCollection","features":[{"id":"6d9ZF99qW5zIFBUZh7rTu4UuMB8UAjYC","type":"Feature","geometry":{"type":"Polygon","coordinates":[[[-118.37501331024575,34.180990857035],[-118.19173459449476,34.063929240734225],[-118.25420037402054,33.95923242559719],[-118.50200418070989,34.03833596855081],[-118.4244367841559,34.158273127595464],[-118.37501331024575,34.180990857035]]]},"properties":{}}]},"contacts":[{"name":"Mohamed","phone":"9876543210","work_timings":{"from":"09:00 AM","to":"05:00 PM"},"work_days":["tuesday","wednesday","thursday","friday","monday"]},{"name":"Thaha","phone":"9786545321","work_timings":{"from":"09:00 AM","to":"05:00 PM"},"work_days":["monday","tuesday","wednesday","thursday","friday","sunday","saturday"]},{"name":"Zahee","phone":"9638527410","work_timings":{"from":"09:00 AM","to":"05:00 PM"},"work_days":["monday","tuesday","wednesday","thursday","friday","sunday"]}]}}'
RESPONSE
{
  "branch": {
    "id": "BLR"
  }
}