# Get Leave Policies Retrieve all leave policies (leave types) in your workspace. Supports filtering by ID. Endpoint: GET /leaves/policies Version: 2.0.0 Security: oauth2, apiKey ## Query parameters: - `workspace_id` (integer, required) ID of the workspace Example: 1 - `id` (string) UUID of the leave policy Example: "a1b2c3d4-e5f6-7890-abcd-ef1234567890" - `page` (integer) Page number for pagination Example: 1 - `per_page` (integer) Number of items per page (max 100) Example: 20 ## Response 200 fields (application/json): - `success` (boolean) Example: true - `data` (array) - `data.id` (string) UUID of the leave policy Example: "a1b2c3d4-e5f6-7890-abcd-ef1234567890" - `data.name` (string) Name of the leave policy Example: "Vacation" - `data.max_days` (number,null) Maximum days allowed per year Example: 20 - `meta` (object) - `meta.api_version` (string) Example: "2.0.0" - `meta.timestamp` (string) ## Response 400 fields (application/json): - `success` (boolean, required) - `message` (string, required) Error message describing what went wrong Example: "An error occurred" - `error` (string,null) Optional additional error details Example: "Internal Server Error" - `meta` (object, required) - `meta.api_version` (string) Example: "2.0.0" - `meta.timestamp` (string) ## Response 401 fields (application/json): - `success` (boolean, required) - `message` (string, required) Error message describing what went wrong Example: "An error occurred" - `error` (string,null) Optional additional error details Example: "Internal Server Error" - `meta` (object, required) - `meta.api_version` (string) Example: "2.0.0" - `meta.timestamp` (string) ## Response 403 fields (application/json): - `success` (boolean, required) - `message` (string, required) Error message describing what went wrong Example: "An error occurred" - `error` (string,null) Optional additional error details Example: "Internal Server Error" - `meta` (object, required) - `meta.api_version` (string) Example: "2.0.0" - `meta.timestamp` (string) ## Response 500 fields (application/json): - `success` (boolean, required) - `message` (string, required) Error message describing what went wrong Example: "An error occurred" - `error` (string,null) Optional additional error details Example: "Internal Server Error" - `meta` (object, required) - `meta.api_version` (string) Example: "2.0.0" - `meta.timestamp` (string)