lib/purecloudplatformclientv2/api/analytics_api.rb in purecloudplatformclientv2-61.0.0 vs lib/purecloudplatformclientv2/api/analytics_api.rb in purecloudplatformclientv2-62.0.0

- old
+ new

@@ -22,10 +22,74 @@ def initialize(api_client = ApiClient.default) @api_client = api_client end + # Delete/cancel an async request + # + # @param job_id jobId + # @param [Hash] opts the optional parameters + # @return [nil] + def delete_analytics_conversations_details_job(job_id, opts = {}) + delete_analytics_conversations_details_job_with_http_info(job_id, opts) + return nil + end + + # Delete/cancel an async request + # + # @param job_id jobId + # @param [Hash] opts the optional parameters + # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers + def delete_analytics_conversations_details_job_with_http_info(job_id, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug "Calling API: AnalyticsApi.delete_analytics_conversations_details_job ..." + end + + + # verify the required parameter 'job_id' is set + fail ArgumentError, "Missing the required parameter 'job_id' when calling AnalyticsApi.delete_analytics_conversations_details_job" if job_id.nil? + + + + + + # resource path + local_var_path = "/api/v2/analytics/conversations/details/jobs/{jobId}".sub('{format}','json').sub('{' + 'jobId' + '}', job_id.to_s) + + # query parameters + query_params = {} + + # header parameters + header_params = {} + + # HTTP header 'Accept' (if needed) + local_header_accept = ['application/json'] + local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result + + # HTTP header 'Content-Type' + local_header_content_type = ['application/json'] + header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type) + + # form parameters + form_params = {} + + # http body (model) + post_body = nil + + auth_names = ['PureCloud OAuth'] + data, status_code, headers = @api_client.call_api(:DELETE, 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: AnalyticsApi#delete_analytics_conversations_details_job\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + # Delete a scheduled report job. # # @param schedule_id Schedule ID # @param [Hash] opts the optional parameters # @return [nil] @@ -215,10 +279,149 @@ @api_client.config.logger.debug "API called: AnalyticsApi#get_analytics_conversations_details\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end + # Get status for async query for conversation details + # + # @param job_id jobId + # @param [Hash] opts the optional parameters + # @return [AsyncQueryStatus] + def get_analytics_conversations_details_job(job_id, opts = {}) + data, _status_code, _headers = get_analytics_conversations_details_job_with_http_info(job_id, opts) + return data + end + + # Get status for async query for conversation details + # + # @param job_id jobId + # @param [Hash] opts the optional parameters + # @return [Array<(AsyncQueryStatus, Fixnum, Hash)>] AsyncQueryStatus data, response status code and response headers + def get_analytics_conversations_details_job_with_http_info(job_id, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug "Calling API: AnalyticsApi.get_analytics_conversations_details_job ..." + end + + + # verify the required parameter 'job_id' is set + fail ArgumentError, "Missing the required parameter 'job_id' when calling AnalyticsApi.get_analytics_conversations_details_job" if job_id.nil? + + + + + + # resource path + local_var_path = "/api/v2/analytics/conversations/details/jobs/{jobId}".sub('{format}','json').sub('{' + 'jobId' + '}', job_id.to_s) + + # query parameters + query_params = {} + + # header parameters + header_params = {} + + # HTTP header 'Accept' (if needed) + local_header_accept = ['application/json'] + local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result + + # HTTP header 'Content-Type' + local_header_content_type = ['application/json'] + header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type) + + # form parameters + form_params = {} + + # http body (model) + post_body = nil + + auth_names = ['PureCloud 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 => 'AsyncQueryStatus') + if @api_client.config.debugging + @api_client.config.logger.debug "API called: AnalyticsApi#get_analytics_conversations_details_job\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + + # Fetch a page of results for an async query + # + # @param job_id jobId + # @param [Hash] opts the optional parameters + # @option opts [String] :cursor Indicates where to resume query results (not required for first page) + # @return [AnalyticsConversationAsyncQueryResponse] + def get_analytics_conversations_details_job_results(job_id, opts = {}) + data, _status_code, _headers = get_analytics_conversations_details_job_results_with_http_info(job_id, opts) + return data + end + + # Fetch a page of results for an async query + # + # @param job_id jobId + # @param [Hash] opts the optional parameters + # @option opts [String] :cursor Indicates where to resume query results (not required for first page) + # @return [Array<(AnalyticsConversationAsyncQueryResponse, Fixnum, Hash)>] AnalyticsConversationAsyncQueryResponse data, response status code and response headers + def get_analytics_conversations_details_job_results_with_http_info(job_id, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug "Calling API: AnalyticsApi.get_analytics_conversations_details_job_results ..." + end + + + # verify the required parameter 'job_id' is set + fail ArgumentError, "Missing the required parameter 'job_id' when calling AnalyticsApi.get_analytics_conversations_details_job_results" if job_id.nil? + + + + + + + + + + + + # resource path + local_var_path = "/api/v2/analytics/conversations/details/jobs/{jobId}/results".sub('{format}','json').sub('{' + 'jobId' + '}', job_id.to_s) + + # query parameters + query_params = {} + query_params[:'cursor'] = opts[:'cursor'] if opts[:'cursor'] + + # header parameters + header_params = {} + + # HTTP header 'Accept' (if needed) + local_header_accept = ['application/json'] + local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result + + # HTTP header 'Content-Type' + local_header_content_type = ['application/json'] + header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type) + + # form parameters + form_params = {} + + # http body (model) + post_body = nil + + auth_names = ['PureCloud 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 => 'AnalyticsConversationAsyncQueryResponse') + if @api_client.config.debugging + @api_client.config.logger.debug "API called: AnalyticsApi#get_analytics_conversations_details_job_results\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + # Get all view export requests for a user # # @param [Hash] opts the optional parameters # @return [ReportingExportJobListing] def get_analytics_reporting_exports(opts = {}) @@ -1033,9 +1236,74 @@ :body => post_body, :auth_names => auth_names, :return_type => 'AggregateQueryResponse') if @api_client.config.debugging @api_client.config.logger.debug "API called: AnalyticsApi#post_analytics_conversations_aggregates_query\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" + end + return data, status_code, headers + end + + # Query for conversation details asynchronously + # + # @param body query + # @param [Hash] opts the optional parameters + # @return [AsyncQueryResponse] + def post_analytics_conversations_details_jobs(body, opts = {}) + data, _status_code, _headers = post_analytics_conversations_details_jobs_with_http_info(body, opts) + return data + end + + # Query for conversation details asynchronously + # + # @param body query + # @param [Hash] opts the optional parameters + # @return [Array<(AsyncQueryResponse, Fixnum, Hash)>] AsyncQueryResponse data, response status code and response headers + def post_analytics_conversations_details_jobs_with_http_info(body, opts = {}) + if @api_client.config.debugging + @api_client.config.logger.debug "Calling API: AnalyticsApi.post_analytics_conversations_details_jobs ..." + end + + + # verify the required parameter 'body' is set + fail ArgumentError, "Missing the required parameter 'body' when calling AnalyticsApi.post_analytics_conversations_details_jobs" if body.nil? + + + + + + # resource path + local_var_path = "/api/v2/analytics/conversations/details/jobs".sub('{format}','json') + + # query parameters + query_params = {} + + # header parameters + header_params = {} + + # HTTP header 'Accept' (if needed) + local_header_accept = ['application/json'] + local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result + + # HTTP header 'Content-Type' + local_header_content_type = ['application/json'] + header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type) + + # form parameters + form_params = {} + + # http body (model) + post_body = @api_client.object_to_http_body(body) + + auth_names = ['PureCloud OAuth'] + 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 => 'AsyncQueryResponse') + if @api_client.config.debugging + @api_client.config.logger.debug "API called: AnalyticsApi#post_analytics_conversations_details_jobs\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Query for conversation details