purecloudplatformclientv2 15.0.0 → 16.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/docs/Action.md +21 -0
- data/docs/ActionConfig.md +14 -0
- data/docs/ActionContract.md +14 -0
- data/docs/ActionContractInput.md +14 -0
- data/docs/ActionEntityListing.md +22 -0
- data/docs/ActionInput.md +15 -0
- data/docs/ActionOutput.md +18 -0
- data/docs/ActiveAlertCount.md +13 -0
- data/docs/AggregationQuery.md +1 -1
- data/docs/AlertingApi.md +54 -0
- data/docs/ArchitectApi.md +31 -25
- data/docs/CallConversationNotificationCallMediaParticipant.md +1 -0
- data/docs/CallConversationNotificationParticipants.md +1 -0
- data/docs/CallbackConversationNotificationCallbackMediaParticipant.md +1 -0
- data/docs/CallbackConversationNotificationParticipants.md +1 -0
- data/docs/Category.md +13 -0
- data/docs/CategoryEntityListing.md +17 -0
- data/docs/ChatConversationNotificationChatMediaParticipant.md +1 -0
- data/docs/ChatConversationNotificationParticipants.md +1 -0
- data/docs/CobrowseConversationNotificationCobrowseMediaParticipant.md +1 -0
- data/docs/CobrowseConversationNotificationParticipants.md +1 -0
- data/docs/ConversationNotificationCall.md +1 -0
- data/docs/ConversationNotificationCalls.md +1 -0
- data/docs/ConversationNotificationEmail.md +1 -0
- data/docs/ConversationNotificationEmails.md +1 -0
- data/docs/ConversationNotificationParticipant.md +1 -0
- data/docs/ConversationNotificationParticipants.md +1 -0
- data/docs/ConversationsApi.md +3 -3
- data/docs/Document.md +1 -1
- data/docs/DomainOrganizationRole.md +1 -1
- data/docs/DomainOrganizationRoleCreate.md +1 -1
- data/docs/DomainOrganizationRoleUpdate.md +1 -1
- data/docs/DraftValidationResult.md +14 -0
- data/docs/EmailConversationNotificationEmailMediaParticipant.md +2 -0
- data/docs/EmailConversationNotificationParticipants.md +2 -0
- data/docs/FaxDocument.md +1 -1
- data/docs/IntegrationsApi.md +1355 -0
- data/docs/JsonNode.md +4 -4
- data/docs/ManagementUnit.md +1 -1
- data/docs/ManagementUnitListing.md +22 -0
- data/docs/OutboundApi.md +59 -0
- data/docs/PostActionInput.md +18 -0
- data/docs/PostInputContract.md +13 -0
- data/docs/PostOutputContract.md +13 -0
- data/docs/PublishDraftInput.md +13 -0
- data/docs/RecordingApi.md +123 -0
- data/docs/RequestConfig.md +17 -0
- data/docs/ResponseConfig.md +15 -0
- data/docs/ScreenShareConversationNotificationParticipants.md +1 -0
- data/docs/ScreenShareConversationNotificationScreenShareMediaParticipant.md +1 -0
- data/docs/SocialConversationNotificationParticipants.md +1 -0
- data/docs/SocialConversationNotificationSocialMediaParticipant.md +1 -0
- data/docs/TestExecutionOperationResult.md +17 -0
- data/docs/TestExecutionResult.md +16 -0
- data/docs/UpdateActionInput.md +16 -0
- data/docs/UpdateDraftInput.md +18 -0
- data/docs/VideoConversationNotificationParticipants.md +1 -0
- data/docs/VideoConversationNotificationVideoMediaParticipant.md +1 -0
- data/docs/WorkforceManagementApi.md +2 -4
- data/lib/purecloudplatformclientv2.rb +23 -1
- data/lib/purecloudplatformclientv2/api/alerting_api.rb +55 -0
- data/lib/purecloudplatformclientv2/api/architect_api.rb +52 -20
- data/lib/purecloudplatformclientv2/api/conversations_api.rb +2 -2
- data/lib/purecloudplatformclientv2/api/integrations_api.rb +1723 -0
- data/lib/purecloudplatformclientv2/api/outbound_api.rb +65 -0
- data/lib/purecloudplatformclientv2/api/recording_api.rb +140 -0
- data/lib/purecloudplatformclientv2/api/workforce_management_api.rb +3 -12
- data/lib/purecloudplatformclientv2/api_client.rb +1 -1
- data/lib/purecloudplatformclientv2/models/action.rb +409 -0
- data/lib/purecloudplatformclientv2/models/action_config.rb +229 -0
- data/lib/purecloudplatformclientv2/models/action_contract.rb +229 -0
- data/lib/purecloudplatformclientv2/models/action_contract_input.rb +239 -0
- data/lib/purecloudplatformclientv2/models/action_entity_listing.rb +428 -0
- data/lib/purecloudplatformclientv2/models/action_input.rb +255 -0
- data/lib/purecloudplatformclientv2/models/action_output.rb +333 -0
- data/lib/purecloudplatformclientv2/models/active_alert_count.rb +202 -0
- data/lib/purecloudplatformclientv2/models/aggregation_query.rb +1 -1
- data/lib/purecloudplatformclientv2/models/call_conversation_notification_call_media_participant.rb +26 -1
- data/lib/purecloudplatformclientv2/models/call_conversation_notification_participants.rb +26 -1
- data/lib/purecloudplatformclientv2/models/callback_conversation_notification_callback_media_participant.rb +26 -1
- data/lib/purecloudplatformclientv2/models/callback_conversation_notification_participants.rb +26 -1
- data/lib/purecloudplatformclientv2/models/category.rb +203 -0
- data/lib/purecloudplatformclientv2/models/category_entity_listing.rb +303 -0
- data/lib/purecloudplatformclientv2/models/chat_conversation_notification_chat_media_participant.rb +26 -1
- data/lib/purecloudplatformclientv2/models/chat_conversation_notification_participants.rb +26 -1
- data/lib/purecloudplatformclientv2/models/cobrowse_conversation_notification_cobrowse_media_participant.rb +26 -1
- data/lib/purecloudplatformclientv2/models/cobrowse_conversation_notification_participants.rb +26 -1
- data/lib/purecloudplatformclientv2/models/condition.rb +2 -2
- data/lib/purecloudplatformclientv2/models/conversation_notification_call.rb +26 -1
- data/lib/purecloudplatformclientv2/models/conversation_notification_calls.rb +26 -1
- data/lib/purecloudplatformclientv2/models/conversation_notification_email.rb +26 -1
- data/lib/purecloudplatformclientv2/models/conversation_notification_emails.rb +26 -1
- data/lib/purecloudplatformclientv2/models/conversation_notification_participant.rb +40 -1
- data/lib/purecloudplatformclientv2/models/conversation_notification_participants.rb +40 -1
- data/lib/purecloudplatformclientv2/models/dependency.rb +2 -2
- data/lib/purecloudplatformclientv2/models/dependency_object.rb +2 -2
- data/lib/purecloudplatformclientv2/models/document.rb +12 -12
- data/lib/purecloudplatformclientv2/models/domain_organization_role.rb +12 -12
- data/lib/purecloudplatformclientv2/models/domain_organization_role_create.rb +12 -12
- data/lib/purecloudplatformclientv2/models/domain_organization_role_update.rb +12 -12
- data/lib/purecloudplatformclientv2/models/draft_validation_result.rb +231 -0
- data/lib/purecloudplatformclientv2/models/email_conversation_notification_email_media_participant.rb +54 -4
- data/lib/purecloudplatformclientv2/models/email_conversation_notification_participants.rb +54 -4
- data/lib/purecloudplatformclientv2/models/fax_document.rb +12 -12
- data/lib/purecloudplatformclientv2/models/flow.rb +2 -2
- data/lib/purecloudplatformclientv2/models/interaction_stats_alert.rb +2 -2
- data/lib/purecloudplatformclientv2/models/interaction_stats_rule.rb +2 -2
- data/lib/purecloudplatformclientv2/models/json_node.rb +72 -72
- data/lib/purecloudplatformclientv2/models/management_unit.rb +7 -7
- data/lib/purecloudplatformclientv2/models/management_unit_listing.rb +428 -0
- data/lib/purecloudplatformclientv2/models/post_action_input.rb +358 -0
- data/lib/purecloudplatformclientv2/models/post_input_contract.rb +208 -0
- data/lib/purecloudplatformclientv2/models/post_output_contract.rb +208 -0
- data/lib/purecloudplatformclientv2/models/publish_draft_input.rb +208 -0
- data/lib/purecloudplatformclientv2/models/request_config.rb +309 -0
- data/lib/purecloudplatformclientv2/models/response_config.rb +257 -0
- data/lib/purecloudplatformclientv2/models/screen_share_conversation_notification_participants.rb +26 -1
- data/lib/purecloudplatformclientv2/models/screen_share_conversation_notification_screen_share_media_participant.rb +26 -1
- data/lib/purecloudplatformclientv2/models/social_conversation_notification_participants.rb +26 -1
- data/lib/purecloudplatformclientv2/models/social_conversation_notification_social_media_participant.rb +26 -1
- data/lib/purecloudplatformclientv2/models/test_execution_operation_result.rb +306 -0
- data/lib/purecloudplatformclientv2/models/test_execution_result.rb +282 -0
- data/lib/purecloudplatformclientv2/models/{publish_flow_notification_notification.rb → update_action_input.rb} +35 -26
- data/lib/purecloudplatformclientv2/models/update_draft_input.rb +338 -0
- data/lib/purecloudplatformclientv2/models/video_conversation_notification_participants.rb +26 -1
- data/lib/purecloudplatformclientv2/models/video_conversation_notification_video_media_participant.rb +26 -1
- data/lib/purecloudplatformclientv2/version.rb +1 -1
- metadata +91 -47
- data/docs/PublishFlowNotificationNotification.md +0 -16
@@ -686,6 +686,71 @@ module PureCloud
|
|
686
686
|
return data, status_code, headers
|
687
687
|
end
|
688
688
|
|
689
|
+
# Delete multiple contact lists.
|
690
|
+
#
|
691
|
+
# @param id contact list id(s) to delete
|
692
|
+
# @param [Hash] opts the optional parameters
|
693
|
+
# @return [nil]
|
694
|
+
def delete_outbound_contactlists(id, opts = {})
|
695
|
+
delete_outbound_contactlists_with_http_info(id, opts)
|
696
|
+
return nil
|
697
|
+
end
|
698
|
+
|
699
|
+
# Delete multiple contact lists.
|
700
|
+
#
|
701
|
+
# @param id contact list id(s) to delete
|
702
|
+
# @param [Hash] opts the optional parameters
|
703
|
+
# @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
|
704
|
+
def delete_outbound_contactlists_with_http_info(id, opts = {})
|
705
|
+
if @api_client.config.debugging
|
706
|
+
@api_client.config.logger.debug "Calling API: OutboundApi.delete_outbound_contactlists ..."
|
707
|
+
end
|
708
|
+
|
709
|
+
|
710
|
+
# verify the required parameter 'id' is set
|
711
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling OutboundApi.delete_outbound_contactlists" if id.nil?
|
712
|
+
|
713
|
+
|
714
|
+
|
715
|
+
|
716
|
+
|
717
|
+
# resource path
|
718
|
+
local_var_path = "/api/v2/outbound/contactlists".sub('{format}','json')
|
719
|
+
|
720
|
+
# query parameters
|
721
|
+
query_params = {}
|
722
|
+
query_params[:'id'] = @api_client.build_collection_param(id, :multi)
|
723
|
+
|
724
|
+
# header parameters
|
725
|
+
header_params = {}
|
726
|
+
|
727
|
+
# HTTP header 'Accept' (if needed)
|
728
|
+
local_header_accept = ['application/json']
|
729
|
+
local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
|
730
|
+
|
731
|
+
# HTTP header 'Content-Type'
|
732
|
+
local_header_content_type = ['application/json']
|
733
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
|
734
|
+
|
735
|
+
# form parameters
|
736
|
+
form_params = {}
|
737
|
+
|
738
|
+
# http body (model)
|
739
|
+
post_body = nil
|
740
|
+
|
741
|
+
auth_names = ['PureCloud Auth']
|
742
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
|
743
|
+
:header_params => header_params,
|
744
|
+
:query_params => query_params,
|
745
|
+
:form_params => form_params,
|
746
|
+
:body => post_body,
|
747
|
+
:auth_names => auth_names)
|
748
|
+
if @api_client.config.debugging
|
749
|
+
@api_client.config.logger.debug "API called: OutboundApi#delete_outbound_contactlists\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
750
|
+
end
|
751
|
+
return data, status_code, headers
|
752
|
+
end
|
753
|
+
|
689
754
|
# Delete dialer DNC list
|
690
755
|
#
|
691
756
|
# @param dnc_list_id DncList ID
|
@@ -568,6 +568,146 @@ module PureCloud
|
|
568
568
|
return data, status_code, headers
|
569
569
|
end
|
570
570
|
|
571
|
+
# Get recording metadata for a conversation. Does not return playable media.
|
572
|
+
#
|
573
|
+
# @param conversation_id Conversation ID
|
574
|
+
# @param [Hash] opts the optional parameters
|
575
|
+
# @return [Array<Recording>]
|
576
|
+
def get_conversation_recordingmetadata(conversation_id, opts = {})
|
577
|
+
data, _status_code, _headers = get_conversation_recordingmetadata_with_http_info(conversation_id, opts)
|
578
|
+
return data
|
579
|
+
end
|
580
|
+
|
581
|
+
# Get recording metadata for a conversation. Does not return playable media.
|
582
|
+
#
|
583
|
+
# @param conversation_id Conversation ID
|
584
|
+
# @param [Hash] opts the optional parameters
|
585
|
+
# @return [Array<(Array<Recording>, Fixnum, Hash)>] Array<Recording> data, response status code and response headers
|
586
|
+
def get_conversation_recordingmetadata_with_http_info(conversation_id, opts = {})
|
587
|
+
if @api_client.config.debugging
|
588
|
+
@api_client.config.logger.debug "Calling API: RecordingApi.get_conversation_recordingmetadata ..."
|
589
|
+
end
|
590
|
+
|
591
|
+
|
592
|
+
# verify the required parameter 'conversation_id' is set
|
593
|
+
fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.get_conversation_recordingmetadata" if conversation_id.nil?
|
594
|
+
|
595
|
+
|
596
|
+
|
597
|
+
|
598
|
+
|
599
|
+
# resource path
|
600
|
+
local_var_path = "/api/v2/conversations/{conversationId}/recordingmetadata".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s)
|
601
|
+
|
602
|
+
# query parameters
|
603
|
+
query_params = {}
|
604
|
+
|
605
|
+
# header parameters
|
606
|
+
header_params = {}
|
607
|
+
|
608
|
+
# HTTP header 'Accept' (if needed)
|
609
|
+
local_header_accept = ['application/json']
|
610
|
+
local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
|
611
|
+
|
612
|
+
# HTTP header 'Content-Type'
|
613
|
+
local_header_content_type = ['application/json']
|
614
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
|
615
|
+
|
616
|
+
# form parameters
|
617
|
+
form_params = {}
|
618
|
+
|
619
|
+
# http body (model)
|
620
|
+
post_body = nil
|
621
|
+
|
622
|
+
auth_names = ['PureCloud Auth']
|
623
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
624
|
+
:header_params => header_params,
|
625
|
+
:query_params => query_params,
|
626
|
+
:form_params => form_params,
|
627
|
+
:body => post_body,
|
628
|
+
:auth_names => auth_names,
|
629
|
+
:return_type => 'Array<Recording>')
|
630
|
+
if @api_client.config.debugging
|
631
|
+
@api_client.config.logger.debug "API called: RecordingApi#get_conversation_recordingmetadata\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
632
|
+
end
|
633
|
+
return data, status_code, headers
|
634
|
+
end
|
635
|
+
|
636
|
+
# Get metadata for a specific recording. Does not return playable media.
|
637
|
+
#
|
638
|
+
# @param conversation_id Conversation ID
|
639
|
+
# @param recording_id Recording ID
|
640
|
+
# @param [Hash] opts the optional parameters
|
641
|
+
# @return [Recording]
|
642
|
+
def get_conversation_recordingmetadata_recording_id(conversation_id, recording_id, opts = {})
|
643
|
+
data, _status_code, _headers = get_conversation_recordingmetadata_recording_id_with_http_info(conversation_id, recording_id, opts)
|
644
|
+
return data
|
645
|
+
end
|
646
|
+
|
647
|
+
# Get metadata for a specific recording. Does not return playable media.
|
648
|
+
#
|
649
|
+
# @param conversation_id Conversation ID
|
650
|
+
# @param recording_id Recording ID
|
651
|
+
# @param [Hash] opts the optional parameters
|
652
|
+
# @return [Array<(Recording, Fixnum, Hash)>] Recording data, response status code and response headers
|
653
|
+
def get_conversation_recordingmetadata_recording_id_with_http_info(conversation_id, recording_id, opts = {})
|
654
|
+
if @api_client.config.debugging
|
655
|
+
@api_client.config.logger.debug "Calling API: RecordingApi.get_conversation_recordingmetadata_recording_id ..."
|
656
|
+
end
|
657
|
+
|
658
|
+
|
659
|
+
# verify the required parameter 'conversation_id' is set
|
660
|
+
fail ArgumentError, "Missing the required parameter 'conversation_id' when calling RecordingApi.get_conversation_recordingmetadata_recording_id" if conversation_id.nil?
|
661
|
+
|
662
|
+
|
663
|
+
|
664
|
+
|
665
|
+
|
666
|
+
|
667
|
+
# verify the required parameter 'recording_id' is set
|
668
|
+
fail ArgumentError, "Missing the required parameter 'recording_id' when calling RecordingApi.get_conversation_recordingmetadata_recording_id" if recording_id.nil?
|
669
|
+
|
670
|
+
|
671
|
+
|
672
|
+
|
673
|
+
|
674
|
+
# resource path
|
675
|
+
local_var_path = "/api/v2/conversations/{conversationId}/recordingmetadata/{recordingId}".sub('{format}','json').sub('{' + 'conversationId' + '}', conversation_id.to_s).sub('{' + 'recordingId' + '}', recording_id.to_s)
|
676
|
+
|
677
|
+
# query parameters
|
678
|
+
query_params = {}
|
679
|
+
|
680
|
+
# header parameters
|
681
|
+
header_params = {}
|
682
|
+
|
683
|
+
# HTTP header 'Accept' (if needed)
|
684
|
+
local_header_accept = ['application/json']
|
685
|
+
local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
|
686
|
+
|
687
|
+
# HTTP header 'Content-Type'
|
688
|
+
local_header_content_type = ['application/json']
|
689
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
|
690
|
+
|
691
|
+
# form parameters
|
692
|
+
form_params = {}
|
693
|
+
|
694
|
+
# http body (model)
|
695
|
+
post_body = nil
|
696
|
+
|
697
|
+
auth_names = ['PureCloud Auth']
|
698
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
699
|
+
:header_params => header_params,
|
700
|
+
:query_params => query_params,
|
701
|
+
:form_params => form_params,
|
702
|
+
:body => post_body,
|
703
|
+
:auth_names => auth_names,
|
704
|
+
:return_type => 'Recording')
|
705
|
+
if @api_client.config.debugging
|
706
|
+
@api_client.config.logger.debug "API called: RecordingApi#get_conversation_recordingmetadata_recording_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
707
|
+
end
|
708
|
+
return data, status_code, headers
|
709
|
+
end
|
710
|
+
|
571
711
|
# Get all of a Conversation's Recordings.
|
572
712
|
#
|
573
713
|
# @param conversation_id Conversation ID
|
@@ -468,10 +468,9 @@ module PureCloud
|
|
468
468
|
# Get management units
|
469
469
|
#
|
470
470
|
# @param [Hash] opts the optional parameters
|
471
|
-
# @option opts [String] :selector Selector
|
472
471
|
# @option opts [Integer] :page_size (default to 25)
|
473
472
|
# @option opts [Integer] :page_number (default to 1)
|
474
|
-
# @return [
|
473
|
+
# @return [ManagementUnitListing]
|
475
474
|
def get_workforcemanagement_managementunits(opts = {})
|
476
475
|
data, _status_code, _headers = get_workforcemanagement_managementunits_with_http_info(opts)
|
477
476
|
return data
|
@@ -480,10 +479,9 @@ module PureCloud
|
|
480
479
|
# Get management units
|
481
480
|
#
|
482
481
|
# @param [Hash] opts the optional parameters
|
483
|
-
# @option opts [String] :selector Selector
|
484
482
|
# @option opts [Integer] :page_size
|
485
483
|
# @option opts [Integer] :page_number
|
486
|
-
# @return [Array<(
|
484
|
+
# @return [Array<(ManagementUnitListing, Fixnum, Hash)>] ManagementUnitListing data, response status code and response headers
|
487
485
|
def get_workforcemanagement_managementunits_with_http_info(opts = {})
|
488
486
|
if @api_client.config.debugging
|
489
487
|
@api_client.config.logger.debug "Calling API: WorkforceManagementApi.get_workforcemanagement_managementunits ..."
|
@@ -501,18 +499,11 @@ module PureCloud
|
|
501
499
|
|
502
500
|
|
503
501
|
|
504
|
-
|
505
|
-
|
506
|
-
|
507
|
-
|
508
|
-
|
509
|
-
|
510
502
|
# resource path
|
511
503
|
local_var_path = "/api/v2/workforcemanagement/managementunits".sub('{format}','json')
|
512
504
|
|
513
505
|
# query parameters
|
514
506
|
query_params = {}
|
515
|
-
query_params[:'selector'] = opts[:'selector'] if opts[:'selector']
|
516
507
|
query_params[:'pageSize'] = opts[:'page_size'] if opts[:'page_size']
|
517
508
|
query_params[:'pageNumber'] = opts[:'page_number'] if opts[:'page_number']
|
518
509
|
|
@@ -540,7 +531,7 @@ module PureCloud
|
|
540
531
|
:form_params => form_params,
|
541
532
|
:body => post_body,
|
542
533
|
:auth_names => auth_names,
|
543
|
-
:return_type => '
|
534
|
+
:return_type => 'ManagementUnitListing')
|
544
535
|
if @api_client.config.debugging
|
545
536
|
@api_client.config.logger.debug "API called: WorkforceManagementApi#get_workforcemanagement_managementunits\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
546
537
|
end
|
@@ -76,7 +76,7 @@ module PureCloud
|
|
76
76
|
http_method = http_method.to_sym.downcase
|
77
77
|
|
78
78
|
header_params = @default_headers.merge(opts[:header_params] || {})
|
79
|
-
header_params['purecloud-sdk'] = '
|
79
|
+
header_params['purecloud-sdk'] = '16.0.0'
|
80
80
|
query_params = opts[:query_params] || {}
|
81
81
|
form_params = opts[:form_params] || {}
|
82
82
|
|
@@ -0,0 +1,409 @@
|
|
1
|
+
=begin
|
2
|
+
PureCloud Platform API
|
3
|
+
|
4
|
+
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.
|
5
|
+
|
6
|
+
OpenAPI spec version: v2
|
7
|
+
Contact: DeveloperEvangelists@genesys.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
|
10
|
+
License: ININ
|
11
|
+
http://www.inin.com
|
12
|
+
|
13
|
+
Terms of Service: https://developer.mypurecloud.com/tos
|
14
|
+
|
15
|
+
=end
|
16
|
+
|
17
|
+
require 'date'
|
18
|
+
|
19
|
+
module PureCloud
|
20
|
+
class Action
|
21
|
+
# The globally unique identifier for the object.
|
22
|
+
attr_accessor :id
|
23
|
+
|
24
|
+
attr_accessor :name
|
25
|
+
|
26
|
+
# The ID of the integration for which this action is associated
|
27
|
+
attr_accessor :integration_id
|
28
|
+
|
29
|
+
# Category of Action
|
30
|
+
attr_accessor :category
|
31
|
+
|
32
|
+
# Action contract
|
33
|
+
attr_accessor :contract
|
34
|
+
|
35
|
+
# Version of this action
|
36
|
+
attr_accessor :version
|
37
|
+
|
38
|
+
# Indication of whether or not the action is designed to accept sensitive data
|
39
|
+
attr_accessor :secure
|
40
|
+
|
41
|
+
# Configuration to support request and response processing
|
42
|
+
attr_accessor :config
|
43
|
+
|
44
|
+
# The URI for this object
|
45
|
+
attr_accessor :self_uri
|
46
|
+
|
47
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
48
|
+
def self.attribute_map
|
49
|
+
{
|
50
|
+
|
51
|
+
:'id' => :'id',
|
52
|
+
|
53
|
+
:'name' => :'name',
|
54
|
+
|
55
|
+
:'integration_id' => :'integrationId',
|
56
|
+
|
57
|
+
:'category' => :'category',
|
58
|
+
|
59
|
+
:'contract' => :'contract',
|
60
|
+
|
61
|
+
:'version' => :'version',
|
62
|
+
|
63
|
+
:'secure' => :'secure',
|
64
|
+
|
65
|
+
:'config' => :'config',
|
66
|
+
|
67
|
+
:'self_uri' => :'selfUri'
|
68
|
+
|
69
|
+
}
|
70
|
+
end
|
71
|
+
|
72
|
+
# Attribute type mapping.
|
73
|
+
def self.swagger_types
|
74
|
+
{
|
75
|
+
|
76
|
+
:'id' => :'String',
|
77
|
+
|
78
|
+
:'name' => :'String',
|
79
|
+
|
80
|
+
:'integration_id' => :'String',
|
81
|
+
|
82
|
+
:'category' => :'String',
|
83
|
+
|
84
|
+
:'contract' => :'ActionContract',
|
85
|
+
|
86
|
+
:'version' => :'Integer',
|
87
|
+
|
88
|
+
:'secure' => :'BOOLEAN',
|
89
|
+
|
90
|
+
:'config' => :'ActionConfig',
|
91
|
+
|
92
|
+
:'self_uri' => :'String'
|
93
|
+
|
94
|
+
}
|
95
|
+
end
|
96
|
+
|
97
|
+
# Initializes the object
|
98
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
99
|
+
def initialize(attributes = {})
|
100
|
+
return unless attributes.is_a?(Hash)
|
101
|
+
|
102
|
+
# convert string to symbol for hash key
|
103
|
+
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
104
|
+
|
105
|
+
|
106
|
+
if attributes.has_key?(:'id')
|
107
|
+
|
108
|
+
|
109
|
+
self.id = attributes[:'id']
|
110
|
+
|
111
|
+
|
112
|
+
end
|
113
|
+
|
114
|
+
|
115
|
+
if attributes.has_key?(:'name')
|
116
|
+
|
117
|
+
|
118
|
+
self.name = attributes[:'name']
|
119
|
+
|
120
|
+
|
121
|
+
end
|
122
|
+
|
123
|
+
|
124
|
+
if attributes.has_key?(:'integrationId')
|
125
|
+
|
126
|
+
|
127
|
+
self.integration_id = attributes[:'integrationId']
|
128
|
+
|
129
|
+
|
130
|
+
end
|
131
|
+
|
132
|
+
|
133
|
+
if attributes.has_key?(:'category')
|
134
|
+
|
135
|
+
|
136
|
+
self.category = attributes[:'category']
|
137
|
+
|
138
|
+
|
139
|
+
end
|
140
|
+
|
141
|
+
|
142
|
+
if attributes.has_key?(:'contract')
|
143
|
+
|
144
|
+
|
145
|
+
self.contract = attributes[:'contract']
|
146
|
+
|
147
|
+
|
148
|
+
end
|
149
|
+
|
150
|
+
|
151
|
+
if attributes.has_key?(:'version')
|
152
|
+
|
153
|
+
|
154
|
+
self.version = attributes[:'version']
|
155
|
+
|
156
|
+
|
157
|
+
end
|
158
|
+
|
159
|
+
|
160
|
+
if attributes.has_key?(:'secure')
|
161
|
+
|
162
|
+
|
163
|
+
self.secure = attributes[:'secure']
|
164
|
+
|
165
|
+
|
166
|
+
end
|
167
|
+
|
168
|
+
|
169
|
+
if attributes.has_key?(:'config')
|
170
|
+
|
171
|
+
|
172
|
+
self.config = attributes[:'config']
|
173
|
+
|
174
|
+
|
175
|
+
end
|
176
|
+
|
177
|
+
|
178
|
+
if attributes.has_key?(:'selfUri')
|
179
|
+
|
180
|
+
|
181
|
+
self.self_uri = attributes[:'selfUri']
|
182
|
+
|
183
|
+
|
184
|
+
end
|
185
|
+
|
186
|
+
|
187
|
+
end
|
188
|
+
|
189
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
190
|
+
# @return Array for valid properies with the reasons
|
191
|
+
def list_invalid_properties
|
192
|
+
invalid_properties = Array.new
|
193
|
+
|
194
|
+
|
195
|
+
return invalid_properties
|
196
|
+
end
|
197
|
+
|
198
|
+
# Check to see if the all the properties in the model are valid
|
199
|
+
# @return true if the model is valid
|
200
|
+
def valid?
|
201
|
+
|
202
|
+
|
203
|
+
|
204
|
+
|
205
|
+
|
206
|
+
|
207
|
+
|
208
|
+
|
209
|
+
|
210
|
+
|
211
|
+
|
212
|
+
|
213
|
+
|
214
|
+
|
215
|
+
|
216
|
+
|
217
|
+
|
218
|
+
|
219
|
+
|
220
|
+
|
221
|
+
|
222
|
+
|
223
|
+
|
224
|
+
|
225
|
+
|
226
|
+
|
227
|
+
|
228
|
+
|
229
|
+
|
230
|
+
|
231
|
+
|
232
|
+
|
233
|
+
|
234
|
+
|
235
|
+
|
236
|
+
|
237
|
+
|
238
|
+
end
|
239
|
+
|
240
|
+
|
241
|
+
|
242
|
+
|
243
|
+
|
244
|
+
|
245
|
+
|
246
|
+
|
247
|
+
|
248
|
+
|
249
|
+
|
250
|
+
|
251
|
+
|
252
|
+
|
253
|
+
|
254
|
+
|
255
|
+
|
256
|
+
|
257
|
+
|
258
|
+
|
259
|
+
|
260
|
+
|
261
|
+
|
262
|
+
|
263
|
+
|
264
|
+
|
265
|
+
|
266
|
+
|
267
|
+
|
268
|
+
|
269
|
+
|
270
|
+
|
271
|
+
|
272
|
+
|
273
|
+
|
274
|
+
|
275
|
+
|
276
|
+
|
277
|
+
|
278
|
+
|
279
|
+
|
280
|
+
|
281
|
+
|
282
|
+
|
283
|
+
|
284
|
+
|
285
|
+
|
286
|
+
# Checks equality by comparing each attribute.
|
287
|
+
# @param [Object] Object to be compared
|
288
|
+
def ==(o)
|
289
|
+
return true if self.equal?(o)
|
290
|
+
self.class == o.class &&
|
291
|
+
id == o.id &&
|
292
|
+
name == o.name &&
|
293
|
+
integration_id == o.integration_id &&
|
294
|
+
category == o.category &&
|
295
|
+
contract == o.contract &&
|
296
|
+
version == o.version &&
|
297
|
+
secure == o.secure &&
|
298
|
+
config == o.config &&
|
299
|
+
self_uri == o.self_uri
|
300
|
+
end
|
301
|
+
|
302
|
+
# @see the `==` method
|
303
|
+
# @param [Object] Object to be compared
|
304
|
+
def eql?(o)
|
305
|
+
self == o
|
306
|
+
end
|
307
|
+
|
308
|
+
# Calculates hash code according to all attributes.
|
309
|
+
# @return [Fixnum] Hash code
|
310
|
+
def hash
|
311
|
+
[id, name, integration_id, category, contract, version, secure, config, self_uri].hash
|
312
|
+
end
|
313
|
+
|
314
|
+
# build the object from hash
|
315
|
+
def build_from_hash(attributes)
|
316
|
+
return nil unless attributes.is_a?(Hash)
|
317
|
+
self.class.swagger_types.each_pair do |key, type|
|
318
|
+
if type =~ /^Array<(.*)>/i
|
319
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
320
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
321
|
+
else
|
322
|
+
#TODO show warning in debug mode
|
323
|
+
end
|
324
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
325
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
326
|
+
else
|
327
|
+
# data not found in attributes(hash), not an issue as the data can be optional
|
328
|
+
end
|
329
|
+
end
|
330
|
+
|
331
|
+
self
|
332
|
+
end
|
333
|
+
|
334
|
+
def _deserialize(type, value)
|
335
|
+
case type.to_sym
|
336
|
+
when :DateTime
|
337
|
+
DateTime.parse(value)
|
338
|
+
when :Date
|
339
|
+
Date.parse(value)
|
340
|
+
when :String
|
341
|
+
value.to_s
|
342
|
+
when :Integer
|
343
|
+
value.to_i
|
344
|
+
when :Float
|
345
|
+
value.to_f
|
346
|
+
when :BOOLEAN
|
347
|
+
if value.to_s =~ /^(true|t|yes|y|1)$/i
|
348
|
+
true
|
349
|
+
else
|
350
|
+
false
|
351
|
+
end
|
352
|
+
when :Object
|
353
|
+
# generic object (usually a Hash), return directly
|
354
|
+
value
|
355
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
356
|
+
inner_type = Regexp.last_match[:inner_type]
|
357
|
+
value.map { |v| _deserialize(inner_type, v) }
|
358
|
+
when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
|
359
|
+
k_type = Regexp.last_match[:k_type]
|
360
|
+
v_type = Regexp.last_match[:v_type]
|
361
|
+
{}.tap do |hash|
|
362
|
+
value.each do |k, v|
|
363
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
364
|
+
end
|
365
|
+
end
|
366
|
+
else # model
|
367
|
+
_model = Object.const_get("PureCloud").const_get(type).new
|
368
|
+
_model.build_from_hash(value)
|
369
|
+
end
|
370
|
+
end
|
371
|
+
|
372
|
+
def to_s
|
373
|
+
to_hash.to_s
|
374
|
+
end
|
375
|
+
|
376
|
+
# to_body is an alias to to_body (backward compatibility))
|
377
|
+
def to_body
|
378
|
+
to_hash
|
379
|
+
end
|
380
|
+
|
381
|
+
# return the object in the form of hash
|
382
|
+
def to_hash
|
383
|
+
hash = {}
|
384
|
+
self.class.attribute_map.each_pair do |attr, param|
|
385
|
+
value = self.send(attr)
|
386
|
+
next if value.nil?
|
387
|
+
hash[param] = _to_hash(value)
|
388
|
+
end
|
389
|
+
hash
|
390
|
+
end
|
391
|
+
|
392
|
+
# Method to output non-array value in the form of hash
|
393
|
+
# For object, use to_hash. Otherwise, just return the value
|
394
|
+
def _to_hash(value)
|
395
|
+
if value.is_a?(Array)
|
396
|
+
value.compact.map{ |v| _to_hash(v) }
|
397
|
+
elsif value.is_a?(Hash)
|
398
|
+
{}.tap do |hash|
|
399
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
400
|
+
end
|
401
|
+
elsif value.respond_to? :to_hash
|
402
|
+
value.to_hash
|
403
|
+
else
|
404
|
+
value
|
405
|
+
end
|
406
|
+
end
|
407
|
+
|
408
|
+
end
|
409
|
+
end
|