# ObjectDepartmentAPI All URIs are relative to *https://prod.api.appcluster01.ca-central-1.ezmax.com/rest* Method | HTTP request | Description ------------- | ------------- | ------------- [**departmentGetAutocompleteV2**](ObjectDepartmentAPI.md#departmentgetautocompletev2) | **GET** /2/object/department/getAutocomplete/{sSelector} | Retrieve Departments and IDs # **departmentGetAutocompleteV2** ```swift open class func departmentGetAutocompleteV2(sSelector: SSelector_departmentGetAutocompleteV2, eFilterActive: EFilterActive_departmentGetAutocompleteV2? = nil, sQuery: String? = nil, acceptLanguage: HeaderAcceptLanguage? = nil, completion: @escaping (_ data: DepartmentGetAutocompleteV2Response?, _ error: Error?) -> Void) ``` Retrieve Departments and IDs Get the list of Department to be used in a dropdown or autocomplete control. ### Example ```swift // The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new import OpenAPIClient let sSelector = "sSelector_example" // String | The type of Departments to return let eFilterActive = "eFilterActive_example" // String | Specify which results we want to display. (optional) (default to .active) let sQuery = "sQuery_example" // String | Allow to filter the returned results (optional) let acceptLanguage = Header-Accept-Language() // HeaderAcceptLanguage | (optional) // Retrieve Departments and IDs ObjectDepartmentAPI.departmentGetAutocompleteV2(sSelector: sSelector, eFilterActive: eFilterActive, sQuery: sQuery, acceptLanguage: acceptLanguage) { (response, error) in guard error == nil else { print(error) return } if (response) { dump(response) } } ``` ### Parameters Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- **sSelector** | **String** | The type of Departments to return | **eFilterActive** | **String** | Specify which results we want to display. | [optional] [default to .active] **sQuery** | **String** | Allow to filter the returned results | [optional] **acceptLanguage** | [**HeaderAcceptLanguage**](.md) | | [optional] ### Return type [**DepartmentGetAutocompleteV2Response**](DepartmentGetAutocompleteV2Response.md) ### Authorization [Authorization](../README.md#Authorization) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)