The V3 departments API is now deprecated. As a result, the following routes will be sunset and no longer respond starting from September 2026:
/api/v3/departments
/api/v3/departments/{id}
/api/v3/departments/tree
If you are using any of its endpoints, then you should migrate either to the V4 departments API or to the Lucca API departments endpoints.
If you migrate to the V4 departments API, you will benefit from a similar data model, endpoints, and authentication, with some improvements, but at the cost of a future migration to the Lucca API (no date has been set for now).
If you migrate to the Lucca API departments endpoints, you will benefit from a more integrated experience, but at the cost of an entirely different authentication method (OAuth2 bearer tokens).
Note that there are no equivalent to the V3 “tree” endpoint in neither the V4 nor the Lucca API, as it posed serious performance issues in large organizations (paging could not be enforced).