Method: ArtikCloud::UsersApi#get_user_devices_with_http_info
- Defined in:
- lib/artikcloud/api/users_api.rb
#get_user_devices_with_http_info(user_id, opts = {}) ⇒ Array<(DevicesEnvelope, Fixnum, Hash)>
Get User Devices Retrieve User's Devices
270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 |
# File 'lib/artikcloud/api/users_api.rb', line 270 def get_user_devices_with_http_info(user_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: UsersApi.get_user_devices ..." end # verify the required parameter 'user_id' is set fail ArgumentError, "Missing the required parameter 'user_id' when calling UsersApi.get_user_devices" if user_id.nil? # resource path local_var_path = "/users/{userId}/devices".sub('{format}','json').sub('{' + 'userId' + '}', user_id.to_s) # query parameters query_params = {} query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil? query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil? query_params[:'includeProperties'] = opts[:'include_properties'] if !opts[:'include_properties'].nil? query_params[:'owner'] = opts[:'owner'] if !opts[:'owner'].nil? query_params[:'includeShareInfo'] = opts[:'include_share_info'] if !opts[:'include_share_info'].nil? query_params[:'dtid'] = opts[:'dtid'] if !opts[:'dtid'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['artikcloud_oauth'] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'DevicesEnvelope') if @api_client.config.debugging @api_client.config.logger.debug "API called: UsersApi#get_user_devices\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |