azure_mgmt_customer_insights 0.14.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE.txt +21 -0
- data/lib/azure_mgmt_customer_insights.rb +6 -0
- data/lib/generated/azure_mgmt_customer_insights.rb +144 -0
- data/lib/generated/azure_mgmt_customer_insights/authorization_policies.rb +634 -0
- data/lib/generated/azure_mgmt_customer_insights/connector_mappings.rb +548 -0
- data/lib/generated/azure_mgmt_customer_insights/connectors.rb +606 -0
- data/lib/generated/azure_mgmt_customer_insights/customer_insights_management_client.rb +191 -0
- data/lib/generated/azure_mgmt_customer_insights/hubs.rb +841 -0
- data/lib/generated/azure_mgmt_customer_insights/images.rb +242 -0
- data/lib/generated/azure_mgmt_customer_insights/interactions.rb +591 -0
- data/lib/generated/azure_mgmt_customer_insights/kpi.rb +689 -0
- data/lib/generated/azure_mgmt_customer_insights/links.rb +565 -0
- data/lib/generated/azure_mgmt_customer_insights/models/assignment_principal.rb +71 -0
- data/lib/generated/azure_mgmt_customer_insights/models/authorization_policy.rb +87 -0
- data/lib/generated/azure_mgmt_customer_insights/models/authorization_policy_list_result.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/authorization_policy_resource_format.rb +111 -0
- data/lib/generated/azure_mgmt_customer_insights/models/azure_blob_connector_properties.rb +44 -0
- data/lib/generated/azure_mgmt_customer_insights/models/calculation_window_types.rb +19 -0
- data/lib/generated/azure_mgmt_customer_insights/models/canonical_profile_definition.rb +63 -0
- data/lib/generated/azure_mgmt_customer_insights/models/canonical_profile_definition_properties_item.rb +86 -0
- data/lib/generated/azure_mgmt_customer_insights/models/canonical_property_value_type.rb +18 -0
- data/lib/generated/azure_mgmt_customer_insights/models/cardinality_types.rb +17 -0
- data/lib/generated/azure_mgmt_customer_insights/models/completion_operation_types.rb +17 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_list_result.rb +94 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_availability.rb +56 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_complete_operation.rb +57 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_error_management.rb +57 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_format.rb +97 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_list_result.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_properties.rb +131 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_resource_format.rb +226 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_states.rb +21 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_mapping_structure.rb +74 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_resource_format.rb +183 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_states.rb +20 -0
- data/lib/generated/azure_mgmt_customer_insights/models/connector_types.rb +20 -0
- data/lib/generated/azure_mgmt_customer_insights/models/crm_connector_entities.rb +64 -0
- data/lib/generated/azure_mgmt_customer_insights/models/crm_connector_properties.rb +93 -0
- data/lib/generated/azure_mgmt_customer_insights/models/data_source_precedence.rb +102 -0
- data/lib/generated/azure_mgmt_customer_insights/models/data_source_type.rb +17 -0
- data/lib/generated/azure_mgmt_customer_insights/models/enriching_kpi.rb +229 -0
- data/lib/generated/azure_mgmt_customer_insights/models/entity_type.rb +18 -0
- data/lib/generated/azure_mgmt_customer_insights/models/entity_type_definition.rb +243 -0
- data/lib/generated/azure_mgmt_customer_insights/models/entity_types.rb +18 -0
- data/lib/generated/azure_mgmt_customer_insights/models/error_management_types.rb +17 -0
- data/lib/generated/azure_mgmt_customer_insights/models/frequency_types.rb +19 -0
- data/lib/generated/azure_mgmt_customer_insights/models/get_image_upload_url_input.rb +64 -0
- data/lib/generated/azure_mgmt_customer_insights/models/hub.rb +135 -0
- data/lib/generated/azure_mgmt_customer_insights/models/hub_billing_info_format.rb +74 -0
- data/lib/generated/azure_mgmt_customer_insights/models/hub_list_result.rb +94 -0
- data/lib/generated/azure_mgmt_customer_insights/models/image_definition.rb +64 -0
- data/lib/generated/azure_mgmt_customer_insights/models/instance_operation_type.rb +16 -0
- data/lib/generated/azure_mgmt_customer_insights/models/interaction_list_result.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/interaction_resource_format.rb +434 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_alias.rb +54 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_definition.rb +293 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_extract.rb +54 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_functions.rb +22 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_group_by_metadata.rb +71 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_list_result.rb +94 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_participant_profiles_metadata.rb +44 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_resource_format.rb +317 -0
- data/lib/generated/azure_mgmt_customer_insights/models/kpi_thresholds.rb +64 -0
- data/lib/generated/azure_mgmt_customer_insights/models/link_list_result.rb +94 -0
- data/lib/generated/azure_mgmt_customer_insights/models/link_resource_format.rb +235 -0
- data/lib/generated/azure_mgmt_customer_insights/models/link_types.rb +16 -0
- data/lib/generated/azure_mgmt_customer_insights/models/metadata_definition_base.rb +152 -0
- data/lib/generated/azure_mgmt_customer_insights/models/participant.rb +117 -0
- data/lib/generated/azure_mgmt_customer_insights/models/participant_profile_property_reference.rb +56 -0
- data/lib/generated/azure_mgmt_customer_insights/models/participant_property_reference.rb +54 -0
- data/lib/generated/azure_mgmt_customer_insights/models/permission_types.rb +17 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_distribution_definition.rb +73 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_distribution_definition_distributions_item.rb +85 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_grades_item.rb +64 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_list_result.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_mappings.rb +64 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_model_life_cycle.rb +32 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_model_status.rb +161 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_resource_format.rb +279 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_system_generated_entities.rb +85 -0
- data/lib/generated/azure_mgmt_customer_insights/models/prediction_training_results.rb +98 -0
- data/lib/generated/azure_mgmt_customer_insights/models/profile_enum_valid_values_format.rb +61 -0
- data/lib/generated/azure_mgmt_customer_insights/models/profile_list_result.rb +94 -0
- data/lib/generated/azure_mgmt_customer_insights/models/profile_resource_format.rb +312 -0
- data/lib/generated/azure_mgmt_customer_insights/models/property_definition.rb +218 -0
- data/lib/generated/azure_mgmt_customer_insights/models/provisioning_states.rb +20 -0
- data/lib/generated/azure_mgmt_customer_insights/models/proxy_resource.rb +67 -0
- data/lib/generated/azure_mgmt_customer_insights/models/relationship_link_field_mapping.rb +66 -0
- data/lib/generated/azure_mgmt_customer_insights/models/relationship_link_list_result.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/relationship_link_resource_format.rb +218 -0
- data/lib/generated/azure_mgmt_customer_insights/models/relationship_list_result.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/relationship_resource_format.rb +219 -0
- data/lib/generated/azure_mgmt_customer_insights/models/relationship_type_field_mapping.rb +55 -0
- data/lib/generated/azure_mgmt_customer_insights/models/relationship_type_mapping.rb +55 -0
- data/lib/generated/azure_mgmt_customer_insights/models/relationships_lookup.rb +107 -0
- data/lib/generated/azure_mgmt_customer_insights/models/resource.rb +94 -0
- data/lib/generated/azure_mgmt_customer_insights/models/resource_set_description.rb +69 -0
- data/lib/generated/azure_mgmt_customer_insights/models/role_assignment_list_result.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/role_assignment_resource_format.rb +306 -0
- data/lib/generated/azure_mgmt_customer_insights/models/role_list_result.rb +94 -0
- data/lib/generated/azure_mgmt_customer_insights/models/role_resource_format.rb +78 -0
- data/lib/generated/azure_mgmt_customer_insights/models/role_types.rb +20 -0
- data/lib/generated/azure_mgmt_customer_insights/models/salesforce_connector_properties.rb +63 -0
- data/lib/generated/azure_mgmt_customer_insights/models/salesforce_discover_setting.rb +44 -0
- data/lib/generated/azure_mgmt_customer_insights/models/salesforce_table.rb +84 -0
- data/lib/generated/azure_mgmt_customer_insights/models/status.rb +17 -0
- data/lib/generated/azure_mgmt_customer_insights/models/strong_id.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/suggest_relationship_links_response.rb +65 -0
- data/lib/generated/azure_mgmt_customer_insights/models/type_properties_mapping.rb +66 -0
- data/lib/generated/azure_mgmt_customer_insights/models/view_list_result.rb +94 -0
- data/lib/generated/azure_mgmt_customer_insights/models/view_resource_format.rb +139 -0
- data/lib/generated/azure_mgmt_customer_insights/models/widget_type_list_result.rb +95 -0
- data/lib/generated/azure_mgmt_customer_insights/models/widget_type_resource_format.rb +160 -0
- data/lib/generated/azure_mgmt_customer_insights/module_definition.rb +8 -0
- data/lib/generated/azure_mgmt_customer_insights/predictions.rb +896 -0
- data/lib/generated/azure_mgmt_customer_insights/profiles.rb +733 -0
- data/lib/generated/azure_mgmt_customer_insights/relationship_links.rb +610 -0
- data/lib/generated/azure_mgmt_customer_insights/relationships.rb +606 -0
- data/lib/generated/azure_mgmt_customer_insights/role_assignments.rb +566 -0
- data/lib/generated/azure_mgmt_customer_insights/roles.rb +227 -0
- data/lib/generated/azure_mgmt_customer_insights/version.rb +8 -0
- data/lib/generated/azure_mgmt_customer_insights/views.rb +530 -0
- data/lib/generated/azure_mgmt_customer_insights/widget_types.rb +323 -0
- metadata +236 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: c6edb812e075c8b9ad711e2903b0afb7196cd03e
|
4
|
+
data.tar.gz: 898d68e85f68ec4dcdf2bcb44f101d8bbef8837e
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: afbea041a2d5b28f2d87c4a2d3bcc02032d293d87512dc37de40f06e80436680f9609c80b5cf3e618d5442c65abd89c8890f3d1d4e517be13642c718c6b6ddec
|
7
|
+
data.tar.gz: 65528bf2d42d29c5ccf89ad0958d3d217c0ecc85f9e941705f19cafa321d204c5df92197dffbfc1c0ad63bd284a7f51ce598f932d3c2f29dde972ff6b2b30791
|
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2015 Microsoft Corporation
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
@@ -0,0 +1,144 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
require 'uri'
|
7
|
+
require 'cgi'
|
8
|
+
require 'date'
|
9
|
+
require 'json'
|
10
|
+
require 'base64'
|
11
|
+
require 'erb'
|
12
|
+
require 'securerandom'
|
13
|
+
require 'time'
|
14
|
+
require 'timeliness'
|
15
|
+
require 'faraday'
|
16
|
+
require 'faraday-cookie_jar'
|
17
|
+
require 'concurrent'
|
18
|
+
require 'ms_rest'
|
19
|
+
require 'generated/azure_mgmt_customer_insights/module_definition'
|
20
|
+
require 'ms_rest_azure'
|
21
|
+
|
22
|
+
module Azure::ARM::CustomerInsights
|
23
|
+
autoload :Hubs, 'generated/azure_mgmt_customer_insights/hubs.rb'
|
24
|
+
autoload :Profiles, 'generated/azure_mgmt_customer_insights/profiles.rb'
|
25
|
+
autoload :Interactions, 'generated/azure_mgmt_customer_insights/interactions.rb'
|
26
|
+
autoload :Relationships, 'generated/azure_mgmt_customer_insights/relationships.rb'
|
27
|
+
autoload :RelationshipLinks, 'generated/azure_mgmt_customer_insights/relationship_links.rb'
|
28
|
+
autoload :AuthorizationPolicies, 'generated/azure_mgmt_customer_insights/authorization_policies.rb'
|
29
|
+
autoload :Connectors, 'generated/azure_mgmt_customer_insights/connectors.rb'
|
30
|
+
autoload :ConnectorMappings, 'generated/azure_mgmt_customer_insights/connector_mappings.rb'
|
31
|
+
autoload :Kpi, 'generated/azure_mgmt_customer_insights/kpi.rb'
|
32
|
+
autoload :WidgetTypes, 'generated/azure_mgmt_customer_insights/widget_types.rb'
|
33
|
+
autoload :Views, 'generated/azure_mgmt_customer_insights/views.rb'
|
34
|
+
autoload :Links, 'generated/azure_mgmt_customer_insights/links.rb'
|
35
|
+
autoload :Roles, 'generated/azure_mgmt_customer_insights/roles.rb'
|
36
|
+
autoload :RoleAssignments, 'generated/azure_mgmt_customer_insights/role_assignments.rb'
|
37
|
+
autoload :Images, 'generated/azure_mgmt_customer_insights/images.rb'
|
38
|
+
autoload :Predictions, 'generated/azure_mgmt_customer_insights/predictions.rb'
|
39
|
+
autoload :CustomerInsightsManagementClient, 'generated/azure_mgmt_customer_insights/customer_insights_management_client.rb'
|
40
|
+
|
41
|
+
module Models
|
42
|
+
autoload :InteractionListResult, 'generated/azure_mgmt_customer_insights/models/interaction_list_result.rb'
|
43
|
+
autoload :ParticipantProfilePropertyReference, 'generated/azure_mgmt_customer_insights/models/participant_profile_property_reference.rb'
|
44
|
+
autoload :Participant, 'generated/azure_mgmt_customer_insights/models/participant.rb'
|
45
|
+
autoload :HubListResult, 'generated/azure_mgmt_customer_insights/models/hub_list_result.rb'
|
46
|
+
autoload :StrongId, 'generated/azure_mgmt_customer_insights/models/strong_id.rb'
|
47
|
+
autoload :ProfileEnumValidValuesFormat, 'generated/azure_mgmt_customer_insights/models/profile_enum_valid_values_format.rb'
|
48
|
+
autoload :DataSourcePrecedence, 'generated/azure_mgmt_customer_insights/models/data_source_precedence.rb'
|
49
|
+
autoload :PropertyDefinition, 'generated/azure_mgmt_customer_insights/models/property_definition.rb'
|
50
|
+
autoload :RelationshipsLookup, 'generated/azure_mgmt_customer_insights/models/relationships_lookup.rb'
|
51
|
+
autoload :AuthorizationPolicy, 'generated/azure_mgmt_customer_insights/models/authorization_policy.rb'
|
52
|
+
autoload :ProfileListResult, 'generated/azure_mgmt_customer_insights/models/profile_list_result.rb'
|
53
|
+
autoload :SalesforceTable, 'generated/azure_mgmt_customer_insights/models/salesforce_table.rb'
|
54
|
+
autoload :ImageDefinition, 'generated/azure_mgmt_customer_insights/models/image_definition.rb'
|
55
|
+
autoload :AzureBlobConnectorProperties, 'generated/azure_mgmt_customer_insights/models/azure_blob_connector_properties.rb'
|
56
|
+
autoload :HubBillingInfoFormat, 'generated/azure_mgmt_customer_insights/models/hub_billing_info_format.rb'
|
57
|
+
autoload :CrmConnectorProperties, 'generated/azure_mgmt_customer_insights/models/crm_connector_properties.rb'
|
58
|
+
autoload :ConnectorMappingFormat, 'generated/azure_mgmt_customer_insights/models/connector_mapping_format.rb'
|
59
|
+
autoload :KpiListResult, 'generated/azure_mgmt_customer_insights/models/kpi_list_result.rb'
|
60
|
+
autoload :ConnectorMappingStructure, 'generated/azure_mgmt_customer_insights/models/connector_mapping_structure.rb'
|
61
|
+
autoload :PredictionListResult, 'generated/azure_mgmt_customer_insights/models/prediction_list_result.rb'
|
62
|
+
autoload :ConnectorMappingProperties, 'generated/azure_mgmt_customer_insights/models/connector_mapping_properties.rb'
|
63
|
+
autoload :PredictionModelStatus, 'generated/azure_mgmt_customer_insights/models/prediction_model_status.rb'
|
64
|
+
autoload :KpiGroupByMetadata, 'generated/azure_mgmt_customer_insights/models/kpi_group_by_metadata.rb'
|
65
|
+
autoload :ConnectorListResult, 'generated/azure_mgmt_customer_insights/models/connector_list_result.rb'
|
66
|
+
autoload :KpiAlias, 'generated/azure_mgmt_customer_insights/models/kpi_alias.rb'
|
67
|
+
autoload :PredictionTrainingResults, 'generated/azure_mgmt_customer_insights/models/prediction_training_results.rb'
|
68
|
+
autoload :KpiDefinition, 'generated/azure_mgmt_customer_insights/models/kpi_definition.rb'
|
69
|
+
autoload :ConnectorMappingListResult, 'generated/azure_mgmt_customer_insights/models/connector_mapping_list_result.rb'
|
70
|
+
autoload :ProxyResource, 'generated/azure_mgmt_customer_insights/models/proxy_resource.rb'
|
71
|
+
autoload :CanonicalProfileDefinition, 'generated/azure_mgmt_customer_insights/models/canonical_profile_definition.rb'
|
72
|
+
autoload :ParticipantPropertyReference, 'generated/azure_mgmt_customer_insights/models/participant_property_reference.rb'
|
73
|
+
autoload :AuthorizationPolicyListResult, 'generated/azure_mgmt_customer_insights/models/authorization_policy_list_result.rb'
|
74
|
+
autoload :RelationshipTypeMapping, 'generated/azure_mgmt_customer_insights/models/relationship_type_mapping.rb'
|
75
|
+
autoload :CanonicalProfileDefinitionPropertiesItem, 'generated/azure_mgmt_customer_insights/models/canonical_profile_definition_properties_item.rb'
|
76
|
+
autoload :RelationshipLinkFieldMapping, 'generated/azure_mgmt_customer_insights/models/relationship_link_field_mapping.rb'
|
77
|
+
autoload :RoleListResult, 'generated/azure_mgmt_customer_insights/models/role_list_result.rb'
|
78
|
+
autoload :GetImageUploadUrlInput, 'generated/azure_mgmt_customer_insights/models/get_image_upload_url_input.rb'
|
79
|
+
autoload :LinkListResult, 'generated/azure_mgmt_customer_insights/models/link_list_result.rb'
|
80
|
+
autoload :SalesforceConnectorProperties, 'generated/azure_mgmt_customer_insights/models/salesforce_connector_properties.rb'
|
81
|
+
autoload :PredictionDistributionDefinition, 'generated/azure_mgmt_customer_insights/models/prediction_distribution_definition.rb'
|
82
|
+
autoload :ConnectorMappingErrorManagement, 'generated/azure_mgmt_customer_insights/models/connector_mapping_error_management.rb'
|
83
|
+
autoload :RelationshipListResult, 'generated/azure_mgmt_customer_insights/models/relationship_list_result.rb'
|
84
|
+
autoload :ConnectorMappingCompleteOperation, 'generated/azure_mgmt_customer_insights/models/connector_mapping_complete_operation.rb'
|
85
|
+
autoload :PredictionDistributionDefinitionDistributionsItem, 'generated/azure_mgmt_customer_insights/models/prediction_distribution_definition_distributions_item.rb'
|
86
|
+
autoload :KpiParticipantProfilesMetadata, 'generated/azure_mgmt_customer_insights/models/kpi_participant_profiles_metadata.rb'
|
87
|
+
autoload :RelationshipLinkListResult, 'generated/azure_mgmt_customer_insights/models/relationship_link_list_result.rb'
|
88
|
+
autoload :Resource, 'generated/azure_mgmt_customer_insights/models/resource.rb'
|
89
|
+
autoload :PredictionSystemGeneratedEntities, 'generated/azure_mgmt_customer_insights/models/prediction_system_generated_entities.rb'
|
90
|
+
autoload :RelationshipTypeFieldMapping, 'generated/azure_mgmt_customer_insights/models/relationship_type_field_mapping.rb'
|
91
|
+
autoload :ViewListResult, 'generated/azure_mgmt_customer_insights/models/view_list_result.rb'
|
92
|
+
autoload :SalesforceDiscoverSetting, 'generated/azure_mgmt_customer_insights/models/salesforce_discover_setting.rb'
|
93
|
+
autoload :PredictionGradesItem, 'generated/azure_mgmt_customer_insights/models/prediction_grades_item.rb'
|
94
|
+
autoload :ConnectorMappingAvailability, 'generated/azure_mgmt_customer_insights/models/connector_mapping_availability.rb'
|
95
|
+
autoload :WidgetTypeListResult, 'generated/azure_mgmt_customer_insights/models/widget_type_list_result.rb'
|
96
|
+
autoload :KpiExtract, 'generated/azure_mgmt_customer_insights/models/kpi_extract.rb'
|
97
|
+
autoload :AssignmentPrincipal, 'generated/azure_mgmt_customer_insights/models/assignment_principal.rb'
|
98
|
+
autoload :MetadataDefinitionBase, 'generated/azure_mgmt_customer_insights/models/metadata_definition_base.rb'
|
99
|
+
autoload :ResourceSetDescription, 'generated/azure_mgmt_customer_insights/models/resource_set_description.rb'
|
100
|
+
autoload :KpiThresholds, 'generated/azure_mgmt_customer_insights/models/kpi_thresholds.rb'
|
101
|
+
autoload :PredictionMappings, 'generated/azure_mgmt_customer_insights/models/prediction_mappings.rb'
|
102
|
+
autoload :CrmConnectorEntities, 'generated/azure_mgmt_customer_insights/models/crm_connector_entities.rb'
|
103
|
+
autoload :RoleAssignmentListResult, 'generated/azure_mgmt_customer_insights/models/role_assignment_list_result.rb'
|
104
|
+
autoload :TypePropertiesMapping, 'generated/azure_mgmt_customer_insights/models/type_properties_mapping.rb'
|
105
|
+
autoload :SuggestRelationshipLinksResponse, 'generated/azure_mgmt_customer_insights/models/suggest_relationship_links_response.rb'
|
106
|
+
autoload :Hub, 'generated/azure_mgmt_customer_insights/models/hub.rb'
|
107
|
+
autoload :EntityTypeDefinition, 'generated/azure_mgmt_customer_insights/models/entity_type_definition.rb'
|
108
|
+
autoload :ProfileResourceFormat, 'generated/azure_mgmt_customer_insights/models/profile_resource_format.rb'
|
109
|
+
autoload :InteractionResourceFormat, 'generated/azure_mgmt_customer_insights/models/interaction_resource_format.rb'
|
110
|
+
autoload :KpiResourceFormat, 'generated/azure_mgmt_customer_insights/models/kpi_resource_format.rb'
|
111
|
+
autoload :EnrichingKpi, 'generated/azure_mgmt_customer_insights/models/enriching_kpi.rb'
|
112
|
+
autoload :ConnectorResourceFormat, 'generated/azure_mgmt_customer_insights/models/connector_resource_format.rb'
|
113
|
+
autoload :ConnectorMappingResourceFormat, 'generated/azure_mgmt_customer_insights/models/connector_mapping_resource_format.rb'
|
114
|
+
autoload :AuthorizationPolicyResourceFormat, 'generated/azure_mgmt_customer_insights/models/authorization_policy_resource_format.rb'
|
115
|
+
autoload :LinkResourceFormat, 'generated/azure_mgmt_customer_insights/models/link_resource_format.rb'
|
116
|
+
autoload :RelationshipResourceFormat, 'generated/azure_mgmt_customer_insights/models/relationship_resource_format.rb'
|
117
|
+
autoload :RelationshipLinkResourceFormat, 'generated/azure_mgmt_customer_insights/models/relationship_link_resource_format.rb'
|
118
|
+
autoload :ViewResourceFormat, 'generated/azure_mgmt_customer_insights/models/view_resource_format.rb'
|
119
|
+
autoload :WidgetTypeResourceFormat, 'generated/azure_mgmt_customer_insights/models/widget_type_resource_format.rb'
|
120
|
+
autoload :RoleAssignmentResourceFormat, 'generated/azure_mgmt_customer_insights/models/role_assignment_resource_format.rb'
|
121
|
+
autoload :RoleResourceFormat, 'generated/azure_mgmt_customer_insights/models/role_resource_format.rb'
|
122
|
+
autoload :PredictionResourceFormat, 'generated/azure_mgmt_customer_insights/models/prediction_resource_format.rb'
|
123
|
+
autoload :EntityTypes, 'generated/azure_mgmt_customer_insights/models/entity_types.rb'
|
124
|
+
autoload :DataSourceType, 'generated/azure_mgmt_customer_insights/models/data_source_type.rb'
|
125
|
+
autoload :Status, 'generated/azure_mgmt_customer_insights/models/status.rb'
|
126
|
+
autoload :ProvisioningStates, 'generated/azure_mgmt_customer_insights/models/provisioning_states.rb'
|
127
|
+
autoload :PermissionTypes, 'generated/azure_mgmt_customer_insights/models/permission_types.rb'
|
128
|
+
autoload :ConnectorTypes, 'generated/azure_mgmt_customer_insights/models/connector_types.rb'
|
129
|
+
autoload :ConnectorStates, 'generated/azure_mgmt_customer_insights/models/connector_states.rb'
|
130
|
+
autoload :ErrorManagementTypes, 'generated/azure_mgmt_customer_insights/models/error_management_types.rb'
|
131
|
+
autoload :FrequencyTypes, 'generated/azure_mgmt_customer_insights/models/frequency_types.rb'
|
132
|
+
autoload :CompletionOperationTypes, 'generated/azure_mgmt_customer_insights/models/completion_operation_types.rb'
|
133
|
+
autoload :ConnectorMappingStates, 'generated/azure_mgmt_customer_insights/models/connector_mapping_states.rb'
|
134
|
+
autoload :CalculationWindowTypes, 'generated/azure_mgmt_customer_insights/models/calculation_window_types.rb'
|
135
|
+
autoload :KpiFunctions, 'generated/azure_mgmt_customer_insights/models/kpi_functions.rb'
|
136
|
+
autoload :EntityType, 'generated/azure_mgmt_customer_insights/models/entity_type.rb'
|
137
|
+
autoload :LinkTypes, 'generated/azure_mgmt_customer_insights/models/link_types.rb'
|
138
|
+
autoload :InstanceOperationType, 'generated/azure_mgmt_customer_insights/models/instance_operation_type.rb'
|
139
|
+
autoload :CardinalityTypes, 'generated/azure_mgmt_customer_insights/models/cardinality_types.rb'
|
140
|
+
autoload :RoleTypes, 'generated/azure_mgmt_customer_insights/models/role_types.rb'
|
141
|
+
autoload :CanonicalPropertyValueType, 'generated/azure_mgmt_customer_insights/models/canonical_property_value_type.rb'
|
142
|
+
autoload :PredictionModelLifeCycle, 'generated/azure_mgmt_customer_insights/models/prediction_model_life_cycle.rb'
|
143
|
+
end
|
144
|
+
end
|
@@ -0,0 +1,634 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::ARM::CustomerInsights
|
7
|
+
#
|
8
|
+
# The Azure Customer Insights management API provides a RESTful set of web
|
9
|
+
# services that interact with Azure Customer Insights service to manage your
|
10
|
+
# resources. The API has entities that capture the relationship between an
|
11
|
+
# end user and the Azure Customer Insights service.
|
12
|
+
#
|
13
|
+
class AuthorizationPolicies
|
14
|
+
include MsRestAzure
|
15
|
+
|
16
|
+
#
|
17
|
+
# Creates and initializes a new instance of the AuthorizationPolicies class.
|
18
|
+
# @param client service class for accessing basic functionality.
|
19
|
+
#
|
20
|
+
def initialize(client)
|
21
|
+
@client = client
|
22
|
+
end
|
23
|
+
|
24
|
+
# @return [CustomerInsightsManagementClient] reference to the CustomerInsightsManagementClient
|
25
|
+
attr_reader :client
|
26
|
+
|
27
|
+
#
|
28
|
+
# Creates an authorization policy or updates an existing authorization policy.
|
29
|
+
#
|
30
|
+
# @param resource_group_name [String] The name of the resource group.
|
31
|
+
# @param hub_name [String] The name of the hub.
|
32
|
+
# @param authorization_policy_name [String] The name of the policy.
|
33
|
+
# @param parameters [AuthorizationPolicyResourceFormat] Parameters supplied to
|
34
|
+
# the CreateOrUpdate authorization policy operation.
|
35
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
36
|
+
# will be added to the HTTP request.
|
37
|
+
#
|
38
|
+
# @return [AuthorizationPolicyResourceFormat] operation results.
|
39
|
+
#
|
40
|
+
def create_or_update(resource_group_name, hub_name, authorization_policy_name, parameters, custom_headers = nil)
|
41
|
+
response = create_or_update_async(resource_group_name, hub_name, authorization_policy_name, parameters, custom_headers).value!
|
42
|
+
response.body unless response.nil?
|
43
|
+
end
|
44
|
+
|
45
|
+
#
|
46
|
+
# Creates an authorization policy or updates an existing authorization policy.
|
47
|
+
#
|
48
|
+
# @param resource_group_name [String] The name of the resource group.
|
49
|
+
# @param hub_name [String] The name of the hub.
|
50
|
+
# @param authorization_policy_name [String] The name of the policy.
|
51
|
+
# @param parameters [AuthorizationPolicyResourceFormat] Parameters supplied to
|
52
|
+
# the CreateOrUpdate authorization policy operation.
|
53
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
54
|
+
# will be added to the HTTP request.
|
55
|
+
#
|
56
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
57
|
+
#
|
58
|
+
def create_or_update_with_http_info(resource_group_name, hub_name, authorization_policy_name, parameters, custom_headers = nil)
|
59
|
+
create_or_update_async(resource_group_name, hub_name, authorization_policy_name, parameters, custom_headers).value!
|
60
|
+
end
|
61
|
+
|
62
|
+
#
|
63
|
+
# Creates an authorization policy or updates an existing authorization policy.
|
64
|
+
#
|
65
|
+
# @param resource_group_name [String] The name of the resource group.
|
66
|
+
# @param hub_name [String] The name of the hub.
|
67
|
+
# @param authorization_policy_name [String] The name of the policy.
|
68
|
+
# @param parameters [AuthorizationPolicyResourceFormat] Parameters supplied to
|
69
|
+
# the CreateOrUpdate authorization policy operation.
|
70
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
71
|
+
# to the HTTP request.
|
72
|
+
#
|
73
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
74
|
+
#
|
75
|
+
def create_or_update_async(resource_group_name, hub_name, authorization_policy_name, parameters, custom_headers = nil)
|
76
|
+
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
77
|
+
fail ArgumentError, 'hub_name is nil' if hub_name.nil?
|
78
|
+
fail ArgumentError, 'authorization_policy_name is nil' if authorization_policy_name.nil?
|
79
|
+
fail ArgumentError, 'parameters is nil' if parameters.nil?
|
80
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
81
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
82
|
+
|
83
|
+
|
84
|
+
request_headers = {}
|
85
|
+
|
86
|
+
# Set Headers
|
87
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
88
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
89
|
+
|
90
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
91
|
+
|
92
|
+
# Serialize Request
|
93
|
+
request_mapper = Azure::ARM::CustomerInsights::Models::AuthorizationPolicyResourceFormat.mapper()
|
94
|
+
request_content = @client.serialize(request_mapper, parameters)
|
95
|
+
request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
|
96
|
+
|
97
|
+
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.CustomerInsights/hubs/{hubName}/authorizationPolicies/{authorizationPolicyName}'
|
98
|
+
|
99
|
+
request_url = @base_url || @client.base_url
|
100
|
+
|
101
|
+
options = {
|
102
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
103
|
+
path_params: {'resourceGroupName' => resource_group_name,'hubName' => hub_name,'authorizationPolicyName' => authorization_policy_name,'subscriptionId' => @client.subscription_id},
|
104
|
+
query_params: {'api-version' => @client.api_version},
|
105
|
+
body: request_content,
|
106
|
+
headers: request_headers.merge(custom_headers || {}),
|
107
|
+
base_url: request_url
|
108
|
+
}
|
109
|
+
promise = @client.make_request_async(:put, path_template, options)
|
110
|
+
|
111
|
+
promise = promise.then do |result|
|
112
|
+
http_response = result.response
|
113
|
+
status_code = http_response.status
|
114
|
+
response_content = http_response.body
|
115
|
+
unless status_code == 200 || status_code == 201
|
116
|
+
error_model = JSON.load(response_content)
|
117
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
118
|
+
end
|
119
|
+
|
120
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
121
|
+
# Deserialize Response
|
122
|
+
if status_code == 200
|
123
|
+
begin
|
124
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
125
|
+
result_mapper = Azure::ARM::CustomerInsights::Models::AuthorizationPolicyResourceFormat.mapper()
|
126
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
127
|
+
rescue Exception => e
|
128
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
129
|
+
end
|
130
|
+
end
|
131
|
+
# Deserialize Response
|
132
|
+
if status_code == 201
|
133
|
+
begin
|
134
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
135
|
+
result_mapper = Azure::ARM::CustomerInsights::Models::AuthorizationPolicyResourceFormat.mapper()
|
136
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
137
|
+
rescue Exception => e
|
138
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
139
|
+
end
|
140
|
+
end
|
141
|
+
|
142
|
+
result
|
143
|
+
end
|
144
|
+
|
145
|
+
promise.execute
|
146
|
+
end
|
147
|
+
|
148
|
+
#
|
149
|
+
# Gets an authorization policy in the hub.
|
150
|
+
#
|
151
|
+
# @param resource_group_name [String] The name of the resource group.
|
152
|
+
# @param hub_name [String] The name of the hub.
|
153
|
+
# @param authorization_policy_name [String] The name of the policy.
|
154
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
155
|
+
# will be added to the HTTP request.
|
156
|
+
#
|
157
|
+
# @return [AuthorizationPolicyResourceFormat] operation results.
|
158
|
+
#
|
159
|
+
def get(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
160
|
+
response = get_async(resource_group_name, hub_name, authorization_policy_name, custom_headers).value!
|
161
|
+
response.body unless response.nil?
|
162
|
+
end
|
163
|
+
|
164
|
+
#
|
165
|
+
# Gets an authorization policy in the hub.
|
166
|
+
#
|
167
|
+
# @param resource_group_name [String] The name of the resource group.
|
168
|
+
# @param hub_name [String] The name of the hub.
|
169
|
+
# @param authorization_policy_name [String] The name of the policy.
|
170
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
171
|
+
# will be added to the HTTP request.
|
172
|
+
#
|
173
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
174
|
+
#
|
175
|
+
def get_with_http_info(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
176
|
+
get_async(resource_group_name, hub_name, authorization_policy_name, custom_headers).value!
|
177
|
+
end
|
178
|
+
|
179
|
+
#
|
180
|
+
# Gets an authorization policy in the hub.
|
181
|
+
#
|
182
|
+
# @param resource_group_name [String] The name of the resource group.
|
183
|
+
# @param hub_name [String] The name of the hub.
|
184
|
+
# @param authorization_policy_name [String] The name of the policy.
|
185
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
186
|
+
# to the HTTP request.
|
187
|
+
#
|
188
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
189
|
+
#
|
190
|
+
def get_async(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
191
|
+
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
192
|
+
fail ArgumentError, 'hub_name is nil' if hub_name.nil?
|
193
|
+
fail ArgumentError, 'authorization_policy_name is nil' if authorization_policy_name.nil?
|
194
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
195
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
196
|
+
|
197
|
+
|
198
|
+
request_headers = {}
|
199
|
+
|
200
|
+
# Set Headers
|
201
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
202
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
203
|
+
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.CustomerInsights/hubs/{hubName}/authorizationPolicies/{authorizationPolicyName}'
|
204
|
+
|
205
|
+
request_url = @base_url || @client.base_url
|
206
|
+
|
207
|
+
options = {
|
208
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
209
|
+
path_params: {'resourceGroupName' => resource_group_name,'hubName' => hub_name,'authorizationPolicyName' => authorization_policy_name,'subscriptionId' => @client.subscription_id},
|
210
|
+
query_params: {'api-version' => @client.api_version},
|
211
|
+
headers: request_headers.merge(custom_headers || {}),
|
212
|
+
base_url: request_url
|
213
|
+
}
|
214
|
+
promise = @client.make_request_async(:get, path_template, options)
|
215
|
+
|
216
|
+
promise = promise.then do |result|
|
217
|
+
http_response = result.response
|
218
|
+
status_code = http_response.status
|
219
|
+
response_content = http_response.body
|
220
|
+
unless status_code == 200
|
221
|
+
error_model = JSON.load(response_content)
|
222
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
223
|
+
end
|
224
|
+
|
225
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
226
|
+
# Deserialize Response
|
227
|
+
if status_code == 200
|
228
|
+
begin
|
229
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
230
|
+
result_mapper = Azure::ARM::CustomerInsights::Models::AuthorizationPolicyResourceFormat.mapper()
|
231
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
232
|
+
rescue Exception => e
|
233
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
234
|
+
end
|
235
|
+
end
|
236
|
+
|
237
|
+
result
|
238
|
+
end
|
239
|
+
|
240
|
+
promise.execute
|
241
|
+
end
|
242
|
+
|
243
|
+
#
|
244
|
+
# Gets all the authorization policies in a specified hub.
|
245
|
+
#
|
246
|
+
# @param resource_group_name [String] The name of the resource group.
|
247
|
+
# @param hub_name [String] The name of the hub.
|
248
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
249
|
+
# will be added to the HTTP request.
|
250
|
+
#
|
251
|
+
# @return [Array<AuthorizationPolicyResourceFormat>] operation results.
|
252
|
+
#
|
253
|
+
def list_by_hub(resource_group_name, hub_name, custom_headers = nil)
|
254
|
+
first_page = list_by_hub_as_lazy(resource_group_name, hub_name, custom_headers)
|
255
|
+
first_page.get_all_items
|
256
|
+
end
|
257
|
+
|
258
|
+
#
|
259
|
+
# Gets all the authorization policies in a specified hub.
|
260
|
+
#
|
261
|
+
# @param resource_group_name [String] The name of the resource group.
|
262
|
+
# @param hub_name [String] The name of the hub.
|
263
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
264
|
+
# will be added to the HTTP request.
|
265
|
+
#
|
266
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
267
|
+
#
|
268
|
+
def list_by_hub_with_http_info(resource_group_name, hub_name, custom_headers = nil)
|
269
|
+
list_by_hub_async(resource_group_name, hub_name, custom_headers).value!
|
270
|
+
end
|
271
|
+
|
272
|
+
#
|
273
|
+
# Gets all the authorization policies in a specified hub.
|
274
|
+
#
|
275
|
+
# @param resource_group_name [String] The name of the resource group.
|
276
|
+
# @param hub_name [String] The name of the hub.
|
277
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
278
|
+
# to the HTTP request.
|
279
|
+
#
|
280
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
281
|
+
#
|
282
|
+
def list_by_hub_async(resource_group_name, hub_name, custom_headers = nil)
|
283
|
+
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
284
|
+
fail ArgumentError, 'hub_name is nil' if hub_name.nil?
|
285
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
286
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
287
|
+
|
288
|
+
|
289
|
+
request_headers = {}
|
290
|
+
|
291
|
+
# Set Headers
|
292
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
293
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
294
|
+
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.CustomerInsights/hubs/{hubName}/authorizationPolicies'
|
295
|
+
|
296
|
+
request_url = @base_url || @client.base_url
|
297
|
+
|
298
|
+
options = {
|
299
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
300
|
+
path_params: {'resourceGroupName' => resource_group_name,'hubName' => hub_name,'subscriptionId' => @client.subscription_id},
|
301
|
+
query_params: {'api-version' => @client.api_version},
|
302
|
+
headers: request_headers.merge(custom_headers || {}),
|
303
|
+
base_url: request_url
|
304
|
+
}
|
305
|
+
promise = @client.make_request_async(:get, path_template, options)
|
306
|
+
|
307
|
+
promise = promise.then do |result|
|
308
|
+
http_response = result.response
|
309
|
+
status_code = http_response.status
|
310
|
+
response_content = http_response.body
|
311
|
+
unless status_code == 200
|
312
|
+
error_model = JSON.load(response_content)
|
313
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
314
|
+
end
|
315
|
+
|
316
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
317
|
+
# Deserialize Response
|
318
|
+
if status_code == 200
|
319
|
+
begin
|
320
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
321
|
+
result_mapper = Azure::ARM::CustomerInsights::Models::AuthorizationPolicyListResult.mapper()
|
322
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
323
|
+
rescue Exception => e
|
324
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
325
|
+
end
|
326
|
+
end
|
327
|
+
|
328
|
+
result
|
329
|
+
end
|
330
|
+
|
331
|
+
promise.execute
|
332
|
+
end
|
333
|
+
|
334
|
+
#
|
335
|
+
# Regenerates the primary policy key of the specified authorization policy.
|
336
|
+
#
|
337
|
+
# @param resource_group_name [String] The name of the resource group.
|
338
|
+
# @param hub_name [String] The name of the hub.
|
339
|
+
# @param authorization_policy_name [String] The name of the policy.
|
340
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
341
|
+
# will be added to the HTTP request.
|
342
|
+
#
|
343
|
+
# @return [AuthorizationPolicy] operation results.
|
344
|
+
#
|
345
|
+
def regenerate_primary_key(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
346
|
+
response = regenerate_primary_key_async(resource_group_name, hub_name, authorization_policy_name, custom_headers).value!
|
347
|
+
response.body unless response.nil?
|
348
|
+
end
|
349
|
+
|
350
|
+
#
|
351
|
+
# Regenerates the primary policy key of the specified authorization policy.
|
352
|
+
#
|
353
|
+
# @param resource_group_name [String] The name of the resource group.
|
354
|
+
# @param hub_name [String] The name of the hub.
|
355
|
+
# @param authorization_policy_name [String] The name of the policy.
|
356
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
357
|
+
# will be added to the HTTP request.
|
358
|
+
#
|
359
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
360
|
+
#
|
361
|
+
def regenerate_primary_key_with_http_info(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
362
|
+
regenerate_primary_key_async(resource_group_name, hub_name, authorization_policy_name, custom_headers).value!
|
363
|
+
end
|
364
|
+
|
365
|
+
#
|
366
|
+
# Regenerates the primary policy key of the specified authorization policy.
|
367
|
+
#
|
368
|
+
# @param resource_group_name [String] The name of the resource group.
|
369
|
+
# @param hub_name [String] The name of the hub.
|
370
|
+
# @param authorization_policy_name [String] The name of the policy.
|
371
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
372
|
+
# to the HTTP request.
|
373
|
+
#
|
374
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
375
|
+
#
|
376
|
+
def regenerate_primary_key_async(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
377
|
+
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
378
|
+
fail ArgumentError, 'hub_name is nil' if hub_name.nil?
|
379
|
+
fail ArgumentError, 'authorization_policy_name is nil' if authorization_policy_name.nil?
|
380
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
381
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
382
|
+
|
383
|
+
|
384
|
+
request_headers = {}
|
385
|
+
|
386
|
+
# Set Headers
|
387
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
388
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
389
|
+
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.CustomerInsights/hubs/{hubName}/authorizationPolicies/{authorizationPolicyName}/regeneratePrimaryKey'
|
390
|
+
|
391
|
+
request_url = @base_url || @client.base_url
|
392
|
+
|
393
|
+
options = {
|
394
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
395
|
+
path_params: {'resourceGroupName' => resource_group_name,'hubName' => hub_name,'authorizationPolicyName' => authorization_policy_name,'subscriptionId' => @client.subscription_id},
|
396
|
+
query_params: {'api-version' => @client.api_version},
|
397
|
+
headers: request_headers.merge(custom_headers || {}),
|
398
|
+
base_url: request_url
|
399
|
+
}
|
400
|
+
promise = @client.make_request_async(:post, path_template, options)
|
401
|
+
|
402
|
+
promise = promise.then do |result|
|
403
|
+
http_response = result.response
|
404
|
+
status_code = http_response.status
|
405
|
+
response_content = http_response.body
|
406
|
+
unless status_code == 200
|
407
|
+
error_model = JSON.load(response_content)
|
408
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
409
|
+
end
|
410
|
+
|
411
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
412
|
+
# Deserialize Response
|
413
|
+
if status_code == 200
|
414
|
+
begin
|
415
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
416
|
+
result_mapper = Azure::ARM::CustomerInsights::Models::AuthorizationPolicy.mapper()
|
417
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
418
|
+
rescue Exception => e
|
419
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
420
|
+
end
|
421
|
+
end
|
422
|
+
|
423
|
+
result
|
424
|
+
end
|
425
|
+
|
426
|
+
promise.execute
|
427
|
+
end
|
428
|
+
|
429
|
+
#
|
430
|
+
# Regenerates the secondary policy key of the specified authorization policy.
|
431
|
+
#
|
432
|
+
# @param resource_group_name [String] The name of the resource group.
|
433
|
+
# @param hub_name [String] The name of the hub.
|
434
|
+
# @param authorization_policy_name [String] The name of the policy.
|
435
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
436
|
+
# will be added to the HTTP request.
|
437
|
+
#
|
438
|
+
# @return [AuthorizationPolicy] operation results.
|
439
|
+
#
|
440
|
+
def regenerate_secondary_key(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
441
|
+
response = regenerate_secondary_key_async(resource_group_name, hub_name, authorization_policy_name, custom_headers).value!
|
442
|
+
response.body unless response.nil?
|
443
|
+
end
|
444
|
+
|
445
|
+
#
|
446
|
+
# Regenerates the secondary policy key of the specified authorization policy.
|
447
|
+
#
|
448
|
+
# @param resource_group_name [String] The name of the resource group.
|
449
|
+
# @param hub_name [String] The name of the hub.
|
450
|
+
# @param authorization_policy_name [String] The name of the policy.
|
451
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
452
|
+
# will be added to the HTTP request.
|
453
|
+
#
|
454
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
455
|
+
#
|
456
|
+
def regenerate_secondary_key_with_http_info(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
457
|
+
regenerate_secondary_key_async(resource_group_name, hub_name, authorization_policy_name, custom_headers).value!
|
458
|
+
end
|
459
|
+
|
460
|
+
#
|
461
|
+
# Regenerates the secondary policy key of the specified authorization policy.
|
462
|
+
#
|
463
|
+
# @param resource_group_name [String] The name of the resource group.
|
464
|
+
# @param hub_name [String] The name of the hub.
|
465
|
+
# @param authorization_policy_name [String] The name of the policy.
|
466
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
467
|
+
# to the HTTP request.
|
468
|
+
#
|
469
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
470
|
+
#
|
471
|
+
def regenerate_secondary_key_async(resource_group_name, hub_name, authorization_policy_name, custom_headers = nil)
|
472
|
+
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
473
|
+
fail ArgumentError, 'hub_name is nil' if hub_name.nil?
|
474
|
+
fail ArgumentError, 'authorization_policy_name is nil' if authorization_policy_name.nil?
|
475
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
476
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
477
|
+
|
478
|
+
|
479
|
+
request_headers = {}
|
480
|
+
|
481
|
+
# Set Headers
|
482
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
483
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
484
|
+
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.CustomerInsights/hubs/{hubName}/authorizationPolicies/{authorizationPolicyName}/regenerateSecondaryKey'
|
485
|
+
|
486
|
+
request_url = @base_url || @client.base_url
|
487
|
+
|
488
|
+
options = {
|
489
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
490
|
+
path_params: {'resourceGroupName' => resource_group_name,'hubName' => hub_name,'authorizationPolicyName' => authorization_policy_name,'subscriptionId' => @client.subscription_id},
|
491
|
+
query_params: {'api-version' => @client.api_version},
|
492
|
+
headers: request_headers.merge(custom_headers || {}),
|
493
|
+
base_url: request_url
|
494
|
+
}
|
495
|
+
promise = @client.make_request_async(:post, path_template, options)
|
496
|
+
|
497
|
+
promise = promise.then do |result|
|
498
|
+
http_response = result.response
|
499
|
+
status_code = http_response.status
|
500
|
+
response_content = http_response.body
|
501
|
+
unless status_code == 200
|
502
|
+
error_model = JSON.load(response_content)
|
503
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
504
|
+
end
|
505
|
+
|
506
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
507
|
+
# Deserialize Response
|
508
|
+
if status_code == 200
|
509
|
+
begin
|
510
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
511
|
+
result_mapper = Azure::ARM::CustomerInsights::Models::AuthorizationPolicy.mapper()
|
512
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
513
|
+
rescue Exception => e
|
514
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
515
|
+
end
|
516
|
+
end
|
517
|
+
|
518
|
+
result
|
519
|
+
end
|
520
|
+
|
521
|
+
promise.execute
|
522
|
+
end
|
523
|
+
|
524
|
+
#
|
525
|
+
# Gets all the authorization policies in a specified hub.
|
526
|
+
#
|
527
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
528
|
+
# to List operation.
|
529
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
530
|
+
# will be added to the HTTP request.
|
531
|
+
#
|
532
|
+
# @return [AuthorizationPolicyListResult] operation results.
|
533
|
+
#
|
534
|
+
def list_by_hub_next(next_page_link, custom_headers = nil)
|
535
|
+
response = list_by_hub_next_async(next_page_link, custom_headers).value!
|
536
|
+
response.body unless response.nil?
|
537
|
+
end
|
538
|
+
|
539
|
+
#
|
540
|
+
# Gets all the authorization policies in a specified hub.
|
541
|
+
#
|
542
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
543
|
+
# to List operation.
|
544
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
545
|
+
# will be added to the HTTP request.
|
546
|
+
#
|
547
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
548
|
+
#
|
549
|
+
def list_by_hub_next_with_http_info(next_page_link, custom_headers = nil)
|
550
|
+
list_by_hub_next_async(next_page_link, custom_headers).value!
|
551
|
+
end
|
552
|
+
|
553
|
+
#
|
554
|
+
# Gets all the authorization policies in a specified hub.
|
555
|
+
#
|
556
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
557
|
+
# to List operation.
|
558
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
559
|
+
# to the HTTP request.
|
560
|
+
#
|
561
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
562
|
+
#
|
563
|
+
def list_by_hub_next_async(next_page_link, custom_headers = nil)
|
564
|
+
fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
|
565
|
+
|
566
|
+
|
567
|
+
request_headers = {}
|
568
|
+
|
569
|
+
# Set Headers
|
570
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
571
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
572
|
+
path_template = '{nextLink}'
|
573
|
+
|
574
|
+
request_url = @base_url || @client.base_url
|
575
|
+
|
576
|
+
options = {
|
577
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
578
|
+
skip_encoding_path_params: {'nextLink' => next_page_link},
|
579
|
+
headers: request_headers.merge(custom_headers || {}),
|
580
|
+
base_url: request_url
|
581
|
+
}
|
582
|
+
promise = @client.make_request_async(:get, path_template, options)
|
583
|
+
|
584
|
+
promise = promise.then do |result|
|
585
|
+
http_response = result.response
|
586
|
+
status_code = http_response.status
|
587
|
+
response_content = http_response.body
|
588
|
+
unless status_code == 200
|
589
|
+
error_model = JSON.load(response_content)
|
590
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
591
|
+
end
|
592
|
+
|
593
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
594
|
+
# Deserialize Response
|
595
|
+
if status_code == 200
|
596
|
+
begin
|
597
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
598
|
+
result_mapper = Azure::ARM::CustomerInsights::Models::AuthorizationPolicyListResult.mapper()
|
599
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
600
|
+
rescue Exception => e
|
601
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
602
|
+
end
|
603
|
+
end
|
604
|
+
|
605
|
+
result
|
606
|
+
end
|
607
|
+
|
608
|
+
promise.execute
|
609
|
+
end
|
610
|
+
|
611
|
+
#
|
612
|
+
# Gets all the authorization policies in a specified hub.
|
613
|
+
#
|
614
|
+
# @param resource_group_name [String] The name of the resource group.
|
615
|
+
# @param hub_name [String] The name of the hub.
|
616
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
617
|
+
# will be added to the HTTP request.
|
618
|
+
#
|
619
|
+
# @return [AuthorizationPolicyListResult] which provide lazy access to pages of
|
620
|
+
# the response.
|
621
|
+
#
|
622
|
+
def list_by_hub_as_lazy(resource_group_name, hub_name, custom_headers = nil)
|
623
|
+
response = list_by_hub_async(resource_group_name, hub_name, custom_headers).value!
|
624
|
+
unless response.nil?
|
625
|
+
page = response.body
|
626
|
+
page.next_method = Proc.new do |next_page_link|
|
627
|
+
list_by_hub_next_async(next_page_link, custom_headers)
|
628
|
+
end
|
629
|
+
page
|
630
|
+
end
|
631
|
+
end
|
632
|
+
|
633
|
+
end
|
634
|
+
end
|