xbim_aim 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/README.md +413 -0
- data/Rakefile +10 -0
- data/lib/xbim_aim/api/admin_api.rb +358 -0
- data/lib/xbim_aim/api/applications_api.rb +203 -0
- data/lib/xbim_aim/api/assemblies_api.rb +690 -0
- data/lib/xbim_aim/api/assets_api.rb +926 -0
- data/lib/xbim_aim/api/attributes_api.rb +789 -0
- data/lib/xbim_aim/api/component_types_api.rb +690 -0
- data/lib/xbim_aim/api/components_api.rb +803 -0
- data/lib/xbim_aim/api/contacts_api.rb +690 -0
- data/lib/xbim_aim/api/diagnostics_api.rb +109 -0
- data/lib/xbim_aim/api/document_files_api.rb +224 -0
- data/lib/xbim_aim/api/documents_api.rb +690 -0
- data/lib/xbim_aim/api/entities_api.rb +904 -0
- data/lib/xbim_aim/api/facilities_api.rb +690 -0
- data/lib/xbim_aim/api/issues_api.rb +690 -0
- data/lib/xbim_aim/api/jobs_api.rb +690 -0
- data/lib/xbim_aim/api/levels_api.rb +690 -0
- data/lib/xbim_aim/api/logs_api.rb +90 -0
- data/lib/xbim_aim/api/model_files_api.rb +219 -0
- data/lib/xbim_aim/api/model_mapping_api.rb +203 -0
- data/lib/xbim_aim/api/models_api.rb +1308 -0
- data/lib/xbim_aim/api/resources_api.rb +690 -0
- data/lib/xbim_aim/api/schedules_api.rb +496 -0
- data/lib/xbim_aim/api/sites_api.rb +690 -0
- data/lib/xbim_aim/api/spaces_api.rb +803 -0
- data/lib/xbim_aim/api/spares_api.rb +690 -0
- data/lib/xbim_aim/api/stats_api.rb +170 -0
- data/lib/xbim_aim/api/systems_api.rb +690 -0
- data/lib/xbim_aim/api/thumbnails_api.rb +182 -0
- data/lib/xbim_aim/api/wexbim_api.rb +849 -0
- data/lib/xbim_aim/api/zones_api.rb +690 -0
- data/lib/xbim_aim/api_client.rb +390 -0
- data/lib/xbim_aim/api_error.rb +57 -0
- data/lib/xbim_aim/configuration.rb +278 -0
- data/lib/xbim_aim/models/application.rb +277 -0
- data/lib/xbim_aim/models/assembly_diagnostics.rb +299 -0
- data/lib/xbim_aim/models/assembly_info.rb +308 -0
- data/lib/xbim_aim/models/assembly_item.rb +454 -0
- data/lib/xbim_aim/models/asset.rb +339 -0
- data/lib/xbim_aim/models/asset_create.rb +268 -0
- data/lib/xbim_aim/models/asset_edit.rb +263 -0
- data/lib/xbim_aim/models/asset_segment.rb +304 -0
- data/lib/xbim_aim/models/attribute_definition.rb +354 -0
- data/lib/xbim_aim/models/attribute_definition_create.rb +338 -0
- data/lib/xbim_aim/models/attribute_definition_edit.rb +288 -0
- data/lib/xbim_aim/models/attribute_definition_entity.rb +392 -0
- data/lib/xbim_aim/models/attribute_value.rb +333 -0
- data/lib/xbim_aim/models/attribute_value_entity.rb +272 -0
- data/lib/xbim_aim/models/cell.rb +236 -0
- data/lib/xbim_aim/models/classification_node.rb +254 -0
- data/lib/xbim_aim/models/column_definition.rb +297 -0
- data/lib/xbim_aim/models/complex_value_base.rb +261 -0
- data/lib/xbim_aim/models/component.rb +535 -0
- data/lib/xbim_aim/models/component_create.rb +283 -0
- data/lib/xbim_aim/models/component_edit.rb +248 -0
- data/lib/xbim_aim/models/component_info.rb +326 -0
- data/lib/xbim_aim/models/component_type.rb +498 -0
- data/lib/xbim_aim/models/component_type_info.rb +308 -0
- data/lib/xbim_aim/models/contact.rb +443 -0
- data/lib/xbim_aim/models/contact_entity.rb +333 -0
- data/lib/xbim_aim/models/contact_info.rb +308 -0
- data/lib/xbim_aim/models/db_update.rb +227 -0
- data/lib/xbim_aim/models/document.rb +421 -0
- data/lib/xbim_aim/models/document_create.rb +345 -0
- data/lib/xbim_aim/models/document_edit.rb +310 -0
- data/lib/xbim_aim/models/document_info.rb +308 -0
- data/lib/xbim_aim/models/entity.rb +421 -0
- data/lib/xbim_aim/models/entity_base.rb +308 -0
- data/lib/xbim_aim/models/entity_contact.rb +333 -0
- data/lib/xbim_aim/models/entity_create.rb +274 -0
- data/lib/xbim_aim/models/entity_edit.rb +239 -0
- data/lib/xbim_aim/models/entity_mapping_info.rb +299 -0
- data/lib/xbim_aim/models/entity_match_descriptor.rb +245 -0
- data/lib/xbim_aim/models/entity_match_info.rb +238 -0
- data/lib/xbim_aim/models/entity_ref.rb +281 -0
- data/lib/xbim_aim/models/facility.rb +432 -0
- data/lib/xbim_aim/models/facility_info.rb +308 -0
- data/lib/xbim_aim/models/file_upload_result.rb +300 -0
- data/lib/xbim_aim/models/footprint.rb +254 -0
- data/lib/xbim_aim/models/i_metered_resource.rb +254 -0
- data/lib/xbim_aim/models/ifc_type.rb +247 -0
- data/lib/xbim_aim/models/inline_object.rb +294 -0
- data/lib/xbim_aim/models/inline_object1.rb +294 -0
- data/lib/xbim_aim/models/inline_object2.rb +220 -0
- data/lib/xbim_aim/models/inline_object3.rb +223 -0
- data/lib/xbim_aim/models/inline_object4.rb +294 -0
- data/lib/xbim_aim/models/inline_object5.rb +294 -0
- data/lib/xbim_aim/models/issue.rb +443 -0
- data/lib/xbim_aim/models/issue_info.rb +308 -0
- data/lib/xbim_aim/models/job.rb +483 -0
- data/lib/xbim_aim/models/job_create.rb +283 -0
- data/lib/xbim_aim/models/job_edit.rb +248 -0
- data/lib/xbim_aim/models/job_info.rb +308 -0
- data/lib/xbim_aim/models/level.rb +463 -0
- data/lib/xbim_aim/models/level_create.rb +274 -0
- data/lib/xbim_aim/models/level_edit.rb +239 -0
- data/lib/xbim_aim/models/level_info.rb +308 -0
- data/lib/xbim_aim/models/mapping_message_info.rb +281 -0
- data/lib/xbim_aim/models/mapping_properties.rb +227 -0
- data/lib/xbim_aim/models/member_permission.rb +292 -0
- data/lib/xbim_aim/models/member_role.rb +320 -0
- data/lib/xbim_aim/models/model.rb +617 -0
- data/lib/xbim_aim/models/model_create.rb +318 -0
- data/lib/xbim_aim/models/model_edit.rb +284 -0
- data/lib/xbim_aim/models/model_info.rb +380 -0
- data/lib/xbim_aim/models/model_mapping.rb +363 -0
- data/lib/xbim_aim/models/model_mapping_report.rb +354 -0
- data/lib/xbim_aim/models/o_data_list_response_of_application.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_assembly_diagnostics.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_assembly_item.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_asset.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_attribute_definition.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_attribute_definition_entity.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_attribute_value.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_complex_value_base.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_component.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_component_type.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_contact.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_document.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_entity.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_entity_ref.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_facility.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_issue.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_job.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_level.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_member_permission.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_model.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_model_mapping.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_model_mapping_report.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_resource.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_role.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_row.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_schedule.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_site.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_space.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_spare.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_system_item.rb +247 -0
- data/lib/xbim_aim/models/o_data_list_response_of_zone.rb +247 -0
- data/lib/xbim_aim/models/o_data_response_of_boolean.rb +227 -0
- data/lib/xbim_aim/models/quota_status.rb +300 -0
- data/lib/xbim_aim/models/related_entity.rb +432 -0
- data/lib/xbim_aim/models/resource.rb +443 -0
- data/lib/xbim_aim/models/resource_info.rb +308 -0
- data/lib/xbim_aim/models/role.rb +331 -0
- data/lib/xbim_aim/models/role_member.rb +279 -0
- data/lib/xbim_aim/models/row.rb +229 -0
- data/lib/xbim_aim/models/schedule.rb +258 -0
- data/lib/xbim_aim/models/site.rb +432 -0
- data/lib/xbim_aim/models/space.rb +491 -0
- data/lib/xbim_aim/models/space_create.rb +283 -0
- data/lib/xbim_aim/models/space_edit.rb +248 -0
- data/lib/xbim_aim/models/space_info.rb +326 -0
- data/lib/xbim_aim/models/spare.rb +450 -0
- data/lib/xbim_aim/models/spare_create.rb +283 -0
- data/lib/xbim_aim/models/spare_edit.rb +248 -0
- data/lib/xbim_aim/models/spare_info.rb +308 -0
- data/lib/xbim_aim/models/system_info.rb +319 -0
- data/lib/xbim_aim/models/system_item.rb +454 -0
- data/lib/xbim_aim/models/user_permissions.rb +275 -0
- data/lib/xbim_aim/models/value_container.rb +308 -0
- data/lib/xbim_aim/models/zone.rb +454 -0
- data/lib/xbim_aim/models/zone_info.rb +308 -0
- data/lib/xbim_aim/version.rb +15 -0
- data/lib/xbim_aim.rb +197 -0
- data/spec/api/admin_api_spec.rb +95 -0
- data/spec/api/applications_api_spec.rb +71 -0
- data/spec/api/assemblies_api_spec.rb +160 -0
- data/spec/api/assets_api_spec.rb +203 -0
- data/spec/api/attributes_api_spec.rb +177 -0
- data/spec/api/component_types_api_spec.rb +160 -0
- data/spec/api/components_api_spec.rb +184 -0
- data/spec/api/contacts_api_spec.rb +160 -0
- data/spec/api/diagnostics_api_spec.rb +54 -0
- data/spec/api/document_files_api_spec.rb +69 -0
- data/spec/api/documents_api_spec.rb +160 -0
- data/spec/api/entities_api_spec.rb +203 -0
- data/spec/api/facilities_api_spec.rb +160 -0
- data/spec/api/issues_api_spec.rb +160 -0
- data/spec/api/jobs_api_spec.rb +160 -0
- data/spec/api/levels_api_spec.rb +160 -0
- data/spec/api/logs_api_spec.rb +47 -0
- data/spec/api/model_files_api_spec.rb +71 -0
- data/spec/api/model_mapping_api_spec.rb +71 -0
- data/spec/api/models_api_spec.rb +273 -0
- data/spec/api/resources_api_spec.rb +160 -0
- data/spec/api/schedules_api_spec.rb +126 -0
- data/spec/api/sites_api_spec.rb +160 -0
- data/spec/api/spaces_api_spec.rb +184 -0
- data/spec/api/spares_api_spec.rb +160 -0
- data/spec/api/stats_api_spec.rb +61 -0
- data/spec/api/systems_api_spec.rb +160 -0
- data/spec/api/thumbnails_api_spec.rb +63 -0
- data/spec/api/wexbim_api_spec.rb +175 -0
- data/spec/api/zones_api_spec.rb +160 -0
- data/spec/api_client_spec.rb +226 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/application_spec.rb +70 -0
- data/spec/models/assembly_diagnostics_spec.rb +88 -0
- data/spec/models/assembly_info_spec.rb +94 -0
- data/spec/models/assembly_item_spec.rb +178 -0
- data/spec/models/asset_create_spec.rb +44 -0
- data/spec/models/asset_edit_spec.rb +44 -0
- data/spec/models/asset_segment_spec.rb +88 -0
- data/spec/models/asset_spec.rb +92 -0
- data/spec/models/attribute_definition_create_spec.rb +78 -0
- data/spec/models/attribute_definition_edit_spec.rb +62 -0
- data/spec/models/attribute_definition_entity_spec.rb +126 -0
- data/spec/models/attribute_definition_spec.rb +102 -0
- data/spec/models/attribute_value_entity_spec.rb +70 -0
- data/spec/models/attribute_value_spec.rb +92 -0
- data/spec/models/cell_spec.rb +46 -0
- data/spec/models/classification_node_spec.rb +58 -0
- data/spec/models/column_definition_spec.rb +68 -0
- data/spec/models/complex_value_base_spec.rb +44 -0
- data/spec/models/component_create_spec.rb +70 -0
- data/spec/models/component_edit_spec.rb +52 -0
- data/spec/models/component_info_spec.rb +106 -0
- data/spec/models/component_spec.rb +226 -0
- data/spec/models/component_type_info_spec.rb +94 -0
- data/spec/models/component_type_spec.rb +202 -0
- data/spec/models/contact_entity_spec.rb +92 -0
- data/spec/models/contact_info_spec.rb +94 -0
- data/spec/models/contact_spec.rb +172 -0
- data/spec/models/db_update_spec.rb +40 -0
- data/spec/models/document_create_spec.rb +106 -0
- data/spec/models/document_edit_spec.rb +88 -0
- data/spec/models/document_info_spec.rb +94 -0
- data/spec/models/document_spec.rb +160 -0
- data/spec/models/entity_base_spec.rb +94 -0
- data/spec/models/entity_contact_spec.rb +92 -0
- data/spec/models/entity_create_spec.rb +64 -0
- data/spec/models/entity_edit_spec.rb +46 -0
- data/spec/models/entity_mapping_info_spec.rb +88 -0
- data/spec/models/entity_match_descriptor_spec.rb +52 -0
- data/spec/models/entity_match_info_spec.rb +46 -0
- data/spec/models/entity_ref_spec.rb +76 -0
- data/spec/models/entity_spec.rb +160 -0
- data/spec/models/facility_info_spec.rb +94 -0
- data/spec/models/facility_spec.rb +166 -0
- data/spec/models/file_upload_result_spec.rb +82 -0
- data/spec/models/footprint_spec.rb +58 -0
- data/spec/models/i_metered_resource_spec.rb +58 -0
- data/spec/models/ifc_type_spec.rb +52 -0
- data/spec/models/inline_object1_spec.rb +56 -0
- data/spec/models/inline_object2_spec.rb +34 -0
- data/spec/models/inline_object3_spec.rb +34 -0
- data/spec/models/inline_object4_spec.rb +56 -0
- data/spec/models/inline_object5_spec.rb +56 -0
- data/spec/models/inline_object_spec.rb +56 -0
- data/spec/models/issue_info_spec.rb +94 -0
- data/spec/models/issue_spec.rb +172 -0
- data/spec/models/job_create_spec.rb +70 -0
- data/spec/models/job_edit_spec.rb +52 -0
- data/spec/models/job_info_spec.rb +94 -0
- data/spec/models/job_spec.rb +196 -0
- data/spec/models/level_create_spec.rb +64 -0
- data/spec/models/level_edit_spec.rb +46 -0
- data/spec/models/level_info_spec.rb +94 -0
- data/spec/models/level_spec.rb +184 -0
- data/spec/models/mapping_message_info_spec.rb +76 -0
- data/spec/models/mapping_properties_spec.rb +40 -0
- data/spec/models/member_permission_spec.rb +66 -0
- data/spec/models/member_role_spec.rb +82 -0
- data/spec/models/model_create_spec.rb +68 -0
- data/spec/models/model_edit_spec.rb +56 -0
- data/spec/models/model_info_spec.rb +142 -0
- data/spec/models/model_mapping_report_spec.rb +118 -0
- data/spec/models/model_mapping_spec.rb +124 -0
- data/spec/models/model_spec.rb +260 -0
- data/spec/models/o_data_list_response_of_application_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_assembly_diagnostics_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_assembly_item_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_asset_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_attribute_definition_entity_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_attribute_definition_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_attribute_value_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_complex_value_base_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_component_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_component_type_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_contact_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_document_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_entity_ref_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_entity_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_facility_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_issue_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_job_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_level_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_member_permission_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_model_mapping_report_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_model_mapping_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_model_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_resource_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_role_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_row_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_schedule_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_site_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_space_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_spare_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_system_item_spec.rb +52 -0
- data/spec/models/o_data_list_response_of_zone_spec.rb +52 -0
- data/spec/models/o_data_response_of_boolean_spec.rb +40 -0
- data/spec/models/quota_status_spec.rb +66 -0
- data/spec/models/related_entity_spec.rb +166 -0
- data/spec/models/resource_info_spec.rb +94 -0
- data/spec/models/resource_spec.rb +172 -0
- data/spec/models/role_member_spec.rb +56 -0
- data/spec/models/role_spec.rb +88 -0
- data/spec/models/row_spec.rb +40 -0
- data/spec/models/schedule_spec.rb +58 -0
- data/spec/models/site_spec.rb +166 -0
- data/spec/models/space_create_spec.rb +70 -0
- data/spec/models/space_edit_spec.rb +52 -0
- data/spec/models/space_info_spec.rb +106 -0
- data/spec/models/space_spec.rb +202 -0
- data/spec/models/spare_create_spec.rb +70 -0
- data/spec/models/spare_edit_spec.rb +52 -0
- data/spec/models/spare_info_spec.rb +94 -0
- data/spec/models/spare_spec.rb +178 -0
- data/spec/models/system_info_spec.rb +100 -0
- data/spec/models/system_item_spec.rb +178 -0
- data/spec/models/user_permissions_spec.rb +56 -0
- data/spec/models/value_container_spec.rb +78 -0
- data/spec/models/zone_info_spec.rb +94 -0
- data/spec/models/zone_spec.rb +178 -0
- data/spec/spec_helper.rb +111 -0
- data/xbim_aim-1.0.0.gem +0 -0
- data/xbim_aim.gemspec +38 -0
- metadata +413 -0
@@ -0,0 +1,1308 @@
|
|
1
|
+
=begin
|
2
|
+
#XBIM Flex API v2
|
3
|
+
|
4
|
+
#This is the XBIM Flex Swagger service where you can explore the REST API for the platform.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 2.0
|
7
|
+
Contact: info@xbim.net
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.4.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module XbimAim
|
16
|
+
class ModelsApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# Assigns a user to the given role on the model
|
23
|
+
# <span style='font-size: 17px;'>Summary:</span>Assigns a user to the given role on the model.<br/>Return Type: <b></b><br/><br/>
|
24
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
25
|
+
# @param asset_model_id [Integer]
|
26
|
+
# @param region [String] The data center region the data resides in
|
27
|
+
# @param parameters [InlineObject4]
|
28
|
+
# @param [Hash] opts the optional parameters
|
29
|
+
# @return [nil]
|
30
|
+
def models_assign_by_tenantid_and_assetmodelid(tenant_id, asset_model_id, region, parameters, opts = {})
|
31
|
+
models_assign_by_tenantid_and_assetmodelid_with_http_info(tenant_id, asset_model_id, region, parameters, opts)
|
32
|
+
nil
|
33
|
+
end
|
34
|
+
|
35
|
+
# Assigns a user to the given role on the model
|
36
|
+
# <span style='font-size: 17px;'>Summary:</span>Assigns a user to the given role on the model.<br/>Return Type: <b></b><br/><br/>
|
37
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
38
|
+
# @param asset_model_id [Integer]
|
39
|
+
# @param region [String] The data center region the data resides in
|
40
|
+
# @param parameters [InlineObject4]
|
41
|
+
# @param [Hash] opts the optional parameters
|
42
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
43
|
+
def models_assign_by_tenantid_and_assetmodelid_with_http_info(tenant_id, asset_model_id, region, parameters, opts = {})
|
44
|
+
if @api_client.config.debugging
|
45
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_assign_by_tenantid_and_assetmodelid ...'
|
46
|
+
end
|
47
|
+
# verify the required parameter 'tenant_id' is set
|
48
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
49
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_assign_by_tenantid_and_assetmodelid"
|
50
|
+
end
|
51
|
+
# verify the required parameter 'asset_model_id' is set
|
52
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
53
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_assign_by_tenantid_and_assetmodelid"
|
54
|
+
end
|
55
|
+
# verify the required parameter 'region' is set
|
56
|
+
if @api_client.config.client_side_validation && region.nil?
|
57
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_assign_by_tenantid_and_assetmodelid"
|
58
|
+
end
|
59
|
+
# verify enum value
|
60
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
61
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
62
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
63
|
+
end
|
64
|
+
# verify the required parameter 'parameters' is set
|
65
|
+
if @api_client.config.client_side_validation && parameters.nil?
|
66
|
+
fail ArgumentError, "Missing the required parameter 'parameters' when calling ModelsApi.models_assign_by_tenantid_and_assetmodelid"
|
67
|
+
end
|
68
|
+
# resource path
|
69
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})/Roles.Assign'.sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
70
|
+
|
71
|
+
# query parameters
|
72
|
+
query_params = opts[:query_params] || {}
|
73
|
+
|
74
|
+
# header parameters
|
75
|
+
header_params = opts[:header_params] || {}
|
76
|
+
# HTTP header 'Content-Type'
|
77
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
78
|
+
if !content_type.nil?
|
79
|
+
header_params['Content-Type'] = content_type
|
80
|
+
end
|
81
|
+
|
82
|
+
# form parameters
|
83
|
+
form_params = opts[:form_params] || {}
|
84
|
+
|
85
|
+
# http body (model)
|
86
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(parameters)
|
87
|
+
|
88
|
+
# return_type
|
89
|
+
return_type = opts[:debug_return_type]
|
90
|
+
|
91
|
+
# auth_names
|
92
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
93
|
+
|
94
|
+
new_options = opts.merge(
|
95
|
+
:operation => :"ModelsApi.models_assign_by_tenantid_and_assetmodelid",
|
96
|
+
:header_params => header_params,
|
97
|
+
:query_params => query_params,
|
98
|
+
:form_params => form_params,
|
99
|
+
:body => post_body,
|
100
|
+
:auth_names => auth_names,
|
101
|
+
:return_type => return_type
|
102
|
+
)
|
103
|
+
|
104
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
105
|
+
if @api_client.config.debugging
|
106
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_assign_by_tenantid_and_assetmodelid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
107
|
+
end
|
108
|
+
return data, status_code, headers
|
109
|
+
end
|
110
|
+
|
111
|
+
# Archive a model for future deletion
|
112
|
+
# <span style='font-size: 17px;'>Summary:</span>Archive a model for future deletion.<br/>Return Type: <b></b><br/><br/>
|
113
|
+
# @param asset_model_id [Integer] key: AssetModelId
|
114
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
115
|
+
# @param region [String] The data center region the data resides in
|
116
|
+
# @param [Hash] opts the optional parameters
|
117
|
+
# @option opts [String] :if_match If-Match header
|
118
|
+
# @return [nil]
|
119
|
+
def models_delete_by_assetmodelid_and_tenantid(asset_model_id, tenant_id, region, opts = {})
|
120
|
+
models_delete_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts)
|
121
|
+
nil
|
122
|
+
end
|
123
|
+
|
124
|
+
# Archive a model for future deletion
|
125
|
+
# <span style='font-size: 17px;'>Summary:</span>Archive a model for future deletion.<br/>Return Type: <b></b><br/><br/>
|
126
|
+
# @param asset_model_id [Integer] key: AssetModelId
|
127
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
128
|
+
# @param region [String] The data center region the data resides in
|
129
|
+
# @param [Hash] opts the optional parameters
|
130
|
+
# @option opts [String] :if_match If-Match header
|
131
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
132
|
+
def models_delete_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts = {})
|
133
|
+
if @api_client.config.debugging
|
134
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_delete_by_assetmodelid_and_tenantid ...'
|
135
|
+
end
|
136
|
+
# verify the required parameter 'asset_model_id' is set
|
137
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
138
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_delete_by_assetmodelid_and_tenantid"
|
139
|
+
end
|
140
|
+
# verify the required parameter 'tenant_id' is set
|
141
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
142
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_delete_by_assetmodelid_and_tenantid"
|
143
|
+
end
|
144
|
+
# verify the required parameter 'region' is set
|
145
|
+
if @api_client.config.client_side_validation && region.nil?
|
146
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_delete_by_assetmodelid_and_tenantid"
|
147
|
+
end
|
148
|
+
# verify enum value
|
149
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
150
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
151
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
152
|
+
end
|
153
|
+
# resource path
|
154
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})'.sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
155
|
+
|
156
|
+
# query parameters
|
157
|
+
query_params = opts[:query_params] || {}
|
158
|
+
|
159
|
+
# header parameters
|
160
|
+
header_params = opts[:header_params] || {}
|
161
|
+
header_params[:'If-Match'] = opts[:'if_match'] if !opts[:'if_match'].nil?
|
162
|
+
|
163
|
+
# form parameters
|
164
|
+
form_params = opts[:form_params] || {}
|
165
|
+
|
166
|
+
# http body (model)
|
167
|
+
post_body = opts[:debug_body]
|
168
|
+
|
169
|
+
# return_type
|
170
|
+
return_type = opts[:debug_return_type]
|
171
|
+
|
172
|
+
# auth_names
|
173
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
174
|
+
|
175
|
+
new_options = opts.merge(
|
176
|
+
:operation => :"ModelsApi.models_delete_by_assetmodelid_and_tenantid",
|
177
|
+
:header_params => header_params,
|
178
|
+
:query_params => query_params,
|
179
|
+
:form_params => form_params,
|
180
|
+
:body => post_body,
|
181
|
+
:auth_names => auth_names,
|
182
|
+
:return_type => return_type
|
183
|
+
)
|
184
|
+
|
185
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
186
|
+
if @api_client.config.debugging
|
187
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_delete_by_assetmodelid_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
188
|
+
end
|
189
|
+
return data, status_code, headers
|
190
|
+
end
|
191
|
+
|
192
|
+
# Generates a model mappings between two distinct models
|
193
|
+
# <span style='font-size: 17px;'>Summary:</span>Generates a model mappings between two distinct models.<br/>Return Type: <b>ODataListResponseOfModelMappingReport</b><br/>For more information about OData responses <a href='https://www.odata.org/getting-started/understand-odata-in-6-steps/'>link</a>.<br/><br/>
|
194
|
+
# @param asset_model_id [Integer] The model ID to baseline
|
195
|
+
# @param target_model_id [Integer] The latest Model ID to compare against
|
196
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
197
|
+
# @param region [String] The data center region the data resides in
|
198
|
+
# @param [Hash] opts the optional parameters
|
199
|
+
# @option opts [String] :expand Expands related entities inline.
|
200
|
+
# @option opts [String] :filter Filters the results, based on a Boolean condition.
|
201
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
202
|
+
# @option opts [String] :orderby Sorts the results.
|
203
|
+
# @option opts [Integer] :top Returns only the first n results.
|
204
|
+
# @option opts [Integer] :skip Skips the first n results.
|
205
|
+
# @option opts [Boolean] :count Includes a count of the matching results in the response.
|
206
|
+
# @return [ODataListResponseOfModelMappingReport]
|
207
|
+
def models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid(asset_model_id, target_model_id, tenant_id, region, opts = {})
|
208
|
+
data, _status_code, _headers = models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid_with_http_info(asset_model_id, target_model_id, tenant_id, region, opts)
|
209
|
+
data
|
210
|
+
end
|
211
|
+
|
212
|
+
# Generates a model mappings between two distinct models
|
213
|
+
# <span style='font-size: 17px;'>Summary:</span>Generates a model mappings between two distinct models.<br/>Return Type: <b>ODataListResponseOfModelMappingReport</b><br/>For more information about OData responses <a href='https://www.odata.org/getting-started/understand-odata-in-6-steps/'>link</a>.<br/><br/>
|
214
|
+
# @param asset_model_id [Integer] The model ID to baseline
|
215
|
+
# @param target_model_id [Integer] The latest Model ID to compare against
|
216
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
217
|
+
# @param region [String] The data center region the data resides in
|
218
|
+
# @param [Hash] opts the optional parameters
|
219
|
+
# @option opts [String] :expand Expands related entities inline.
|
220
|
+
# @option opts [String] :filter Filters the results, based on a Boolean condition.
|
221
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
222
|
+
# @option opts [String] :orderby Sorts the results.
|
223
|
+
# @option opts [Integer] :top Returns only the first n results.
|
224
|
+
# @option opts [Integer] :skip Skips the first n results.
|
225
|
+
# @option opts [Boolean] :count Includes a count of the matching results in the response.
|
226
|
+
# @return [Array<(ODataListResponseOfModelMappingReport, Integer, Hash)>] ODataListResponseOfModelMappingReport data, response status code and response headers
|
227
|
+
def models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid_with_http_info(asset_model_id, target_model_id, tenant_id, region, opts = {})
|
228
|
+
if @api_client.config.debugging
|
229
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid ...'
|
230
|
+
end
|
231
|
+
# verify the required parameter 'asset_model_id' is set
|
232
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
233
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid"
|
234
|
+
end
|
235
|
+
# verify the required parameter 'target_model_id' is set
|
236
|
+
if @api_client.config.client_side_validation && target_model_id.nil?
|
237
|
+
fail ArgumentError, "Missing the required parameter 'target_model_id' when calling ModelsApi.models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid"
|
238
|
+
end
|
239
|
+
# verify the required parameter 'tenant_id' is set
|
240
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
241
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid"
|
242
|
+
end
|
243
|
+
# verify the required parameter 'region' is set
|
244
|
+
if @api_client.config.client_side_validation && region.nil?
|
245
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid"
|
246
|
+
end
|
247
|
+
# verify enum value
|
248
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
249
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
250
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
251
|
+
end
|
252
|
+
# resource path
|
253
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})/GenerateModelMapping(id={targetModelId})'.sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'targetModelId' + '}', CGI.escape(target_model_id.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
254
|
+
|
255
|
+
# query parameters
|
256
|
+
query_params = opts[:query_params] || {}
|
257
|
+
query_params[:'$expand'] = opts[:'expand'] if !opts[:'expand'].nil?
|
258
|
+
query_params[:'$filter'] = opts[:'filter'] if !opts[:'filter'].nil?
|
259
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
260
|
+
query_params[:'$orderby'] = opts[:'orderby'] if !opts[:'orderby'].nil?
|
261
|
+
query_params[:'$top'] = opts[:'top'] if !opts[:'top'].nil?
|
262
|
+
query_params[:'$skip'] = opts[:'skip'] if !opts[:'skip'].nil?
|
263
|
+
query_params[:'$count'] = opts[:'count'] if !opts[:'count'].nil?
|
264
|
+
|
265
|
+
# header parameters
|
266
|
+
header_params = opts[:header_params] || {}
|
267
|
+
# HTTP header 'Accept' (if needed)
|
268
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/json;odata.metadata=none', 'application/json;odata.metadata=minimal', 'application/json;odata.metadata=full', 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'])
|
269
|
+
|
270
|
+
# form parameters
|
271
|
+
form_params = opts[:form_params] || {}
|
272
|
+
|
273
|
+
# http body (model)
|
274
|
+
post_body = opts[:debug_body]
|
275
|
+
|
276
|
+
# return_type
|
277
|
+
return_type = opts[:debug_return_type] || 'ODataListResponseOfModelMappingReport'
|
278
|
+
|
279
|
+
# auth_names
|
280
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
281
|
+
|
282
|
+
new_options = opts.merge(
|
283
|
+
:operation => :"ModelsApi.models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid",
|
284
|
+
:header_params => header_params,
|
285
|
+
:query_params => query_params,
|
286
|
+
:form_params => form_params,
|
287
|
+
:body => post_body,
|
288
|
+
:auth_names => auth_names,
|
289
|
+
:return_type => return_type
|
290
|
+
)
|
291
|
+
|
292
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
293
|
+
if @api_client.config.debugging
|
294
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_generate_model_mapping_by_assetmodelid_and_targetmodelid_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
295
|
+
end
|
296
|
+
return data, status_code, headers
|
297
|
+
end
|
298
|
+
|
299
|
+
# Returns the EntitySet Models
|
300
|
+
# <span style='font-size: 17px;'>Summary:</span>Returns the EntitySet Models.<br/>Return Type: <b>ODataListResponseOfModel</b><br/>For more information about OData responses <a href='https://www.odata.org/getting-started/understand-odata-in-6-steps/'>link</a>.<br/><br/>
|
301
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
302
|
+
# @param region [String] The data center region the data resides in
|
303
|
+
# @param [Hash] opts the optional parameters
|
304
|
+
# @option opts [String] :expand Expands related entities inline.
|
305
|
+
# @option opts [String] :filter Filters the results, based on a Boolean condition.
|
306
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
307
|
+
# @option opts [String] :orderby Sorts the results.
|
308
|
+
# @option opts [Integer] :top Returns only the first n results.
|
309
|
+
# @option opts [Integer] :skip Skips the first n results.
|
310
|
+
# @option opts [Boolean] :count Includes a count of the matching results in the response.
|
311
|
+
# @return [ODataListResponseOfModel]
|
312
|
+
def models_get_by_tenantid(tenant_id, region, opts = {})
|
313
|
+
data, _status_code, _headers = models_get_by_tenantid_with_http_info(tenant_id, region, opts)
|
314
|
+
data
|
315
|
+
end
|
316
|
+
|
317
|
+
# Returns the EntitySet Models
|
318
|
+
# <span style='font-size: 17px;'>Summary:</span>Returns the EntitySet Models.<br/>Return Type: <b>ODataListResponseOfModel</b><br/>For more information about OData responses <a href='https://www.odata.org/getting-started/understand-odata-in-6-steps/'>link</a>.<br/><br/>
|
319
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
320
|
+
# @param region [String] The data center region the data resides in
|
321
|
+
# @param [Hash] opts the optional parameters
|
322
|
+
# @option opts [String] :expand Expands related entities inline.
|
323
|
+
# @option opts [String] :filter Filters the results, based on a Boolean condition.
|
324
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
325
|
+
# @option opts [String] :orderby Sorts the results.
|
326
|
+
# @option opts [Integer] :top Returns only the first n results.
|
327
|
+
# @option opts [Integer] :skip Skips the first n results.
|
328
|
+
# @option opts [Boolean] :count Includes a count of the matching results in the response.
|
329
|
+
# @return [Array<(ODataListResponseOfModel, Integer, Hash)>] ODataListResponseOfModel data, response status code and response headers
|
330
|
+
def models_get_by_tenantid_with_http_info(tenant_id, region, opts = {})
|
331
|
+
if @api_client.config.debugging
|
332
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_get_by_tenantid ...'
|
333
|
+
end
|
334
|
+
# verify the required parameter 'tenant_id' is set
|
335
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
336
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_get_by_tenantid"
|
337
|
+
end
|
338
|
+
# verify the required parameter 'region' is set
|
339
|
+
if @api_client.config.client_side_validation && region.nil?
|
340
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_get_by_tenantid"
|
341
|
+
end
|
342
|
+
# verify enum value
|
343
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
344
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
345
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
346
|
+
end
|
347
|
+
# resource path
|
348
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models'.sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
349
|
+
|
350
|
+
# query parameters
|
351
|
+
query_params = opts[:query_params] || {}
|
352
|
+
query_params[:'$expand'] = opts[:'expand'] if !opts[:'expand'].nil?
|
353
|
+
query_params[:'$filter'] = opts[:'filter'] if !opts[:'filter'].nil?
|
354
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
355
|
+
query_params[:'$orderby'] = opts[:'orderby'] if !opts[:'orderby'].nil?
|
356
|
+
query_params[:'$top'] = opts[:'top'] if !opts[:'top'].nil?
|
357
|
+
query_params[:'$skip'] = opts[:'skip'] if !opts[:'skip'].nil?
|
358
|
+
query_params[:'$count'] = opts[:'count'] if !opts[:'count'].nil?
|
359
|
+
|
360
|
+
# header parameters
|
361
|
+
header_params = opts[:header_params] || {}
|
362
|
+
# HTTP header 'Accept' (if needed)
|
363
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/json;odata.metadata=none', 'application/json;odata.metadata=minimal', 'application/json;odata.metadata=full', 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'])
|
364
|
+
|
365
|
+
# form parameters
|
366
|
+
form_params = opts[:form_params] || {}
|
367
|
+
|
368
|
+
# http body (model)
|
369
|
+
post_body = opts[:debug_body]
|
370
|
+
|
371
|
+
# return_type
|
372
|
+
return_type = opts[:debug_return_type] || 'ODataListResponseOfModel'
|
373
|
+
|
374
|
+
# auth_names
|
375
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
376
|
+
|
377
|
+
new_options = opts.merge(
|
378
|
+
:operation => :"ModelsApi.models_get_by_tenantid",
|
379
|
+
:header_params => header_params,
|
380
|
+
:query_params => query_params,
|
381
|
+
:form_params => form_params,
|
382
|
+
:body => post_body,
|
383
|
+
:auth_names => auth_names,
|
384
|
+
:return_type => return_type
|
385
|
+
)
|
386
|
+
|
387
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
388
|
+
if @api_client.config.debugging
|
389
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_get_by_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
390
|
+
end
|
391
|
+
return data, status_code, headers
|
392
|
+
end
|
393
|
+
|
394
|
+
# Returns the entity with the key from Models
|
395
|
+
# <span style='font-size: 17px;'>Summary:</span>Returns the entity with the key from Models.<br/>Return Type: <b>Model</b><br/><br/>
|
396
|
+
# @param asset_model_id [Integer] key: AssetModelId
|
397
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
398
|
+
# @param region [String] The data center region the data resides in
|
399
|
+
# @param [Hash] opts the optional parameters
|
400
|
+
# @option opts [String] :expand Expands related entities inline.
|
401
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
402
|
+
# @return [Model]
|
403
|
+
def models_get_single_by_assetmodelid_and_tenantid(asset_model_id, tenant_id, region, opts = {})
|
404
|
+
data, _status_code, _headers = models_get_single_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts)
|
405
|
+
data
|
406
|
+
end
|
407
|
+
|
408
|
+
# Returns the entity with the key from Models
|
409
|
+
# <span style='font-size: 17px;'>Summary:</span>Returns the entity with the key from Models.<br/>Return Type: <b>Model</b><br/><br/>
|
410
|
+
# @param asset_model_id [Integer] key: AssetModelId
|
411
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
412
|
+
# @param region [String] The data center region the data resides in
|
413
|
+
# @param [Hash] opts the optional parameters
|
414
|
+
# @option opts [String] :expand Expands related entities inline.
|
415
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
416
|
+
# @return [Array<(Model, Integer, Hash)>] Model data, response status code and response headers
|
417
|
+
def models_get_single_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts = {})
|
418
|
+
if @api_client.config.debugging
|
419
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_get_single_by_assetmodelid_and_tenantid ...'
|
420
|
+
end
|
421
|
+
# verify the required parameter 'asset_model_id' is set
|
422
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
423
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_get_single_by_assetmodelid_and_tenantid"
|
424
|
+
end
|
425
|
+
# verify the required parameter 'tenant_id' is set
|
426
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
427
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_get_single_by_assetmodelid_and_tenantid"
|
428
|
+
end
|
429
|
+
# verify the required parameter 'region' is set
|
430
|
+
if @api_client.config.client_side_validation && region.nil?
|
431
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_get_single_by_assetmodelid_and_tenantid"
|
432
|
+
end
|
433
|
+
# verify enum value
|
434
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
435
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
436
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
437
|
+
end
|
438
|
+
# resource path
|
439
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})'.sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
440
|
+
|
441
|
+
# query parameters
|
442
|
+
query_params = opts[:query_params] || {}
|
443
|
+
query_params[:'$expand'] = opts[:'expand'] if !opts[:'expand'].nil?
|
444
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
445
|
+
|
446
|
+
# header parameters
|
447
|
+
header_params = opts[:header_params] || {}
|
448
|
+
# HTTP header 'Accept' (if needed)
|
449
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/json;odata.metadata=none', 'application/json;odata.metadata=minimal', 'application/json;odata.metadata=full'])
|
450
|
+
|
451
|
+
# form parameters
|
452
|
+
form_params = opts[:form_params] || {}
|
453
|
+
|
454
|
+
# http body (model)
|
455
|
+
post_body = opts[:debug_body]
|
456
|
+
|
457
|
+
# return_type
|
458
|
+
return_type = opts[:debug_return_type] || 'Model'
|
459
|
+
|
460
|
+
# auth_names
|
461
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
462
|
+
|
463
|
+
new_options = opts.merge(
|
464
|
+
:operation => :"ModelsApi.models_get_single_by_assetmodelid_and_tenantid",
|
465
|
+
:header_params => header_params,
|
466
|
+
:query_params => query_params,
|
467
|
+
:form_params => form_params,
|
468
|
+
:body => post_body,
|
469
|
+
:auth_names => auth_names,
|
470
|
+
:return_type => return_type
|
471
|
+
)
|
472
|
+
|
473
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
474
|
+
if @api_client.config.debugging
|
475
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_get_single_by_assetmodelid_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
476
|
+
end
|
477
|
+
return data, status_code, headers
|
478
|
+
end
|
479
|
+
|
480
|
+
# Gets the list of users with access to this model and their permissions
|
481
|
+
# <span style='font-size: 17px;'>Summary:</span>Gets the list of users with access to this model and their permissions.<br/>Return Type: <b>ODataListResponseOfMemberPermission</b><br/>For more information about OData responses <a href='https://www.odata.org/getting-started/understand-odata-in-6-steps/'>link</a>.<br/><br/>
|
482
|
+
# @param asset_model_id [Integer]
|
483
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
484
|
+
# @param region [String] The data center region the data resides in
|
485
|
+
# @param [Hash] opts the optional parameters
|
486
|
+
# @option opts [String] :expand Expands related entities inline.
|
487
|
+
# @option opts [String] :filter Filters the results, based on a Boolean condition.
|
488
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
489
|
+
# @option opts [String] :orderby Sorts the results.
|
490
|
+
# @option opts [Integer] :top Returns only the first n results.
|
491
|
+
# @option opts [Integer] :skip Skips the first n results.
|
492
|
+
# @option opts [Boolean] :count Includes a count of the matching results in the response.
|
493
|
+
# @return [ODataListResponseOfMemberPermission]
|
494
|
+
def models_member_access_by_assetmodelid_and_tenantid(asset_model_id, tenant_id, region, opts = {})
|
495
|
+
data, _status_code, _headers = models_member_access_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts)
|
496
|
+
data
|
497
|
+
end
|
498
|
+
|
499
|
+
# Gets the list of users with access to this model and their permissions
|
500
|
+
# <span style='font-size: 17px;'>Summary:</span>Gets the list of users with access to this model and their permissions.<br/>Return Type: <b>ODataListResponseOfMemberPermission</b><br/>For more information about OData responses <a href='https://www.odata.org/getting-started/understand-odata-in-6-steps/'>link</a>.<br/><br/>
|
501
|
+
# @param asset_model_id [Integer]
|
502
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
503
|
+
# @param region [String] The data center region the data resides in
|
504
|
+
# @param [Hash] opts the optional parameters
|
505
|
+
# @option opts [String] :expand Expands related entities inline.
|
506
|
+
# @option opts [String] :filter Filters the results, based on a Boolean condition.
|
507
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
508
|
+
# @option opts [String] :orderby Sorts the results.
|
509
|
+
# @option opts [Integer] :top Returns only the first n results.
|
510
|
+
# @option opts [Integer] :skip Skips the first n results.
|
511
|
+
# @option opts [Boolean] :count Includes a count of the matching results in the response.
|
512
|
+
# @return [Array<(ODataListResponseOfMemberPermission, Integer, Hash)>] ODataListResponseOfMemberPermission data, response status code and response headers
|
513
|
+
def models_member_access_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts = {})
|
514
|
+
if @api_client.config.debugging
|
515
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_member_access_by_assetmodelid_and_tenantid ...'
|
516
|
+
end
|
517
|
+
# verify the required parameter 'asset_model_id' is set
|
518
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
519
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_member_access_by_assetmodelid_and_tenantid"
|
520
|
+
end
|
521
|
+
# verify the required parameter 'tenant_id' is set
|
522
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
523
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_member_access_by_assetmodelid_and_tenantid"
|
524
|
+
end
|
525
|
+
# verify the required parameter 'region' is set
|
526
|
+
if @api_client.config.client_side_validation && region.nil?
|
527
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_member_access_by_assetmodelid_and_tenantid"
|
528
|
+
end
|
529
|
+
# verify enum value
|
530
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
531
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
532
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
533
|
+
end
|
534
|
+
# resource path
|
535
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})/MemberAccess'.sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
536
|
+
|
537
|
+
# query parameters
|
538
|
+
query_params = opts[:query_params] || {}
|
539
|
+
query_params[:'$expand'] = opts[:'expand'] if !opts[:'expand'].nil?
|
540
|
+
query_params[:'$filter'] = opts[:'filter'] if !opts[:'filter'].nil?
|
541
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
542
|
+
query_params[:'$orderby'] = opts[:'orderby'] if !opts[:'orderby'].nil?
|
543
|
+
query_params[:'$top'] = opts[:'top'] if !opts[:'top'].nil?
|
544
|
+
query_params[:'$skip'] = opts[:'skip'] if !opts[:'skip'].nil?
|
545
|
+
query_params[:'$count'] = opts[:'count'] if !opts[:'count'].nil?
|
546
|
+
|
547
|
+
# header parameters
|
548
|
+
header_params = opts[:header_params] || {}
|
549
|
+
# HTTP header 'Accept' (if needed)
|
550
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/json;odata.metadata=none', 'application/json;odata.metadata=minimal', 'application/json;odata.metadata=full', 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'])
|
551
|
+
|
552
|
+
# form parameters
|
553
|
+
form_params = opts[:form_params] || {}
|
554
|
+
|
555
|
+
# http body (model)
|
556
|
+
post_body = opts[:debug_body]
|
557
|
+
|
558
|
+
# return_type
|
559
|
+
return_type = opts[:debug_return_type] || 'ODataListResponseOfMemberPermission'
|
560
|
+
|
561
|
+
# auth_names
|
562
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
563
|
+
|
564
|
+
new_options = opts.merge(
|
565
|
+
:operation => :"ModelsApi.models_member_access_by_assetmodelid_and_tenantid",
|
566
|
+
:header_params => header_params,
|
567
|
+
:query_params => query_params,
|
568
|
+
:form_params => form_params,
|
569
|
+
:body => post_body,
|
570
|
+
:auth_names => auth_names,
|
571
|
+
:return_type => return_type
|
572
|
+
)
|
573
|
+
|
574
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
575
|
+
if @api_client.config.debugging
|
576
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_member_access_by_assetmodelid_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
577
|
+
end
|
578
|
+
return data, status_code, headers
|
579
|
+
end
|
580
|
+
|
581
|
+
# Move a model to another asset in this tenant
|
582
|
+
# <span style='font-size: 17px;'>Summary:</span>Move a model to another asset in this tenant.<br/>Return Type: <b>Model</b><br/><br/>
|
583
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
584
|
+
# @param asset_model_id [Integer] The Model ID
|
585
|
+
# @param region [String] The data center region the data resides in
|
586
|
+
# @param model_move_parameters [InlineObject3]
|
587
|
+
# @param [Hash] opts the optional parameters
|
588
|
+
# @return [Model]
|
589
|
+
def models_move_by_tenantid_and_assetmodelid(tenant_id, asset_model_id, region, model_move_parameters, opts = {})
|
590
|
+
data, _status_code, _headers = models_move_by_tenantid_and_assetmodelid_with_http_info(tenant_id, asset_model_id, region, model_move_parameters, opts)
|
591
|
+
data
|
592
|
+
end
|
593
|
+
|
594
|
+
# Move a model to another asset in this tenant
|
595
|
+
# <span style='font-size: 17px;'>Summary:</span>Move a model to another asset in this tenant.<br/>Return Type: <b>Model</b><br/><br/>
|
596
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
597
|
+
# @param asset_model_id [Integer] The Model ID
|
598
|
+
# @param region [String] The data center region the data resides in
|
599
|
+
# @param model_move_parameters [InlineObject3]
|
600
|
+
# @param [Hash] opts the optional parameters
|
601
|
+
# @return [Array<(Model, Integer, Hash)>] Model data, response status code and response headers
|
602
|
+
def models_move_by_tenantid_and_assetmodelid_with_http_info(tenant_id, asset_model_id, region, model_move_parameters, opts = {})
|
603
|
+
if @api_client.config.debugging
|
604
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_move_by_tenantid_and_assetmodelid ...'
|
605
|
+
end
|
606
|
+
# verify the required parameter 'tenant_id' is set
|
607
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
608
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_move_by_tenantid_and_assetmodelid"
|
609
|
+
end
|
610
|
+
# verify the required parameter 'asset_model_id' is set
|
611
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
612
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_move_by_tenantid_and_assetmodelid"
|
613
|
+
end
|
614
|
+
# verify the required parameter 'region' is set
|
615
|
+
if @api_client.config.client_side_validation && region.nil?
|
616
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_move_by_tenantid_and_assetmodelid"
|
617
|
+
end
|
618
|
+
# verify enum value
|
619
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
620
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
621
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
622
|
+
end
|
623
|
+
# verify the required parameter 'model_move_parameters' is set
|
624
|
+
if @api_client.config.client_side_validation && model_move_parameters.nil?
|
625
|
+
fail ArgumentError, "Missing the required parameter 'model_move_parameters' when calling ModelsApi.models_move_by_tenantid_and_assetmodelid"
|
626
|
+
end
|
627
|
+
# resource path
|
628
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})/Asset.Move'.sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
629
|
+
|
630
|
+
# query parameters
|
631
|
+
query_params = opts[:query_params] || {}
|
632
|
+
|
633
|
+
# header parameters
|
634
|
+
header_params = opts[:header_params] || {}
|
635
|
+
# HTTP header 'Accept' (if needed)
|
636
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
637
|
+
# HTTP header 'Content-Type'
|
638
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
639
|
+
if !content_type.nil?
|
640
|
+
header_params['Content-Type'] = content_type
|
641
|
+
end
|
642
|
+
|
643
|
+
# form parameters
|
644
|
+
form_params = opts[:form_params] || {}
|
645
|
+
|
646
|
+
# http body (model)
|
647
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(model_move_parameters)
|
648
|
+
|
649
|
+
# return_type
|
650
|
+
return_type = opts[:debug_return_type] || 'Model'
|
651
|
+
|
652
|
+
# auth_names
|
653
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
654
|
+
|
655
|
+
new_options = opts.merge(
|
656
|
+
:operation => :"ModelsApi.models_move_by_tenantid_and_assetmodelid",
|
657
|
+
:header_params => header_params,
|
658
|
+
:query_params => query_params,
|
659
|
+
:form_params => form_params,
|
660
|
+
:body => post_body,
|
661
|
+
:auth_names => auth_names,
|
662
|
+
:return_type => return_type
|
663
|
+
)
|
664
|
+
|
665
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
666
|
+
if @api_client.config.debugging
|
667
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_move_by_tenantid_and_assetmodelid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
668
|
+
end
|
669
|
+
return data, status_code, headers
|
670
|
+
end
|
671
|
+
|
672
|
+
# Edit an existing model
|
673
|
+
# <span style='font-size: 17px;'>Summary:</span>Edit an existing model.<br/>Return Type: <b>Model</b><br/><br/>
|
674
|
+
# @param asset_model_id [Integer]
|
675
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
676
|
+
# @param region [String] The data center region the data resides in
|
677
|
+
# @param model [ModelEdit] The entity to patch
|
678
|
+
# @param [Hash] opts the optional parameters
|
679
|
+
# @return [Model]
|
680
|
+
def models_patch_by_assetmodelid_and_tenantid(asset_model_id, tenant_id, region, model, opts = {})
|
681
|
+
data, _status_code, _headers = models_patch_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, model, opts)
|
682
|
+
data
|
683
|
+
end
|
684
|
+
|
685
|
+
# Edit an existing model
|
686
|
+
# <span style='font-size: 17px;'>Summary:</span>Edit an existing model.<br/>Return Type: <b>Model</b><br/><br/>
|
687
|
+
# @param asset_model_id [Integer]
|
688
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
689
|
+
# @param region [String] The data center region the data resides in
|
690
|
+
# @param model [ModelEdit] The entity to patch
|
691
|
+
# @param [Hash] opts the optional parameters
|
692
|
+
# @return [Array<(Model, Integer, Hash)>] Model data, response status code and response headers
|
693
|
+
def models_patch_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, model, opts = {})
|
694
|
+
if @api_client.config.debugging
|
695
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_patch_by_assetmodelid_and_tenantid ...'
|
696
|
+
end
|
697
|
+
# verify the required parameter 'asset_model_id' is set
|
698
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
699
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_patch_by_assetmodelid_and_tenantid"
|
700
|
+
end
|
701
|
+
# verify the required parameter 'tenant_id' is set
|
702
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
703
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_patch_by_assetmodelid_and_tenantid"
|
704
|
+
end
|
705
|
+
# verify the required parameter 'region' is set
|
706
|
+
if @api_client.config.client_side_validation && region.nil?
|
707
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_patch_by_assetmodelid_and_tenantid"
|
708
|
+
end
|
709
|
+
# verify enum value
|
710
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
711
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
712
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
713
|
+
end
|
714
|
+
# verify the required parameter 'model' is set
|
715
|
+
if @api_client.config.client_side_validation && model.nil?
|
716
|
+
fail ArgumentError, "Missing the required parameter 'model' when calling ModelsApi.models_patch_by_assetmodelid_and_tenantid"
|
717
|
+
end
|
718
|
+
# resource path
|
719
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})'.sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
720
|
+
|
721
|
+
# query parameters
|
722
|
+
query_params = opts[:query_params] || {}
|
723
|
+
|
724
|
+
# header parameters
|
725
|
+
header_params = opts[:header_params] || {}
|
726
|
+
# HTTP header 'Accept' (if needed)
|
727
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
728
|
+
# HTTP header 'Content-Type'
|
729
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
730
|
+
if !content_type.nil?
|
731
|
+
header_params['Content-Type'] = content_type
|
732
|
+
end
|
733
|
+
|
734
|
+
# form parameters
|
735
|
+
form_params = opts[:form_params] || {}
|
736
|
+
|
737
|
+
# http body (model)
|
738
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(model)
|
739
|
+
|
740
|
+
# return_type
|
741
|
+
return_type = opts[:debug_return_type] || 'Model'
|
742
|
+
|
743
|
+
# auth_names
|
744
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
745
|
+
|
746
|
+
new_options = opts.merge(
|
747
|
+
:operation => :"ModelsApi.models_patch_by_assetmodelid_and_tenantid",
|
748
|
+
:header_params => header_params,
|
749
|
+
:query_params => query_params,
|
750
|
+
:form_params => form_params,
|
751
|
+
:body => post_body,
|
752
|
+
:auth_names => auth_names,
|
753
|
+
:return_type => return_type
|
754
|
+
)
|
755
|
+
|
756
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
757
|
+
if @api_client.config.debugging
|
758
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_patch_by_assetmodelid_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
759
|
+
end
|
760
|
+
return data, status_code, headers
|
761
|
+
end
|
762
|
+
|
763
|
+
# Gets the effective permissions for the current user
|
764
|
+
# <span style='font-size: 17px;'>Summary:</span>Gets the effective permissions for the current user.<br/>Return Type: <b>UserPermissions</b><br/><br/>
|
765
|
+
# @param asset_model_id [Integer]
|
766
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
767
|
+
# @param region [String] The data center region the data resides in
|
768
|
+
# @param [Hash] opts the optional parameters
|
769
|
+
# @option opts [String] :expand Expands related entities inline.
|
770
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
771
|
+
# @return [UserPermissions]
|
772
|
+
def models_permissions_by_assetmodelid_and_tenantid(asset_model_id, tenant_id, region, opts = {})
|
773
|
+
data, _status_code, _headers = models_permissions_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts)
|
774
|
+
data
|
775
|
+
end
|
776
|
+
|
777
|
+
# Gets the effective permissions for the current user
|
778
|
+
# <span style='font-size: 17px;'>Summary:</span>Gets the effective permissions for the current user.<br/>Return Type: <b>UserPermissions</b><br/><br/>
|
779
|
+
# @param asset_model_id [Integer]
|
780
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
781
|
+
# @param region [String] The data center region the data resides in
|
782
|
+
# @param [Hash] opts the optional parameters
|
783
|
+
# @option opts [String] :expand Expands related entities inline.
|
784
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
785
|
+
# @return [Array<(UserPermissions, Integer, Hash)>] UserPermissions data, response status code and response headers
|
786
|
+
def models_permissions_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts = {})
|
787
|
+
if @api_client.config.debugging
|
788
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_permissions_by_assetmodelid_and_tenantid ...'
|
789
|
+
end
|
790
|
+
# verify the required parameter 'asset_model_id' is set
|
791
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
792
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_permissions_by_assetmodelid_and_tenantid"
|
793
|
+
end
|
794
|
+
# verify the required parameter 'tenant_id' is set
|
795
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
796
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_permissions_by_assetmodelid_and_tenantid"
|
797
|
+
end
|
798
|
+
# verify the required parameter 'region' is set
|
799
|
+
if @api_client.config.client_side_validation && region.nil?
|
800
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_permissions_by_assetmodelid_and_tenantid"
|
801
|
+
end
|
802
|
+
# verify enum value
|
803
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
804
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
805
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
806
|
+
end
|
807
|
+
# resource path
|
808
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})/Permissions'.sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
809
|
+
|
810
|
+
# query parameters
|
811
|
+
query_params = opts[:query_params] || {}
|
812
|
+
query_params[:'$expand'] = opts[:'expand'] if !opts[:'expand'].nil?
|
813
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
814
|
+
|
815
|
+
# header parameters
|
816
|
+
header_params = opts[:header_params] || {}
|
817
|
+
# HTTP header 'Accept' (if needed)
|
818
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
819
|
+
|
820
|
+
# form parameters
|
821
|
+
form_params = opts[:form_params] || {}
|
822
|
+
|
823
|
+
# http body (model)
|
824
|
+
post_body = opts[:debug_body]
|
825
|
+
|
826
|
+
# return_type
|
827
|
+
return_type = opts[:debug_return_type] || 'UserPermissions'
|
828
|
+
|
829
|
+
# auth_names
|
830
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
831
|
+
|
832
|
+
new_options = opts.merge(
|
833
|
+
:operation => :"ModelsApi.models_permissions_by_assetmodelid_and_tenantid",
|
834
|
+
:header_params => header_params,
|
835
|
+
:query_params => query_params,
|
836
|
+
:form_params => form_params,
|
837
|
+
:body => post_body,
|
838
|
+
:auth_names => auth_names,
|
839
|
+
:return_type => return_type
|
840
|
+
)
|
841
|
+
|
842
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
843
|
+
if @api_client.config.debugging
|
844
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_permissions_by_assetmodelid_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
845
|
+
end
|
846
|
+
return data, status_code, headers
|
847
|
+
end
|
848
|
+
|
849
|
+
# Creates a new Model for the given Asset
|
850
|
+
# <span style='font-size: 17px;'>Summary:</span>Creates a new Model for the given Asset.<br/>The ability to create Models may be limited by access level.<br/>Return Type: <b>Model</b><br/><br/>
|
851
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
852
|
+
# @param region [String] The data center region the data resides in
|
853
|
+
# @param model [ModelCreate]
|
854
|
+
# @param [Hash] opts the optional parameters
|
855
|
+
# @return [Model]
|
856
|
+
def models_post_by_tenantid(tenant_id, region, model, opts = {})
|
857
|
+
data, _status_code, _headers = models_post_by_tenantid_with_http_info(tenant_id, region, model, opts)
|
858
|
+
data
|
859
|
+
end
|
860
|
+
|
861
|
+
# Creates a new Model for the given Asset
|
862
|
+
# <span style='font-size: 17px;'>Summary:</span>Creates a new Model for the given Asset.<br/>The ability to create Models may be limited by access level.<br/>Return Type: <b>Model</b><br/><br/>
|
863
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
864
|
+
# @param region [String] The data center region the data resides in
|
865
|
+
# @param model [ModelCreate]
|
866
|
+
# @param [Hash] opts the optional parameters
|
867
|
+
# @return [Array<(Model, Integer, Hash)>] Model data, response status code and response headers
|
868
|
+
def models_post_by_tenantid_with_http_info(tenant_id, region, model, opts = {})
|
869
|
+
if @api_client.config.debugging
|
870
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_post_by_tenantid ...'
|
871
|
+
end
|
872
|
+
# verify the required parameter 'tenant_id' is set
|
873
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
874
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_post_by_tenantid"
|
875
|
+
end
|
876
|
+
# verify the required parameter 'region' is set
|
877
|
+
if @api_client.config.client_side_validation && region.nil?
|
878
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_post_by_tenantid"
|
879
|
+
end
|
880
|
+
# verify enum value
|
881
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
882
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
883
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
884
|
+
end
|
885
|
+
# verify the required parameter 'model' is set
|
886
|
+
if @api_client.config.client_side_validation && model.nil?
|
887
|
+
fail ArgumentError, "Missing the required parameter 'model' when calling ModelsApi.models_post_by_tenantid"
|
888
|
+
end
|
889
|
+
# resource path
|
890
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models'.sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
891
|
+
|
892
|
+
# query parameters
|
893
|
+
query_params = opts[:query_params] || {}
|
894
|
+
|
895
|
+
# header parameters
|
896
|
+
header_params = opts[:header_params] || {}
|
897
|
+
# HTTP header 'Accept' (if needed)
|
898
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
899
|
+
# HTTP header 'Content-Type'
|
900
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
901
|
+
if !content_type.nil?
|
902
|
+
header_params['Content-Type'] = content_type
|
903
|
+
end
|
904
|
+
|
905
|
+
# form parameters
|
906
|
+
form_params = opts[:form_params] || {}
|
907
|
+
|
908
|
+
# http body (model)
|
909
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(model)
|
910
|
+
|
911
|
+
# return_type
|
912
|
+
return_type = opts[:debug_return_type] || 'Model'
|
913
|
+
|
914
|
+
# auth_names
|
915
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
916
|
+
|
917
|
+
new_options = opts.merge(
|
918
|
+
:operation => :"ModelsApi.models_post_by_tenantid",
|
919
|
+
:header_params => header_params,
|
920
|
+
:query_params => query_params,
|
921
|
+
:form_params => form_params,
|
922
|
+
:body => post_body,
|
923
|
+
:auth_names => auth_names,
|
924
|
+
:return_type => return_type
|
925
|
+
)
|
926
|
+
|
927
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
928
|
+
if @api_client.config.debugging
|
929
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_post_by_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
930
|
+
end
|
931
|
+
return data, status_code, headers
|
932
|
+
end
|
933
|
+
|
934
|
+
# Requeues a model for processing and import
|
935
|
+
# <span style='font-size: 17px;'>Summary:</span>Requeues a model for processing and import.<br/>Return Type: <b>boolean</b><br/><br/>
|
936
|
+
# @param asset_model_id [Integer] The model ID to requeue
|
937
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
938
|
+
# @param region [String] The data center region the data resides in
|
939
|
+
# @param [Hash] opts the optional parameters
|
940
|
+
# @return [Boolean]
|
941
|
+
def models_reprocess_by_assetmodelid_and_tenantid(asset_model_id, tenant_id, region, opts = {})
|
942
|
+
data, _status_code, _headers = models_reprocess_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts)
|
943
|
+
data
|
944
|
+
end
|
945
|
+
|
946
|
+
# Requeues a model for processing and import
|
947
|
+
# <span style='font-size: 17px;'>Summary:</span>Requeues a model for processing and import.<br/>Return Type: <b>boolean</b><br/><br/>
|
948
|
+
# @param asset_model_id [Integer] The model ID to requeue
|
949
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
950
|
+
# @param region [String] The data center region the data resides in
|
951
|
+
# @param [Hash] opts the optional parameters
|
952
|
+
# @return [Array<(Boolean, Integer, Hash)>] Boolean data, response status code and response headers
|
953
|
+
def models_reprocess_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts = {})
|
954
|
+
if @api_client.config.debugging
|
955
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_reprocess_by_assetmodelid_and_tenantid ...'
|
956
|
+
end
|
957
|
+
# verify the required parameter 'asset_model_id' is set
|
958
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
959
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_reprocess_by_assetmodelid_and_tenantid"
|
960
|
+
end
|
961
|
+
# verify the required parameter 'tenant_id' is set
|
962
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
963
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_reprocess_by_assetmodelid_and_tenantid"
|
964
|
+
end
|
965
|
+
# verify the required parameter 'region' is set
|
966
|
+
if @api_client.config.client_side_validation && region.nil?
|
967
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_reprocess_by_assetmodelid_and_tenantid"
|
968
|
+
end
|
969
|
+
# verify enum value
|
970
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
971
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
972
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
973
|
+
end
|
974
|
+
# resource path
|
975
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})/Reprocess()'.sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
976
|
+
|
977
|
+
# query parameters
|
978
|
+
query_params = opts[:query_params] || {}
|
979
|
+
|
980
|
+
# header parameters
|
981
|
+
header_params = opts[:header_params] || {}
|
982
|
+
# HTTP header 'Accept' (if needed)
|
983
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
984
|
+
|
985
|
+
# form parameters
|
986
|
+
form_params = opts[:form_params] || {}
|
987
|
+
|
988
|
+
# http body (model)
|
989
|
+
post_body = opts[:debug_body]
|
990
|
+
|
991
|
+
# return_type
|
992
|
+
return_type = opts[:debug_return_type] || 'Boolean'
|
993
|
+
|
994
|
+
# auth_names
|
995
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
996
|
+
|
997
|
+
new_options = opts.merge(
|
998
|
+
:operation => :"ModelsApi.models_reprocess_by_assetmodelid_and_tenantid",
|
999
|
+
:header_params => header_params,
|
1000
|
+
:query_params => query_params,
|
1001
|
+
:form_params => form_params,
|
1002
|
+
:body => post_body,
|
1003
|
+
:auth_names => auth_names,
|
1004
|
+
:return_type => return_type
|
1005
|
+
)
|
1006
|
+
|
1007
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1008
|
+
if @api_client.config.debugging
|
1009
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_reprocess_by_assetmodelid_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1010
|
+
end
|
1011
|
+
return data, status_code, headers
|
1012
|
+
end
|
1013
|
+
|
1014
|
+
# Revokes a user from the given role on the model
|
1015
|
+
# <span style='font-size: 17px;'>Summary:</span>Revokes a user from the given role on the model.<br/>Return Type: <b></b><br/><br/>
|
1016
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
1017
|
+
# @param asset_model_id [Integer]
|
1018
|
+
# @param region [String] The data center region the data resides in
|
1019
|
+
# @param parameters [InlineObject5]
|
1020
|
+
# @param [Hash] opts the optional parameters
|
1021
|
+
# @return [nil]
|
1022
|
+
def models_revoke_by_tenantid_and_assetmodelid(tenant_id, asset_model_id, region, parameters, opts = {})
|
1023
|
+
models_revoke_by_tenantid_and_assetmodelid_with_http_info(tenant_id, asset_model_id, region, parameters, opts)
|
1024
|
+
nil
|
1025
|
+
end
|
1026
|
+
|
1027
|
+
# Revokes a user from the given role on the model
|
1028
|
+
# <span style='font-size: 17px;'>Summary:</span>Revokes a user from the given role on the model.<br/>Return Type: <b></b><br/><br/>
|
1029
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
1030
|
+
# @param asset_model_id [Integer]
|
1031
|
+
# @param region [String] The data center region the data resides in
|
1032
|
+
# @param parameters [InlineObject5]
|
1033
|
+
# @param [Hash] opts the optional parameters
|
1034
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
1035
|
+
def models_revoke_by_tenantid_and_assetmodelid_with_http_info(tenant_id, asset_model_id, region, parameters, opts = {})
|
1036
|
+
if @api_client.config.debugging
|
1037
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_revoke_by_tenantid_and_assetmodelid ...'
|
1038
|
+
end
|
1039
|
+
# verify the required parameter 'tenant_id' is set
|
1040
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
1041
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_revoke_by_tenantid_and_assetmodelid"
|
1042
|
+
end
|
1043
|
+
# verify the required parameter 'asset_model_id' is set
|
1044
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
1045
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_revoke_by_tenantid_and_assetmodelid"
|
1046
|
+
end
|
1047
|
+
# verify the required parameter 'region' is set
|
1048
|
+
if @api_client.config.client_side_validation && region.nil?
|
1049
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_revoke_by_tenantid_and_assetmodelid"
|
1050
|
+
end
|
1051
|
+
# verify enum value
|
1052
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
1053
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
1054
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
1055
|
+
end
|
1056
|
+
# verify the required parameter 'parameters' is set
|
1057
|
+
if @api_client.config.client_side_validation && parameters.nil?
|
1058
|
+
fail ArgumentError, "Missing the required parameter 'parameters' when calling ModelsApi.models_revoke_by_tenantid_and_assetmodelid"
|
1059
|
+
end
|
1060
|
+
# resource path
|
1061
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})/Roles.Revoke'.sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
1062
|
+
|
1063
|
+
# query parameters
|
1064
|
+
query_params = opts[:query_params] || {}
|
1065
|
+
|
1066
|
+
# header parameters
|
1067
|
+
header_params = opts[:header_params] || {}
|
1068
|
+
# HTTP header 'Content-Type'
|
1069
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
1070
|
+
if !content_type.nil?
|
1071
|
+
header_params['Content-Type'] = content_type
|
1072
|
+
end
|
1073
|
+
|
1074
|
+
# form parameters
|
1075
|
+
form_params = opts[:form_params] || {}
|
1076
|
+
|
1077
|
+
# http body (model)
|
1078
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(parameters)
|
1079
|
+
|
1080
|
+
# return_type
|
1081
|
+
return_type = opts[:debug_return_type]
|
1082
|
+
|
1083
|
+
# auth_names
|
1084
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
1085
|
+
|
1086
|
+
new_options = opts.merge(
|
1087
|
+
:operation => :"ModelsApi.models_revoke_by_tenantid_and_assetmodelid",
|
1088
|
+
:header_params => header_params,
|
1089
|
+
:query_params => query_params,
|
1090
|
+
:form_params => form_params,
|
1091
|
+
:body => post_body,
|
1092
|
+
:auth_names => auth_names,
|
1093
|
+
:return_type => return_type
|
1094
|
+
)
|
1095
|
+
|
1096
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1097
|
+
if @api_client.config.debugging
|
1098
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_revoke_by_tenantid_and_assetmodelid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1099
|
+
end
|
1100
|
+
return data, status_code, headers
|
1101
|
+
end
|
1102
|
+
|
1103
|
+
# Gets the roles for the given Model
|
1104
|
+
# <span style='font-size: 17px;'>Summary:</span>Gets the roles for the given Model.<br/>Return Type: <b>ODataListResponseOfRole</b><br/>For more information about OData responses <a href='https://www.odata.org/getting-started/understand-odata-in-6-steps/'>link</a>.<br/><br/>
|
1105
|
+
# @param asset_model_id [Integer]
|
1106
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
1107
|
+
# @param region [String] The data center region the data resides in
|
1108
|
+
# @param [Hash] opts the optional parameters
|
1109
|
+
# @option opts [String] :expand Expands related entities inline.
|
1110
|
+
# @option opts [String] :filter Filters the results, based on a Boolean condition.
|
1111
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
1112
|
+
# @option opts [String] :orderby Sorts the results.
|
1113
|
+
# @option opts [Integer] :top Returns only the first n results.
|
1114
|
+
# @option opts [Integer] :skip Skips the first n results.
|
1115
|
+
# @option opts [Boolean] :count Includes a count of the matching results in the response.
|
1116
|
+
# @return [ODataListResponseOfRole]
|
1117
|
+
def models_roles_by_assetmodelid_and_tenantid(asset_model_id, tenant_id, region, opts = {})
|
1118
|
+
data, _status_code, _headers = models_roles_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts)
|
1119
|
+
data
|
1120
|
+
end
|
1121
|
+
|
1122
|
+
# Gets the roles for the given Model
|
1123
|
+
# <span style='font-size: 17px;'>Summary:</span>Gets the roles for the given Model.<br/>Return Type: <b>ODataListResponseOfRole</b><br/>For more information about OData responses <a href='https://www.odata.org/getting-started/understand-odata-in-6-steps/'>link</a>.<br/><br/>
|
1124
|
+
# @param asset_model_id [Integer]
|
1125
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
1126
|
+
# @param region [String] The data center region the data resides in
|
1127
|
+
# @param [Hash] opts the optional parameters
|
1128
|
+
# @option opts [String] :expand Expands related entities inline.
|
1129
|
+
# @option opts [String] :filter Filters the results, based on a Boolean condition.
|
1130
|
+
# @option opts [String] :select Selects which properties to include in the response.
|
1131
|
+
# @option opts [String] :orderby Sorts the results.
|
1132
|
+
# @option opts [Integer] :top Returns only the first n results.
|
1133
|
+
# @option opts [Integer] :skip Skips the first n results.
|
1134
|
+
# @option opts [Boolean] :count Includes a count of the matching results in the response.
|
1135
|
+
# @return [Array<(ODataListResponseOfRole, Integer, Hash)>] ODataListResponseOfRole data, response status code and response headers
|
1136
|
+
def models_roles_by_assetmodelid_and_tenantid_with_http_info(asset_model_id, tenant_id, region, opts = {})
|
1137
|
+
if @api_client.config.debugging
|
1138
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_roles_by_assetmodelid_and_tenantid ...'
|
1139
|
+
end
|
1140
|
+
# verify the required parameter 'asset_model_id' is set
|
1141
|
+
if @api_client.config.client_side_validation && asset_model_id.nil?
|
1142
|
+
fail ArgumentError, "Missing the required parameter 'asset_model_id' when calling ModelsApi.models_roles_by_assetmodelid_and_tenantid"
|
1143
|
+
end
|
1144
|
+
# verify the required parameter 'tenant_id' is set
|
1145
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
1146
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_roles_by_assetmodelid_and_tenantid"
|
1147
|
+
end
|
1148
|
+
# verify the required parameter 'region' is set
|
1149
|
+
if @api_client.config.client_side_validation && region.nil?
|
1150
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_roles_by_assetmodelid_and_tenantid"
|
1151
|
+
end
|
1152
|
+
# verify enum value
|
1153
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
1154
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
1155
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
1156
|
+
end
|
1157
|
+
# resource path
|
1158
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({AssetModelId})/Roles'.sub('{' + 'AssetModelId' + '}', CGI.escape(asset_model_id.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
1159
|
+
|
1160
|
+
# query parameters
|
1161
|
+
query_params = opts[:query_params] || {}
|
1162
|
+
query_params[:'$expand'] = opts[:'expand'] if !opts[:'expand'].nil?
|
1163
|
+
query_params[:'$filter'] = opts[:'filter'] if !opts[:'filter'].nil?
|
1164
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
1165
|
+
query_params[:'$orderby'] = opts[:'orderby'] if !opts[:'orderby'].nil?
|
1166
|
+
query_params[:'$top'] = opts[:'top'] if !opts[:'top'].nil?
|
1167
|
+
query_params[:'$skip'] = opts[:'skip'] if !opts[:'skip'].nil?
|
1168
|
+
query_params[:'$count'] = opts[:'count'] if !opts[:'count'].nil?
|
1169
|
+
|
1170
|
+
# header parameters
|
1171
|
+
header_params = opts[:header_params] || {}
|
1172
|
+
# HTTP header 'Accept' (if needed)
|
1173
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/json;odata.metadata=none', 'application/json;odata.metadata=minimal', 'application/json;odata.metadata=full', 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'])
|
1174
|
+
|
1175
|
+
# form parameters
|
1176
|
+
form_params = opts[:form_params] || {}
|
1177
|
+
|
1178
|
+
# http body (model)
|
1179
|
+
post_body = opts[:debug_body]
|
1180
|
+
|
1181
|
+
# return_type
|
1182
|
+
return_type = opts[:debug_return_type] || 'ODataListResponseOfRole'
|
1183
|
+
|
1184
|
+
# auth_names
|
1185
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
1186
|
+
|
1187
|
+
new_options = opts.merge(
|
1188
|
+
:operation => :"ModelsApi.models_roles_by_assetmodelid_and_tenantid",
|
1189
|
+
:header_params => header_params,
|
1190
|
+
:query_params => query_params,
|
1191
|
+
:form_params => form_params,
|
1192
|
+
:body => post_body,
|
1193
|
+
:auth_names => auth_names,
|
1194
|
+
:return_type => return_type
|
1195
|
+
)
|
1196
|
+
|
1197
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
1198
|
+
if @api_client.config.debugging
|
1199
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_roles_by_assetmodelid_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1200
|
+
end
|
1201
|
+
return data, status_code, headers
|
1202
|
+
end
|
1203
|
+
|
1204
|
+
# Supercede an existing model with a new version
|
1205
|
+
# <span style='font-size: 17px;'>Summary:</span>Supercede an existing model with a new version.<br/>Return Type: <b>FileUploadResult</b><br/><br/>
|
1206
|
+
# @param key [Integer] The ID of the model to supercede.
|
1207
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
1208
|
+
# @param region [String] The data center region the data resides in
|
1209
|
+
# @param file [File] A model file in the correct format (IFC / IFCZip / Zip)
|
1210
|
+
# @param [Hash] opts the optional parameters
|
1211
|
+
# @option opts [String] :revision A version identifier for the model.
|
1212
|
+
# @option opts [String] :status A status identifier for the model
|
1213
|
+
# @option opts [Integer] :model_id The ID of the model to be populated with the data. If not defined, a new model will be created.
|
1214
|
+
# @option opts [String] :original_filename The original filename of the model, for zipped models
|
1215
|
+
# @return [FileUploadResult]
|
1216
|
+
def models_supercede_by_key_and_tenantid(key, tenant_id, region, file, opts = {})
|
1217
|
+
data, _status_code, _headers = models_supercede_by_key_and_tenantid_with_http_info(key, tenant_id, region, file, opts)
|
1218
|
+
data
|
1219
|
+
end
|
1220
|
+
|
1221
|
+
# Supercede an existing model with a new version
|
1222
|
+
# <span style='font-size: 17px;'>Summary:</span>Supercede an existing model with a new version.<br/>Return Type: <b>FileUploadResult</b><br/><br/>
|
1223
|
+
# @param key [Integer] The ID of the model to supercede.
|
1224
|
+
# @param tenant_id [String] The unique Tenant ID (UUID or Identifier string)
|
1225
|
+
# @param region [String] The data center region the data resides in
|
1226
|
+
# @param file [File] A model file in the correct format (IFC / IFCZip / Zip)
|
1227
|
+
# @param [Hash] opts the optional parameters
|
1228
|
+
# @option opts [String] :revision A version identifier for the model.
|
1229
|
+
# @option opts [String] :status A status identifier for the model
|
1230
|
+
# @option opts [Integer] :model_id The ID of the model to be populated with the data. If not defined, a new model will be created.
|
1231
|
+
# @option opts [String] :original_filename The original filename of the model, for zipped models
|
1232
|
+
# @return [Array<(FileUploadResult, Integer, Hash)>] FileUploadResult data, response status code and response headers
|
1233
|
+
def models_supercede_by_key_and_tenantid_with_http_info(key, tenant_id, region, file, opts = {})
|
1234
|
+
if @api_client.config.debugging
|
1235
|
+
@api_client.config.logger.debug 'Calling API: ModelsApi.models_supercede_by_key_and_tenantid ...'
|
1236
|
+
end
|
1237
|
+
# verify the required parameter 'key' is set
|
1238
|
+
if @api_client.config.client_side_validation && key.nil?
|
1239
|
+
fail ArgumentError, "Missing the required parameter 'key' when calling ModelsApi.models_supercede_by_key_and_tenantid"
|
1240
|
+
end
|
1241
|
+
# verify the required parameter 'tenant_id' is set
|
1242
|
+
if @api_client.config.client_side_validation && tenant_id.nil?
|
1243
|
+
fail ArgumentError, "Missing the required parameter 'tenant_id' when calling ModelsApi.models_supercede_by_key_and_tenantid"
|
1244
|
+
end
|
1245
|
+
# verify the required parameter 'region' is set
|
1246
|
+
if @api_client.config.client_side_validation && region.nil?
|
1247
|
+
fail ArgumentError, "Missing the required parameter 'region' when calling ModelsApi.models_supercede_by_key_and_tenantid"
|
1248
|
+
end
|
1249
|
+
# verify enum value
|
1250
|
+
allowable_values = ["UK", "WestEurope", "Sandbox"]
|
1251
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(region)
|
1252
|
+
fail ArgumentError, "invalid value for \"region\", must be one of #{allowable_values}"
|
1253
|
+
end
|
1254
|
+
# verify the required parameter 'file' is set
|
1255
|
+
if @api_client.config.client_side_validation && file.nil?
|
1256
|
+
fail ArgumentError, "Missing the required parameter 'file' when calling ModelsApi.models_supercede_by_key_and_tenantid"
|
1257
|
+
end
|
1258
|
+
# resource path
|
1259
|
+
local_var_path = '/{region}/aim/2.0/{tenantId}/Models({key})/Supercede()'.sub('{' + 'key' + '}', CGI.escape(key.to_s)).sub('{' + 'tenantId' + '}', CGI.escape(tenant_id.to_s)).sub('{' + 'region' + '}', CGI.escape(region.to_s))
|
1260
|
+
|
1261
|
+
# query parameters
|
1262
|
+
query_params = opts[:query_params] || {}
|
1263
|
+
|
1264
|
+
# header parameters
|
1265
|
+
header_params = opts[:header_params] || {}
|
1266
|
+
# HTTP header 'Accept' (if needed)
|
1267
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1268
|
+
# HTTP header 'Content-Type'
|
1269
|
+
content_type = @api_client.select_header_content_type(['multipart/form-data'])
|
1270
|
+
if !content_type.nil?
|
1271
|
+
header_params['Content-Type'] = content_type
|
1272
|
+
end
|
1273
|
+
|
1274
|
+
# form parameters
|
1275
|
+
form_params = opts[:form_params] || {}
|
1276
|
+
form_params['file'] = file
|
1277
|
+
form_params['revision'] = opts[:'revision'] if !opts[:'revision'].nil?
|
1278
|
+
form_params['status'] = opts[:'status'] if !opts[:'status'].nil?
|
1279
|
+
form_params['modelId'] = opts[:'model_id'] if !opts[:'model_id'].nil?
|
1280
|
+
form_params['originalFilename'] = opts[:'original_filename'] if !opts[:'original_filename'].nil?
|
1281
|
+
|
1282
|
+
# http body (model)
|
1283
|
+
post_body = opts[:debug_body]
|
1284
|
+
|
1285
|
+
# return_type
|
1286
|
+
return_type = opts[:debug_return_type] || 'FileUploadResult'
|
1287
|
+
|
1288
|
+
# auth_names
|
1289
|
+
auth_names = opts[:debug_auth_names] || ['oauth2']
|
1290
|
+
|
1291
|
+
new_options = opts.merge(
|
1292
|
+
:operation => :"ModelsApi.models_supercede_by_key_and_tenantid",
|
1293
|
+
:header_params => header_params,
|
1294
|
+
:query_params => query_params,
|
1295
|
+
:form_params => form_params,
|
1296
|
+
:body => post_body,
|
1297
|
+
:auth_names => auth_names,
|
1298
|
+
:return_type => return_type
|
1299
|
+
)
|
1300
|
+
|
1301
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
1302
|
+
if @api_client.config.debugging
|
1303
|
+
@api_client.config.logger.debug "API called: ModelsApi#models_supercede_by_key_and_tenantid\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1304
|
+
end
|
1305
|
+
return data, status_code, headers
|
1306
|
+
end
|
1307
|
+
end
|
1308
|
+
end
|