class PureCloud::WorkforceManagementApi
Attributes
Public Class Methods
# File lib/purecloud/api/workforce_management_api.rb, line 23 def initialize(api_client = ApiClient.default) @api_client = api_client end
Public Instance Methods
Get a list of UserScheduleAdherence
records for the requested users
@param user_id User
Id(s) for which to fetch current schedule adherence information. Min 1, Max of 100 userIds per request @param [Hash] opts the optional parameters @return [Array<UserScheduleAdherence>]
# File lib/purecloud/api/workforce_management_api.rb, line 32 def get_adherence(user_id, opts = {}) data, status_code, headers = get_adherence_with_http_info(user_id, opts) return data end
Get a list of UserScheduleAdherence
records for the requested users
@param user_id User
Id(s) for which to fetch current schedule adherence information. Min 1, Max of 100 userIds per request @param [Hash] opts the optional parameters @return [Array<(Array<UserScheduleAdherence>, Fixnum, Hash)>] Array<UserScheduleAdherence> data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 42 def get_adherence_with_http_info(user_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#get_adherence ..." end # verify the required parameter 'user_id' is set fail "Missing the required parameter 'user_id' when calling get_adherence" if user_id.nil? # resource path local_var_path = "/api/v2/workforcemanagement/adherence".sub('{format}','json') # query parameters query_params = {} query_params[:'userId'] = @api_client.build_collection_param(user_id, :multi) # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'Array<UserScheduleAdherence>') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#get_adherence\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get management units
@param [Hash] opts the optional parameters @option opts [String] :selector Selector @option opts [Integer] :page_size (default to 25) @option opts [Integer] :page_number (default to 1) @return [Array<ManagementUnit>]
# File lib/purecloud/api/workforce_management_api.rb, line 95 def get_managementunits(opts = {}) data, status_code, headers = get_managementunits_with_http_info(opts) return data end
Get activity codes corresponding to a management unit
@param mu_id The muId of the management unit. @param [Hash] opts the optional parameters @return [ActivityCodeContainer]
# File lib/purecloud/api/workforce_management_api.rb, line 157 def get_managementunits_mu_id_activitycodes(mu_id, opts = {}) data, status_code, headers = get_managementunits_mu_id_activitycodes_with_http_info(mu_id, opts) return data end
Get activity codes corresponding to a management unit
@param mu_id The muId of the management unit. @param [Hash] opts the optional parameters @return [Array<(ActivityCodeContainer
, Fixnum, Hash)>] ActivityCodeContainer
data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 167 def get_managementunits_mu_id_activitycodes_with_http_info(mu_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#get_managementunits_mu_id_activitycodes ..." end # verify the required parameter 'mu_id' is set fail "Missing the required parameter 'mu_id' when calling get_managementunits_mu_id_activitycodes" if mu_id.nil? # resource path local_var_path = "/api/v2/workforcemanagement/managementunits/{muId}/activitycodes".sub('{format}','json').sub('{' + 'muId' + '}', mu_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'ActivityCodeContainer') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#get_managementunits_mu_id_activitycodes\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get agents in the management unit
@param mu_id The muId of the management unit. @param [Hash] opts the optional parameters @return [WfmUserEntityListing]
# File lib/purecloud/api/workforce_management_api.rb, line 217 def get_managementunits_mu_id_users(mu_id, opts = {}) data, status_code, headers = get_managementunits_mu_id_users_with_http_info(mu_id, opts) return data end
Get a list of time off requests for any user
@param mu_id The muId of the management unit. @param user_id The userId to whom the Time Off Request applies. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :recently_reviewed Limit results to requests that have been reviewed within the preceding 30 days (default to false) @return [TimeOffRequestList]
# File lib/purecloud/api/workforce_management_api.rb, line 279 def get_managementunits_mu_id_users_user_id_timeoffrequests(mu_id, user_id, opts = {}) data, status_code, headers = get_managementunits_mu_id_users_user_id_timeoffrequests_with_http_info(mu_id, user_id, opts) return data end
Get a time off request by id
@param mu_id The muId of the management unit. @param user_id The userId to whom the Time Off Request applies. @param time_off_request_id Time Off Request Id @param [Hash] opts the optional parameters @return [TimeOffRequest]
# File lib/purecloud/api/workforce_management_api.rb, line 347 def get_managementunits_mu_id_users_user_id_timeoffrequests_timeoffrequest_id(mu_id, user_id, time_off_request_id, opts = {}) data, status_code, headers = get_managementunits_mu_id_users_user_id_timeoffrequests_timeoffrequest_id_with_http_info(mu_id, user_id, time_off_request_id, opts) return data end
Get a time off request by id
@param mu_id The muId of the management unit. @param user_id The userId to whom the Time Off Request applies. @param time_off_request_id Time Off Request Id @param [Hash] opts the optional parameters @return [Array<(TimeOffRequest
, Fixnum, Hash)>] TimeOffRequest
data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 359 def get_managementunits_mu_id_users_user_id_timeoffrequests_timeoffrequest_id_with_http_info(mu_id, user_id, time_off_request_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#get_managementunits_mu_id_users_user_id_timeoffrequests_timeoffrequest_id ..." end # verify the required parameter 'mu_id' is set fail "Missing the required parameter 'mu_id' when calling get_managementunits_mu_id_users_user_id_timeoffrequests_timeoffrequest_id" if mu_id.nil? # verify the required parameter 'user_id' is set fail "Missing the required parameter 'user_id' when calling get_managementunits_mu_id_users_user_id_timeoffrequests_timeoffrequest_id" if user_id.nil? # verify the required parameter 'time_off_request_id' is set fail "Missing the required parameter 'time_off_request_id' when calling get_managementunits_mu_id_users_user_id_timeoffrequests_timeoffrequest_id" if time_off_request_id.nil? # resource path local_var_path = "/api/v2/workforcemanagement/managementunits/{muId}/users/{userId}/timeoffrequests/{timeOffRequestId}".sub('{format}','json').sub('{' + 'muId' + '}', mu_id.to_s).sub('{' + 'userId' + '}', user_id.to_s).sub('{' + 'timeOffRequestId' + '}', time_off_request_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'TimeOffRequest') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#get_managementunits_mu_id_users_user_id_timeoffrequests_timeoffrequest_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of time off requests for any user
@param mu_id The muId of the management unit. @param user_id The userId to whom the Time Off Request applies. @param [Hash] opts the optional parameters @option opts [BOOLEAN] :recently_reviewed Limit results to requests that have been reviewed within the preceding 30 days @return [Array<(TimeOffRequestList
, Fixnum, Hash)>] TimeOffRequestList
data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 291 def get_managementunits_mu_id_users_user_id_timeoffrequests_with_http_info(mu_id, user_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#get_managementunits_mu_id_users_user_id_timeoffrequests ..." end # verify the required parameter 'mu_id' is set fail "Missing the required parameter 'mu_id' when calling get_managementunits_mu_id_users_user_id_timeoffrequests" if mu_id.nil? # verify the required parameter 'user_id' is set fail "Missing the required parameter 'user_id' when calling get_managementunits_mu_id_users_user_id_timeoffrequests" if user_id.nil? # resource path local_var_path = "/api/v2/workforcemanagement/managementunits/{muId}/users/{userId}/timeoffrequests".sub('{format}','json').sub('{' + 'muId' + '}', mu_id.to_s).sub('{' + 'userId' + '}', user_id.to_s) # query parameters query_params = {} query_params[:'recentlyReviewed'] = opts[:'recently_reviewed'] if opts[:'recently_reviewed'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'TimeOffRequestList') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#get_managementunits_mu_id_users_user_id_timeoffrequests\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get agents in the management unit
@param mu_id The muId of the management unit. @param [Hash] opts the optional parameters @return [Array<(WfmUserEntityListing
, Fixnum, Hash)>] WfmUserEntityListing
data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 227 def get_managementunits_mu_id_users_with_http_info(mu_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#get_managementunits_mu_id_users ..." end # verify the required parameter 'mu_id' is set fail "Missing the required parameter 'mu_id' when calling get_managementunits_mu_id_users" if mu_id.nil? # resource path local_var_path = "/api/v2/workforcemanagement/managementunits/{muId}/users".sub('{format}','json').sub('{' + 'muId' + '}', mu_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'WfmUserEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#get_managementunits_mu_id_users\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get management units
@param [Hash] opts the optional parameters @option opts [String] :selector Selector @option opts [Integer] :page_size @option opts [Integer] :page_number @return [Array<(Array<ManagementUnit>, Fixnum, Hash)>] Array<ManagementUnit> data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 107 def get_managementunits_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#get_managementunits ..." end # resource path local_var_path = "/api/v2/workforcemanagement/managementunits".sub('{format}','json') # query parameters query_params = {} query_params[:'selector'] = opts[:'selector'] if opts[:'selector'] query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'Array<ManagementUnit>') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#get_managementunits\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of time off requests for the current user
@param [Hash] opts the optional parameters @option opts [BOOLEAN] :recently_reviewed Limit results to requests that have been reviewed within the preceding 30 days (default to false) @return [TimeOffRequestList]
# File lib/purecloud/api/workforce_management_api.rb, line 415 def get_timeoffrequests(opts = {}) data, status_code, headers = get_timeoffrequests_with_http_info(opts) return data end
Get a time off request for the current user by id
@param time_off_request_id Time Off Request Id @param [Hash] opts the optional parameters @return [TimeOffRequest]
# File lib/purecloud/api/workforce_management_api.rb, line 473 def get_timeoffrequests_timeoffrequest_id(time_off_request_id, opts = {}) data, status_code, headers = get_timeoffrequests_timeoffrequest_id_with_http_info(time_off_request_id, opts) return data end
Get a time off request for the current user by id
@param time_off_request_id Time Off Request Id @param [Hash] opts the optional parameters @return [Array<(TimeOffRequest
, Fixnum, Hash)>] TimeOffRequest
data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 483 def get_timeoffrequests_timeoffrequest_id_with_http_info(time_off_request_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#get_timeoffrequests_timeoffrequest_id ..." end # verify the required parameter 'time_off_request_id' is set fail "Missing the required parameter 'time_off_request_id' when calling get_timeoffrequests_timeoffrequest_id" if time_off_request_id.nil? # resource path local_var_path = "/api/v2/workforcemanagement/timeoffrequests/{timeOffRequestId}".sub('{format}','json').sub('{' + 'timeOffRequestId' + '}', time_off_request_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'TimeOffRequest') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#get_timeoffrequests_timeoffrequest_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a list of time off requests for the current user
@param [Hash] opts the optional parameters @option opts [BOOLEAN] :recently_reviewed Limit results to requests that have been reviewed within the preceding 30 days @return [Array<(TimeOffRequestList
, Fixnum, Hash)>] TimeOffRequestList
data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 425 def get_timeoffrequests_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#get_timeoffrequests ..." end # resource path local_var_path = "/api/v2/workforcemanagement/timeoffrequests".sub('{format}','json') # query parameters query_params = {} query_params[:'recentlyReviewed'] = opts[:'recently_reviewed'] if opts[:'recently_reviewed'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = nil auth_names = ['PureCloud Auth'] 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 => 'TimeOffRequestList') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#get_timeoffrequests\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Mark a time off request for the current user as read or unread
@param time_off_request_id Time Off Request Id @param [Hash] opts the optional parameters @option opts [TimeOffRequestPatch] :body @return [nil]
# File lib/purecloud/api/workforce_management_api.rb, line 534 def patch_timeoffrequests_timeoffrequest_id(time_off_request_id, opts = {}) patch_timeoffrequests_timeoffrequest_id_with_http_info(time_off_request_id, opts) return nil end
Mark a time off request for the current user as read or unread
@param time_off_request_id Time Off Request Id @param [Hash] opts the optional parameters @option opts [TimeOffRequestPatch] :body @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 545 def patch_timeoffrequests_timeoffrequest_id_with_http_info(time_off_request_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#patch_timeoffrequests_timeoffrequest_id ..." end # verify the required parameter 'time_off_request_id' is set fail "Missing the required parameter 'time_off_request_id' when calling patch_timeoffrequests_timeoffrequest_id" if time_off_request_id.nil? # resource path local_var_path = "/api/v2/workforcemanagement/timeoffrequests/{timeOffRequestId}".sub('{format}','json').sub('{' + 'timeOffRequestId' + '}', time_off_request_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names) if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#patch_timeoffrequests_timeoffrequest_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get user schedules within the given time range
@param mu_id The muId of the management unit. @param [Hash] opts the optional parameters @option opts [UserListScheduleRequestBody] :body body @return [UserScheduleContainer]
# File lib/purecloud/api/workforce_management_api.rb, line 595 def post_managementunits_mu_id_schedules_search(mu_id, opts = {}) data, status_code, headers = post_managementunits_mu_id_schedules_search_with_http_info(mu_id, opts) return data end
Get user schedules within the given time range
@param mu_id The muId of the management unit. @param [Hash] opts the optional parameters @option opts [UserListScheduleRequestBody] :body body @return [Array<(UserScheduleContainer
, Fixnum, Hash)>] UserScheduleContainer
data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 606 def post_managementunits_mu_id_schedules_search_with_http_info(mu_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#post_managementunits_mu_id_schedules_search ..." end # verify the required parameter 'mu_id' is set fail "Missing the required parameter 'mu_id' when calling post_managementunits_mu_id_schedules_search" if mu_id.nil? # resource path local_var_path = "/api/v2/workforcemanagement/managementunits/{muId}/schedules/search".sub('{format}','json').sub('{' + 'muId' + '}', mu_id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'UserScheduleContainer') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#post_managementunits_mu_id_schedules_search\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Get a schedule for the current user
@param [Hash] opts the optional parameters @option opts [CurrentUserScheduleRequestBody] :body body @return [UserScheduleContainer]
# File lib/purecloud/api/workforce_management_api.rb, line 656 def post_schedules(opts = {}) data, status_code, headers = post_schedules_with_http_info(opts) return data end
Get a schedule for the current user
@param [Hash] opts the optional parameters @option opts [CurrentUserScheduleRequestBody] :body body @return [Array<(UserScheduleContainer
, Fixnum, Hash)>] UserScheduleContainer
data, response status code and response headers
# File lib/purecloud/api/workforce_management_api.rb, line 666 def post_schedules_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: WorkforceManagementApi#post_schedules ..." end # resource path local_var_path = "/api/v2/workforcemanagement/schedules".sub('{format}','json') # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) _header_accept = ['application/json'] _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result # HTTP header 'Content-Type' _header_content_type = ['application/json'] header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type) # form parameters form_params = {} # http body (model) post_body = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud Auth'] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'UserScheduleContainer') if @api_client.config.debugging @api_client.config.logger.debug "API called: WorkforceManagementApi#post_schedules\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end