topological_inventory-ingress_api-client 1.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/LICENSE.txt +202 -0
- data/README.md +284 -0
- data/Rakefile +10 -0
- data/docs/Cluster.md +31 -0
- data/docs/ClusterAllOf.md +31 -0
- data/docs/ClusterReference.md +21 -0
- data/docs/ClusterReferenceReference.md +17 -0
- data/docs/ClusterTag.md +19 -0
- data/docs/ClusterTagAllOf.md +19 -0
- data/docs/Container.md +33 -0
- data/docs/ContainerAllOf.md +33 -0
- data/docs/ContainerGroup.md +35 -0
- data/docs/ContainerGroupAllOf.md +35 -0
- data/docs/ContainerGroupReference.md +21 -0
- data/docs/ContainerGroupTag.md +19 -0
- data/docs/ContainerGroupTagAllOf.md +19 -0
- data/docs/ContainerImage.md +31 -0
- data/docs/ContainerImageAllOf.md +31 -0
- data/docs/ContainerImageReference.md +21 -0
- data/docs/ContainerImageTag.md +19 -0
- data/docs/ContainerImageTagAllOf.md +19 -0
- data/docs/ContainerNode.md +49 -0
- data/docs/ContainerNodeAllOf.md +49 -0
- data/docs/ContainerNodeReference.md +21 -0
- data/docs/ContainerNodeReferenceByName.md +21 -0
- data/docs/ContainerNodeReferenceByNameReference.md +17 -0
- data/docs/ContainerNodeTag.md +19 -0
- data/docs/ContainerNodeTagAllOf.md +19 -0
- data/docs/ContainerProject.md +33 -0
- data/docs/ContainerProjectAllOf.md +33 -0
- data/docs/ContainerProjectReference.md +21 -0
- data/docs/ContainerProjectReferenceByName.md +21 -0
- data/docs/ContainerProjectTag.md +19 -0
- data/docs/ContainerProjectTagAllOf.md +19 -0
- data/docs/ContainerResourceQuota.md +35 -0
- data/docs/ContainerResourceQuotaAllOf.md +35 -0
- data/docs/ContainerTemplate.md +31 -0
- data/docs/ContainerTemplateAllOf.md +31 -0
- data/docs/ContainerTemplateReference.md +21 -0
- data/docs/ContainerTemplateTag.md +19 -0
- data/docs/ContainerTemplateTagAllOf.md +19 -0
- data/docs/CrossLinkVmReference.md +21 -0
- data/docs/CrossLinkVmReferenceReference.md +17 -0
- data/docs/Datastore.md +37 -0
- data/docs/DatastoreAllOf.md +37 -0
- data/docs/DatastoreMount.md +23 -0
- data/docs/DatastoreMountAllOf.md +23 -0
- data/docs/DatastoreReference.md +21 -0
- data/docs/DatastoreReferenceReference.md +17 -0
- data/docs/DatastoreTag.md +19 -0
- data/docs/DatastoreTagAllOf.md +19 -0
- data/docs/DefaultApi.md +97 -0
- data/docs/Flavor.md +33 -0
- data/docs/FlavorAllOf.md +33 -0
- data/docs/FlavorReference.md +21 -0
- data/docs/FlavorReferenceReference.md +17 -0
- data/docs/Host.md +43 -0
- data/docs/HostAllOf.md +43 -0
- data/docs/HostReference.md +21 -0
- data/docs/HostTag.md +19 -0
- data/docs/HostTagAllOf.md +19 -0
- data/docs/Inventory.md +33 -0
- data/docs/InventoryCollection.md +21 -0
- data/docs/InventoryCollectionCluster.md +21 -0
- data/docs/InventoryCollectionClusterTag.md +21 -0
- data/docs/InventoryCollectionContainer.md +21 -0
- data/docs/InventoryCollectionContainerGroup.md +21 -0
- data/docs/InventoryCollectionContainerGroupTag.md +21 -0
- data/docs/InventoryCollectionContainerImage.md +21 -0
- data/docs/InventoryCollectionContainerImageTag.md +21 -0
- data/docs/InventoryCollectionContainerNode.md +21 -0
- data/docs/InventoryCollectionContainerNodeTag.md +21 -0
- data/docs/InventoryCollectionContainerProject.md +21 -0
- data/docs/InventoryCollectionContainerProjectTag.md +21 -0
- data/docs/InventoryCollectionContainerResourceQuota.md +21 -0
- data/docs/InventoryCollectionContainerTemplate.md +21 -0
- data/docs/InventoryCollectionContainerTemplateTag.md +21 -0
- data/docs/InventoryCollectionDatastore.md +21 -0
- data/docs/InventoryCollectionDatastoreMount.md +21 -0
- data/docs/InventoryCollectionDatastoreTag.md +21 -0
- data/docs/InventoryCollectionFlavor.md +21 -0
- data/docs/InventoryCollectionHost.md +21 -0
- data/docs/InventoryCollectionHostTag.md +21 -0
- data/docs/InventoryCollectionIpaddress.md +21 -0
- data/docs/InventoryCollectionIpaddressTag.md +21 -0
- data/docs/InventoryCollectionNetwork.md +21 -0
- data/docs/InventoryCollectionNetworkAdapter.md +21 -0
- data/docs/InventoryCollectionNetworkAdapterTag.md +21 -0
- data/docs/InventoryCollectionNetworkTag.md +21 -0
- data/docs/InventoryCollectionOrchestrationStack.md +21 -0
- data/docs/InventoryCollectionReservation.md +21 -0
- data/docs/InventoryCollectionReservationTag.md +21 -0
- data/docs/InventoryCollectionSecurityGroup.md +21 -0
- data/docs/InventoryCollectionSecurityGroupTag.md +21 -0
- data/docs/InventoryCollectionServiceCredential.md +21 -0
- data/docs/InventoryCollectionServiceInstance.md +21 -0
- data/docs/InventoryCollectionServiceInstanceNode.md +21 -0
- data/docs/InventoryCollectionServiceInventory.md +21 -0
- data/docs/InventoryCollectionServiceInventoryTag.md +21 -0
- data/docs/InventoryCollectionServiceOffering.md +21 -0
- data/docs/InventoryCollectionServiceOfferingIcon.md +21 -0
- data/docs/InventoryCollectionServiceOfferingNode.md +21 -0
- data/docs/InventoryCollectionServiceOfferingTag.md +21 -0
- data/docs/InventoryCollectionServicePlan.md +21 -0
- data/docs/InventoryCollectionSourceRegion.md +21 -0
- data/docs/InventoryCollectionSubnet.md +21 -0
- data/docs/InventoryCollectionSubnetTag.md +21 -0
- data/docs/InventoryCollectionSubscription.md +21 -0
- data/docs/InventoryCollectionTag.md +21 -0
- data/docs/InventoryCollectionVm.md +21 -0
- data/docs/InventoryCollectionVmSecurityGroup.md +21 -0
- data/docs/InventoryCollectionVmTag.md +21 -0
- data/docs/InventoryCollectionVolume.md +21 -0
- data/docs/InventoryCollectionVolumeAttachment.md +21 -0
- data/docs/InventoryCollectionVolumeType.md +21 -0
- data/docs/InventoryObjectLazy.md +21 -0
- data/docs/Ipaddress.md +41 -0
- data/docs/IpaddressAllOf.md +41 -0
- data/docs/IpaddressReference.md +21 -0
- data/docs/IpaddressTag.md +19 -0
- data/docs/IpaddressTagAllOf.md +19 -0
- data/docs/Network.md +39 -0
- data/docs/NetworkAdapter.md +37 -0
- data/docs/NetworkAdapterAllOf.md +37 -0
- data/docs/NetworkAdapterReference.md +21 -0
- data/docs/NetworkAdapterTag.md +19 -0
- data/docs/NetworkAdapterTagAllOf.md +19 -0
- data/docs/NetworkAllOf.md +39 -0
- data/docs/NetworkReference.md +21 -0
- data/docs/NetworkTag.md +19 -0
- data/docs/NetworkTagAllOf.md +19 -0
- data/docs/OrchestrationStack.md +35 -0
- data/docs/OrchestrationStackAllOf.md +35 -0
- data/docs/OrchestrationStackReference.md +21 -0
- data/docs/Reservation.md +39 -0
- data/docs/ReservationAllOf.md +39 -0
- data/docs/ReservationReference.md +21 -0
- data/docs/ReservationTag.md +19 -0
- data/docs/ReservationTagAllOf.md +19 -0
- data/docs/Schema.md +17 -0
- data/docs/SecurityGroup.md +39 -0
- data/docs/SecurityGroupAllOf.md +39 -0
- data/docs/SecurityGroupReference.md +21 -0
- data/docs/SecurityGroupTag.md +19 -0
- data/docs/SecurityGroupTagAllOf.md +19 -0
- data/docs/ServiceCredential.md +31 -0
- data/docs/ServiceCredentialAllOf.md +31 -0
- data/docs/ServiceCredentialReference.md +21 -0
- data/docs/ServiceInstance.md +45 -0
- data/docs/ServiceInstanceAllOf.md +45 -0
- data/docs/ServiceInstanceNode.md +37 -0
- data/docs/ServiceInstanceNodeAllOf.md +37 -0
- data/docs/ServiceInstanceReference.md +21 -0
- data/docs/ServiceInventory.md +31 -0
- data/docs/ServiceInventoryAllOf.md +31 -0
- data/docs/ServiceInventoryReference.md +21 -0
- data/docs/ServiceInventoryTag.md +19 -0
- data/docs/ServiceInventoryTagAllOf.md +19 -0
- data/docs/ServiceOffering.md +51 -0
- data/docs/ServiceOfferingAllOf.md +51 -0
- data/docs/ServiceOfferingIcon.md +19 -0
- data/docs/ServiceOfferingIconAllOf.md +19 -0
- data/docs/ServiceOfferingIconReference.md +21 -0
- data/docs/ServiceOfferingNode.md +37 -0
- data/docs/ServiceOfferingNodeAllOf.md +37 -0
- data/docs/ServiceOfferingReference.md +21 -0
- data/docs/ServiceOfferingTag.md +19 -0
- data/docs/ServiceOfferingTagAllOf.md +19 -0
- data/docs/ServicePlan.md +43 -0
- data/docs/ServicePlanAllOf.md +43 -0
- data/docs/ServicePlanReference.md +21 -0
- data/docs/SourceRegion.md +23 -0
- data/docs/SourceRegionAllOf.md +23 -0
- data/docs/SourceRegionReference.md +21 -0
- data/docs/Subnet.md +41 -0
- data/docs/SubnetAllOf.md +41 -0
- data/docs/SubnetReference.md +21 -0
- data/docs/SubnetTag.md +19 -0
- data/docs/SubnetTagAllOf.md +19 -0
- data/docs/Subscription.md +21 -0
- data/docs/SubscriptionAllOf.md +21 -0
- data/docs/SubscriptionReference.md +21 -0
- data/docs/Tag.md +23 -0
- data/docs/TagAllOf.md +23 -0
- data/docs/TagReference.md +21 -0
- data/docs/TagReferenceReference.md +21 -0
- data/docs/Vm.md +55 -0
- data/docs/VmAllOf.md +55 -0
- data/docs/VmReference.md +21 -0
- data/docs/VmSecurityGroup.md +19 -0
- data/docs/VmSecurityGroupAllOf.md +19 -0
- data/docs/VmTag.md +19 -0
- data/docs/VmTagAllOf.md +19 -0
- data/docs/Volume.md +41 -0
- data/docs/VolumeAllOf.md +41 -0
- data/docs/VolumeAttachment.md +23 -0
- data/docs/VolumeAttachmentAllOf.md +23 -0
- data/docs/VolumeReference.md +21 -0
- data/docs/VolumeType.md +25 -0
- data/docs/VolumeTypeAllOf.md +25 -0
- data/docs/VolumeTypeReference.md +21 -0
- data/git_push.sh +58 -0
- data/lib/topological_inventory-ingress_api-client.rb +237 -0
- data/lib/topological_inventory-ingress_api-client/api/default_api.rb +138 -0
- data/lib/topological_inventory-ingress_api-client/api_client.rb +385 -0
- data/lib/topological_inventory-ingress_api-client/api_error.rb +57 -0
- data/lib/topological_inventory-ingress_api-client/configuration.rb +261 -0
- data/lib/topological_inventory-ingress_api-client/models/cluster.rb +289 -0
- data/lib/topological_inventory-ingress_api-client/models/cluster_all_of.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/cluster_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/cluster_reference_reference.rb +211 -0
- data/lib/topological_inventory-ingress_api-client/models/cluster_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/cluster_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/container.rb +303 -0
- data/lib/topological_inventory-ingress_api-client/models/container_all_of.rb +295 -0
- data/lib/topological_inventory-ingress_api-client/models/container_group.rb +307 -0
- data/lib/topological_inventory-ingress_api-client/models/container_group_all_of.rb +299 -0
- data/lib/topological_inventory-ingress_api-client/models/container_group_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/container_group_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/container_group_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/container_image.rb +289 -0
- data/lib/topological_inventory-ingress_api-client/models/container_image_all_of.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/container_image_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/container_image_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/container_image_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/container_node.rb +383 -0
- data/lib/topological_inventory-ingress_api-client/models/container_node_all_of.rb +375 -0
- data/lib/topological_inventory-ingress_api-client/models/container_node_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/container_node_reference_by_name.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/container_node_reference_by_name_reference.rb +207 -0
- data/lib/topological_inventory-ingress_api-client/models/container_node_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/container_node_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/container_project.rb +299 -0
- data/lib/topological_inventory-ingress_api-client/models/container_project_all_of.rb +291 -0
- data/lib/topological_inventory-ingress_api-client/models/container_project_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/container_project_reference_by_name.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/container_project_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/container_project_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/container_resource_quota.rb +308 -0
- data/lib/topological_inventory-ingress_api-client/models/container_resource_quota_all_of.rb +300 -0
- data/lib/topological_inventory-ingress_api-client/models/container_template.rb +288 -0
- data/lib/topological_inventory-ingress_api-client/models/container_template_all_of.rb +280 -0
- data/lib/topological_inventory-ingress_api-client/models/container_template_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/container_template_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/container_template_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/cross_link_vm_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/cross_link_vm_reference_reference.rb +207 -0
- data/lib/topological_inventory-ingress_api-client/models/datastore.rb +327 -0
- data/lib/topological_inventory-ingress_api-client/models/datastore_all_of.rb +319 -0
- data/lib/topological_inventory-ingress_api-client/models/datastore_mount.rb +253 -0
- data/lib/topological_inventory-ingress_api-client/models/datastore_mount_all_of.rb +245 -0
- data/lib/topological_inventory-ingress_api-client/models/datastore_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/datastore_reference_reference.rb +212 -0
- data/lib/topological_inventory-ingress_api-client/models/datastore_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/datastore_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/flavor.rb +307 -0
- data/lib/topological_inventory-ingress_api-client/models/flavor_all_of.rb +299 -0
- data/lib/topological_inventory-ingress_api-client/models/flavor_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/flavor_reference_reference.rb +212 -0
- data/lib/topological_inventory-ingress_api-client/models/host.rb +349 -0
- data/lib/topological_inventory-ingress_api-client/models/host_all_of.rb +341 -0
- data/lib/topological_inventory-ingress_api-client/models/host_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/host_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/host_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory.rb +280 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_cluster.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_cluster_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_group.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_group_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_image.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_image_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_node.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_node_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_project.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_project_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_resource_quota.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_template.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_container_template_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_datastore.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_datastore_mount.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_datastore_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_flavor.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_host.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_host_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_ipaddress.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_ipaddress_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_network.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_network_adapter.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_network_adapter_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_network_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_orchestration_stack.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_reservation.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_reservation_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_security_group.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_security_group_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_credential.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_instance.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_instance_node.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_inventory.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_inventory_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_offering.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_offering_icon.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_offering_node.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_offering_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_service_plan.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_source_region.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_subnet.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_subnet_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_subscription.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_vm.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_vm_security_group.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_vm_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_volume.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_volume_attachment.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_collection_volume_type.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/inventory_object_lazy.rb +239 -0
- data/lib/topological_inventory-ingress_api-client/models/ipaddress.rb +377 -0
- data/lib/topological_inventory-ingress_api-client/models/ipaddress_all_of.rb +369 -0
- data/lib/topological_inventory-ingress_api-client/models/ipaddress_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/ipaddress_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/ipaddress_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/network.rb +329 -0
- data/lib/topological_inventory-ingress_api-client/models/network_adapter.rb +318 -0
- data/lib/topological_inventory-ingress_api-client/models/network_adapter_all_of.rb +310 -0
- data/lib/topological_inventory-ingress_api-client/models/network_adapter_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/network_adapter_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/network_adapter_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/network_all_of.rb +321 -0
- data/lib/topological_inventory-ingress_api-client/models/network_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/network_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/network_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/orchestration_stack.rb +309 -0
- data/lib/topological_inventory-ingress_api-client/models/orchestration_stack_all_of.rb +301 -0
- data/lib/topological_inventory-ingress_api-client/models/orchestration_stack_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/reservation.rb +329 -0
- data/lib/topological_inventory-ingress_api-client/models/reservation_all_of.rb +321 -0
- data/lib/topological_inventory-ingress_api-client/models/reservation_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/reservation_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/reservation_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/schema.rb +206 -0
- data/lib/topological_inventory-ingress_api-client/models/security_group.rb +329 -0
- data/lib/topological_inventory-ingress_api-client/models/security_group_all_of.rb +321 -0
- data/lib/topological_inventory-ingress_api-client/models/security_group_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/security_group_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/security_group_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/service_credential.rb +289 -0
- data/lib/topological_inventory-ingress_api-client/models/service_credential_all_of.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/service_credential_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/service_instance.rb +360 -0
- data/lib/topological_inventory-ingress_api-client/models/service_instance_all_of.rb +352 -0
- data/lib/topological_inventory-ingress_api-client/models/service_instance_node.rb +319 -0
- data/lib/topological_inventory-ingress_api-client/models/service_instance_node_all_of.rb +311 -0
- data/lib/topological_inventory-ingress_api-client/models/service_instance_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/service_inventory.rb +289 -0
- data/lib/topological_inventory-ingress_api-client/models/service_inventory_all_of.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/service_inventory_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/service_inventory_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/service_inventory_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering.rb +389 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_all_of.rb +381 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_icon.rb +229 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_icon_all_of.rb +221 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_icon_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_node.rb +319 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_node_all_of.rb +311 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/service_offering_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/service_plan.rb +349 -0
- data/lib/topological_inventory-ingress_api-client/models/service_plan_all_of.rb +341 -0
- data/lib/topological_inventory-ingress_api-client/models/service_plan_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/source_region.rb +249 -0
- data/lib/topological_inventory-ingress_api-client/models/source_region_all_of.rb +241 -0
- data/lib/topological_inventory-ingress_api-client/models/source_region_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/subnet.rb +339 -0
- data/lib/topological_inventory-ingress_api-client/models/subnet_all_of.rb +331 -0
- data/lib/topological_inventory-ingress_api-client/models/subnet_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/subnet_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/subnet_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/subscription.rb +239 -0
- data/lib/topological_inventory-ingress_api-client/models/subscription_all_of.rb +231 -0
- data/lib/topological_inventory-ingress_api-client/models/subscription_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/tag.rb +257 -0
- data/lib/topological_inventory-ingress_api-client/models/tag_all_of.rb +249 -0
- data/lib/topological_inventory-ingress_api-client/models/tag_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/tag_reference_reference.rb +239 -0
- data/lib/topological_inventory-ingress_api-client/models/vm.rb +413 -0
- data/lib/topological_inventory-ingress_api-client/models/vm_all_of.rb +405 -0
- data/lib/topological_inventory-ingress_api-client/models/vm_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/vm_security_group.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/vm_security_group_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/vm_tag.rb +233 -0
- data/lib/topological_inventory-ingress_api-client/models/vm_tag_all_of.rb +225 -0
- data/lib/topological_inventory-ingress_api-client/models/volume.rb +339 -0
- data/lib/topological_inventory-ingress_api-client/models/volume_all_of.rb +331 -0
- data/lib/topological_inventory-ingress_api-client/models/volume_attachment.rb +253 -0
- data/lib/topological_inventory-ingress_api-client/models/volume_attachment_all_of.rb +245 -0
- data/lib/topological_inventory-ingress_api-client/models/volume_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/models/volume_type.rb +259 -0
- data/lib/topological_inventory-ingress_api-client/models/volume_type_all_of.rb +251 -0
- data/lib/topological_inventory-ingress_api-client/models/volume_type_reference.rb +281 -0
- data/lib/topological_inventory-ingress_api-client/version.rb +15 -0
- data/spec/api/default_api_spec.rb +57 -0
- data/spec/api_client_spec.rb +226 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/cluster_all_of_spec.rb +83 -0
- data/spec/models/cluster_reference_reference_spec.rb +41 -0
- data/spec/models/cluster_reference_spec.rb +53 -0
- data/spec/models/cluster_spec.rb +83 -0
- data/spec/models/cluster_tag_all_of_spec.rb +47 -0
- data/spec/models/cluster_tag_spec.rb +47 -0
- data/spec/models/container_all_of_spec.rb +89 -0
- data/spec/models/container_group_all_of_spec.rb +95 -0
- data/spec/models/container_group_reference_spec.rb +53 -0
- data/spec/models/container_group_spec.rb +95 -0
- data/spec/models/container_group_tag_all_of_spec.rb +47 -0
- data/spec/models/container_group_tag_spec.rb +47 -0
- data/spec/models/container_image_all_of_spec.rb +83 -0
- data/spec/models/container_image_reference_spec.rb +53 -0
- data/spec/models/container_image_spec.rb +83 -0
- data/spec/models/container_image_tag_all_of_spec.rb +47 -0
- data/spec/models/container_image_tag_spec.rb +47 -0
- data/spec/models/container_node_all_of_spec.rb +137 -0
- data/spec/models/container_node_reference_by_name_reference_spec.rb +41 -0
- data/spec/models/container_node_reference_by_name_spec.rb +53 -0
- data/spec/models/container_node_reference_spec.rb +53 -0
- data/spec/models/container_node_spec.rb +137 -0
- data/spec/models/container_node_tag_all_of_spec.rb +47 -0
- data/spec/models/container_node_tag_spec.rb +47 -0
- data/spec/models/container_project_all_of_spec.rb +89 -0
- data/spec/models/container_project_reference_by_name_spec.rb +53 -0
- data/spec/models/container_project_reference_spec.rb +53 -0
- data/spec/models/container_project_spec.rb +89 -0
- data/spec/models/container_project_tag_all_of_spec.rb +47 -0
- data/spec/models/container_project_tag_spec.rb +47 -0
- data/spec/models/container_resource_quota_all_of_spec.rb +95 -0
- data/spec/models/container_resource_quota_spec.rb +95 -0
- data/spec/models/container_spec.rb +89 -0
- data/spec/models/container_template_all_of_spec.rb +83 -0
- data/spec/models/container_template_reference_spec.rb +53 -0
- data/spec/models/container_template_spec.rb +83 -0
- data/spec/models/container_template_tag_all_of_spec.rb +47 -0
- data/spec/models/container_template_tag_spec.rb +47 -0
- data/spec/models/cross_link_vm_reference_reference_spec.rb +41 -0
- data/spec/models/cross_link_vm_reference_spec.rb +53 -0
- data/spec/models/datastore_all_of_spec.rb +101 -0
- data/spec/models/datastore_mount_all_of_spec.rb +59 -0
- data/spec/models/datastore_mount_spec.rb +59 -0
- data/spec/models/datastore_reference_reference_spec.rb +41 -0
- data/spec/models/datastore_reference_spec.rb +53 -0
- data/spec/models/datastore_spec.rb +101 -0
- data/spec/models/datastore_tag_all_of_spec.rb +47 -0
- data/spec/models/datastore_tag_spec.rb +47 -0
- data/spec/models/flavor_all_of_spec.rb +89 -0
- data/spec/models/flavor_reference_reference_spec.rb +41 -0
- data/spec/models/flavor_reference_spec.rb +53 -0
- data/spec/models/flavor_spec.rb +89 -0
- data/spec/models/host_all_of_spec.rb +119 -0
- data/spec/models/host_reference_spec.rb +53 -0
- data/spec/models/host_spec.rb +119 -0
- data/spec/models/host_tag_all_of_spec.rb +47 -0
- data/spec/models/host_tag_spec.rb +47 -0
- data/spec/models/inventory_collection_cluster_spec.rb +53 -0
- data/spec/models/inventory_collection_cluster_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_container_group_spec.rb +53 -0
- data/spec/models/inventory_collection_container_group_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_container_image_spec.rb +53 -0
- data/spec/models/inventory_collection_container_image_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_container_node_spec.rb +53 -0
- data/spec/models/inventory_collection_container_node_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_container_project_spec.rb +53 -0
- data/spec/models/inventory_collection_container_project_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_container_resource_quota_spec.rb +53 -0
- data/spec/models/inventory_collection_container_spec.rb +53 -0
- data/spec/models/inventory_collection_container_template_spec.rb +53 -0
- data/spec/models/inventory_collection_container_template_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_datastore_mount_spec.rb +53 -0
- data/spec/models/inventory_collection_datastore_spec.rb +53 -0
- data/spec/models/inventory_collection_datastore_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_flavor_spec.rb +53 -0
- data/spec/models/inventory_collection_host_spec.rb +53 -0
- data/spec/models/inventory_collection_host_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_ipaddress_spec.rb +53 -0
- data/spec/models/inventory_collection_ipaddress_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_network_adapter_spec.rb +53 -0
- data/spec/models/inventory_collection_network_adapter_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_network_spec.rb +53 -0
- data/spec/models/inventory_collection_network_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_orchestration_stack_spec.rb +53 -0
- data/spec/models/inventory_collection_reservation_spec.rb +53 -0
- data/spec/models/inventory_collection_reservation_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_security_group_spec.rb +53 -0
- data/spec/models/inventory_collection_security_group_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_service_credential_spec.rb +53 -0
- data/spec/models/inventory_collection_service_instance_node_spec.rb +53 -0
- data/spec/models/inventory_collection_service_instance_spec.rb +53 -0
- data/spec/models/inventory_collection_service_inventory_spec.rb +53 -0
- data/spec/models/inventory_collection_service_inventory_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_service_offering_icon_spec.rb +53 -0
- data/spec/models/inventory_collection_service_offering_node_spec.rb +53 -0
- data/spec/models/inventory_collection_service_offering_spec.rb +53 -0
- data/spec/models/inventory_collection_service_offering_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_service_plan_spec.rb +53 -0
- data/spec/models/inventory_collection_source_region_spec.rb +53 -0
- data/spec/models/inventory_collection_spec.rb +53 -0
- data/spec/models/inventory_collection_subnet_spec.rb +53 -0
- data/spec/models/inventory_collection_subnet_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_subscription_spec.rb +53 -0
- data/spec/models/inventory_collection_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_vm_security_group_spec.rb +53 -0
- data/spec/models/inventory_collection_vm_spec.rb +53 -0
- data/spec/models/inventory_collection_vm_tag_spec.rb +53 -0
- data/spec/models/inventory_collection_volume_attachment_spec.rb +53 -0
- data/spec/models/inventory_collection_volume_spec.rb +53 -0
- data/spec/models/inventory_collection_volume_type_spec.rb +53 -0
- data/spec/models/inventory_object_lazy_spec.rb +53 -0
- data/spec/models/inventory_spec.rb +89 -0
- data/spec/models/ipaddress_all_of_spec.rb +117 -0
- data/spec/models/ipaddress_reference_spec.rb +53 -0
- data/spec/models/ipaddress_spec.rb +117 -0
- data/spec/models/ipaddress_tag_all_of_spec.rb +47 -0
- data/spec/models/ipaddress_tag_spec.rb +47 -0
- data/spec/models/network_adapter_all_of_spec.rb +101 -0
- data/spec/models/network_adapter_reference_spec.rb +53 -0
- data/spec/models/network_adapter_spec.rb +101 -0
- data/spec/models/network_adapter_tag_all_of_spec.rb +47 -0
- data/spec/models/network_adapter_tag_spec.rb +47 -0
- data/spec/models/network_all_of_spec.rb +107 -0
- data/spec/models/network_reference_spec.rb +53 -0
- data/spec/models/network_spec.rb +107 -0
- data/spec/models/network_tag_all_of_spec.rb +47 -0
- data/spec/models/network_tag_spec.rb +47 -0
- data/spec/models/orchestration_stack_all_of_spec.rb +95 -0
- data/spec/models/orchestration_stack_reference_spec.rb +53 -0
- data/spec/models/orchestration_stack_spec.rb +95 -0
- data/spec/models/reservation_all_of_spec.rb +107 -0
- data/spec/models/reservation_reference_spec.rb +53 -0
- data/spec/models/reservation_spec.rb +107 -0
- data/spec/models/reservation_tag_all_of_spec.rb +47 -0
- data/spec/models/reservation_tag_spec.rb +47 -0
- data/spec/models/schema_spec.rb +41 -0
- data/spec/models/security_group_all_of_spec.rb +107 -0
- data/spec/models/security_group_reference_spec.rb +53 -0
- data/spec/models/security_group_spec.rb +107 -0
- data/spec/models/security_group_tag_all_of_spec.rb +47 -0
- data/spec/models/security_group_tag_spec.rb +47 -0
- data/spec/models/service_credential_all_of_spec.rb +83 -0
- data/spec/models/service_credential_reference_spec.rb +53 -0
- data/spec/models/service_credential_spec.rb +83 -0
- data/spec/models/service_instance_all_of_spec.rb +125 -0
- data/spec/models/service_instance_node_all_of_spec.rb +101 -0
- data/spec/models/service_instance_node_spec.rb +95 -0
- data/spec/models/service_instance_reference_spec.rb +53 -0
- data/spec/models/service_instance_spec.rb +119 -0
- data/spec/models/service_inventory_all_of_spec.rb +83 -0
- data/spec/models/service_inventory_reference_spec.rb +53 -0
- data/spec/models/service_inventory_spec.rb +83 -0
- data/spec/models/service_inventory_tag_all_of_spec.rb +47 -0
- data/spec/models/service_inventory_tag_spec.rb +47 -0
- data/spec/models/service_offering_all_of_spec.rb +143 -0
- data/spec/models/service_offering_icon_all_of_spec.rb +47 -0
- data/spec/models/service_offering_icon_reference_spec.rb +53 -0
- data/spec/models/service_offering_icon_spec.rb +47 -0
- data/spec/models/service_offering_node_all_of_spec.rb +101 -0
- data/spec/models/service_offering_node_spec.rb +95 -0
- data/spec/models/service_offering_reference_spec.rb +53 -0
- data/spec/models/service_offering_spec.rb +137 -0
- data/spec/models/service_offering_tag_all_of_spec.rb +47 -0
- data/spec/models/service_offering_tag_spec.rb +47 -0
- data/spec/models/service_plan_all_of_spec.rb +119 -0
- data/spec/models/service_plan_reference_spec.rb +53 -0
- data/spec/models/service_plan_spec.rb +119 -0
- data/spec/models/source_region_all_of_spec.rb +59 -0
- data/spec/models/source_region_reference_spec.rb +53 -0
- data/spec/models/source_region_spec.rb +59 -0
- data/spec/models/subnet_all_of_spec.rb +113 -0
- data/spec/models/subnet_reference_spec.rb +53 -0
- data/spec/models/subnet_spec.rb +113 -0
- data/spec/models/subnet_tag_all_of_spec.rb +47 -0
- data/spec/models/subnet_tag_spec.rb +47 -0
- data/spec/models/subscription_all_of_spec.rb +53 -0
- data/spec/models/subscription_reference_spec.rb +53 -0
- data/spec/models/subscription_spec.rb +53 -0
- data/spec/models/tag_all_of_spec.rb +59 -0
- data/spec/models/tag_reference_reference_spec.rb +53 -0
- data/spec/models/tag_reference_spec.rb +53 -0
- data/spec/models/tag_spec.rb +59 -0
- data/spec/models/vm_all_of_spec.rb +155 -0
- data/spec/models/vm_reference_spec.rb +53 -0
- data/spec/models/vm_security_group_all_of_spec.rb +47 -0
- data/spec/models/vm_security_group_spec.rb +47 -0
- data/spec/models/vm_spec.rb +149 -0
- data/spec/models/vm_tag_all_of_spec.rb +47 -0
- data/spec/models/vm_tag_spec.rb +47 -0
- data/spec/models/volume_all_of_spec.rb +113 -0
- data/spec/models/volume_attachment_all_of_spec.rb +59 -0
- data/spec/models/volume_attachment_spec.rb +59 -0
- data/spec/models/volume_reference_spec.rb +53 -0
- data/spec/models/volume_spec.rb +113 -0
- data/spec/models/volume_type_all_of_spec.rb +65 -0
- data/spec/models/volume_type_reference_spec.rb +53 -0
- data/spec/models/volume_type_spec.rb +65 -0
- data/spec/spec_helper.rb +111 -0
- data/topological_inventory-ingress_api-client.gemspec +45 -0
- metadata +1032 -0
@@ -0,0 +1,237 @@
|
|
1
|
+
=begin
|
2
|
+
#Topological Inventory Ingress API
|
3
|
+
|
4
|
+
#Topological Inventory Ingress API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 0.0.2
|
7
|
+
Contact: support@redhat.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.2.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
# Common files
|
14
|
+
require 'topological_inventory-ingress_api-client/api_client'
|
15
|
+
require 'topological_inventory-ingress_api-client/api_error'
|
16
|
+
require 'topological_inventory-ingress_api-client/version'
|
17
|
+
require 'topological_inventory-ingress_api-client/configuration'
|
18
|
+
|
19
|
+
# Models
|
20
|
+
require 'topological_inventory-ingress_api-client/models/cluster'
|
21
|
+
require 'topological_inventory-ingress_api-client/models/cluster_all_of'
|
22
|
+
require 'topological_inventory-ingress_api-client/models/cluster_reference'
|
23
|
+
require 'topological_inventory-ingress_api-client/models/cluster_reference_reference'
|
24
|
+
require 'topological_inventory-ingress_api-client/models/cluster_tag'
|
25
|
+
require 'topological_inventory-ingress_api-client/models/cluster_tag_all_of'
|
26
|
+
require 'topological_inventory-ingress_api-client/models/container'
|
27
|
+
require 'topological_inventory-ingress_api-client/models/container_all_of'
|
28
|
+
require 'topological_inventory-ingress_api-client/models/container_group'
|
29
|
+
require 'topological_inventory-ingress_api-client/models/container_group_all_of'
|
30
|
+
require 'topological_inventory-ingress_api-client/models/container_group_reference'
|
31
|
+
require 'topological_inventory-ingress_api-client/models/container_group_tag'
|
32
|
+
require 'topological_inventory-ingress_api-client/models/container_group_tag_all_of'
|
33
|
+
require 'topological_inventory-ingress_api-client/models/container_image'
|
34
|
+
require 'topological_inventory-ingress_api-client/models/container_image_all_of'
|
35
|
+
require 'topological_inventory-ingress_api-client/models/container_image_reference'
|
36
|
+
require 'topological_inventory-ingress_api-client/models/container_image_tag'
|
37
|
+
require 'topological_inventory-ingress_api-client/models/container_image_tag_all_of'
|
38
|
+
require 'topological_inventory-ingress_api-client/models/container_node'
|
39
|
+
require 'topological_inventory-ingress_api-client/models/container_node_all_of'
|
40
|
+
require 'topological_inventory-ingress_api-client/models/container_node_reference'
|
41
|
+
require 'topological_inventory-ingress_api-client/models/container_node_reference_by_name'
|
42
|
+
require 'topological_inventory-ingress_api-client/models/container_node_reference_by_name_reference'
|
43
|
+
require 'topological_inventory-ingress_api-client/models/container_node_tag'
|
44
|
+
require 'topological_inventory-ingress_api-client/models/container_node_tag_all_of'
|
45
|
+
require 'topological_inventory-ingress_api-client/models/container_project'
|
46
|
+
require 'topological_inventory-ingress_api-client/models/container_project_all_of'
|
47
|
+
require 'topological_inventory-ingress_api-client/models/container_project_reference'
|
48
|
+
require 'topological_inventory-ingress_api-client/models/container_project_reference_by_name'
|
49
|
+
require 'topological_inventory-ingress_api-client/models/container_project_tag'
|
50
|
+
require 'topological_inventory-ingress_api-client/models/container_project_tag_all_of'
|
51
|
+
require 'topological_inventory-ingress_api-client/models/container_resource_quota'
|
52
|
+
require 'topological_inventory-ingress_api-client/models/container_resource_quota_all_of'
|
53
|
+
require 'topological_inventory-ingress_api-client/models/container_template'
|
54
|
+
require 'topological_inventory-ingress_api-client/models/container_template_all_of'
|
55
|
+
require 'topological_inventory-ingress_api-client/models/container_template_reference'
|
56
|
+
require 'topological_inventory-ingress_api-client/models/container_template_tag'
|
57
|
+
require 'topological_inventory-ingress_api-client/models/container_template_tag_all_of'
|
58
|
+
require 'topological_inventory-ingress_api-client/models/cross_link_vm_reference'
|
59
|
+
require 'topological_inventory-ingress_api-client/models/cross_link_vm_reference_reference'
|
60
|
+
require 'topological_inventory-ingress_api-client/models/datastore'
|
61
|
+
require 'topological_inventory-ingress_api-client/models/datastore_all_of'
|
62
|
+
require 'topological_inventory-ingress_api-client/models/datastore_mount'
|
63
|
+
require 'topological_inventory-ingress_api-client/models/datastore_mount_all_of'
|
64
|
+
require 'topological_inventory-ingress_api-client/models/datastore_reference'
|
65
|
+
require 'topological_inventory-ingress_api-client/models/datastore_reference_reference'
|
66
|
+
require 'topological_inventory-ingress_api-client/models/datastore_tag'
|
67
|
+
require 'topological_inventory-ingress_api-client/models/datastore_tag_all_of'
|
68
|
+
require 'topological_inventory-ingress_api-client/models/flavor'
|
69
|
+
require 'topological_inventory-ingress_api-client/models/flavor_all_of'
|
70
|
+
require 'topological_inventory-ingress_api-client/models/flavor_reference'
|
71
|
+
require 'topological_inventory-ingress_api-client/models/flavor_reference_reference'
|
72
|
+
require 'topological_inventory-ingress_api-client/models/host'
|
73
|
+
require 'topological_inventory-ingress_api-client/models/host_all_of'
|
74
|
+
require 'topological_inventory-ingress_api-client/models/host_reference'
|
75
|
+
require 'topological_inventory-ingress_api-client/models/host_tag'
|
76
|
+
require 'topological_inventory-ingress_api-client/models/host_tag_all_of'
|
77
|
+
require 'topological_inventory-ingress_api-client/models/inventory'
|
78
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection'
|
79
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_cluster'
|
80
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_cluster_tag'
|
81
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container'
|
82
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_group'
|
83
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_group_tag'
|
84
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_image'
|
85
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_image_tag'
|
86
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_node'
|
87
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_node_tag'
|
88
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_project'
|
89
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_project_tag'
|
90
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_resource_quota'
|
91
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_template'
|
92
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_container_template_tag'
|
93
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_datastore'
|
94
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_datastore_mount'
|
95
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_datastore_tag'
|
96
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_flavor'
|
97
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_host'
|
98
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_host_tag'
|
99
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_ipaddress'
|
100
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_ipaddress_tag'
|
101
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_network'
|
102
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_network_adapter'
|
103
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_network_adapter_tag'
|
104
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_network_tag'
|
105
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_orchestration_stack'
|
106
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_reservation'
|
107
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_reservation_tag'
|
108
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_security_group'
|
109
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_security_group_tag'
|
110
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_credential'
|
111
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_instance'
|
112
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_instance_node'
|
113
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_inventory'
|
114
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_inventory_tag'
|
115
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_offering'
|
116
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_offering_icon'
|
117
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_offering_node'
|
118
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_offering_tag'
|
119
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_service_plan'
|
120
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_source_region'
|
121
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_subnet'
|
122
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_subnet_tag'
|
123
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_subscription'
|
124
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_tag'
|
125
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_vm'
|
126
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_vm_security_group'
|
127
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_vm_tag'
|
128
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_volume'
|
129
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_volume_attachment'
|
130
|
+
require 'topological_inventory-ingress_api-client/models/inventory_collection_volume_type'
|
131
|
+
require 'topological_inventory-ingress_api-client/models/inventory_object_lazy'
|
132
|
+
require 'topological_inventory-ingress_api-client/models/ipaddress'
|
133
|
+
require 'topological_inventory-ingress_api-client/models/ipaddress_all_of'
|
134
|
+
require 'topological_inventory-ingress_api-client/models/ipaddress_reference'
|
135
|
+
require 'topological_inventory-ingress_api-client/models/ipaddress_tag'
|
136
|
+
require 'topological_inventory-ingress_api-client/models/ipaddress_tag_all_of'
|
137
|
+
require 'topological_inventory-ingress_api-client/models/network'
|
138
|
+
require 'topological_inventory-ingress_api-client/models/network_adapter'
|
139
|
+
require 'topological_inventory-ingress_api-client/models/network_adapter_all_of'
|
140
|
+
require 'topological_inventory-ingress_api-client/models/network_adapter_reference'
|
141
|
+
require 'topological_inventory-ingress_api-client/models/network_adapter_tag'
|
142
|
+
require 'topological_inventory-ingress_api-client/models/network_adapter_tag_all_of'
|
143
|
+
require 'topological_inventory-ingress_api-client/models/network_all_of'
|
144
|
+
require 'topological_inventory-ingress_api-client/models/network_reference'
|
145
|
+
require 'topological_inventory-ingress_api-client/models/network_tag'
|
146
|
+
require 'topological_inventory-ingress_api-client/models/network_tag_all_of'
|
147
|
+
require 'topological_inventory-ingress_api-client/models/orchestration_stack'
|
148
|
+
require 'topological_inventory-ingress_api-client/models/orchestration_stack_all_of'
|
149
|
+
require 'topological_inventory-ingress_api-client/models/orchestration_stack_reference'
|
150
|
+
require 'topological_inventory-ingress_api-client/models/reservation'
|
151
|
+
require 'topological_inventory-ingress_api-client/models/reservation_all_of'
|
152
|
+
require 'topological_inventory-ingress_api-client/models/reservation_reference'
|
153
|
+
require 'topological_inventory-ingress_api-client/models/reservation_tag'
|
154
|
+
require 'topological_inventory-ingress_api-client/models/reservation_tag_all_of'
|
155
|
+
require 'topological_inventory-ingress_api-client/models/schema'
|
156
|
+
require 'topological_inventory-ingress_api-client/models/security_group'
|
157
|
+
require 'topological_inventory-ingress_api-client/models/security_group_all_of'
|
158
|
+
require 'topological_inventory-ingress_api-client/models/security_group_reference'
|
159
|
+
require 'topological_inventory-ingress_api-client/models/security_group_tag'
|
160
|
+
require 'topological_inventory-ingress_api-client/models/security_group_tag_all_of'
|
161
|
+
require 'topological_inventory-ingress_api-client/models/service_credential'
|
162
|
+
require 'topological_inventory-ingress_api-client/models/service_credential_all_of'
|
163
|
+
require 'topological_inventory-ingress_api-client/models/service_credential_reference'
|
164
|
+
require 'topological_inventory-ingress_api-client/models/service_instance'
|
165
|
+
require 'topological_inventory-ingress_api-client/models/service_instance_all_of'
|
166
|
+
require 'topological_inventory-ingress_api-client/models/service_instance_node'
|
167
|
+
require 'topological_inventory-ingress_api-client/models/service_instance_node_all_of'
|
168
|
+
require 'topological_inventory-ingress_api-client/models/service_instance_reference'
|
169
|
+
require 'topological_inventory-ingress_api-client/models/service_inventory'
|
170
|
+
require 'topological_inventory-ingress_api-client/models/service_inventory_all_of'
|
171
|
+
require 'topological_inventory-ingress_api-client/models/service_inventory_reference'
|
172
|
+
require 'topological_inventory-ingress_api-client/models/service_inventory_tag'
|
173
|
+
require 'topological_inventory-ingress_api-client/models/service_inventory_tag_all_of'
|
174
|
+
require 'topological_inventory-ingress_api-client/models/service_offering'
|
175
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_all_of'
|
176
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_icon'
|
177
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_icon_all_of'
|
178
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_icon_reference'
|
179
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_node'
|
180
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_node_all_of'
|
181
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_reference'
|
182
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_tag'
|
183
|
+
require 'topological_inventory-ingress_api-client/models/service_offering_tag_all_of'
|
184
|
+
require 'topological_inventory-ingress_api-client/models/service_plan'
|
185
|
+
require 'topological_inventory-ingress_api-client/models/service_plan_all_of'
|
186
|
+
require 'topological_inventory-ingress_api-client/models/service_plan_reference'
|
187
|
+
require 'topological_inventory-ingress_api-client/models/source_region'
|
188
|
+
require 'topological_inventory-ingress_api-client/models/source_region_all_of'
|
189
|
+
require 'topological_inventory-ingress_api-client/models/source_region_reference'
|
190
|
+
require 'topological_inventory-ingress_api-client/models/subnet'
|
191
|
+
require 'topological_inventory-ingress_api-client/models/subnet_all_of'
|
192
|
+
require 'topological_inventory-ingress_api-client/models/subnet_reference'
|
193
|
+
require 'topological_inventory-ingress_api-client/models/subnet_tag'
|
194
|
+
require 'topological_inventory-ingress_api-client/models/subnet_tag_all_of'
|
195
|
+
require 'topological_inventory-ingress_api-client/models/subscription'
|
196
|
+
require 'topological_inventory-ingress_api-client/models/subscription_all_of'
|
197
|
+
require 'topological_inventory-ingress_api-client/models/subscription_reference'
|
198
|
+
require 'topological_inventory-ingress_api-client/models/tag'
|
199
|
+
require 'topological_inventory-ingress_api-client/models/tag_all_of'
|
200
|
+
require 'topological_inventory-ingress_api-client/models/tag_reference'
|
201
|
+
require 'topological_inventory-ingress_api-client/models/tag_reference_reference'
|
202
|
+
require 'topological_inventory-ingress_api-client/models/vm'
|
203
|
+
require 'topological_inventory-ingress_api-client/models/vm_all_of'
|
204
|
+
require 'topological_inventory-ingress_api-client/models/vm_reference'
|
205
|
+
require 'topological_inventory-ingress_api-client/models/vm_security_group'
|
206
|
+
require 'topological_inventory-ingress_api-client/models/vm_security_group_all_of'
|
207
|
+
require 'topological_inventory-ingress_api-client/models/vm_tag'
|
208
|
+
require 'topological_inventory-ingress_api-client/models/vm_tag_all_of'
|
209
|
+
require 'topological_inventory-ingress_api-client/models/volume'
|
210
|
+
require 'topological_inventory-ingress_api-client/models/volume_all_of'
|
211
|
+
require 'topological_inventory-ingress_api-client/models/volume_attachment'
|
212
|
+
require 'topological_inventory-ingress_api-client/models/volume_attachment_all_of'
|
213
|
+
require 'topological_inventory-ingress_api-client/models/volume_reference'
|
214
|
+
require 'topological_inventory-ingress_api-client/models/volume_type'
|
215
|
+
require 'topological_inventory-ingress_api-client/models/volume_type_all_of'
|
216
|
+
require 'topological_inventory-ingress_api-client/models/volume_type_reference'
|
217
|
+
|
218
|
+
# APIs
|
219
|
+
require 'topological_inventory-ingress_api-client/api/default_api'
|
220
|
+
|
221
|
+
module TopologicalInventoryIngressApiClient
|
222
|
+
class << self
|
223
|
+
# Customize default settings for the SDK using block.
|
224
|
+
# TopologicalInventoryIngressApiClient.configure do |config|
|
225
|
+
# config.username = "xxx"
|
226
|
+
# config.password = "xxx"
|
227
|
+
# end
|
228
|
+
# If no block given, return the default Configuration object.
|
229
|
+
def configure
|
230
|
+
if block_given?
|
231
|
+
yield(Configuration.default)
|
232
|
+
else
|
233
|
+
Configuration.default
|
234
|
+
end
|
235
|
+
end
|
236
|
+
end
|
237
|
+
end
|
@@ -0,0 +1,138 @@
|
|
1
|
+
=begin
|
2
|
+
#Topological Inventory Ingress API
|
3
|
+
|
4
|
+
#Topological Inventory Ingress API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 0.0.2
|
7
|
+
Contact: support@redhat.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.2.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module TopologicalInventoryIngressApiClient
|
16
|
+
class DefaultApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# Return this API document in JSON format
|
23
|
+
# @param [Hash] opts the optional parameters
|
24
|
+
# @return [nil]
|
25
|
+
def get_documentation(opts = {})
|
26
|
+
get_documentation_with_http_info(opts)
|
27
|
+
nil
|
28
|
+
end
|
29
|
+
|
30
|
+
# Return this API document in JSON format
|
31
|
+
# @param [Hash] opts the optional parameters
|
32
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
33
|
+
def get_documentation_with_http_info(opts = {})
|
34
|
+
if @api_client.config.debugging
|
35
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.get_documentation ...'
|
36
|
+
end
|
37
|
+
# resource path
|
38
|
+
local_var_path = '/openapi.json'
|
39
|
+
|
40
|
+
# query parameters
|
41
|
+
query_params = opts[:query_params] || {}
|
42
|
+
|
43
|
+
# header parameters
|
44
|
+
header_params = opts[:header_params] || {}
|
45
|
+
|
46
|
+
# form parameters
|
47
|
+
form_params = opts[:form_params] || {}
|
48
|
+
|
49
|
+
# http body (model)
|
50
|
+
post_body = opts[:body]
|
51
|
+
|
52
|
+
# return_type
|
53
|
+
return_type = opts[:return_type]
|
54
|
+
|
55
|
+
# auth_names
|
56
|
+
auth_names = opts[:auth_names] || []
|
57
|
+
|
58
|
+
new_options = opts.merge(
|
59
|
+
:header_params => header_params,
|
60
|
+
:query_params => query_params,
|
61
|
+
:form_params => form_params,
|
62
|
+
:body => post_body,
|
63
|
+
:auth_names => auth_names,
|
64
|
+
:return_type => return_type
|
65
|
+
)
|
66
|
+
|
67
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
68
|
+
if @api_client.config.debugging
|
69
|
+
@api_client.config.logger.debug "API called: DefaultApi#get_documentation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
70
|
+
end
|
71
|
+
return data, status_code, headers
|
72
|
+
end
|
73
|
+
|
74
|
+
# save inventory
|
75
|
+
# Submits a payload to be persisted to the database
|
76
|
+
# @param inventory [Inventory] Inventory payload
|
77
|
+
# @param [Hash] opts the optional parameters
|
78
|
+
# @return [Object]
|
79
|
+
def save_inventory(inventory, opts = {})
|
80
|
+
data, _status_code, _headers = save_inventory_with_http_info(inventory, opts)
|
81
|
+
data
|
82
|
+
end
|
83
|
+
|
84
|
+
# save inventory
|
85
|
+
# Submits a payload to be persisted to the database
|
86
|
+
# @param inventory [Inventory] Inventory payload
|
87
|
+
# @param [Hash] opts the optional parameters
|
88
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
89
|
+
def save_inventory_with_http_info(inventory, opts = {})
|
90
|
+
if @api_client.config.debugging
|
91
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.save_inventory ...'
|
92
|
+
end
|
93
|
+
# verify the required parameter 'inventory' is set
|
94
|
+
if @api_client.config.client_side_validation && inventory.nil?
|
95
|
+
fail ArgumentError, "Missing the required parameter 'inventory' when calling DefaultApi.save_inventory"
|
96
|
+
end
|
97
|
+
# resource path
|
98
|
+
local_var_path = '/inventory'
|
99
|
+
|
100
|
+
# query parameters
|
101
|
+
query_params = opts[:query_params] || {}
|
102
|
+
|
103
|
+
# header parameters
|
104
|
+
header_params = opts[:header_params] || {}
|
105
|
+
# HTTP header 'Accept' (if needed)
|
106
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
107
|
+
# HTTP header 'Content-Type'
|
108
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
109
|
+
|
110
|
+
# form parameters
|
111
|
+
form_params = opts[:form_params] || {}
|
112
|
+
|
113
|
+
# http body (model)
|
114
|
+
post_body = opts[:body] || @api_client.object_to_http_body(inventory)
|
115
|
+
|
116
|
+
# return_type
|
117
|
+
return_type = opts[:return_type] || 'Object'
|
118
|
+
|
119
|
+
# auth_names
|
120
|
+
auth_names = opts[:auth_names] || []
|
121
|
+
|
122
|
+
new_options = opts.merge(
|
123
|
+
:header_params => header_params,
|
124
|
+
:query_params => query_params,
|
125
|
+
:form_params => form_params,
|
126
|
+
:body => post_body,
|
127
|
+
:auth_names => auth_names,
|
128
|
+
:return_type => return_type
|
129
|
+
)
|
130
|
+
|
131
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
132
|
+
if @api_client.config.debugging
|
133
|
+
@api_client.config.logger.debug "API called: DefaultApi#save_inventory\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
134
|
+
end
|
135
|
+
return data, status_code, headers
|
136
|
+
end
|
137
|
+
end
|
138
|
+
end
|
@@ -0,0 +1,385 @@
|
|
1
|
+
=begin
|
2
|
+
#Topological Inventory Ingress API
|
3
|
+
|
4
|
+
#Topological Inventory Ingress API
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 0.0.2
|
7
|
+
Contact: support@redhat.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.2.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'json'
|
15
|
+
require 'logger'
|
16
|
+
require 'tempfile'
|
17
|
+
require 'typhoeus'
|
18
|
+
|
19
|
+
module TopologicalInventoryIngressApiClient
|
20
|
+
class ApiClient
|
21
|
+
# The Configuration object holding settings to be used in the API client.
|
22
|
+
attr_accessor :config
|
23
|
+
|
24
|
+
# Defines the headers to be used in HTTP requests of all API calls by default.
|
25
|
+
#
|
26
|
+
# @return [Hash]
|
27
|
+
attr_accessor :default_headers
|
28
|
+
|
29
|
+
# Initializes the ApiClient
|
30
|
+
# @option config [Configuration] Configuration for initializing the object, default to Configuration.default
|
31
|
+
def initialize(config = Configuration.default)
|
32
|
+
@config = config
|
33
|
+
@user_agent = "OpenAPI-Generator/#{VERSION}/ruby"
|
34
|
+
@default_headers = {
|
35
|
+
'Content-Type' => 'application/json',
|
36
|
+
'User-Agent' => @user_agent
|
37
|
+
}
|
38
|
+
end
|
39
|
+
|
40
|
+
def self.default
|
41
|
+
@@default ||= ApiClient.new
|
42
|
+
end
|
43
|
+
|
44
|
+
# Call an API with given options.
|
45
|
+
#
|
46
|
+
# @return [Array<(Object, Integer, Hash)>] an array of 3 elements:
|
47
|
+
# the data deserialized from response body (could be nil), response status code and response headers.
|
48
|
+
def call_api(http_method, path, opts = {})
|
49
|
+
request = build_request(http_method, path, opts)
|
50
|
+
response = request.run
|
51
|
+
|
52
|
+
if @config.debugging
|
53
|
+
@config.logger.debug "HTTP response body ~BEGIN~\n#{response.body}\n~END~\n"
|
54
|
+
end
|
55
|
+
|
56
|
+
unless response.success?
|
57
|
+
if response.timed_out?
|
58
|
+
fail ApiError.new('Connection timed out')
|
59
|
+
elsif response.code == 0
|
60
|
+
# Errors from libcurl will be made visible here
|
61
|
+
fail ApiError.new(:code => 0,
|
62
|
+
:message => response.return_message)
|
63
|
+
else
|
64
|
+
fail ApiError.new(:code => response.code,
|
65
|
+
:response_headers => response.headers,
|
66
|
+
:response_body => response.body),
|
67
|
+
response.status_message
|
68
|
+
end
|
69
|
+
end
|
70
|
+
|
71
|
+
if opts[:return_type]
|
72
|
+
data = deserialize(response, opts[:return_type])
|
73
|
+
else
|
74
|
+
data = nil
|
75
|
+
end
|
76
|
+
return data, response.code, response.headers
|
77
|
+
end
|
78
|
+
|
79
|
+
# Builds the HTTP request
|
80
|
+
#
|
81
|
+
# @param [String] http_method HTTP method/verb (e.g. POST)
|
82
|
+
# @param [String] path URL path (e.g. /account/new)
|
83
|
+
# @option opts [Hash] :header_params Header parameters
|
84
|
+
# @option opts [Hash] :query_params Query parameters
|
85
|
+
# @option opts [Hash] :form_params Query parameters
|
86
|
+
# @option opts [Object] :body HTTP body (JSON/XML)
|
87
|
+
# @return [Typhoeus::Request] A Typhoeus Request
|
88
|
+
def build_request(http_method, path, opts = {})
|
89
|
+
url = build_request_url(path)
|
90
|
+
http_method = http_method.to_sym.downcase
|
91
|
+
|
92
|
+
header_params = @default_headers.merge(opts[:header_params] || {})
|
93
|
+
query_params = opts[:query_params] || {}
|
94
|
+
form_params = opts[:form_params] || {}
|
95
|
+
|
96
|
+
|
97
|
+
# set ssl_verifyhosts option based on @config.verify_ssl_host (true/false)
|
98
|
+
_verify_ssl_host = @config.verify_ssl_host ? 2 : 0
|
99
|
+
|
100
|
+
req_opts = {
|
101
|
+
:method => http_method,
|
102
|
+
:headers => header_params,
|
103
|
+
:params => query_params,
|
104
|
+
:params_encoding => @config.params_encoding,
|
105
|
+
:timeout => @config.timeout,
|
106
|
+
:ssl_verifypeer => @config.verify_ssl,
|
107
|
+
:ssl_verifyhost => _verify_ssl_host,
|
108
|
+
:sslcert => @config.cert_file,
|
109
|
+
:sslkey => @config.key_file,
|
110
|
+
:verbose => @config.debugging
|
111
|
+
}
|
112
|
+
|
113
|
+
# set custom cert, if provided
|
114
|
+
req_opts[:cainfo] = @config.ssl_ca_cert if @config.ssl_ca_cert
|
115
|
+
|
116
|
+
if [:post, :patch, :put, :delete].include?(http_method)
|
117
|
+
req_body = build_request_body(header_params, form_params, opts[:body])
|
118
|
+
req_opts.update :body => req_body
|
119
|
+
if @config.debugging
|
120
|
+
@config.logger.debug "HTTP request body param ~BEGIN~\n#{req_body}\n~END~\n"
|
121
|
+
end
|
122
|
+
end
|
123
|
+
|
124
|
+
request = Typhoeus::Request.new(url, req_opts)
|
125
|
+
download_file(request) if opts[:return_type] == 'File'
|
126
|
+
request
|
127
|
+
end
|
128
|
+
|
129
|
+
# Builds the HTTP request body
|
130
|
+
#
|
131
|
+
# @param [Hash] header_params Header parameters
|
132
|
+
# @param [Hash] form_params Query parameters
|
133
|
+
# @param [Object] body HTTP body (JSON/XML)
|
134
|
+
# @return [String] HTTP body data in the form of string
|
135
|
+
def build_request_body(header_params, form_params, body)
|
136
|
+
# http form
|
137
|
+
if header_params['Content-Type'] == 'application/x-www-form-urlencoded' ||
|
138
|
+
header_params['Content-Type'] == 'multipart/form-data'
|
139
|
+
data = {}
|
140
|
+
form_params.each do |key, value|
|
141
|
+
case value
|
142
|
+
when ::File, ::Array, nil
|
143
|
+
# let typhoeus handle File, Array and nil parameters
|
144
|
+
data[key] = value
|
145
|
+
else
|
146
|
+
data[key] = value.to_s
|
147
|
+
end
|
148
|
+
end
|
149
|
+
elsif body
|
150
|
+
data = body.is_a?(String) ? body : body.to_json
|
151
|
+
else
|
152
|
+
data = nil
|
153
|
+
end
|
154
|
+
data
|
155
|
+
end
|
156
|
+
|
157
|
+
# Check if the given MIME is a JSON MIME.
|
158
|
+
# JSON MIME examples:
|
159
|
+
# application/json
|
160
|
+
# application/json; charset=UTF8
|
161
|
+
# APPLICATION/JSON
|
162
|
+
# */*
|
163
|
+
# @param [String] mime MIME
|
164
|
+
# @return [Boolean] True if the MIME is application/json
|
165
|
+
def json_mime?(mime)
|
166
|
+
(mime == '*/*') || !(mime =~ /Application\/.*json(?!p)(;.*)?/i).nil?
|
167
|
+
end
|
168
|
+
|
169
|
+
# Deserialize the response to the given return type.
|
170
|
+
#
|
171
|
+
# @param [Response] response HTTP response
|
172
|
+
# @param [String] return_type some examples: "User", "Array<User>", "Hash<String, Integer>"
|
173
|
+
def deserialize(response, return_type)
|
174
|
+
body = response.body
|
175
|
+
|
176
|
+
# handle file downloading - return the File instance processed in request callbacks
|
177
|
+
# note that response body is empty when the file is written in chunks in request on_body callback
|
178
|
+
return @tempfile if return_type == 'File'
|
179
|
+
|
180
|
+
return nil if body.nil? || body.empty?
|
181
|
+
|
182
|
+
# return response body directly for String return type
|
183
|
+
return body if return_type == 'String'
|
184
|
+
|
185
|
+
# ensuring a default content type
|
186
|
+
content_type = response.headers['Content-Type'] || 'application/json'
|
187
|
+
|
188
|
+
fail "Content-Type is not supported: #{content_type}" unless json_mime?(content_type)
|
189
|
+
|
190
|
+
begin
|
191
|
+
data = JSON.parse("[#{body}]", :symbolize_names => true)[0]
|
192
|
+
rescue JSON::ParserError => e
|
193
|
+
if %w(String Date DateTime).include?(return_type)
|
194
|
+
data = body
|
195
|
+
else
|
196
|
+
raise e
|
197
|
+
end
|
198
|
+
end
|
199
|
+
|
200
|
+
convert_to_type data, return_type
|
201
|
+
end
|
202
|
+
|
203
|
+
# Convert data to the given return type.
|
204
|
+
# @param [Object] data Data to be converted
|
205
|
+
# @param [String] return_type Return type
|
206
|
+
# @return [Mixed] Data in a particular type
|
207
|
+
def convert_to_type(data, return_type)
|
208
|
+
return nil if data.nil?
|
209
|
+
case return_type
|
210
|
+
when 'String'
|
211
|
+
data.to_s
|
212
|
+
when 'Integer'
|
213
|
+
data.to_i
|
214
|
+
when 'Float'
|
215
|
+
data.to_f
|
216
|
+
when 'Boolean'
|
217
|
+
data == true
|
218
|
+
when 'DateTime'
|
219
|
+
# parse date time (expecting ISO 8601 format)
|
220
|
+
DateTime.parse data
|
221
|
+
when 'Date'
|
222
|
+
# parse date time (expecting ISO 8601 format)
|
223
|
+
Date.parse data
|
224
|
+
when 'Object'
|
225
|
+
# generic object (usually a Hash), return directly
|
226
|
+
data
|
227
|
+
when /\AArray<(.+)>\z/
|
228
|
+
# e.g. Array<Pet>
|
229
|
+
sub_type = $1
|
230
|
+
data.map { |item| convert_to_type(item, sub_type) }
|
231
|
+
when /\AHash\<String, (.+)\>\z/
|
232
|
+
# e.g. Hash<String, Integer>
|
233
|
+
sub_type = $1
|
234
|
+
{}.tap do |hash|
|
235
|
+
data.each { |k, v| hash[k] = convert_to_type(v, sub_type) }
|
236
|
+
end
|
237
|
+
else
|
238
|
+
# models, e.g. Pet
|
239
|
+
TopologicalInventoryIngressApiClient.const_get(return_type).build_from_hash(data)
|
240
|
+
end
|
241
|
+
end
|
242
|
+
|
243
|
+
# Save response body into a file in (the defined) temporary folder, using the filename
|
244
|
+
# from the "Content-Disposition" header if provided, otherwise a random filename.
|
245
|
+
# The response body is written to the file in chunks in order to handle files which
|
246
|
+
# size is larger than maximum Ruby String or even larger than the maximum memory a Ruby
|
247
|
+
# process can use.
|
248
|
+
#
|
249
|
+
# @see Configuration#temp_folder_path
|
250
|
+
def download_file(request)
|
251
|
+
tempfile = nil
|
252
|
+
encoding = nil
|
253
|
+
request.on_headers do |response|
|
254
|
+
content_disposition = response.headers['Content-Disposition']
|
255
|
+
if content_disposition && content_disposition =~ /filename=/i
|
256
|
+
filename = content_disposition[/filename=['"]?([^'"\s]+)['"]?/, 1]
|
257
|
+
prefix = sanitize_filename(filename)
|
258
|
+
else
|
259
|
+
prefix = 'download-'
|
260
|
+
end
|
261
|
+
prefix = prefix + '-' unless prefix.end_with?('-')
|
262
|
+
encoding = response.body.encoding
|
263
|
+
tempfile = Tempfile.open(prefix, @config.temp_folder_path, encoding: encoding)
|
264
|
+
@tempfile = tempfile
|
265
|
+
end
|
266
|
+
request.on_body do |chunk|
|
267
|
+
chunk.force_encoding(encoding)
|
268
|
+
tempfile.write(chunk)
|
269
|
+
end
|
270
|
+
request.on_complete do |response|
|
271
|
+
tempfile.close if tempfile
|
272
|
+
@config.logger.info "Temp file written to #{tempfile.path}, please copy the file to a proper folder "\
|
273
|
+
"with e.g. `FileUtils.cp(tempfile.path, '/new/file/path')` otherwise the temp file "\
|
274
|
+
"will be deleted automatically with GC. It's also recommended to delete the temp file "\
|
275
|
+
"explicitly with `tempfile.delete`"
|
276
|
+
end
|
277
|
+
end
|
278
|
+
|
279
|
+
# Sanitize filename by removing path.
|
280
|
+
# e.g. ../../sun.gif becomes sun.gif
|
281
|
+
#
|
282
|
+
# @param [String] filename the filename to be sanitized
|
283
|
+
# @return [String] the sanitized filename
|
284
|
+
def sanitize_filename(filename)
|
285
|
+
filename.gsub(/.*[\/\\]/, '')
|
286
|
+
end
|
287
|
+
|
288
|
+
def build_request_url(path)
|
289
|
+
# Add leading and trailing slashes to path
|
290
|
+
path = "/#{path}".gsub(/\/+/, '/')
|
291
|
+
@config.base_url + path
|
292
|
+
end
|
293
|
+
|
294
|
+
# Update hearder and query params based on authentication settings.
|
295
|
+
#
|
296
|
+
# @param [Hash] header_params Header parameters
|
297
|
+
# @param [Hash] query_params Query parameters
|
298
|
+
# @param [String] auth_names Authentication scheme name
|
299
|
+
def update_params_for_auth!(header_params, query_params, auth_names)
|
300
|
+
Array(auth_names).each do |auth_name|
|
301
|
+
auth_setting = @config.auth_settings[auth_name]
|
302
|
+
next unless auth_setting
|
303
|
+
case auth_setting[:in]
|
304
|
+
when 'header' then header_params[auth_setting[:key]] = auth_setting[:value]
|
305
|
+
when 'query' then query_params[auth_setting[:key]] = auth_setting[:value]
|
306
|
+
else fail ArgumentError, 'Authentication token must be in `query` of `header`'
|
307
|
+
end
|
308
|
+
end
|
309
|
+
end
|
310
|
+
|
311
|
+
# Sets user agent in HTTP header
|
312
|
+
#
|
313
|
+
# @param [String] user_agent User agent (e.g. openapi-generator/ruby/1.0.0)
|
314
|
+
def user_agent=(user_agent)
|
315
|
+
@user_agent = user_agent
|
316
|
+
@default_headers['User-Agent'] = @user_agent
|
317
|
+
end
|
318
|
+
|
319
|
+
# Return Accept header based on an array of accepts provided.
|
320
|
+
# @param [Array] accepts array for Accept
|
321
|
+
# @return [String] the Accept header (e.g. application/json)
|
322
|
+
def select_header_accept(accepts)
|
323
|
+
return nil if accepts.nil? || accepts.empty?
|
324
|
+
# use JSON when present, otherwise use all of the provided
|
325
|
+
json_accept = accepts.find { |s| json_mime?(s) }
|
326
|
+
json_accept || accepts.join(',')
|
327
|
+
end
|
328
|
+
|
329
|
+
# Return Content-Type header based on an array of content types provided.
|
330
|
+
# @param [Array] content_types array for Content-Type
|
331
|
+
# @return [String] the Content-Type header (e.g. application/json)
|
332
|
+
def select_header_content_type(content_types)
|
333
|
+
# use application/json by default
|
334
|
+
return 'application/json' if content_types.nil? || content_types.empty?
|
335
|
+
# use JSON when present, otherwise use the first one
|
336
|
+
json_content_type = content_types.find { |s| json_mime?(s) }
|
337
|
+
json_content_type || content_types.first
|
338
|
+
end
|
339
|
+
|
340
|
+
# Convert object (array, hash, object, etc) to JSON string.
|
341
|
+
# @param [Object] model object to be converted into JSON string
|
342
|
+
# @return [String] JSON string representation of the object
|
343
|
+
def object_to_http_body(model)
|
344
|
+
return model if model.nil? || model.is_a?(String)
|
345
|
+
local_body = nil
|
346
|
+
if model.is_a?(Array)
|
347
|
+
local_body = model.map { |m| object_to_hash(m) }
|
348
|
+
else
|
349
|
+
local_body = object_to_hash(model)
|
350
|
+
end
|
351
|
+
local_body.to_json
|
352
|
+
end
|
353
|
+
|
354
|
+
# Convert object(non-array) to hash.
|
355
|
+
# @param [Object] obj object to be converted into JSON string
|
356
|
+
# @return [String] JSON string representation of the object
|
357
|
+
def object_to_hash(obj)
|
358
|
+
if obj.respond_to?(:to_hash)
|
359
|
+
obj.to_hash
|
360
|
+
else
|
361
|
+
obj
|
362
|
+
end
|
363
|
+
end
|
364
|
+
|
365
|
+
# Build parameter value according to the given collection format.
|
366
|
+
# @param [String] collection_format one of :csv, :ssv, :tsv, :pipes and :multi
|
367
|
+
def build_collection_param(param, collection_format)
|
368
|
+
case collection_format
|
369
|
+
when :csv
|
370
|
+
param.join(',')
|
371
|
+
when :ssv
|
372
|
+
param.join(' ')
|
373
|
+
when :tsv
|
374
|
+
param.join("\t")
|
375
|
+
when :pipes
|
376
|
+
param.join('|')
|
377
|
+
when :multi
|
378
|
+
# return the array directly as typhoeus will handle it as expected
|
379
|
+
param
|
380
|
+
else
|
381
|
+
fail "unknown collection format: #{collection_format.inspect}"
|
382
|
+
end
|
383
|
+
end
|
384
|
+
end
|
385
|
+
end
|