=begin PureCloud Platform API With the PureCloud Platform API, you can control all aspects of your PureCloud environment. With the APIs you can access the system configuration, manage conversations and more. OpenAPI spec version: v2 Contact: DeveloperEvangelists@genesys.com Generated by: https://github.com/swagger-api/swagger-codegen.git License: UNLICENSED https://help.mypurecloud.com/articles/terms-and-conditions/ Terms of Service: https://help.mypurecloud.com/articles/terms-and-conditions/ =end require "uri" module PureCloud class RecordingApi attr_accessor :api_client def initialize(api_client = ApiClient.default) @api_client = api_client end # Delete annotation # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param annotation_id Annotation ID # @param [Hash] opts the optional parameters # @return [nil] def delete_conversation_recording_annotation(conversation_id, recording_id, annotation_id, opts = {}) delete_conversation_recording_annotation_with_http_info(conversation_id, recording_id, annotation_id, opts) return nil end # Delete annotation # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param annotation_id Annotation ID # @param [Hash] opts the optional parameters # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers def delete_conversation_recording_annotation_with_http_info(conversation_id, recording_id, annotation_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.delete_conversation_recording_annotation ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.delete_conversation_recording_annotation" if conversation_id.nil? # verify the required parameter 'recording_id' is set fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.delete_conversation_recording_annotation" if recording_id.nil? # verify the required parameter 'annotation_id' is set fail ArgumentError, "Missing the required parameter 'annotation_id' when calling RecordingApi.delete_conversation_recording_annotation" if annotation_id.nil? # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordings/{recordingId}/annotations/{annotationId}".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_id.to_s).sub('{' + 'annotationId' + '}', annotation_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: RecordingApi#delete_conversation_recording_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Deletes a single orphan recording # # @param orphan_id Orphan ID # @param [Hash] opts the optional parameters # @return [OrphanRecording] def delete_orphanrecording(orphan_id, opts = {}) data, _status_code, _headers = delete_orphanrecording_with_http_info(orphan_id, opts) return data end # Deletes a single orphan recording # # @param orphan_id Orphan ID # @param [Hash] opts the optional parameters # @return [Array<(OrphanRecording, Fixnum, Hash)>] OrphanRecording data, response status code and response headers def delete_orphanrecording_with_http_info(orphan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.delete_orphanrecording ..." end # verify the required parameter 'orphan_id' is set fail ArgumentError, "Missing the required parameter 'orphan_id' when calling RecordingApi.delete_orphanrecording" if orphan_id.nil? # resource path local_var_path = "/api/v2/orphanrecordings/{orphanId}".sub('{format}','json').sub('{' + 'orphanId' + '}', orphan_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, :return_type => 'OrphanRecording') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#delete_orphanrecording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Delete the recording bulk job # # @param job_id jobId # @param [Hash] opts the optional parameters # @return [nil] def delete_recording_job(job_id, opts = {}) delete_recording_job_with_http_info(job_id, opts) return nil end # Delete the recording bulk job # # @param job_id jobId # @param [Hash] opts the optional parameters # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers def delete_recording_job_with_http_info(job_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.delete_recording_job ..." end # verify the required parameter 'job_id' is set fail ArgumentError, "Missing the required parameter 'job_id' when calling RecordingApi.delete_recording_job" if job_id.nil? # resource path local_var_path = "/api/v2/recording/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: RecordingApi#delete_recording_job\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Delete media retention policies # Bulk delete of media retention policies, this will only delete the polices that match the ids specified in the query param. # @param ids # @param [Hash] opts the optional parameters # @return [nil] def delete_recording_mediaretentionpolicies(ids, opts = {}) delete_recording_mediaretentionpolicies_with_http_info(ids, opts) return nil end # Delete media retention policies # Bulk delete of media retention policies, this will only delete the polices that match the ids specified in the query param. # @param ids # @param [Hash] opts the optional parameters # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers def delete_recording_mediaretentionpolicies_with_http_info(ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.delete_recording_mediaretentionpolicies ..." end # verify the required parameter 'ids' is set fail ArgumentError, "Missing the required parameter 'ids' when calling RecordingApi.delete_recording_mediaretentionpolicies" if ids.nil? # resource path local_var_path = "/api/v2/recording/mediaretentionpolicies".sub('{format}','json') # query parameters query_params = {} query_params[:'ids'] = ids # 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: RecordingApi#delete_recording_mediaretentionpolicies\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Delete a media retention policy # # @param policy_id Policy ID # @param [Hash] opts the optional parameters # @return [nil] def delete_recording_mediaretentionpolicy(policy_id, opts = {}) delete_recording_mediaretentionpolicy_with_http_info(policy_id, opts) return nil end # Delete a media retention policy # # @param policy_id Policy ID # @param [Hash] opts the optional parameters # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers def delete_recording_mediaretentionpolicy_with_http_info(policy_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.delete_recording_mediaretentionpolicy ..." end # verify the required parameter 'policy_id' is set fail ArgumentError, "Missing the required parameter 'policy_id' when calling RecordingApi.delete_recording_mediaretentionpolicy" if policy_id.nil? # resource path local_var_path = "/api/v2/recording/mediaretentionpolicies/{policyId}".sub('{format}','json').sub('{' + 'policyId' + '}', policy_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: RecordingApi#delete_recording_mediaretentionpolicy\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Gets a specific recording. # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param [Hash] opts the optional parameters # @option opts [String] :format_id The desired media format. (default to WEBM) # @option opts [BOOLEAN] :download requesting a download format of the recording (default to false) # @option opts [String] :file_name the name of the downloaded fileName # @option opts [String] :locale The locale for the requested file when downloading, as an ISO 639-1 code # @return [Recording] def get_conversation_recording(conversation_id, recording_id, opts = {}) data, _status_code, _headers = get_conversation_recording_with_http_info(conversation_id, recording_id, opts) return data end # Gets a specific recording. # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param [Hash] opts the optional parameters # @option opts [String] :format_id The desired media format. # @option opts [BOOLEAN] :download requesting a download format of the recording # @option opts [String] :file_name the name of the downloaded fileName # @option opts [String] :locale The locale for the requested file when downloading, as an ISO 639-1 code # @return [Array<(Recording, Fixnum, Hash)>] Recording data, response status code and response headers def get_conversation_recording_with_http_info(conversation_id, recording_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_conversation_recording ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.get_conversation_recording" if conversation_id.nil? # verify the required parameter 'recording_id' is set fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.get_conversation_recording" if recording_id.nil? if opts[:'format_id'] && !['WAV', 'WEBM', 'WAV_ULAW', 'OGG_VORBIS', 'OGG_OPUS', 'MP3', 'NONE'].include?(opts[:'format_id']) fail ArgumentError, 'invalid value for "format_id", must be one of WAV, WEBM, WAV_ULAW, OGG_VORBIS, OGG_OPUS, MP3, NONE' end # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordings/{recordingId}".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_id.to_s) # query parameters query_params = {} query_params[:'formatId'] = opts[:'format_id'] if opts[:'format_id'] query_params[:'download'] = opts[:'download'] if opts[:'download'] query_params[:'fileName'] = opts[:'file_name'] if opts[:'file_name'] query_params[:'locale'] = opts[:'locale'] if opts[:'locale'] # 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 => 'Recording') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_conversation_recording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get annotation # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param annotation_id Annotation ID # @param [Hash] opts the optional parameters # @return [Annotation] def get_conversation_recording_annotation(conversation_id, recording_id, annotation_id, opts = {}) data, _status_code, _headers = get_conversation_recording_annotation_with_http_info(conversation_id, recording_id, annotation_id, opts) return data end # Get annotation # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param annotation_id Annotation ID # @param [Hash] opts the optional parameters # @return [Array<(Annotation, Fixnum, Hash)>] Annotation data, response status code and response headers def get_conversation_recording_annotation_with_http_info(conversation_id, recording_id, annotation_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_conversation_recording_annotation ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.get_conversation_recording_annotation" if conversation_id.nil? # verify the required parameter 'recording_id' is set fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.get_conversation_recording_annotation" if recording_id.nil? # verify the required parameter 'annotation_id' is set fail ArgumentError, "Missing the required parameter 'annotation_id' when calling RecordingApi.get_conversation_recording_annotation" if annotation_id.nil? # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordings/{recordingId}/annotations/{annotationId}".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_id.to_s).sub('{' + 'annotationId' + '}', annotation_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 => 'Annotation') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_conversation_recording_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get annotations for recording # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param [Hash] opts the optional parameters # @return [Array] def get_conversation_recording_annotations(conversation_id, recording_id, opts = {}) data, _status_code, _headers = get_conversation_recording_annotations_with_http_info(conversation_id, recording_id, opts) return data end # Get annotations for recording # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param [Hash] opts the optional parameters # @return [Array<(Array, Fixnum, Hash)>] Array data, response status code and response headers def get_conversation_recording_annotations_with_http_info(conversation_id, recording_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_conversation_recording_annotations ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.get_conversation_recording_annotations" if conversation_id.nil? # verify the required parameter 'recording_id' is set fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.get_conversation_recording_annotations" if recording_id.nil? # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordings/{recordingId}/annotations".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_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 => 'Array') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_conversation_recording_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get recording metadata for a conversation. Does not return playable media. # # @param conversation_id Conversation ID # @param [Hash] opts the optional parameters # @return [Array] def get_conversation_recordingmetadata(conversation_id, opts = {}) data, _status_code, _headers = get_conversation_recordingmetadata_with_http_info(conversation_id, opts) return data end # Get recording metadata for a conversation. Does not return playable media. # # @param conversation_id Conversation ID # @param [Hash] opts the optional parameters # @return [Array<(Array, Fixnum, Hash)>] Array data, response status code and response headers def get_conversation_recordingmetadata_with_http_info(conversation_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_conversation_recordingmetadata ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.get_conversation_recordingmetadata" if conversation_id.nil? # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordingmetadata".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_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 => 'Array') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_conversation_recordingmetadata\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get metadata for a specific recording. Does not return playable media. # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param [Hash] opts the optional parameters # @return [RecordingMetadata] def get_conversation_recordingmetadata_recording_id(conversation_id, recording_id, opts = {}) data, _status_code, _headers = get_conversation_recordingmetadata_recording_id_with_http_info(conversation_id, recording_id, opts) return data end # Get metadata for a specific recording. Does not return playable media. # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param [Hash] opts the optional parameters # @return [Array<(RecordingMetadata, Fixnum, Hash)>] RecordingMetadata data, response status code and response headers def get_conversation_recordingmetadata_recording_id_with_http_info(conversation_id, recording_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_conversation_recordingmetadata_recording_id ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.get_conversation_recordingmetadata_recording_id" if conversation_id.nil? # verify the required parameter 'recording_id' is set fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.get_conversation_recordingmetadata_recording_id" if recording_id.nil? # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordingmetadata/{recordingId}".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_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 => 'RecordingMetadata') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_conversation_recordingmetadata_recording_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get all of a Conversation's Recordings. # # @param conversation_id Conversation ID # @param [Hash] opts the optional parameters # @option opts [Integer] :max_wait_ms The maximum number of milliseconds to wait for the recording to be ready. Must be a positive value. (default to 5000) # @option opts [String] :format_id The desired media format. Possible values: NONE, MP3, WAV, or WEBM (default to WEBM) # @return [Array] def get_conversation_recordings(conversation_id, opts = {}) data, _status_code, _headers = get_conversation_recordings_with_http_info(conversation_id, opts) return data end # Get all of a Conversation's Recordings. # # @param conversation_id Conversation ID # @param [Hash] opts the optional parameters # @option opts [Integer] :max_wait_ms The maximum number of milliseconds to wait for the recording to be ready. Must be a positive value. # @option opts [String] :format_id The desired media format. Possible values: NONE, MP3, WAV, or WEBM # @return [Array<(Array, Fixnum, Hash)>] Array data, response status code and response headers def get_conversation_recordings_with_http_info(conversation_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_conversation_recordings ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.get_conversation_recordings" if conversation_id.nil? if opts[:'format_id'] && !['WAV', 'WEBM', 'WAV_ULAW', 'OGG_VORBIS', 'OGG_OPUS', 'MP3', 'NONE'].include?(opts[:'format_id']) fail ArgumentError, 'invalid value for "format_id", must be one of WAV, WEBM, WAV_ULAW, OGG_VORBIS, OGG_OPUS, MP3, NONE' end # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordings".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s) # query parameters query_params = {} query_params[:'maxWaitMs'] = opts[:'max_wait_ms'] if opts[:'max_wait_ms'] query_params[:'formatId'] = opts[:'format_id'] if opts[:'format_id'] # 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 => 'Array') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_conversation_recordings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Gets a single orphan recording # # @param orphan_id Orphan ID # @param [Hash] opts the optional parameters # @return [OrphanRecording] def get_orphanrecording(orphan_id, opts = {}) data, _status_code, _headers = get_orphanrecording_with_http_info(orphan_id, opts) return data end # Gets a single orphan recording # # @param orphan_id Orphan ID # @param [Hash] opts the optional parameters # @return [Array<(OrphanRecording, Fixnum, Hash)>] OrphanRecording data, response status code and response headers def get_orphanrecording_with_http_info(orphan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_orphanrecording ..." end # verify the required parameter 'orphan_id' is set fail ArgumentError, "Missing the required parameter 'orphan_id' when calling RecordingApi.get_orphanrecording" if orphan_id.nil? # resource path local_var_path = "/api/v2/orphanrecordings/{orphanId}".sub('{format}','json').sub('{' + 'orphanId' + '}', orphan_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 => 'OrphanRecording') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_orphanrecording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Gets the media of a single orphan recording # A 202 response means the orphaned media is currently transcoding and will be available shortly.A 200 response denotes the transcoded orphan media is available now and is contained in the response body. # @param orphan_id Orphan ID # @param [Hash] opts the optional parameters # @option opts [String] :format_id The desired media format. (default to WEBM) # @option opts [BOOLEAN] :download requesting a download format of the recording (default to false) # @option opts [String] :file_name the name of the downloaded fileName # @option opts [String] :locale The locale for the requested file when downloading, as an ISO 639-1 code # @return [Recording] def get_orphanrecording_media(orphan_id, opts = {}) data, _status_code, _headers = get_orphanrecording_media_with_http_info(orphan_id, opts) return data end # Gets the media of a single orphan recording # A 202 response means the orphaned media is currently transcoding and will be available shortly.A 200 response denotes the transcoded orphan media is available now and is contained in the response body. # @param orphan_id Orphan ID # @param [Hash] opts the optional parameters # @option opts [String] :format_id The desired media format. # @option opts [BOOLEAN] :download requesting a download format of the recording # @option opts [String] :file_name the name of the downloaded fileName # @option opts [String] :locale The locale for the requested file when downloading, as an ISO 639-1 code # @return [Array<(Recording, Fixnum, Hash)>] Recording data, response status code and response headers def get_orphanrecording_media_with_http_info(orphan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_orphanrecording_media ..." end # verify the required parameter 'orphan_id' is set fail ArgumentError, "Missing the required parameter 'orphan_id' when calling RecordingApi.get_orphanrecording_media" if orphan_id.nil? if opts[:'format_id'] && !['WAV', 'WEBM', 'WAV_ULAW', 'OGG_VORBIS', 'OGG_OPUS', 'MP3', 'NONE'].include?(opts[:'format_id']) fail ArgumentError, 'invalid value for "format_id", must be one of WAV, WEBM, WAV_ULAW, OGG_VORBIS, OGG_OPUS, MP3, NONE' end # resource path local_var_path = "/api/v2/orphanrecordings/{orphanId}/media".sub('{format}','json').sub('{' + 'orphanId' + '}', orphan_id.to_s) # query parameters query_params = {} query_params[:'formatId'] = opts[:'format_id'] if opts[:'format_id'] query_params[:'download'] = opts[:'download'] if opts[:'download'] query_params[:'fileName'] = opts[:'file_name'] if opts[:'file_name'] query_params[:'locale'] = opts[:'locale'] if opts[:'locale'] # 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 => 'Recording') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_orphanrecording_media\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Gets all orphan recordings # # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size The total page size requested (default to 25) # @option opts [Integer] :page_number The page number requested (default to 1) # @option opts [String] :sort_by variable name requested to sort by # @option opts [Array] :expand variable name requested by expand list # @option opts [String] :next_page next page token # @option opts [String] :previous_page Previous page token # @option opts [BOOLEAN] :has_conversation Filter resulting orphans by whether the conversation is known. False returns all orphans for the organization. (default to false) # @option opts [String] :media Filter resulting orphans based on their media type # @return [OrphanRecordingListing] def get_orphanrecordings(opts = {}) data, _status_code, _headers = get_orphanrecordings_with_http_info(opts) return data end # Gets all orphan recordings # # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size The total page size requested # @option opts [Integer] :page_number The page number requested # @option opts [String] :sort_by variable name requested to sort by # @option opts [Array] :expand variable name requested by expand list # @option opts [String] :next_page next page token # @option opts [String] :previous_page Previous page token # @option opts [BOOLEAN] :has_conversation Filter resulting orphans by whether the conversation is known. False returns all orphans for the organization. # @option opts [String] :media Filter resulting orphans based on their media type # @return [Array<(OrphanRecordingListing, Fixnum, Hash)>] OrphanRecordingListing data, response status code and response headers def get_orphanrecordings_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_orphanrecordings ..." end if opts[:'media'] && !['Call', 'Screen'].include?(opts[:'media']) fail ArgumentError, 'invalid value for "media", must be one of Call, Screen' end # resource path local_var_path = "/api/v2/orphanrecordings".sub('{format}','json') # query parameters query_params = {} query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'sortBy'] = opts[:'sort_by'] if opts[:'sort_by'] query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] query_params[:'nextPage'] = opts[:'next_page'] if opts[:'next_page'] query_params[:'previousPage'] = opts[:'previous_page'] if opts[:'previous_page'] query_params[:'hasConversation'] = opts[:'has_conversation'] if opts[:'has_conversation'] query_params[:'media'] = opts[:'media'] if opts[:'media'] # 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 => 'OrphanRecordingListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_orphanrecordings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get the status and results for a batch request job, only the user that submitted the job may retrieve results # # @param job_id jobId # @param [Hash] opts the optional parameters # @return [BatchDownloadJobStatusResult] def get_recording_batchrequest(job_id, opts = {}) data, _status_code, _headers = get_recording_batchrequest_with_http_info(job_id, opts) return data end # Get the status and results for a batch request job, only the user that submitted the job may retrieve results # # @param job_id jobId # @param [Hash] opts the optional parameters # @return [Array<(BatchDownloadJobStatusResult, Fixnum, Hash)>] BatchDownloadJobStatusResult data, response status code and response headers def get_recording_batchrequest_with_http_info(job_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_batchrequest ..." end # verify the required parameter 'job_id' is set fail ArgumentError, "Missing the required parameter 'job_id' when calling RecordingApi.get_recording_batchrequest" if job_id.nil? # resource path local_var_path = "/api/v2/recording/batchrequests/{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 => 'BatchDownloadJobStatusResult') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_batchrequest\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get the status of the job associated with the job id. # # @param job_id jobId # @param [Hash] opts the optional parameters # @return [RecordingJob] def get_recording_job(job_id, opts = {}) data, _status_code, _headers = get_recording_job_with_http_info(job_id, opts) return data end # Get the status of the job associated with the job id. # # @param job_id jobId # @param [Hash] opts the optional parameters # @return [Array<(RecordingJob, Fixnum, Hash)>] RecordingJob data, response status code and response headers def get_recording_job_with_http_info(job_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_job ..." end # verify the required parameter 'job_id' is set fail ArgumentError, "Missing the required parameter 'job_id' when calling RecordingApi.get_recording_job" if job_id.nil? # resource path local_var_path = "/api/v2/recording/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 => 'RecordingJob') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_job\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get the status of all jobs within the user's organization # # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size Page size (default to 25) # @option opts [Integer] :page_number Page number (default to 1) # @option opts [String] :sort_by Sort by (default to userId) # @option opts [String] :state Filter by state # @option opts [BOOLEAN] :show_only_my_jobs Show only my jobs # @option opts [String] :job_type Job Type (Can be left empty for both) # @return [RecordingJobEntityListing] def get_recording_jobs(opts = {}) data, _status_code, _headers = get_recording_jobs_with_http_info(opts) return data end # Get the status of all jobs within the user's organization # # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size Page size # @option opts [Integer] :page_number Page number # @option opts [String] :sort_by Sort by # @option opts [String] :state Filter by state # @option opts [BOOLEAN] :show_only_my_jobs Show only my jobs # @option opts [String] :job_type Job Type (Can be left empty for both) # @return [Array<(RecordingJobEntityListing, Fixnum, Hash)>] RecordingJobEntityListing data, response status code and response headers def get_recording_jobs_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_jobs ..." end if opts[:'sort_by'] && !['userId', 'dateCreated'].include?(opts[:'sort_by']) fail ArgumentError, 'invalid value for "sort_by", must be one of userId, dateCreated' end if opts[:'state'] && !['FULFILLED', 'PENDING', 'READY', 'PROCESSING', 'CANCELLED', 'FAILED'].include?(opts[:'state']) fail ArgumentError, 'invalid value for "state", must be one of FULFILLED, PENDING, READY, PROCESSING, CANCELLED, FAILED' end if opts[:'job_type'] && !['DELETE', 'EXPORT'].include?(opts[:'job_type']) fail ArgumentError, 'invalid value for "job_type", must be one of DELETE, EXPORT' end # resource path local_var_path = "/api/v2/recording/jobs".sub('{format}','json') # query parameters query_params = {} query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'sortBy'] = opts[:'sort_by'] if opts[:'sort_by'] query_params[:'state'] = opts[:'state'] if opts[:'state'] query_params[:'showOnlyMyJobs'] = opts[:'show_only_my_jobs'] if opts[:'show_only_my_jobs'] query_params[:'jobType'] = opts[:'job_type'] if opts[:'job_type'] # 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 => 'RecordingJobEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_jobs\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get the local encryption settings # # @param settings_id Settings Id # @param [Hash] opts the optional parameters # @return [LocalEncryptionConfiguration] def get_recording_localkeys_setting(settings_id, opts = {}) data, _status_code, _headers = get_recording_localkeys_setting_with_http_info(settings_id, opts) return data end # Get the local encryption settings # # @param settings_id Settings Id # @param [Hash] opts the optional parameters # @return [Array<(LocalEncryptionConfiguration, Fixnum, Hash)>] LocalEncryptionConfiguration data, response status code and response headers def get_recording_localkeys_setting_with_http_info(settings_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_localkeys_setting ..." end # verify the required parameter 'settings_id' is set fail ArgumentError, "Missing the required parameter 'settings_id' when calling RecordingApi.get_recording_localkeys_setting" if settings_id.nil? # resource path local_var_path = "/api/v2/recording/localkeys/settings/{settingsId}".sub('{format}','json').sub('{' + 'settingsId' + '}', settings_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 => 'LocalEncryptionConfiguration') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_localkeys_setting\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # gets a list local key settings data # # @param [Hash] opts the optional parameters # @return [LocalEncryptionConfigurationListing] def get_recording_localkeys_settings(opts = {}) data, _status_code, _headers = get_recording_localkeys_settings_with_http_info(opts) return data end # gets a list local key settings data # # @param [Hash] opts the optional parameters # @return [Array<(LocalEncryptionConfigurationListing, Fixnum, Hash)>] LocalEncryptionConfigurationListing data, response status code and response headers def get_recording_localkeys_settings_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_localkeys_settings ..." end # resource path local_var_path = "/api/v2/recording/localkeys/settings".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 = 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 => 'LocalEncryptionConfigurationListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_localkeys_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Gets media retention policy list with query options to filter on name and enabled. # for a less verbose response, add summary=true to this endpoint # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size The total page size requested (default to 25) # @option opts [Integer] :page_number The page number requested (default to 1) # @option opts [String] :sort_by variable name requested to sort by # @option opts [Array] :expand variable name requested by expand list # @option opts [String] :next_page next page token # @option opts [String] :previous_page Previous page token # @option opts [String] :name the policy name - used for filtering results in searches. # @option opts [BOOLEAN] :enabled checks to see if policy is enabled - use enabled = true or enabled = false # @option opts [BOOLEAN] :summary provides a less verbose response of policy lists. (default to false) # @option opts [BOOLEAN] :has_errors provides a way to fetch all policies with errors or policies that do not have errors # @return [PolicyEntityListing] def get_recording_mediaretentionpolicies(opts = {}) data, _status_code, _headers = get_recording_mediaretentionpolicies_with_http_info(opts) return data end # Gets media retention policy list with query options to filter on name and enabled. # for a less verbose response, add summary=true to this endpoint # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size The total page size requested # @option opts [Integer] :page_number The page number requested # @option opts [String] :sort_by variable name requested to sort by # @option opts [Array] :expand variable name requested by expand list # @option opts [String] :next_page next page token # @option opts [String] :previous_page Previous page token # @option opts [String] :name the policy name - used for filtering results in searches. # @option opts [BOOLEAN] :enabled checks to see if policy is enabled - use enabled = true or enabled = false # @option opts [BOOLEAN] :summary provides a less verbose response of policy lists. # @option opts [BOOLEAN] :has_errors provides a way to fetch all policies with errors or policies that do not have errors # @return [Array<(PolicyEntityListing, Fixnum, Hash)>] PolicyEntityListing data, response status code and response headers def get_recording_mediaretentionpolicies_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_mediaretentionpolicies ..." end # resource path local_var_path = "/api/v2/recording/mediaretentionpolicies".sub('{format}','json') # query parameters query_params = {} query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size'] query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number'] query_params[:'sortBy'] = opts[:'sort_by'] if opts[:'sort_by'] query_params[:'expand'] = @api_client.build_collection_param(opts[:'expand'], :multi) if opts[:'expand'] query_params[:'nextPage'] = opts[:'next_page'] if opts[:'next_page'] query_params[:'previousPage'] = opts[:'previous_page'] if opts[:'previous_page'] query_params[:'name'] = opts[:'name'] if opts[:'name'] query_params[:'enabled'] = opts[:'enabled'] if opts[:'enabled'] query_params[:'summary'] = opts[:'summary'] if opts[:'summary'] query_params[:'hasErrors'] = opts[:'has_errors'] if opts[:'has_errors'] # 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 => 'PolicyEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_mediaretentionpolicies\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get a media retention policy # # @param policy_id Policy ID # @param [Hash] opts the optional parameters # @return [Policy] def get_recording_mediaretentionpolicy(policy_id, opts = {}) data, _status_code, _headers = get_recording_mediaretentionpolicy_with_http_info(policy_id, opts) return data end # Get a media retention policy # # @param policy_id Policy ID # @param [Hash] opts the optional parameters # @return [Array<(Policy, Fixnum, Hash)>] Policy data, response status code and response headers def get_recording_mediaretentionpolicy_with_http_info(policy_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_mediaretentionpolicy ..." end # verify the required parameter 'policy_id' is set fail ArgumentError, "Missing the required parameter 'policy_id' when calling RecordingApi.get_recording_mediaretentionpolicy" if policy_id.nil? # resource path local_var_path = "/api/v2/recording/mediaretentionpolicies/{policyId}".sub('{format}','json').sub('{' + 'policyId' + '}', policy_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 => 'Policy') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_mediaretentionpolicy\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get encryption key list # # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size Page size (default to 25) # @option opts [Integer] :page_number Page number (default to 1) # @return [EncryptionKeyEntityListing] def get_recording_recordingkeys(opts = {}) data, _status_code, _headers = get_recording_recordingkeys_with_http_info(opts) return data end # Get encryption key list # # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size Page size # @option opts [Integer] :page_number Page number # @return [Array<(EncryptionKeyEntityListing, Fixnum, Hash)>] EncryptionKeyEntityListing data, response status code and response headers def get_recording_recordingkeys_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_recordingkeys ..." end # resource path local_var_path = "/api/v2/recording/recordingkeys".sub('{format}','json') # query parameters query_params = {} 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) 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 => 'EncryptionKeyEntityListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_recordingkeys\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get key rotation schedule # # @param [Hash] opts the optional parameters # @return [KeyRotationSchedule] def get_recording_recordingkeys_rotationschedule(opts = {}) data, _status_code, _headers = get_recording_recordingkeys_rotationschedule_with_http_info(opts) return data end # Get key rotation schedule # # @param [Hash] opts the optional parameters # @return [Array<(KeyRotationSchedule, Fixnum, Hash)>] KeyRotationSchedule data, response status code and response headers def get_recording_recordingkeys_rotationschedule_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_recordingkeys_rotationschedule ..." end # resource path local_var_path = "/api/v2/recording/recordingkeys/rotationschedule".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 = 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 => 'KeyRotationSchedule') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_recordingkeys_rotationschedule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get the Recording Settings for the Organization # # @param [Hash] opts the optional parameters # @option opts [BOOLEAN] :create_default If no settings are found, a new one is created with default values (default to false) # @return [RecordingSettings] def get_recording_settings(opts = {}) data, _status_code, _headers = get_recording_settings_with_http_info(opts) return data end # Get the Recording Settings for the Organization # # @param [Hash] opts the optional parameters # @option opts [BOOLEAN] :create_default If no settings are found, a new one is created with default values # @return [Array<(RecordingSettings, Fixnum, Hash)>] RecordingSettings data, response status code and response headers def get_recording_settings_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recording_settings ..." end # resource path local_var_path = "/api/v2/recording/settings".sub('{format}','json') # query parameters query_params = {} query_params[:'createDefault'] = opts[:'create_default'] if opts[:'create_default'] # 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 => 'RecordingSettings') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recording_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Retrieves a paged listing of screen recording sessions # # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size Page size (default to 25) # @option opts [Integer] :page_number Page number (default to 1) # @return [ScreenRecordingSessionListing] def get_recordings_screensessions(opts = {}) data, _status_code, _headers = get_recordings_screensessions_with_http_info(opts) return data end # Retrieves a paged listing of screen recording sessions # # @param [Hash] opts the optional parameters # @option opts [Integer] :page_size Page size # @option opts [Integer] :page_number Page number # @return [Array<(ScreenRecordingSessionListing, Fixnum, Hash)>] ScreenRecordingSessionListing data, response status code and response headers def get_recordings_screensessions_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.get_recordings_screensessions ..." end # resource path local_var_path = "/api/v2/recordings/screensessions".sub('{format}','json') # query parameters query_params = {} 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) 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 => 'ScreenRecordingSessionListing') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#get_recordings_screensessions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Patch a media retention policy # # @param policy_id Policy ID # @param body Policy # @param [Hash] opts the optional parameters # @return [Policy] def patch_recording_mediaretentionpolicy(policy_id, body, opts = {}) data, _status_code, _headers = patch_recording_mediaretentionpolicy_with_http_info(policy_id, body, opts) return data end # Patch a media retention policy # # @param policy_id Policy ID # @param body Policy # @param [Hash] opts the optional parameters # @return [Array<(Policy, Fixnum, Hash)>] Policy data, response status code and response headers def patch_recording_mediaretentionpolicy_with_http_info(policy_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.patch_recording_mediaretentionpolicy ..." end # verify the required parameter 'policy_id' is set fail ArgumentError, "Missing the required parameter 'policy_id' when calling RecordingApi.patch_recording_mediaretentionpolicy" if policy_id.nil? # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.patch_recording_mediaretentionpolicy" if body.nil? # resource path local_var_path = "/api/v2/recording/mediaretentionpolicies/{policyId}".sub('{format}','json').sub('{' + 'policyId' + '}', policy_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 = @api_client.object_to_http_body(body) auth_names = ['PureCloud OAuth'] 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, :return_type => 'Policy') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#patch_recording_mediaretentionpolicy\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Update a screen recording session # # @param recording_session_id Screen recording session ID # @param [Hash] opts the optional parameters # @option opts [ScreenRecordingSessionRequest] :body # @return [nil] def patch_recordings_screensession(recording_session_id, opts = {}) patch_recordings_screensession_with_http_info(recording_session_id, opts) return nil end # Update a screen recording session # # @param recording_session_id Screen recording session ID # @param [Hash] opts the optional parameters # @option opts [ScreenRecordingSessionRequest] :body # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers def patch_recordings_screensession_with_http_info(recording_session_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.patch_recordings_screensession ..." end # verify the required parameter 'recording_session_id' is set fail ArgumentError, "Missing the required parameter 'recording_session_id' when calling RecordingApi.patch_recordings_screensession" if recording_session_id.nil? # resource path local_var_path = "/api/v2/recordings/screensessions/{recordingSessionId}".sub('{format}','json').sub('{' + 'recordingSessionId' + '}', recording_session_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 = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud OAuth'] 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: RecordingApi#patch_recordings_screensession\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Create annotation # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param body annotation # @param [Hash] opts the optional parameters # @return [Annotation] def post_conversation_recording_annotations(conversation_id, recording_id, body, opts = {}) data, _status_code, _headers = post_conversation_recording_annotations_with_http_info(conversation_id, recording_id, body, opts) return data end # Create annotation # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param body annotation # @param [Hash] opts the optional parameters # @return [Array<(Annotation, Fixnum, Hash)>] Annotation data, response status code and response headers def post_conversation_recording_annotations_with_http_info(conversation_id, recording_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.post_conversation_recording_annotations ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.post_conversation_recording_annotations" if conversation_id.nil? # verify the required parameter 'recording_id' is set fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.post_conversation_recording_annotations" if recording_id.nil? # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.post_conversation_recording_annotations" if body.nil? # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordings/{recordingId}/annotations".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_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 = @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 => 'Annotation') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#post_conversation_recording_annotations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Submit a batch download request for recordings. Recordings in response will be in their original format/codec - configured in the Trunk configuration. # # @param body Job submission criteria # @param [Hash] opts the optional parameters # @return [BatchDownloadJobSubmissionResult] def post_recording_batchrequests(body, opts = {}) data, _status_code, _headers = post_recording_batchrequests_with_http_info(body, opts) return data end # Submit a batch download request for recordings. Recordings in response will be in their original format/codec - configured in the Trunk configuration. # # @param body Job submission criteria # @param [Hash] opts the optional parameters # @return [Array<(BatchDownloadJobSubmissionResult, Fixnum, Hash)>] BatchDownloadJobSubmissionResult data, response status code and response headers def post_recording_batchrequests_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.post_recording_batchrequests ..." end # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.post_recording_batchrequests" if body.nil? # resource path local_var_path = "/api/v2/recording/batchrequests".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 => 'BatchDownloadJobSubmissionResult') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#post_recording_batchrequests\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Create a recording bulk job # # @param body query # @param [Hash] opts the optional parameters # @return [RecordingJob] def post_recording_jobs(body, opts = {}) data, _status_code, _headers = post_recording_jobs_with_http_info(body, opts) return data end # Create a recording bulk job # # @param body query # @param [Hash] opts the optional parameters # @return [Array<(RecordingJob, Fixnum, Hash)>] RecordingJob data, response status code and response headers def post_recording_jobs_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.post_recording_jobs ..." end # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.post_recording_jobs" if body.nil? # resource path local_var_path = "/api/v2/recording/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 => 'RecordingJob') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#post_recording_jobs\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # create a local recording key # # @param body Local Encryption body # @param [Hash] opts the optional parameters # @return [EncryptionKey] def post_recording_localkeys(body, opts = {}) data, _status_code, _headers = post_recording_localkeys_with_http_info(body, opts) return data end # create a local recording key # # @param body Local Encryption body # @param [Hash] opts the optional parameters # @return [Array<(EncryptionKey, Fixnum, Hash)>] EncryptionKey data, response status code and response headers def post_recording_localkeys_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.post_recording_localkeys ..." end # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.post_recording_localkeys" if body.nil? # resource path local_var_path = "/api/v2/recording/localkeys".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 => 'EncryptionKey') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#post_recording_localkeys\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # create settings for local key creation # # @param body Local Encryption Configuration # @param [Hash] opts the optional parameters # @return [LocalEncryptionConfiguration] def post_recording_localkeys_settings(body, opts = {}) data, _status_code, _headers = post_recording_localkeys_settings_with_http_info(body, opts) return data end # create settings for local key creation # # @param body Local Encryption Configuration # @param [Hash] opts the optional parameters # @return [Array<(LocalEncryptionConfiguration, Fixnum, Hash)>] LocalEncryptionConfiguration data, response status code and response headers def post_recording_localkeys_settings_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.post_recording_localkeys_settings ..." end # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.post_recording_localkeys_settings" if body.nil? # resource path local_var_path = "/api/v2/recording/localkeys/settings".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 => 'LocalEncryptionConfiguration') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#post_recording_localkeys_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Create media retention policy # # @param body Policy # @param [Hash] opts the optional parameters # @return [Policy] def post_recording_mediaretentionpolicies(body, opts = {}) data, _status_code, _headers = post_recording_mediaretentionpolicies_with_http_info(body, opts) return data end # Create media retention policy # # @param body Policy # @param [Hash] opts the optional parameters # @return [Array<(Policy, Fixnum, Hash)>] Policy data, response status code and response headers def post_recording_mediaretentionpolicies_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.post_recording_mediaretentionpolicies ..." end # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.post_recording_mediaretentionpolicies" if body.nil? # resource path local_var_path = "/api/v2/recording/mediaretentionpolicies".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 => 'Policy') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#post_recording_mediaretentionpolicies\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Create encryption key # # @param [Hash] opts the optional parameters # @return [EncryptionKey] def post_recording_recordingkeys(opts = {}) data, _status_code, _headers = post_recording_recordingkeys_with_http_info(opts) return data end # Create encryption key # # @param [Hash] opts the optional parameters # @return [Array<(EncryptionKey, Fixnum, Hash)>] EncryptionKey data, response status code and response headers def post_recording_recordingkeys_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.post_recording_recordingkeys ..." end # resource path local_var_path = "/api/v2/recording/recordingkeys".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 = nil 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 => 'EncryptionKey') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#post_recording_recordingkeys\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Get a list of conversations with protected recordings # # @param body conversationIds # @param [Hash] opts the optional parameters # @return [Array] def post_recordings_deletionprotection(body, opts = {}) data, _status_code, _headers = post_recordings_deletionprotection_with_http_info(body, opts) return data end # Get a list of conversations with protected recordings # # @param body conversationIds # @param [Hash] opts the optional parameters # @return [Array<(Array, Fixnum, Hash)>] Array data, response status code and response headers def post_recordings_deletionprotection_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.post_recordings_deletionprotection ..." end # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.post_recordings_deletionprotection" if body.nil? # resource path local_var_path = "/api/v2/recordings/deletionprotection".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 => 'Array') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#post_recordings_deletionprotection\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Updates the retention records on a recording. # Currently supports updating and removing both archive and delete dates for eligible recordings. A request to change the archival date of an archived recording will result in a restoration of the recording until the new date set. The recording:recording:view permission is required for the recording, as well as either the recording:recording:editRetention or recording:screenRecording:editRetention permissions depending on the type of recording. # @param conversation_id Conversation ID # @param recording_id Recording ID # @param body recording # @param [Hash] opts the optional parameters # @return [Recording] def put_conversation_recording(conversation_id, recording_id, body, opts = {}) data, _status_code, _headers = put_conversation_recording_with_http_info(conversation_id, recording_id, body, opts) return data end # Updates the retention records on a recording. # Currently supports updating and removing both archive and delete dates for eligible recordings. A request to change the archival date of an archived recording will result in a restoration of the recording until the new date set. The recording:recording:view permission is required for the recording, as well as either the recording:recording:editRetention or recording:screenRecording:editRetention permissions depending on the type of recording. # @param conversation_id Conversation ID # @param recording_id Recording ID # @param body recording # @param [Hash] opts the optional parameters # @return [Array<(Recording, Fixnum, Hash)>] Recording data, response status code and response headers def put_conversation_recording_with_http_info(conversation_id, recording_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_conversation_recording ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.put_conversation_recording" if conversation_id.nil? # verify the required parameter 'recording_id' is set fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.put_conversation_recording" if recording_id.nil? # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.put_conversation_recording" if body.nil? # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordings/{recordingId}".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_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 = @api_client.object_to_http_body(body) auth_names = ['PureCloud OAuth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Recording') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#put_conversation_recording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Update annotation # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param annotation_id Annotation ID # @param body annotation # @param [Hash] opts the optional parameters # @return [Annotation] def put_conversation_recording_annotation(conversation_id, recording_id, annotation_id, body, opts = {}) data, _status_code, _headers = put_conversation_recording_annotation_with_http_info(conversation_id, recording_id, annotation_id, body, opts) return data end # Update annotation # # @param conversation_id Conversation ID # @param recording_id Recording ID # @param annotation_id Annotation ID # @param body annotation # @param [Hash] opts the optional parameters # @return [Array<(Annotation, Fixnum, Hash)>] Annotation data, response status code and response headers def put_conversation_recording_annotation_with_http_info(conversation_id, recording_id, annotation_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_conversation_recording_annotation ..." end # verify the required parameter 'conversation_id' is set fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.put_conversation_recording_annotation" if conversation_id.nil? # verify the required parameter 'recording_id' is set fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.put_conversation_recording_annotation" if recording_id.nil? # verify the required parameter 'annotation_id' is set fail ArgumentError, "Missing the required parameter 'annotation_id' when calling RecordingApi.put_conversation_recording_annotation" if annotation_id.nil? # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.put_conversation_recording_annotation" if body.nil? # resource path local_var_path = "/api/v2/conversations/{conversationId}/recordings/{recordingId}/annotations/{annotationId}".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_id.to_s).sub('{' + 'annotationId' + '}', annotation_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 = @api_client.object_to_http_body(body) auth_names = ['PureCloud OAuth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Annotation') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#put_conversation_recording_annotation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Updates an orphan recording to a regular recording with retention values # If this operation is successful the orphan will no longer exist. It will be replaced by the resulting recording in the response. This replacement recording is accessible by the normal Recording api. # @param orphan_id Orphan ID # @param [Hash] opts the optional parameters # @option opts [OrphanUpdateRequest] :body # @return [Recording] def put_orphanrecording(orphan_id, opts = {}) data, _status_code, _headers = put_orphanrecording_with_http_info(orphan_id, opts) return data end # Updates an orphan recording to a regular recording with retention values # If this operation is successful the orphan will no longer exist. It will be replaced by the resulting recording in the response. This replacement recording is accessible by the normal Recording api. # @param orphan_id Orphan ID # @param [Hash] opts the optional parameters # @option opts [OrphanUpdateRequest] :body # @return [Array<(Recording, Fixnum, Hash)>] Recording data, response status code and response headers def put_orphanrecording_with_http_info(orphan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_orphanrecording ..." end # verify the required parameter 'orphan_id' is set fail ArgumentError, "Missing the required parameter 'orphan_id' when calling RecordingApi.put_orphanrecording" if orphan_id.nil? # resource path local_var_path = "/api/v2/orphanrecordings/{orphanId}".sub('{format}','json').sub('{' + 'orphanId' + '}', orphan_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 = @api_client.object_to_http_body(opts[:'body']) auth_names = ['PureCloud OAuth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Recording') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#put_orphanrecording\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Execute the recording bulk job. # A job must be executed by the same user whom originally created the job. In addition, the user must have permission to update the recording's retention. # @param job_id jobId # @param body query # @param [Hash] opts the optional parameters # @return [RecordingJob] def put_recording_job(job_id, body, opts = {}) data, _status_code, _headers = put_recording_job_with_http_info(job_id, body, opts) return data end # Execute the recording bulk job. # A job must be executed by the same user whom originally created the job. In addition, the user must have permission to update the recording's retention. # @param job_id jobId # @param body query # @param [Hash] opts the optional parameters # @return [Array<(RecordingJob, Fixnum, Hash)>] RecordingJob data, response status code and response headers def put_recording_job_with_http_info(job_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_recording_job ..." end # verify the required parameter 'job_id' is set fail ArgumentError, "Missing the required parameter 'job_id' when calling RecordingApi.put_recording_job" if job_id.nil? # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.put_recording_job" if body.nil? # resource path local_var_path = "/api/v2/recording/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 = @api_client.object_to_http_body(body) auth_names = ['PureCloud OAuth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'RecordingJob') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#put_recording_job\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Update the local encryption settings # # @param settings_id Settings Id # @param body Local Encryption metadata # @param [Hash] opts the optional parameters # @return [LocalEncryptionConfiguration] def put_recording_localkeys_setting(settings_id, body, opts = {}) data, _status_code, _headers = put_recording_localkeys_setting_with_http_info(settings_id, body, opts) return data end # Update the local encryption settings # # @param settings_id Settings Id # @param body Local Encryption metadata # @param [Hash] opts the optional parameters # @return [Array<(LocalEncryptionConfiguration, Fixnum, Hash)>] LocalEncryptionConfiguration data, response status code and response headers def put_recording_localkeys_setting_with_http_info(settings_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_recording_localkeys_setting ..." end # verify the required parameter 'settings_id' is set fail ArgumentError, "Missing the required parameter 'settings_id' when calling RecordingApi.put_recording_localkeys_setting" if settings_id.nil? # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.put_recording_localkeys_setting" if body.nil? # resource path local_var_path = "/api/v2/recording/localkeys/settings/{settingsId}".sub('{format}','json').sub('{' + 'settingsId' + '}', settings_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 = @api_client.object_to_http_body(body) auth_names = ['PureCloud OAuth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'LocalEncryptionConfiguration') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#put_recording_localkeys_setting\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Update a media retention policy # # @param policy_id Policy ID # @param body Policy # @param [Hash] opts the optional parameters # @return [Policy] def put_recording_mediaretentionpolicy(policy_id, body, opts = {}) data, _status_code, _headers = put_recording_mediaretentionpolicy_with_http_info(policy_id, body, opts) return data end # Update a media retention policy # # @param policy_id Policy ID # @param body Policy # @param [Hash] opts the optional parameters # @return [Array<(Policy, Fixnum, Hash)>] Policy data, response status code and response headers def put_recording_mediaretentionpolicy_with_http_info(policy_id, body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_recording_mediaretentionpolicy ..." end # verify the required parameter 'policy_id' is set fail ArgumentError, "Missing the required parameter 'policy_id' when calling RecordingApi.put_recording_mediaretentionpolicy" if policy_id.nil? # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.put_recording_mediaretentionpolicy" if body.nil? # resource path local_var_path = "/api/v2/recording/mediaretentionpolicies/{policyId}".sub('{format}','json').sub('{' + 'policyId' + '}', policy_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 = @api_client.object_to_http_body(body) auth_names = ['PureCloud OAuth'] data, status_code, headers = @api_client.call_api(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Policy') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#put_recording_mediaretentionpolicy\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Update key rotation schedule # # @param body KeyRotationSchedule # @param [Hash] opts the optional parameters # @return [KeyRotationSchedule] def put_recording_recordingkeys_rotationschedule(body, opts = {}) data, _status_code, _headers = put_recording_recordingkeys_rotationschedule_with_http_info(body, opts) return data end # Update key rotation schedule # # @param body KeyRotationSchedule # @param [Hash] opts the optional parameters # @return [Array<(KeyRotationSchedule, Fixnum, Hash)>] KeyRotationSchedule data, response status code and response headers def put_recording_recordingkeys_rotationschedule_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_recording_recordingkeys_rotationschedule ..." end # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.put_recording_recordingkeys_rotationschedule" if body.nil? # resource path local_var_path = "/api/v2/recording/recordingkeys/rotationschedule".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(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'KeyRotationSchedule') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#put_recording_recordingkeys_rotationschedule\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Update the Recording Settings for the Organization # # @param body Recording settings # @param [Hash] opts the optional parameters # @return [RecordingSettings] def put_recording_settings(body, opts = {}) data, _status_code, _headers = put_recording_settings_with_http_info(body, opts) return data end # Update the Recording Settings for the Organization # # @param body Recording settings # @param [Hash] opts the optional parameters # @return [Array<(RecordingSettings, Fixnum, Hash)>] RecordingSettings data, response status code and response headers def put_recording_settings_with_http_info(body, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_recording_settings ..." end # verify the required parameter 'body' is set fail ArgumentError, "Missing the required parameter 'body' when calling RecordingApi.put_recording_settings" if body.nil? # resource path local_var_path = "/api/v2/recording/settings".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(:PUT, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'RecordingSettings') if @api_client.config.debugging @api_client.config.logger.debug "API called: RecordingApi#put_recording_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end # Apply or revoke recording protection for conversations # # @param [Hash] opts the optional parameters # @option opts [BOOLEAN] :protect Check for apply, uncheck for revoke (each action requires the respective permission) (default to true) # @option opts [ConversationDeletionProtectionQuery] :body # @return [nil] def put_recordings_deletionprotection(opts = {}) put_recordings_deletionprotection_with_http_info(opts) return nil end # Apply or revoke recording protection for conversations # # @param [Hash] opts the optional parameters # @option opts [BOOLEAN] :protect Check for apply, uncheck for revoke (each action requires the respective permission) # @option opts [ConversationDeletionProtectionQuery] :body # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers def put_recordings_deletionprotection_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug "Calling API: RecordingApi.put_recordings_deletionprotection ..." end # resource path local_var_path = "/api/v2/recordings/deletionprotection".sub('{format}','json') # query parameters query_params = {} query_params[:'protect'] = opts[:'protect'] if opts[:'protect'] # 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(opts[:'body']) auth_names = ['PureCloud OAuth'] data, status_code, headers = @api_client.call_api(:PUT, 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: RecordingApi#put_recordings_deletionprotection\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end end end