diff --git a/client.go b/client.go new file mode 100644 index 0000000..549be8f --- /dev/null +++ b/client.go @@ -0,0 +1,35178 @@ +// Package katapult provides primitives to interact with the openapi HTTP API. +// +// Code generated by github.com/deepmap/oapi-codegen/v2 version v2.0.0 DO NOT EDIT. +package katapult + +import ( + "bytes" + "context" + "encoding/json" + "fmt" + "io" + "net/http" + "net/url" + "strings" + + "github.com/deepmap/oapi-codegen/v2/pkg/securityprovider" + "github.com/oapi-codegen/runtime" +) + +const ( + AuthenticatorScopes = "Authenticator.Scopes" +) + +// Defines values for CertificateNotFoundEnum. +const ( + CertificateNotFound CertificateNotFoundEnum = "certificate_not_found" +) + +// Defines values for CertificateStateEnum. +const ( + CertificateStateEnumIssueFailed CertificateStateEnum = "issue_failed" + CertificateStateEnumIssued CertificateStateEnum = "issued" + CertificateStateEnumIssuing CertificateStateEnum = "issuing" + CertificateStateEnumPending CertificateStateEnum = "pending" +) + +// Defines values for CountryNotFoundEnum. +const ( + CountryNotFound CountryNotFoundEnum = "country_not_found" +) + +// Defines values for CountryStateNotFoundEnum. +const ( + CountryStateNotFound CountryStateNotFoundEnum = "country_state_not_found" +) + +// Defines values for CurrencyNotFoundEnum. +const ( + CurrencyNotFound CurrencyNotFoundEnum = "currency_not_found" +) + +// Defines values for DNSRecordNotFoundEnum. +const ( + DnsRecordNotFound DNSRecordNotFoundEnum = "dns_record_not_found" +) + +// Defines values for DNSRecordTypeEnum. +const ( + DNSRecordTypeEnumA DNSRecordTypeEnum = "a" + DNSRecordTypeEnumAaaa DNSRecordTypeEnum = "aaaa" + DNSRecordTypeEnumAlias DNSRecordTypeEnum = "alias" + DNSRecordTypeEnumCaa DNSRecordTypeEnum = "caa" + DNSRecordTypeEnumCname DNSRecordTypeEnum = "cname" + DNSRecordTypeEnumMx DNSRecordTypeEnum = "mx" + DNSRecordTypeEnumNs DNSRecordTypeEnum = "ns" + DNSRecordTypeEnumSrv DNSRecordTypeEnum = "srv" + DNSRecordTypeEnumSshfp DNSRecordTypeEnum = "sshfp" + DNSRecordTypeEnumTxt DNSRecordTypeEnum = "txt" + DNSRecordTypeEnumVirtualMachine DNSRecordTypeEnum = "virtual_machine" +) + +// Defines values for DNSRecordTypesEnum. +const ( + DNSRecordTypesEnumA DNSRecordTypesEnum = "A" + DNSRecordTypesEnumAAAA DNSRecordTypesEnum = "AAAA" + DNSRecordTypesEnumALIAS DNSRecordTypesEnum = "ALIAS" + DNSRecordTypesEnumCAA DNSRecordTypesEnum = "CAA" + DNSRecordTypesEnumCNAME DNSRecordTypesEnum = "CNAME" + DNSRecordTypesEnumIPS DNSRecordTypesEnum = "IPS" + DNSRecordTypesEnumMX DNSRecordTypesEnum = "MX" + DNSRecordTypesEnumNS DNSRecordTypesEnum = "NS" + DNSRecordTypesEnumPTR DNSRecordTypesEnum = "PTR" + DNSRecordTypesEnumSOA DNSRecordTypesEnum = "SOA" + DNSRecordTypesEnumSRV DNSRecordTypesEnum = "SRV" + DNSRecordTypesEnumSSHFP DNSRecordTypesEnum = "SSHFP" + DNSRecordTypesEnumTXT DNSRecordTypesEnum = "TXT" + DNSRecordTypesEnumVirtualMachine DNSRecordTypesEnum = "VirtualMachine" +) + +// Defines values for DNSZoneAlreadyVerifiedEnum. +const ( + DnsZoneAlreadyVerified DNSZoneAlreadyVerifiedEnum = "dns_zone_already_verified" +) + +// Defines values for DNSZoneNotFoundEnum. +const ( + DnsZoneNotFound DNSZoneNotFoundEnum = "dns_zone_not_found" +) + +// Defines values for DNSZoneNotVerifiedEnum. +const ( + DnsZoneNotVerified DNSZoneNotVerifiedEnum = "dns_zone_not_verified" +) + +// Defines values for DataCenterNotFoundEnum. +const ( + DataCenterNotFound DataCenterNotFoundEnum = "data_center_not_found" +) + +// Defines values for DeletionRestrictedEnum. +const ( + DeletionRestrictedEnumDeletionRestricted DeletionRestrictedEnum = "deletion_restricted" +) + +// Defines values for DiskBackupPolicyNotFoundEnum. +const ( + DiskBackupPolicyNotFound DiskBackupPolicyNotFoundEnum = "disk_backup_policy_not_found" +) + +// Defines values for DiskNotFoundEnum. +const ( + DiskNotFound DiskNotFoundEnum = "disk_not_found" +) + +// Defines values for DiskStateEnum. +const ( + DiskStateEnumBuilding DiskStateEnum = "building" + DiskStateEnumBuilt DiskStateEnum = "built" + DiskStateEnumConfiguring DiskStateEnum = "configuring" + DiskStateEnumFailed DiskStateEnum = "failed" + DiskStateEnumFormatting DiskStateEnum = "formatting" + DiskStateEnumImporting DiskStateEnum = "importing" + DiskStateEnumInstalling DiskStateEnum = "installing" + DiskStateEnumNotBuilt DiskStateEnum = "not_built" + DiskStateEnumResizing DiskStateEnum = "resizing" + DiskStateEnumRestoring DiskStateEnum = "restoring" +) + +// Defines values for DiskTemplateNotFoundEnum. +const ( + DiskTemplateNotFound DiskTemplateNotFoundEnum = "disk_template_not_found" +) + +// Defines values for DiskTemplateVersionNotFoundEnum. +const ( + DiskTemplateVersionNotFound DiskTemplateVersionNotFoundEnum = "disk_template_version_not_found" +) + +// Defines values for FileStorageVolumeNotFoundEnum. +const ( + FileStorageVolumeNotFound FileStorageVolumeNotFoundEnum = "file_storage_volume_not_found" +) + +// Defines values for FileStorageVolumeStateEnum. +const ( + FileStorageVolumeStateEnumConfiguring FileStorageVolumeStateEnum = "configuring" + FileStorageVolumeStateEnumFailed FileStorageVolumeStateEnum = "failed" + FileStorageVolumeStateEnumPending FileStorageVolumeStateEnum = "pending" + FileStorageVolumeStateEnumReady FileStorageVolumeStateEnum = "ready" +) + +// Defines values for FlexibleResourcesUnavailableToOrganizationEnum. +const ( + FlexibleResourcesUnavailableToOrganization FlexibleResourcesUnavailableToOrganizationEnum = "flexible_resources_unavailable_to_organization" +) + +// Defines values for GPUTypeNotFoundEnum. +const ( + GpuTypeNotFound GPUTypeNotFoundEnum = "gpu_type_not_found" +) + +// Defines values for IPAddressNotFoundEnum. +const ( + IpAddressNotFound IPAddressNotFoundEnum = "ip_address_not_found" +) + +// Defines values for IPAddressVersionEnum. +const ( + Ipv4 IPAddressVersionEnum = "ipv4" + Ipv6 IPAddressVersionEnum = "ipv6" +) + +// Defines values for IPAlreadyAllocatedEnum. +const ( + IpAlreadyAllocated IPAlreadyAllocatedEnum = "ip_already_allocated" +) + +// Defines values for IdentityNotLinkedToWebSessionEnum. +const ( + IdentityNotLinkedToWebSession IdentityNotLinkedToWebSessionEnum = "identity_not_linked_to_web_session" +) + +// Defines values for InfrastructureDNSZoneCannotBeEditedEnum. +const ( + InfrastructureDnsZoneCannotBeEdited InfrastructureDNSZoneCannotBeEditedEnum = "infrastructure_dns_zone_cannot_be_edited" +) + +// Defines values for InterfaceNotFoundEnum. +const ( + InterfaceNotFound InterfaceNotFoundEnum = "interface_not_found" +) + +// Defines values for InvalidAPITokenEnum. +const ( + InvalidApiToken InvalidAPITokenEnum = "invalid_api_token" +) + +// Defines values for InvalidIPEnum. +const ( + InvalidIp InvalidIPEnum = "invalid_ip" +) + +// Defines values for InvalidSpecXMLEnum. +const ( + InvalidSpecXml InvalidSpecXMLEnum = "invalid_spec_xml" +) + +// Defines values for InvalidTimestampEnum. +const ( + InvalidTimestamp InvalidTimestampEnum = "invalid_timestamp" +) + +// Defines values for IssuerEnum. +const ( + Custom IssuerEnum = "custom" + LetsEncrypt IssuerEnum = "lets_encrypt" + SelfSigned IssuerEnum = "self_signed" +) + +// Defines values for LoadBalancerNotFoundEnum. +const ( + LoadBalancerNotFound LoadBalancerNotFoundEnum = "load_balancer_not_found" +) + +// Defines values for LoadBalancerResourceTypesEnum. +const ( + Tags LoadBalancerResourceTypesEnum = "tags" + VirtualMachineGroups LoadBalancerResourceTypesEnum = "virtual_machine_groups" + VirtualMachines LoadBalancerResourceTypesEnum = "virtual_machines" +) + +// Defines values for LoadBalancerRuleAlgorithmEnum. +const ( + LeastConnections LoadBalancerRuleAlgorithmEnum = "least_connections" + RoundRobin LoadBalancerRuleAlgorithmEnum = "round_robin" + Sticky LoadBalancerRuleAlgorithmEnum = "sticky" +) + +// Defines values for LoadBalancerRuleCheckProtocolEnum. +const ( + LoadBalancerRuleCheckProtocolEnumHTTP LoadBalancerRuleCheckProtocolEnum = "HTTP" + LoadBalancerRuleCheckProtocolEnumTCP LoadBalancerRuleCheckProtocolEnum = "TCP" +) + +// Defines values for LoadBalancerRuleHTTPStatusesEnum. +const ( + N2 LoadBalancerRuleHTTPStatusesEnum = "2" + N23 LoadBalancerRuleHTTPStatusesEnum = "23" + N234 LoadBalancerRuleHTTPStatusesEnum = "234" +) + +// Defines values for LoadBalancerRuleNotFoundEnum. +const ( + LoadBalancerRuleNotFound LoadBalancerRuleNotFoundEnum = "load_balancer_rule_not_found" +) + +// Defines values for LoadBalancerRuleProtocolEnum. +const ( + LoadBalancerRuleProtocolEnumHTTP LoadBalancerRuleProtocolEnum = "HTTP" + LoadBalancerRuleProtocolEnumHTTPS LoadBalancerRuleProtocolEnum = "HTTPS" + LoadBalancerRuleProtocolEnumTCP LoadBalancerRuleProtocolEnum = "TCP" +) + +// Defines values for LocationRequiredEnum. +const ( + LocationRequired LocationRequiredEnum = "location_required" +) + +// Defines values for MissingAPITokenEnum. +const ( + MissingApiToken MissingAPITokenEnum = "missing_api_token" +) + +// Defines values for NetworkNotFoundEnum. +const ( + NetworkNotFound NetworkNotFoundEnum = "network_not_found" +) + +// Defines values for NetworkSpeedProfileNotFoundEnum. +const ( + NetworkSpeedProfileNotFound NetworkSpeedProfileNotFoundEnum = "network_speed_profile_not_found" +) + +// Defines values for NoAllocationEnum. +const ( + NoAllocation NoAllocationEnum = "no_allocation" +) + +// Defines values for NoAvailableAddressesEnum. +const ( + NoAvailableAddresses NoAvailableAddressesEnum = "no_available_addresses" +) + +// Defines values for NoInterfaceAvailableEnum. +const ( + NoInterfaceAvailable NoInterfaceAvailableEnum = "no_interface_available" +) + +// Defines values for NoUserAssociatedWithIdentityEnum. +const ( + NoUserAssociatedWithIdentity NoUserAssociatedWithIdentityEnum = "no_user_associated_with_identity" +) + +// Defines values for ObjectInTrashEnum. +const ( + ObjectInTrashEnumObjectInTrash ObjectInTrashEnum = "object_in_trash" +) + +// Defines values for OperatingSystemNotFoundEnum. +const ( + OperatingSystemNotFound OperatingSystemNotFoundEnum = "operating_system_not_found" +) + +// Defines values for OrganizationLimitReachedEnum. +const ( + OrganizationLimitReached OrganizationLimitReachedEnum = "organization_limit_reached" +) + +// Defines values for OrganizationNotActivatedEnum. +const ( + OrganizationNotActivated OrganizationNotActivatedEnum = "organization_not_activated" +) + +// Defines values for OrganizationNotFoundEnum. +const ( + OrganizationNotFound OrganizationNotFoundEnum = "organization_not_found" +) + +// Defines values for OrganizationSuspendedEnum. +const ( + OrganizationSuspended OrganizationSuspendedEnum = "organization_suspended" +) + +// Defines values for PermissionDeniedEnum. +const ( + PermissionDeniedEnumPermissionDenied PermissionDeniedEnum = "permission_denied" +) + +// Defines values for PrivacyTypesEnum. +const ( + Private PrivacyTypesEnum = "private" + Public PrivacyTypesEnum = "public" +) + +// Defines values for PropertyTypeEnum. +const ( + Iodef PropertyTypeEnum = "iodef" + Issue PropertyTypeEnum = "issue" + Issuewild PropertyTypeEnum = "issuewild" +) + +// Defines values for RateLimitReachedEnum. +const ( + RateLimitReachedEnumRateLimitReached RateLimitReachedEnum = "rate_limit_reached" +) + +// Defines values for ResourceCreationRestrictedEnum. +const ( + ResourceCreationRestrictedEnumResourceCreationRestricted ResourceCreationRestrictedEnum = "resource_creation_restricted" +) + +// Defines values for ResourceDoesNotSupportUnallocationEnum. +const ( + ResourceDoesNotSupportUnallocation ResourceDoesNotSupportUnallocationEnum = "resource_does_not_support_unallocation" +) + +// Defines values for SSHKeyNotFoundEnum. +const ( + SshKeyNotFound SSHKeyNotFoundEnum = "ssh_key_not_found" +) + +// Defines values for ScheduleIntervalTypeEnum. +const ( + Daily ScheduleIntervalTypeEnum = "daily" + Hourly ScheduleIntervalTypeEnum = "hourly" + Monthly ScheduleIntervalTypeEnum = "monthly" + Weekly ScheduleIntervalTypeEnum = "weekly" +) + +// Defines values for ScopeNotGrantedErrorEnum. +const ( + ScopeNotGranted ScopeNotGrantedErrorEnum = "scope_not_granted" +) + +// Defines values for SecurityGroupNotFoundEnum. +const ( + SecurityGroupNotFound SecurityGroupNotFoundEnum = "security_group_not_found" +) + +// Defines values for SecurityGroupRuleActionEnum. +const ( + Allow SecurityGroupRuleActionEnum = "allow" + Deny SecurityGroupRuleActionEnum = "deny" +) + +// Defines values for SecurityGroupRuleDirectionEnum. +const ( + Inbound SecurityGroupRuleDirectionEnum = "inbound" + Outbound SecurityGroupRuleDirectionEnum = "outbound" +) + +// Defines values for SecurityGroupRuleNotFoundEnum. +const ( + SecurityGroupRuleNotFound SecurityGroupRuleNotFoundEnum = "security_group_rule_not_found" +) + +// Defines values for SecurityGroupRuleProtocolEnum. +const ( + ICMP SecurityGroupRuleProtocolEnum = "ICMP" + TCP SecurityGroupRuleProtocolEnum = "TCP" + UDP SecurityGroupRuleProtocolEnum = "UDP" +) + +// Defines values for SpeedProfileAlreadyAssignedEnum. +const ( + SpeedProfileAlreadyAssigned SpeedProfileAlreadyAssignedEnum = "speed_profile_already_assigned" +) + +// Defines values for StorageSpeedEnum. +const ( + Nvme StorageSpeedEnum = "nvme" + Ssd StorageSpeedEnum = "ssd" +) + +// Defines values for TagColorsEnum. +const ( + Aqua TagColorsEnum = "aqua" + Black TagColorsEnum = "black" + Brown TagColorsEnum = "brown" + DarkBlue TagColorsEnum = "dark_blue" + DarkGray TagColorsEnum = "dark_gray" + Green TagColorsEnum = "green" + LightBlue TagColorsEnum = "light_blue" + LightBrown TagColorsEnum = "light_brown" + LightGray TagColorsEnum = "light_gray" + Orange TagColorsEnum = "orange" + OrangeRed TagColorsEnum = "orange_red" + PastelAqua TagColorsEnum = "pastel_aqua" + PastelBlack TagColorsEnum = "pastel_black" + PastelBrown TagColorsEnum = "pastel_brown" + PastelDarkBlue TagColorsEnum = "pastel_dark_blue" + PastelDarkGray TagColorsEnum = "pastel_dark_gray" + PastelGreen TagColorsEnum = "pastel_green" + PastelLightBlue TagColorsEnum = "pastel_light_blue" + PastelLightBrown TagColorsEnum = "pastel_light_brown" + PastelLightGray TagColorsEnum = "pastel_light_gray" + PastelOrange TagColorsEnum = "pastel_orange" + PastelOrangeRed TagColorsEnum = "pastel_orange_red" + PastelPink TagColorsEnum = "pastel_pink" + PastelPurple TagColorsEnum = "pastel_purple" + PastelRed TagColorsEnum = "pastel_red" + PastelTeal TagColorsEnum = "pastel_teal" + PastelYellow TagColorsEnum = "pastel_yellow" + Pink TagColorsEnum = "pink" + Purple TagColorsEnum = "purple" + Red TagColorsEnum = "red" + Teal TagColorsEnum = "teal" + Yellow TagColorsEnum = "yellow" +) + +// Defines values for TagNotFoundEnum. +const ( + TagNotFound TagNotFoundEnum = "tag_not_found" +) + +// Defines values for TaskNotFoundEnum. +const ( + TaskNotFound TaskNotFoundEnum = "task_not_found" +) + +// Defines values for TaskQueueingErrorEnum. +const ( + TaskQueueingErrorEnumTaskQueueingError TaskQueueingErrorEnum = "task_queueing_error" +) + +// Defines values for TaskStatusEnum. +const ( + TaskStatusEnumCompleted TaskStatusEnum = "completed" + TaskStatusEnumFailed TaskStatusEnum = "failed" + TaskStatusEnumPending TaskStatusEnum = "pending" + TaskStatusEnumRunning TaskStatusEnum = "running" +) + +// Defines values for TemplateSpecFieldTypeEnum. +const ( + Boolean TemplateSpecFieldTypeEnum = "Boolean" + Keyboard TemplateSpecFieldTypeEnum = "Keyboard" + Password TemplateSpecFieldTypeEnum = "Password" + Text TemplateSpecFieldTypeEnum = "Text" +) + +// Defines values for TrashObjectNotFoundEnum. +const ( + TrashObjectNotFound TrashObjectNotFoundEnum = "trash_object_not_found" +) + +// Defines values for UnauthorizedNetworkForAPITokenEnum. +const ( + UnauthorizedNetworkForApiToken UnauthorizedNetworkForAPITokenEnum = "unauthorized_network_for_api_token" +) + +// Defines values for ValidationErrorEnum. +const ( + ValidationErrorEnumValidationError ValidationErrorEnum = "validation_error" +) + +// Defines values for VirtualMachineBuildNotFoundEnum. +const ( + BuildNotFound VirtualMachineBuildNotFoundEnum = "build_not_found" +) + +// Defines values for VirtualMachineBuildStateEnum. +const ( + VirtualMachineBuildStateEnumBuilding VirtualMachineBuildStateEnum = "building" + VirtualMachineBuildStateEnumComplete VirtualMachineBuildStateEnum = "complete" + VirtualMachineBuildStateEnumDraft VirtualMachineBuildStateEnum = "draft" + VirtualMachineBuildStateEnumFailed VirtualMachineBuildStateEnum = "failed" + VirtualMachineBuildStateEnumPending VirtualMachineBuildStateEnum = "pending" +) + +// Defines values for VirtualMachineDiskAttachmentStateEnum. +const ( + VirtualMachineDiskAttachmentStateEnumAttached VirtualMachineDiskAttachmentStateEnum = "attached" + VirtualMachineDiskAttachmentStateEnumAttaching VirtualMachineDiskAttachmentStateEnum = "attaching" + VirtualMachineDiskAttachmentStateEnumDetached VirtualMachineDiskAttachmentStateEnum = "detached" + VirtualMachineDiskAttachmentStateEnumDetaching VirtualMachineDiskAttachmentStateEnum = "detaching" + VirtualMachineDiskAttachmentStateEnumFailed VirtualMachineDiskAttachmentStateEnum = "failed" +) + +// Defines values for VirtualMachineGPUPendingActionEnum. +const ( + Attach VirtualMachineGPUPendingActionEnum = "attach" + Detach VirtualMachineGPUPendingActionEnum = "detach" +) + +// Defines values for VirtualMachineGPUStatusEnum. +const ( + Attached VirtualMachineGPUStatusEnum = "attached" + Attaching VirtualMachineGPUStatusEnum = "attaching" + Detached VirtualMachineGPUStatusEnum = "detached" + Detaching VirtualMachineGPUStatusEnum = "detaching" + Unknown VirtualMachineGPUStatusEnum = "unknown" +) + +// Defines values for VirtualMachineGroupNotFoundEnum. +const ( + VirtualMachineGroupNotFound VirtualMachineGroupNotFoundEnum = "virtual_machine_group_not_found" +) + +// Defines values for VirtualMachineMustBeStartedEnum. +const ( + VirtualMachineMustBeStartedEnumVirtualMachineMustBeStarted VirtualMachineMustBeStartedEnum = "virtual_machine_must_be_started" +) + +// Defines values for VirtualMachineNetworkInterfaceNotFoundEnum. +const ( + VirtualMachineNetworkInterfaceNotFound VirtualMachineNetworkInterfaceNotFoundEnum = "virtual_machine_network_interface_not_found" +) + +// Defines values for VirtualMachineNotFoundEnum. +const ( + VirtualMachineNotFound VirtualMachineNotFoundEnum = "virtual_machine_not_found" +) + +// Defines values for VirtualMachinePackageNotFoundEnum. +const ( + PackageNotFound VirtualMachinePackageNotFoundEnum = "package_not_found" +) + +// Defines values for VirtualMachineStateEnum. +const ( + Allocated VirtualMachineStateEnum = "allocated" + Allocating VirtualMachineStateEnum = "allocating" + Failed VirtualMachineStateEnum = "failed" + Migrating VirtualMachineStateEnum = "migrating" + Orphaned VirtualMachineStateEnum = "orphaned" + Resetting VirtualMachineStateEnum = "resetting" + ShuttingDown VirtualMachineStateEnum = "shutting_down" + Started VirtualMachineStateEnum = "started" + Starting VirtualMachineStateEnum = "starting" + Stopped VirtualMachineStateEnum = "stopped" + Stopping VirtualMachineStateEnum = "stopping" +) + +// Defines values for ZoneNotFoundEnum. +const ( + ZoneNotFound ZoneNotFoundEnum = "zone_not_found" +) + +// A defines model for A. +type A struct { + Ip *string `json:"ip,omitempty"` +} + +// AAAA defines model for AAAA. +type AAAA struct { + Ip *string `json:"ip,omitempty"` +} + +// ALIAS defines model for ALIAS. +type ALIAS struct { + Name *string `json:"name,omitempty"` +} + +// APIAuthenticator400Schema No API token was provided in the Authorization header. Ensure a token is provided prefixed with Bearer +type APIAuthenticator400Schema struct { + Code *MissingAPITokenEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// Attachment defines model for Attachment. +type Attachment struct { + Digest *string `json:"digest,omitempty"` + FileName *string `json:"file_name,omitempty"` + FileSize *int `json:"file_size,omitempty"` + FileType *string `json:"file_type,omitempty"` + Token *string `json:"token,omitempty"` + Url *string `json:"url,omitempty"` +} + +// AuthSSHKey defines model for AuthSSHKey. +type AuthSSHKey struct { + Fingerprint *string `json:"fingerprint,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// AuthSSHKeyLookup All 'ssh_key[]' params are mutually exclusive, only one can be provided. +type AuthSSHKeyLookup struct { + Id *string `json:"id,omitempty"` +} + +// AuthSSHKeyProperties All 'ssh_key[]' params are mutually exclusive, only one can be provided. +type AuthSSHKeyProperties struct { + Key *string `json:"key,omitempty"` + Name *string `json:"name,omitempty"` +} + +// CAA defines model for CAA. +type CAA struct { + Flags *string `json:"flags,omitempty"` + PropertyType *PropertyTypeEnum `json:"property_type,omitempty"` + PropertyValue *string `json:"property_value,omitempty"` +} + +// CNAME defines model for CNAME. +type CNAME struct { + Name *string `json:"name,omitempty"` +} + +// Certificate defines model for Certificate. +type Certificate struct { + AdditionalNames *[]string `json:"additional_names,omitempty"` + AuthorizationMethod *string `json:"authorization_method,omitempty"` + Certificate *string `json:"certificate,omitempty"` + + // CertificateApiUrl This is the URL that can be used to access this certificate's details. through the certificate API (a different API to this one). If null, this means that it is no longer available. If that is the case, you can get a new URL by resetting the API token for this certificate. + CertificateApiUrl *string `json:"certificate_api_url,omitempty"` + Chain *string `json:"chain,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + ExpiresAt *int `json:"expires_at,omitempty"` + Id *string `json:"id,omitempty"` + IssueError *string `json:"issue_error,omitempty"` + Issuer *IssuerEnum `json:"issuer,omitempty"` + LastIssuedAt *int `json:"last_issued_at,omitempty"` + Name *string `json:"name,omitempty"` + PrivateKey *string `json:"private_key,omitempty"` + State *CertificateStateEnum `json:"state,omitempty"` +} + +// CertificateLookup All 'certificates[]' params are mutually exclusive, only one can be provided. +type CertificateLookup struct { + Id *string `json:"id,omitempty"` +} + +// CertificateNotFoundEnum defines model for CertificateNotFoundEnum. +type CertificateNotFoundEnum string + +// CertificateStateEnum defines model for CertificateStateEnum. +type CertificateStateEnum string + +// Country defines model for Country. +type Country struct { + Eu *bool `json:"eu,omitempty"` + Id *string `json:"id,omitempty"` + IsoCode2 *string `json:"iso_code2,omitempty"` + IsoCode3 *string `json:"iso_code3,omitempty"` + Name *string `json:"name,omitempty"` + TimeZone *string `json:"time_zone,omitempty"` +} + +// CountryNotFoundEnum defines model for CountryNotFoundEnum. +type CountryNotFoundEnum string + +// CountryState defines model for CountryState. +type CountryState struct { + Code *string `json:"code,omitempty"` + Country *Country `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// CountryStateNotFoundEnum defines model for CountryStateNotFoundEnum. +type CountryStateNotFoundEnum string + +// Currency defines model for Currency. +type Currency struct { + Id *string `json:"id,omitempty"` + IsoCode *string `json:"iso_code,omitempty"` + Name *string `json:"name,omitempty"` + Symbol *string `json:"symbol,omitempty"` +} + +// CurrencyNotFoundEnum defines model for CurrencyNotFoundEnum. +type CurrencyNotFoundEnum string + +// DNSRecord defines model for DNSRecord. +type DNSRecord struct { + Content *string `json:"content,omitempty"` + ContentAttributes *DNSRecordContentAttributes `json:"content_attributes,omitempty"` + FullName *string `json:"full_name,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Priority *int `json:"priority,omitempty"` + Ttl *int `json:"ttl,omitempty"` + Type *DNSRecordTypesEnum `json:"type,omitempty"` +} + +// DNSRecordArguments All 'details[]' params are mutually exclusive, only one can be provided. +type DNSRecordArguments struct { + Name *string `json:"name,omitempty"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties *DNSRecordPropertiesArguments `json:"properties,omitempty"` + RecordType *DNSRecordTypeEnum `json:"record_type,omitempty"` + Ttl *int `json:"ttl,omitempty"` +} + +// DNSRecordContentAttributes defines model for DNSRecordContentAttributes. +type DNSRecordContentAttributes struct { + A *RecordContentAttributesForA `json:"A,omitempty"` + AAAA *RecordContentAttributesForAAAA `json:"AAAA,omitempty"` + ALIAS *RecordContentAttributesForALIAS `json:"ALIAS,omitempty"` + CAA *RecordContentAttributesForCAA `json:"CAA,omitempty"` + CNAME *RecordContentAttributesForCNAME `json:"CNAME,omitempty"` + IPS *RecordContentAttributesForIPS `json:"IPS,omitempty"` + MX *RecordContentAttributesForMX `json:"MX,omitempty"` + NS *RecordContentAttributesForNS `json:"NS,omitempty"` + PTR *RecordContentAttributesForPTR `json:"PTR,omitempty"` + SOA *map[string]interface{} `json:"SOA,omitempty"` + SRV *RecordContentAttributesForSRV `json:"SRV,omitempty"` + SSHFP *RecordContentAttributesForSSHFP `json:"SSHFP,omitempty"` + TXT *RecordContentAttributesForTXT `json:"TXT,omitempty"` + VirtualMachine *RecordContentAttributesForVirtualMachine `json:"VirtualMachine,omitempty"` +} + +// DNSRecordLookup All 'dns_record[]' params are mutually exclusive, only one can be provided. +type DNSRecordLookup struct { + Id *string `json:"id,omitempty"` +} + +// DNSRecordNotFoundEnum defines model for DNSRecordNotFoundEnum. +type DNSRecordNotFoundEnum string + +// DNSRecordProperties defines model for DNSRecordProperties. +type DNSRecordProperties struct { + Properties *DNSRecordProperties_Properties `json:"properties,omitempty"` +} + +// DNSRecordProperties_Properties defines model for DNSRecordProperties.Properties. +type DNSRecordProperties_Properties struct { + union json.RawMessage +} + +// DNSRecordPropertiesArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type DNSRecordPropertiesArguments struct { + Algorithm *string `json:"algorithm,omitempty"` + Data *string `json:"data,omitempty"` + Fingerprint *string `json:"fingerprint,omitempty"` + FingerprintType *string `json:"fingerprint_type,omitempty"` + Flags *string `json:"flags,omitempty"` + Host *string `json:"host,omitempty"` + Ip *string `json:"ip,omitempty"` + Name *string `json:"name,omitempty"` + Port *string `json:"port,omitempty"` + Priority *string `json:"priority,omitempty"` + PropertyType *PropertyTypeEnum `json:"property_type,omitempty"` + PropertyValue *string `json:"property_value,omitempty"` + Target *string `json:"target,omitempty"` + + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine *VirtualMachineLookup `json:"virtual_machine,omitempty"` + Weight *string `json:"weight,omitempty"` +} + +// DNSRecordTypeEnum defines model for DNSRecordTypeEnum. +type DNSRecordTypeEnum string + +// DNSRecordTypesEnum defines model for DNSRecordTypesEnum. +type DNSRecordTypesEnum string + +// DNSZone defines model for DNSZone. +type DNSZone struct { + Id *string `json:"id,omitempty"` + InfrastructureZone *bool `json:"infrastructure_zone,omitempty"` + Name *string `json:"name,omitempty"` + Ttl *int `json:"ttl,omitempty"` + Verified *bool `json:"verified,omitempty"` +} + +// DNSZoneAlreadyVerifiedEnum defines model for DNSZoneAlreadyVerifiedEnum. +type DNSZoneAlreadyVerifiedEnum string + +// DNSZoneArguments All 'details[]' params are mutually exclusive, only one can be provided. +type DNSZoneArguments struct { + Name string `json:"name"` + Ttl *int `json:"ttl,omitempty"` +} + +// DNSZoneLookup All 'dns_zone[]' params are mutually exclusive, only one can be provided. +type DNSZoneLookup struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// DNSZoneNotFoundEnum defines model for DNSZoneNotFoundEnum. +type DNSZoneNotFoundEnum string + +// DNSZoneNotVerified defines model for DNSZoneNotVerified. +type DNSZoneNotVerified struct { + VerificationDetails *DNSZoneVerificationDetails `json:"verification_details,omitempty"` +} + +// DNSZoneNotVerifiedEnum defines model for DNSZoneNotVerifiedEnum. +type DNSZoneNotVerifiedEnum string + +// DNSZoneVerificationDetails defines model for DNSZoneVerificationDetails. +type DNSZoneVerificationDetails struct { + Nameservers *[]string `json:"nameservers,omitempty"` +} + +// DataCenter defines model for DataCenter. +type DataCenter struct { + Country *Country `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DataCenterLookup All 'data_center[]' params are mutually exclusive, only one can be provided. +type DataCenterLookup struct { + Id *string `json:"id,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DataCenterNotFoundEnum defines model for DataCenterNotFoundEnum. +type DataCenterNotFoundEnum string + +// DataCenterNotFoundSchema No data center was found matching any of the criteria provided in the arguments +type DataCenterNotFoundSchema struct { + Code *DataCenterNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DeleteDNSZonesDNSZone200ResponseDNSZone defines model for DeleteDNSZonesDNSZone200ResponseDNSZone. +type DeleteDNSZonesDNSZone200ResponseDNSZone struct { + Id *string `json:"id,omitempty"` + InfrastructureZone *bool `json:"infrastructure_zone,omitempty"` + Name *string `json:"name,omitempty"` + Ttl *int `json:"ttl,omitempty"` + Verified *bool `json:"verified,omitempty"` +} + +// DeleteDiskBackupPolicy200ResponseDiskBackupPolicy defines model for DeleteDiskBackupPolicy200ResponseDiskBackupPolicy. +type DeleteDiskBackupPolicy200ResponseDiskBackupPolicy struct { + Id *string `json:"id,omitempty"` +} + +// DeleteDiskBackupPolicySchedule200ResponseDiskBackupPolicy defines model for DeleteDiskBackupPolicySchedule200ResponseDiskBackupPolicy. +type DeleteDiskBackupPolicySchedule200ResponseDiskBackupPolicy struct { + AutoMoveToTrashAt *int `json:"auto_move_to_trash_at,omitempty"` + Id *string `json:"id,omitempty"` + Target *DiskBackupPolicyTarget `json:"target,omitempty"` +} + +// DeleteFileStorageVolume200ResponseFileStorageVolume defines model for DeleteFileStorageVolume200ResponseFileStorageVolume. +type DeleteFileStorageVolume200ResponseFileStorageVolume struct { + Associations *[]string `json:"associations,omitempty"` + DataCenter *DeleteFileStorageVolumePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + + // NfsLocation The NFS location of where to mount the volume from. + NfsLocation *string `json:"nfs_location,omitempty"` + + // Size The size of the volume in bytes. + Size *int `json:"size,omitempty"` + State *FileStorageVolumeStateEnum `json:"state,omitempty"` +} + +// DeleteFileStorageVolumePartDataCenter defines model for DeleteFileStorageVolumePartDataCenter. +type DeleteFileStorageVolumePartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DeleteLoadBalancer200ResponseLoadBalancer defines model for DeleteLoadBalancer200ResponseLoadBalancer. +type DeleteLoadBalancer200ResponseLoadBalancer struct { + ApiReference *string `json:"api_reference,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// DeleteLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule defines model for DeleteLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule. +type DeleteLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule struct { + Id *string `json:"id,omitempty"` +} + +// DeleteSecurityGroup200ResponseSecurityGroup defines model for DeleteSecurityGroup200ResponseSecurityGroup. +type DeleteSecurityGroup200ResponseSecurityGroup struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// DeleteSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule defines model for DeleteSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule. +type DeleteSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule struct { + Id *string `json:"id,omitempty"` +} + +// DeleteVirtualMachine200ResponseVirtualMachine defines model for DeleteVirtualMachine200ResponseVirtualMachine. +type DeleteVirtualMachine200ResponseVirtualMachine struct { + AttachedIso *DeleteVirtualMachinePartAttachedISO `json:"attached_iso,omitempty"` + CpuCores *int `json:"cpu_cores,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Description *string `json:"description,omitempty"` + Fqdn *string `json:"fqdn,omitempty"` + GpuType *DeleteVirtualMachinePartGPUType `json:"gpu_type,omitempty"` + Gpus *[]DeleteVirtualMachinePartGPUs `json:"gpus,omitempty"` + Group *DeleteVirtualMachinePartGroup `json:"group,omitempty"` + Hostname *string `json:"hostname,omitempty"` + Id *string `json:"id,omitempty"` + InitialRootPassword *string `json:"initial_root_password,omitempty"` + IpAddresses *[]DeleteVirtualMachinePartIPAddresses `json:"ip_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Organization *DeleteVirtualMachinePartOrganization `json:"organization,omitempty"` + Package *DeleteVirtualMachinePartPackage `json:"package,omitempty"` + State *VirtualMachineStateEnum `json:"state,omitempty"` + TagNames *[]string `json:"tag_names,omitempty"` + Tags *[]DeleteVirtualMachinePartTags `json:"tags,omitempty"` + Zone *DeleteVirtualMachinePartZone `json:"zone,omitempty"` +} + +// DeleteVirtualMachinePartAttachedISO defines model for DeleteVirtualMachinePartAttachedISO. +type DeleteVirtualMachinePartAttachedISO struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + OperatingSystem *DeleteVirtualMachinePartOperatingSystem `json:"operating_system,omitempty"` +} + +// DeleteVirtualMachinePartBadge defines model for DeleteVirtualMachinePartBadge. +type DeleteVirtualMachinePartBadge struct { + Digest *string `json:"digest,omitempty"` + FileName *string `json:"file_name,omitempty"` + FileSize *int `json:"file_size,omitempty"` + FileType *string `json:"file_type,omitempty"` + Token *string `json:"token,omitempty"` + Url *string `json:"url,omitempty"` +} + +// DeleteVirtualMachinePartCountry defines model for DeleteVirtualMachinePartCountry. +type DeleteVirtualMachinePartCountry struct { + Eu *bool `json:"eu,omitempty"` + Id *string `json:"id,omitempty"` + IsoCode2 *string `json:"iso_code2,omitempty"` + IsoCode3 *string `json:"iso_code3,omitempty"` + Name *string `json:"name,omitempty"` + TimeZone *string `json:"time_zone,omitempty"` +} + +// DeleteVirtualMachinePartCountryState defines model for DeleteVirtualMachinePartCountryState. +type DeleteVirtualMachinePartCountryState struct { + Code *string `json:"code,omitempty"` + Country *DeleteVirtualMachinePartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// DeleteVirtualMachinePartCurrency defines model for DeleteVirtualMachinePartCurrency. +type DeleteVirtualMachinePartCurrency struct { + Id *string `json:"id,omitempty"` + IsoCode *string `json:"iso_code,omitempty"` + Name *string `json:"name,omitempty"` + Symbol *string `json:"symbol,omitempty"` +} + +// DeleteVirtualMachinePartDataCenter defines model for DeleteVirtualMachinePartDataCenter. +type DeleteVirtualMachinePartDataCenter struct { + Country *DeleteVirtualMachinePartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DeleteVirtualMachinePartGPUType defines model for DeleteVirtualMachinePartGPUType. +type DeleteVirtualMachinePartGPUType struct { + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DeleteVirtualMachinePartGPUs defines model for DeleteVirtualMachinePartGPUs. +type DeleteVirtualMachinePartGPUs struct { + // Available When pending action is "attach", this indicates if there is a GPU of the relevant type available. + Available *bool `json:"available,omitempty"` + + // Id Unique ID for this GPU. Not available when status is "detached". + Id *string `json:"id,omitempty"` + PendingAction *VirtualMachineGPUPendingActionEnum `json:"pending_action,omitempty"` + Status *VirtualMachineGPUStatusEnum `json:"status,omitempty"` + Type *DeleteVirtualMachinePartType `json:"type,omitempty"` +} + +// DeleteVirtualMachinePartGroup defines model for DeleteVirtualMachinePartGroup. +type DeleteVirtualMachinePartGroup struct { + AutoSegregate *bool `json:"auto_segregate,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Segregate *bool `json:"segregate,omitempty"` +} + +// DeleteVirtualMachinePartIPAddresses defines model for DeleteVirtualMachinePartIPAddresses. +type DeleteVirtualMachinePartIPAddresses struct { + Address *string `json:"address,omitempty"` + AddressWithMask *string `json:"address_with_mask,omitempty"` + AllocationId *string `json:"allocation_id,omitempty"` + AllocationType *string `json:"allocation_type,omitempty"` + Id *string `json:"id,omitempty"` + Label *string `json:"label,omitempty"` + Network *DeleteVirtualMachinePartNetwork `json:"network,omitempty"` + ReverseDns *string `json:"reverse_dns,omitempty"` + Vip *bool `json:"vip,omitempty"` +} + +// DeleteVirtualMachinePartIcon defines model for DeleteVirtualMachinePartIcon. +type DeleteVirtualMachinePartIcon struct { + Digest *string `json:"digest,omitempty"` + FileName *string `json:"file_name,omitempty"` + FileSize *int `json:"file_size,omitempty"` + FileType *string `json:"file_type,omitempty"` + Token *string `json:"token,omitempty"` + Url *string `json:"url,omitempty"` +} + +// DeleteVirtualMachinePartNetwork defines model for DeleteVirtualMachinePartNetwork. +type DeleteVirtualMachinePartNetwork struct { + DataCenter *DeleteVirtualMachinePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DeleteVirtualMachinePartOperatingSystem defines model for DeleteVirtualMachinePartOperatingSystem. +type DeleteVirtualMachinePartOperatingSystem struct { + Badge *DeleteVirtualMachinePartBadge `json:"badge,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// DeleteVirtualMachinePartOrganization defines model for DeleteVirtualMachinePartOrganization. +type DeleteVirtualMachinePartOrganization struct { + Address1 *string `json:"address1,omitempty"` + Address2 *string `json:"address2,omitempty"` + Address3 *string `json:"address3,omitempty"` + Address4 *string `json:"address4,omitempty"` + BillingName *string `json:"billing_name,omitempty"` + Country *DeleteVirtualMachinePartCountry `json:"country,omitempty"` + CountryState *DeleteVirtualMachinePartCountryState `json:"country_state,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Currency *DeleteVirtualMachinePartCurrency `json:"currency,omitempty"` + Id *string `json:"id,omitempty"` + InfrastructureDomain *string `json:"infrastructure_domain,omitempty"` + Managed *bool `json:"managed,omitempty"` + Name *string `json:"name,omitempty"` + PhoneNumber *string `json:"phone_number,omitempty"` + Postcode *string `json:"postcode,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` + Suspended *bool `json:"suspended,omitempty"` + VatNumber *string `json:"vat_number,omitempty"` +} + +// DeleteVirtualMachinePartPackage defines model for DeleteVirtualMachinePartPackage. +type DeleteVirtualMachinePartPackage struct { + CpuCores *int `json:"cpu_cores,omitempty"` + Icon *DeleteVirtualMachinePartIcon `json:"icon,omitempty"` + Id *string `json:"id,omitempty"` + Ipv4Addresses *int `json:"ipv4_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MonthlyBandwidthAllowanceInGb *int `json:"monthly_bandwidth_allowance_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` + Privacy *PrivacyTypesEnum `json:"privacy,omitempty"` + StorageInGb *int `json:"storage_in_gb,omitempty"` +} + +// DeleteVirtualMachinePartTags defines model for DeleteVirtualMachinePartTags. +type DeleteVirtualMachinePartTags struct { + Color *TagColorsEnum `json:"color,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// DeleteVirtualMachinePartType defines model for DeleteVirtualMachinePartType. +type DeleteVirtualMachinePartType struct { + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DeleteVirtualMachinePartZone defines model for DeleteVirtualMachinePartZone. +type DeleteVirtualMachinePartZone struct { + DataCenter *DeleteVirtualMachinePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DeletionRestricted defines model for DeletionRestricted. +type DeletionRestricted struct { + Errors *[]string `json:"errors,omitempty"` +} + +// DeletionRestrictedEnum defines model for DeletionRestrictedEnum. +type DeletionRestrictedEnum string + +// Disk defines model for Disk. +type Disk struct { + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Installation *DiskInstallation `json:"installation,omitempty"` + IoProfile *DiskIOProfile `json:"io_profile,omitempty"` + Name *string `json:"name,omitempty"` + SizeInGb *int `json:"size_in_gb,omitempty"` + State *DiskStateEnum `json:"state,omitempty"` + StorageSpeed *StorageSpeedEnum `json:"storage_speed,omitempty"` + VirtualMachineDisk *VirtualMachineDisk `json:"virtual_machine_disk,omitempty"` + Wwn *string `json:"wwn,omitempty"` +} + +// DiskBackupPolicyArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type DiskBackupPolicyArguments struct { + Retention *int `json:"retention,omitempty"` + + // Schedule All 'schedule[]' params are mutually exclusive, only one can be provided. + Schedule *ScheduleArguments `json:"schedule,omitempty"` +} + +// DiskBackupPolicyLookup All 'disk_backup_policy[]' params are mutually exclusive, only one can be provided. +type DiskBackupPolicyLookup struct { + Id *string `json:"id,omitempty"` +} + +// DiskBackupPolicyNotFoundEnum defines model for DiskBackupPolicyNotFoundEnum. +type DiskBackupPolicyNotFoundEnum string + +// DiskBackupPolicyTarget defines model for DiskBackupPolicyTarget. +type DiskBackupPolicyTarget struct { + Target *DiskBackupPolicyTarget_Target `json:"target,omitempty"` +} + +// DiskBackupPolicyTarget_Target defines model for DiskBackupPolicyTarget.Target. +type DiskBackupPolicyTarget_Target struct { + union json.RawMessage +} + +// DiskIOProfile defines model for DiskIOProfile. +type DiskIOProfile struct { + Id *string `json:"id,omitempty"` + Iops *int `json:"iops,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` + SpeedInMb *int `json:"speed_in_mb,omitempty"` +} + +// DiskInstallation defines model for DiskInstallation. +type DiskInstallation struct { + Attributes *[]DiskInstallationAttribute `json:"attributes,omitempty"` + DiskTemplateVersion *DiskTemplateVersion `json:"disk_template_version,omitempty"` + Id *string `json:"id,omitempty"` +} + +// DiskInstallationAttribute defines model for DiskInstallationAttribute. +type DiskInstallationAttribute struct { + Description *string `json:"description,omitempty"` + Key *string `json:"key,omitempty"` + Label *string `json:"label,omitempty"` + Protect *bool `json:"protect,omitempty"` + Value *string `json:"value,omitempty"` +} + +// DiskLookup All 'disk[]' params are mutually exclusive, only one can be provided. +type DiskLookup struct { + Id *string `json:"id,omitempty"` +} + +// DiskNotFoundEnum defines model for DiskNotFoundEnum. +type DiskNotFoundEnum string + +// DiskStateEnum defines model for DiskStateEnum. +type DiskStateEnum string + +// DiskTemplate defines model for DiskTemplate. +type DiskTemplate struct { + Description *string `json:"description,omitempty"` + Id *string `json:"id,omitempty"` + LatestVersion *DiskTemplateVersion `json:"latest_version,omitempty"` + Name *string `json:"name,omitempty"` + OperatingSystem *OperatingSystem `json:"operating_system,omitempty"` + Permalink *string `json:"permalink,omitempty"` + Universal *bool `json:"universal,omitempty"` +} + +// DiskTemplateLookup All 'disk_template[]' params are mutually exclusive, only one can be provided. +type DiskTemplateLookup struct { + Id *string `json:"id,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// DiskTemplateNotFoundEnum defines model for DiskTemplateNotFoundEnum. +type DiskTemplateNotFoundEnum string + +// DiskTemplateNotFoundSchema No disk template was found matching any of the criteria provided in the arguments +type DiskTemplateNotFoundSchema struct { + Code *DiskTemplateNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DiskTemplateVersion defines model for DiskTemplateVersion. +type DiskTemplateVersion struct { + DiskTemplate *DiskTemplate `json:"disk_template,omitempty"` + Id *string `json:"id,omitempty"` + Number *int `json:"number,omitempty"` + SizeInGb *int `json:"size_in_gb,omitempty"` + Stable *bool `json:"stable,omitempty"` +} + +// DiskTemplateVersionNotFoundEnum defines model for DiskTemplateVersionNotFoundEnum. +type DiskTemplateVersionNotFoundEnum string + +// FileStorageVolumeArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type FileStorageVolumeArguments struct { + Associations *[]string `json:"associations,omitempty"` + + // DataCenter All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenter *DataCenterLookup `json:"data_center,omitempty"` + + // Name Unique name to help identify the volume. + Name *string `json:"name,omitempty"` +} + +// FileStorageVolumeLookup All 'file_storage_volume[]' params are mutually exclusive, only one can be provided. +type FileStorageVolumeLookup struct { + Id *string `json:"id,omitempty"` +} + +// FileStorageVolumeNotFoundEnum defines model for FileStorageVolumeNotFoundEnum. +type FileStorageVolumeNotFoundEnum string + +// FileStorageVolumeStateEnum defines model for FileStorageVolumeStateEnum. +type FileStorageVolumeStateEnum string + +// FlexibleResourcesUnavailableToOrganizationEnum defines model for FlexibleResourcesUnavailableToOrganizationEnum. +type FlexibleResourcesUnavailableToOrganizationEnum string + +// FlexibleResourcesUnavailableToOrganizationSchema The organization is not permitted to use flexible resources +type FlexibleResourcesUnavailableToOrganizationSchema struct { + Code *FlexibleResourcesUnavailableToOrganizationEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// GPUType defines model for GPUType. +type GPUType struct { + DataCenters *[]DataCenter `json:"data_centers,omitempty"` + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GPUTypeLookup All 'gpu_type[]' params are mutually exclusive, only one can be provided. +type GPUTypeLookup struct { + Id *string `json:"id,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GPUTypeNotFoundEnum defines model for GPUTypeNotFoundEnum. +type GPUTypeNotFoundEnum string + +// GetCountries200ResponseCountries defines model for GetCountries200ResponseCountries. +type GetCountries200ResponseCountries struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetCountryCountryStates200ResponseCountryStates defines model for GetCountryCountryStates200ResponseCountryStates. +type GetCountryCountryStates200ResponseCountryStates struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetCurrencies200ResponseCurrencies defines model for GetCurrencies200ResponseCurrencies. +type GetCurrencies200ResponseCurrencies struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetDNSRecordsDNSRecord200ResponseDNSRecord defines model for GetDNSRecordsDNSRecord200ResponseDNSRecord. +type GetDNSRecordsDNSRecord200ResponseDNSRecord struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Properties *DNSRecordProperties `json:"properties,omitempty"` + RecordType *DNSRecordTypeEnum `json:"record_type,omitempty"` + Ttl *int `json:"ttl,omitempty"` +} + +// GetDNSZonesDNSZoneRecords200ResponseDNSRecords defines model for GetDNSZonesDNSZoneRecords200ResponseDNSRecords. +type GetDNSZonesDNSZoneRecords200ResponseDNSRecords struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Properties *DNSRecordProperties `json:"properties,omitempty"` + RecordType *DNSRecordTypeEnum `json:"record_type,omitempty"` + Ttl *int `json:"ttl,omitempty"` +} + +// GetDataCenter200ResponseDataCenter defines model for GetDataCenter200ResponseDataCenter. +type GetDataCenter200ResponseDataCenter struct { + Country *GetDataCenterPartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDataCenterDefaultNetwork200ResponseNetwork defines model for GetDataCenterDefaultNetwork200ResponseNetwork. +type GetDataCenterDefaultNetwork200ResponseNetwork struct { + DataCenter *GetDataCenterDefaultNetworkPartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDataCenterDefaultNetworkPartDataCenter defines model for GetDataCenterDefaultNetworkPartDataCenter. +type GetDataCenterDefaultNetworkPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDataCenterGPUTypes200ResponseGPUTypes defines model for GetDataCenterGPUTypes200ResponseGPUTypes. +type GetDataCenterGPUTypes200ResponseGPUTypes struct { + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDataCenterPartCountry defines model for GetDataCenterPartCountry. +type GetDataCenterPartCountry struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetDataCenters200ResponseDataCenters defines model for GetDataCenters200ResponseDataCenters. +type GetDataCenters200ResponseDataCenters struct { + Country *GetDataCentersPartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDataCentersPartCountry defines model for GetDataCentersPartCountry. +type GetDataCentersPartCountry struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetDisk200ResponseDisk defines model for GetDisk200ResponseDisk. +type GetDisk200ResponseDisk struct { + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Installation *GetDiskPartInstallation `json:"installation,omitempty"` + IoProfile *GetDiskPartIOProfile `json:"io_profile,omitempty"` + Name *string `json:"name,omitempty"` + SizeInGb *int `json:"size_in_gb,omitempty"` + State *DiskStateEnum `json:"state,omitempty"` + StorageSpeed *StorageSpeedEnum `json:"storage_speed,omitempty"` + VirtualMachineDisk *GetDiskPartVirtualMachineDisk `json:"virtual_machine_disk,omitempty"` + Wwn *string `json:"wwn,omitempty"` +} + +// GetDiskBackupPolicy200ResponseDiskBackupPolicy defines model for GetDiskBackupPolicy200ResponseDiskBackupPolicy. +type GetDiskBackupPolicy200ResponseDiskBackupPolicy struct { + AutoMoveToTrashAt *int `json:"auto_move_to_trash_at,omitempty"` + Id *string `json:"id,omitempty"` + Retention *int `json:"retention,omitempty"` + Schedule *GetDiskBackupPolicyPartSchedule `json:"schedule,omitempty"` + Target *DiskBackupPolicyTarget `json:"target,omitempty"` + TotalSize *float32 `json:"total_size,omitempty"` +} + +// GetDiskBackupPolicyPartSchedule defines model for GetDiskBackupPolicyPartSchedule. +type GetDiskBackupPolicyPartSchedule struct { + Frequency *int `json:"frequency,omitempty"` + Interval *ScheduleIntervalTypeEnum `json:"interval,omitempty"` + Minute *int `json:"minute,omitempty"` + NextInvocationAt *int `json:"next_invocation_at,omitempty"` + Time *int `json:"time,omitempty"` +} + +// GetDiskDiskBackupPolicies200ResponseDiskBackupPolicies defines model for GetDiskDiskBackupPolicies200ResponseDiskBackupPolicies. +type GetDiskDiskBackupPolicies200ResponseDiskBackupPolicies struct { + Id *string `json:"id,omitempty"` + Retention *int `json:"retention,omitempty"` + Schedule *GetDiskDiskBackupPoliciesPartSchedule `json:"schedule,omitempty"` + Target *DiskBackupPolicyTarget `json:"target,omitempty"` + TotalSize *float32 `json:"total_size,omitempty"` +} + +// GetDiskDiskBackupPoliciesPartSchedule defines model for GetDiskDiskBackupPoliciesPartSchedule. +type GetDiskDiskBackupPoliciesPartSchedule struct { + Interval *ScheduleIntervalTypeEnum `json:"interval,omitempty"` + NextInvocationAt *int `json:"next_invocation_at,omitempty"` +} + +// GetDiskPartAttributes defines model for GetDiskPartAttributes. +type GetDiskPartAttributes struct { + Description *string `json:"description,omitempty"` + Key *string `json:"key,omitempty"` + Label *string `json:"label,omitempty"` + Protect *bool `json:"protect,omitempty"` + Value *string `json:"value,omitempty"` +} + +// GetDiskPartDiskTemplate defines model for GetDiskPartDiskTemplate. +type GetDiskPartDiskTemplate struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + OperatingSystem *GetDiskPartOperatingSystem `json:"operating_system,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDiskPartDiskTemplateVersion defines model for GetDiskPartDiskTemplateVersion. +type GetDiskPartDiskTemplateVersion struct { + DiskTemplate *GetDiskPartDiskTemplate `json:"disk_template,omitempty"` + Number *int `json:"number,omitempty"` + Stable *bool `json:"stable,omitempty"` +} + +// GetDiskPartIOProfile defines model for GetDiskPartIOProfile. +type GetDiskPartIOProfile struct { + Id *string `json:"id,omitempty"` + Iops *int `json:"iops,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` + SpeedInMb *int `json:"speed_in_mb,omitempty"` +} + +// GetDiskPartInstallation defines model for GetDiskPartInstallation. +type GetDiskPartInstallation struct { + Attributes *[]GetDiskPartAttributes `json:"attributes,omitempty"` + DiskTemplateVersion *GetDiskPartDiskTemplateVersion `json:"disk_template_version,omitempty"` + Id *string `json:"id,omitempty"` +} + +// GetDiskPartOperatingSystem defines model for GetDiskPartOperatingSystem. +type GetDiskPartOperatingSystem struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetDiskPartVirtualMachine defines model for GetDiskPartVirtualMachine. +type GetDiskPartVirtualMachine struct { + Fqdn *string `json:"fqdn,omitempty"` + Id *string `json:"id,omitempty"` +} + +// GetDiskPartVirtualMachineDisk defines model for GetDiskPartVirtualMachineDisk. +type GetDiskPartVirtualMachineDisk struct { + AttachOnBoot *bool `json:"attach_on_boot,omitempty"` + Boot *bool `json:"boot,omitempty"` + State *VirtualMachineDiskAttachmentStateEnum `json:"state,omitempty"` + VirtualMachine *GetDiskPartVirtualMachine `json:"virtual_machine,omitempty"` +} + +// GetDiskTemplate200ResponseDiskTemplate defines model for GetDiskTemplate200ResponseDiskTemplate. +type GetDiskTemplate200ResponseDiskTemplate struct { + Description *string `json:"description,omitempty"` + Id *string `json:"id,omitempty"` + LatestVersion *GetDiskTemplatePartLatestVersion `json:"latest_version,omitempty"` + Name *string `json:"name,omitempty"` + OperatingSystem *GetDiskTemplatePartOperatingSystem `json:"operating_system,omitempty"` + Permalink *string `json:"permalink,omitempty"` + Universal *bool `json:"universal,omitempty"` +} + +// GetDiskTemplatePartBadge defines model for GetDiskTemplatePartBadge. +type GetDiskTemplatePartBadge struct { + Url *string `json:"url,omitempty"` +} + +// GetDiskTemplatePartLatestVersion defines model for GetDiskTemplatePartLatestVersion. +type GetDiskTemplatePartLatestVersion struct { + Id *string `json:"id,omitempty"` +} + +// GetDiskTemplatePartOperatingSystem defines model for GetDiskTemplatePartOperatingSystem. +type GetDiskTemplatePartOperatingSystem struct { + Badge *GetDiskTemplatePartBadge `json:"badge,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetDiskTemplateVersion200ResponseDiskTemplateVersion defines model for GetDiskTemplateVersion200ResponseDiskTemplateVersion. +type GetDiskTemplateVersion200ResponseDiskTemplateVersion struct { + DiskTemplate *GetDiskTemplateVersionPartDiskTemplate `json:"disk_template,omitempty"` + Id *string `json:"id,omitempty"` + Number *int `json:"number,omitempty"` + SizeInGb *int `json:"size_in_gb,omitempty"` + Stable *bool `json:"stable,omitempty"` +} + +// GetDiskTemplateVersionPartDiskTemplate defines model for GetDiskTemplateVersionPartDiskTemplate. +type GetDiskTemplateVersionPartDiskTemplate struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDiskTemplateVersionSpec200ResponseDiskTemplateVersion defines model for GetDiskTemplateVersionSpec200ResponseDiskTemplateVersion. +type GetDiskTemplateVersionSpec200ResponseDiskTemplateVersion struct { + DiskTemplate *GetDiskTemplateVersionSpecPartDiskTemplate `json:"disk_template,omitempty"` + Id *string `json:"id,omitempty"` + Number *int `json:"number,omitempty"` + SizeInGb *int `json:"size_in_gb,omitempty"` + Stable *bool `json:"stable,omitempty"` +} + +// GetDiskTemplateVersionSpecPartDiskTemplate defines model for GetDiskTemplateVersionSpecPartDiskTemplate. +type GetDiskTemplateVersionSpecPartDiskTemplate struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDiskTemplateVersions200ResponseDiskTemplate defines model for GetDiskTemplateVersions200ResponseDiskTemplate. +type GetDiskTemplateVersions200ResponseDiskTemplate struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetDiskTemplateVersions200ResponseDiskTemplateVersions defines model for GetDiskTemplateVersions200ResponseDiskTemplateVersions. +type GetDiskTemplateVersions200ResponseDiskTemplateVersions struct { + Id *string `json:"id,omitempty"` + Number *int `json:"number,omitempty"` + SizeInGb *int `json:"size_in_gb,omitempty"` + Stable *bool `json:"stable,omitempty"` +} + +// GetFileStorageVolume200ResponseFileStorageVolume defines model for GetFileStorageVolume200ResponseFileStorageVolume. +type GetFileStorageVolume200ResponseFileStorageVolume struct { + Associations *[]string `json:"associations,omitempty"` + DataCenter *GetFileStorageVolumePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + + // NfsLocation The NFS location of where to mount the volume from. + NfsLocation *string `json:"nfs_location,omitempty"` + + // Size The size of the volume in bytes. + Size *int `json:"size,omitempty"` + State *FileStorageVolumeStateEnum `json:"state,omitempty"` +} + +// GetFileStorageVolumePartDataCenter defines model for GetFileStorageVolumePartDataCenter. +type GetFileStorageVolumePartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetGPUType200ResponseGPUType defines model for GetGPUType200ResponseGPUType. +type GetGPUType200ResponseGPUType struct { + DataCenters *[]GetGPUTypePartDataCenters `json:"data_centers,omitempty"` + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetGPUTypePartDataCenters defines model for GetGPUTypePartDataCenters. +type GetGPUTypePartDataCenters struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetGPUTypes200ResponseGPUTypes defines model for GetGPUTypes200ResponseGPUTypes. +type GetGPUTypes200ResponseGPUTypes struct { + DataCenters *[]GetGPUTypesPartDataCenters `json:"data_centers,omitempty"` + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetGPUTypesPartDataCenters defines model for GetGPUTypesPartDataCenters. +type GetGPUTypesPartDataCenters struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetIPAddress200ResponseAllocation defines model for GetIPAddress200ResponseAllocation. +type GetIPAddress200ResponseAllocation struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetLoadBalancer200ResponseLoadBalancer defines model for GetLoadBalancer200ResponseLoadBalancer. +type GetLoadBalancer200ResponseLoadBalancer struct { + ApiReference *string `json:"api_reference,omitempty"` + BackendCertificate *string `json:"backend_certificate,omitempty"` + BackendCertificateKey *string `json:"backend_certificate_key,omitempty"` + DataCenter *GetLoadBalancerPartDataCenter `json:"data_center,omitempty"` + EnableWeighting *bool `json:"enable_weighting,omitempty"` + HttpsRedirect *bool `json:"https_redirect,omitempty"` + Id *string `json:"id,omitempty"` + IpAddress *[]GetLoadBalancerPartIPAddress `json:"ip_address,omitempty"` + Name *string `json:"name,omitempty"` + ResourceIds *[]string `json:"resource_ids,omitempty"` + ResourceType *LoadBalancerResourceTypesEnum `json:"resource_type,omitempty"` + Resources *[]LoadBalancerResource `json:"resources,omitempty"` + StandbyVms *[]string `json:"standby_vms,omitempty"` + Weights *[]GetLoadBalancerPartWeights `json:"weights,omitempty"` +} + +// GetLoadBalancerPartDataCenter defines model for GetLoadBalancerPartDataCenter. +type GetLoadBalancerPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetLoadBalancerPartIPAddress defines model for GetLoadBalancerPartIPAddress. +type GetLoadBalancerPartIPAddress struct { + Address *string `json:"address,omitempty"` + Id *string `json:"id,omitempty"` +} + +// GetLoadBalancerPartWeights defines model for GetLoadBalancerPartWeights. +type GetLoadBalancerPartWeights struct { + VirtualMachineId *string `json:"virtual_machine_id,omitempty"` + Weight *int `json:"weight,omitempty"` +} + +// GetLoadBalancerRules200ResponseLoadBalancerRules defines model for GetLoadBalancerRules200ResponseLoadBalancerRules. +type GetLoadBalancerRules200ResponseLoadBalancerRules struct { + Algorithm *LoadBalancerRuleAlgorithmEnum `json:"algorithm,omitempty"` + Certificates *[]GetLoadBalancerRulesPartCertificates `json:"certificates,omitempty"` + CheckEnabled *bool `json:"check_enabled,omitempty"` + DestinationPort *int `json:"destination_port,omitempty"` + Id *string `json:"id,omitempty"` + ListenPort *int `json:"listen_port,omitempty"` + Protocol *LoadBalancerRuleProtocolEnum `json:"protocol,omitempty"` +} + +// GetLoadBalancerRulesPartCertificates defines model for GetLoadBalancerRulesPartCertificates. +type GetLoadBalancerRulesPartCertificates struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule defines model for GetLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule. +type GetLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule struct { + Algorithm *LoadBalancerRuleAlgorithmEnum `json:"algorithm,omitempty"` + BackendSsl *bool `json:"backend_ssl,omitempty"` + Certificates *[]GetLoadBalancersRulesLoadBalancerRulePartCertificates `json:"certificates,omitempty"` + CheckEnabled *bool `json:"check_enabled,omitempty"` + CheckFall *int `json:"check_fall,omitempty"` + CheckHttpStatuses *LoadBalancerRuleHTTPStatusesEnum `json:"check_http_statuses,omitempty"` + CheckInterval *int `json:"check_interval,omitempty"` + CheckPath *string `json:"check_path,omitempty"` + CheckProtocol *LoadBalancerRuleCheckProtocolEnum `json:"check_protocol,omitempty"` + CheckRise *int `json:"check_rise,omitempty"` + CheckTimeout *int `json:"check_timeout,omitempty"` + DestinationPort *int `json:"destination_port,omitempty"` + Id *string `json:"id,omitempty"` + ListenPort *int `json:"listen_port,omitempty"` + LoadBalancer *GetLoadBalancersRulesLoadBalancerRulePartLoadBalancer `json:"load_balancer,omitempty"` + PassthroughSsl *bool `json:"passthrough_ssl,omitempty"` + Protocol *LoadBalancerRuleProtocolEnum `json:"protocol,omitempty"` + ProxyProtocol *bool `json:"proxy_protocol,omitempty"` +} + +// GetLoadBalancersRulesLoadBalancerRulePartCertificates defines model for GetLoadBalancersRulesLoadBalancerRulePartCertificates. +type GetLoadBalancersRulesLoadBalancerRulePartCertificates struct { + AdditionalNames *[]string `json:"additional_names,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + State *CertificateStateEnum `json:"state,omitempty"` +} + +// GetLoadBalancersRulesLoadBalancerRulePartLoadBalancer defines model for GetLoadBalancersRulesLoadBalancerRulePartLoadBalancer. +type GetLoadBalancersRulesLoadBalancerRulePartLoadBalancer struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetOperatingSystems200ResponseOperatingSystems defines model for GetOperatingSystems200ResponseOperatingSystems. +type GetOperatingSystems200ResponseOperatingSystems struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetOrganizationAvailableNetworks200ResponseNetworks defines model for GetOrganizationAvailableNetworks200ResponseNetworks. +type GetOrganizationAvailableNetworks200ResponseNetworks struct { + DataCenter *GetOrganizationAvailableNetworksPartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetOrganizationAvailableNetworks200ResponseVirtualNetworks defines model for GetOrganizationAvailableNetworks200ResponseVirtualNetworks. +type GetOrganizationAvailableNetworks200ResponseVirtualNetworks struct { + DataCenter *GetOrganizationAvailableNetworksPartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetOrganizationAvailableNetworksPartDataCenter defines model for GetOrganizationAvailableNetworksPartDataCenter. +type GetOrganizationAvailableNetworksPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetOrganizationCertificates200ResponseCertificates defines model for GetOrganizationCertificates200ResponseCertificates. +type GetOrganizationCertificates200ResponseCertificates struct { + ExpiresAt *int `json:"expires_at,omitempty"` + Id *string `json:"id,omitempty"` + Issuer *IssuerEnum `json:"issuer,omitempty"` + LastIssuedAt *int `json:"last_issued_at,omitempty"` + Name *string `json:"name,omitempty"` + State *CertificateStateEnum `json:"state,omitempty"` +} + +// GetOrganizationDiskBackupPolicies200ResponseDiskBackupPolicies defines model for GetOrganizationDiskBackupPolicies200ResponseDiskBackupPolicies. +type GetOrganizationDiskBackupPolicies200ResponseDiskBackupPolicies struct { + Id *string `json:"id,omitempty"` + Retention *int `json:"retention,omitempty"` + Schedule *GetOrganizationDiskBackupPoliciesPartSchedule `json:"schedule,omitempty"` + Target *DiskBackupPolicyTarget `json:"target,omitempty"` + TotalSize *float32 `json:"total_size,omitempty"` +} + +// GetOrganizationDiskBackupPoliciesPartSchedule defines model for GetOrganizationDiskBackupPoliciesPartSchedule. +type GetOrganizationDiskBackupPoliciesPartSchedule struct { + Interval *ScheduleIntervalTypeEnum `json:"interval,omitempty"` + NextInvocationAt *int `json:"next_invocation_at,omitempty"` +} + +// GetOrganizationDiskTemplates200ResponseDiskTemplates defines model for GetOrganizationDiskTemplates200ResponseDiskTemplates. +type GetOrganizationDiskTemplates200ResponseDiskTemplates struct { + Description *string `json:"description,omitempty"` + Id *string `json:"id,omitempty"` + LatestVersion *GetOrganizationDiskTemplatesPartLatestVersion `json:"latest_version,omitempty"` + Name *string `json:"name,omitempty"` + OperatingSystem *GetOrganizationDiskTemplatesPartOperatingSystem `json:"operating_system,omitempty"` + Permalink *string `json:"permalink,omitempty"` + Universal *bool `json:"universal,omitempty"` +} + +// GetOrganizationDiskTemplatesPartLatestVersion defines model for GetOrganizationDiskTemplatesPartLatestVersion. +type GetOrganizationDiskTemplatesPartLatestVersion struct { + Id *string `json:"id,omitempty"` + Number *int `json:"number,omitempty"` +} + +// GetOrganizationDiskTemplatesPartOperatingSystem defines model for GetOrganizationDiskTemplatesPartOperatingSystem. +type GetOrganizationDiskTemplatesPartOperatingSystem struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetOrganizationDisks200ResponseDisk defines model for GetOrganizationDisks200ResponseDisk. +type GetOrganizationDisks200ResponseDisk struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + SizeInGb *int `json:"size_in_gb,omitempty"` + State *DiskStateEnum `json:"state,omitempty"` + VirtualMachineDisk *GetOrganizationDisksPartVirtualMachineDisk `json:"virtual_machine_disk,omitempty"` + Wwn *string `json:"wwn,omitempty"` +} + +// GetOrganizationDisksPartVirtualMachine defines model for GetOrganizationDisksPartVirtualMachine. +type GetOrganizationDisksPartVirtualMachine struct { + Fqdn *string `json:"fqdn,omitempty"` + Id *string `json:"id,omitempty"` +} + +// GetOrganizationDisksPartVirtualMachineDisk defines model for GetOrganizationDisksPartVirtualMachineDisk. +type GetOrganizationDisksPartVirtualMachineDisk struct { + VirtualMachine *GetOrganizationDisksPartVirtualMachine `json:"virtual_machine,omitempty"` +} + +// GetOrganizationFileStorageVolumes200ResponseFileStorageVolumes defines model for GetOrganizationFileStorageVolumes200ResponseFileStorageVolumes. +type GetOrganizationFileStorageVolumes200ResponseFileStorageVolumes struct { + Associations *[]string `json:"associations,omitempty"` + DataCenter *GetOrganizationFileStorageVolumesPartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + + // NfsLocation The NFS location of where to mount the volume from. + NfsLocation *string `json:"nfs_location,omitempty"` + + // Size The size of the volume in bytes. + Size *int `json:"size,omitempty"` + State *FileStorageVolumeStateEnum `json:"state,omitempty"` +} + +// GetOrganizationFileStorageVolumesPartDataCenter defines model for GetOrganizationFileStorageVolumesPartDataCenter. +type GetOrganizationFileStorageVolumesPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetOrganizationIPAddresses200ResponseIPAddresses defines model for GetOrganizationIPAddresses200ResponseIPAddresses. +type GetOrganizationIPAddresses200ResponseIPAddresses struct { + Address *string `json:"address,omitempty"` + AllocationId *string `json:"allocation_id,omitempty"` + AllocationType *string `json:"allocation_type,omitempty"` + Id *string `json:"id,omitempty"` + ReverseDns *string `json:"reverse_dns,omitempty"` + Vip *bool `json:"vip,omitempty"` +} + +// GetOrganizationLoadBalancers200ResponseLoadBalancers defines model for GetOrganizationLoadBalancers200ResponseLoadBalancers. +type GetOrganizationLoadBalancers200ResponseLoadBalancers struct { + ApiReference *string `json:"api_reference,omitempty"` + DataCenter *GetOrganizationLoadBalancersPartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + IpAddress *[]GetOrganizationLoadBalancersPartIPAddress `json:"ip_address,omitempty"` + Name *string `json:"name,omitempty"` + ResourceIds *[]string `json:"resource_ids,omitempty"` + ResourceType *LoadBalancerResourceTypesEnum `json:"resource_type,omitempty"` + Resources *[]LoadBalancerResource `json:"resources,omitempty"` +} + +// GetOrganizationLoadBalancersPartDataCenter defines model for GetOrganizationLoadBalancersPartDataCenter. +type GetOrganizationLoadBalancersPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetOrganizationLoadBalancersPartIPAddress defines model for GetOrganizationLoadBalancersPartIPAddress. +type GetOrganizationLoadBalancersPartIPAddress struct { + Address *string `json:"address,omitempty"` +} + +// GetOrganizationManaged200ResponseOrganizations defines model for GetOrganizationManaged200ResponseOrganizations. +type GetOrganizationManaged200ResponseOrganizations struct { + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + InfrastructureDomain *string `json:"infrastructure_domain,omitempty"` + Managed *bool `json:"managed,omitempty"` + Name *string `json:"name,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` +} + +// GetOrganizationTags200ResponseTags defines model for GetOrganizationTags200ResponseTags. +type GetOrganizationTags200ResponseTags struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetOrganizationUsersWithAccess200ResponseUsers defines model for GetOrganizationUsersWithAccess200ResponseUsers. +type GetOrganizationUsersWithAccess200ResponseUsers struct { + User *GetOrganizationUsersWithAccessPartUser `json:"user,omitempty"` +} + +// GetOrganizationUsersWithAccessPartUser defines model for GetOrganizationUsersWithAccessPartUser. +type GetOrganizationUsersWithAccessPartUser struct { + AvatarUrl *string `json:"avatar_url,omitempty"` + FirstName *string `json:"first_name,omitempty"` + Id *string `json:"id,omitempty"` + LastName *string `json:"last_name,omitempty"` +} + +// GetOrganizationVirtualMachines200ResponseVirtualMachines defines model for GetOrganizationVirtualMachines200ResponseVirtualMachines. +type GetOrganizationVirtualMachines200ResponseVirtualMachines struct { + CreatedAt *int `json:"created_at,omitempty"` + Fqdn *string `json:"fqdn,omitempty"` + GpuType *GetOrganizationVirtualMachinesPartGPUType `json:"gpu_type,omitempty"` + Hostname *string `json:"hostname,omitempty"` + Id *string `json:"id,omitempty"` + IpAddresses *[]GetOrganizationVirtualMachinesPartIPAddresses `json:"ip_addresses,omitempty"` + Name *string `json:"name,omitempty"` + Package *GetOrganizationVirtualMachinesPartPackage `json:"package,omitempty"` + Zone *GetOrganizationVirtualMachinesPartZone `json:"zone,omitempty"` +} + +// GetOrganizationVirtualMachinesPartDataCenter defines model for GetOrganizationVirtualMachinesPartDataCenter. +type GetOrganizationVirtualMachinesPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetOrganizationVirtualMachinesPartGPUType defines model for GetOrganizationVirtualMachinesPartGPUType. +type GetOrganizationVirtualMachinesPartGPUType struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetOrganizationVirtualMachinesPartIPAddresses defines model for GetOrganizationVirtualMachinesPartIPAddresses. +type GetOrganizationVirtualMachinesPartIPAddresses struct { + Address *string `json:"address,omitempty"` +} + +// GetOrganizationVirtualMachinesPartPackage defines model for GetOrganizationVirtualMachinesPartPackage. +type GetOrganizationVirtualMachinesPartPackage struct { + Name *string `json:"name,omitempty"` +} + +// GetOrganizationVirtualMachinesPartZone defines model for GetOrganizationVirtualMachinesPartZone. +type GetOrganizationVirtualMachinesPartZone struct { + DataCenter *GetOrganizationVirtualMachinesPartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetOrganizations200ResponseOrganizations defines model for GetOrganizations200ResponseOrganizations. +type GetOrganizations200ResponseOrganizations struct { + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + InfrastructureDomain *string `json:"infrastructure_domain,omitempty"` + Managed *bool `json:"managed,omitempty"` + Name *string `json:"name,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` + Suspended *bool `json:"suspended,omitempty"` +} + +// GetSecurityGroupRules200ResponseSecurityGroupRules defines model for GetSecurityGroupRules200ResponseSecurityGroupRules. +type GetSecurityGroupRules200ResponseSecurityGroupRules struct { + Action *SecurityGroupRuleActionEnum `json:"action,omitempty"` + Direction *SecurityGroupRuleDirectionEnum `json:"direction,omitempty"` + Id *string `json:"id,omitempty"` + Notes *string `json:"notes,omitempty"` + Ports *string `json:"ports,omitempty"` + Protocol *SecurityGroupRuleProtocolEnum `json:"protocol,omitempty"` + Targets *[]string `json:"targets,omitempty"` +} + +// GetSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule defines model for GetSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule. +type GetSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule struct { + Action *SecurityGroupRuleActionEnum `json:"action,omitempty"` + Direction *SecurityGroupRuleDirectionEnum `json:"direction,omitempty"` + Id *string `json:"id,omitempty"` + Notes *string `json:"notes,omitempty"` + Ports *string `json:"ports,omitempty"` + Protocol *SecurityGroupRuleProtocolEnum `json:"protocol,omitempty"` + SecurityGroup *GetSecurityGroupsRulesSecurityGroupRulePartSecurityGroup `json:"security_group,omitempty"` + Targets *[]string `json:"targets,omitempty"` +} + +// GetSecurityGroupsRulesSecurityGroupRulePartSecurityGroup defines model for GetSecurityGroupsRulesSecurityGroupRulePartSecurityGroup. +type GetSecurityGroupsRulesSecurityGroupRulePartSecurityGroup struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetUsersCurrent200ResponseOrganizations defines model for GetUsersCurrent200ResponseOrganizations. +type GetUsersCurrent200ResponseOrganizations struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` +} + +// GetVMNIVMNI200ResponseVirtualMachineNetworkInterface defines model for GetVMNIVMNI200ResponseVirtualMachineNetworkInterface. +type GetVMNIVMNI200ResponseVirtualMachineNetworkInterface struct { + Id *string `json:"id,omitempty"` + IpAddresses *[]GetVMNIVMNIPartIPAddresses `json:"ip_addresses,omitempty"` + MacAddress *string `json:"mac_address,omitempty"` + Name *string `json:"name,omitempty"` + Network *GetVMNIVMNIPartNetwork `json:"network,omitempty"` + SpeedProfile *GetVMNIVMNIPartSpeedProfile `json:"speed_profile,omitempty"` + State *string `json:"state,omitempty"` + VirtualMachine *GetVMNIVMNIPartVirtualMachine `json:"virtual_machine,omitempty"` +} + +// GetVMNIVMNIPartIPAddresses defines model for GetVMNIVMNIPartIPAddresses. +type GetVMNIVMNIPartIPAddresses struct { + Address *string `json:"address,omitempty"` + Id *string `json:"id,omitempty"` +} + +// GetVMNIVMNIPartNetwork defines model for GetVMNIVMNIPartNetwork. +type GetVMNIVMNIPartNetwork struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetVMNIVMNIPartSpeedProfile defines model for GetVMNIVMNIPartSpeedProfile. +type GetVMNIVMNIPartSpeedProfile struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetVMNIVMNIPartVirtualMachine defines model for GetVMNIVMNIPartVirtualMachine. +type GetVMNIVMNIPartVirtualMachine struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetVirtualMachine200ResponseVirtualMachine defines model for GetVirtualMachine200ResponseVirtualMachine. +type GetVirtualMachine200ResponseVirtualMachine struct { + AttachedIso *GetVirtualMachinePartAttachedISO `json:"attached_iso,omitempty"` + CpuCores *int `json:"cpu_cores,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Description *string `json:"description,omitempty"` + Fqdn *string `json:"fqdn,omitempty"` + GpuType *GetVirtualMachinePartGPUType `json:"gpu_type,omitempty"` + Gpus *[]GetVirtualMachinePartGPUs `json:"gpus,omitempty"` + Group *GetVirtualMachinePartGroup `json:"group,omitempty"` + Hostname *string `json:"hostname,omitempty"` + Id *string `json:"id,omitempty"` + InitialRootPassword *string `json:"initial_root_password,omitempty"` + IpAddresses *[]GetVirtualMachinePartIPAddresses `json:"ip_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Organization *GetVirtualMachinePartOrganization `json:"organization,omitempty"` + Package *GetVirtualMachinePartPackage `json:"package,omitempty"` + State *VirtualMachineStateEnum `json:"state,omitempty"` + TagNames *[]string `json:"tag_names,omitempty"` + Tags *[]GetVirtualMachinePartTags `json:"tags,omitempty"` + Zone *GetVirtualMachinePartZone `json:"zone,omitempty"` +} + +// GetVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicies defines model for GetVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicies. +type GetVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicies struct { + Id *string `json:"id,omitempty"` + Retention *int `json:"retention,omitempty"` + Schedule *GetVirtualMachineDiskBackupPoliciesPartSchedule `json:"schedule,omitempty"` + Target *DiskBackupPolicyTarget `json:"target,omitempty"` + TotalSize *float32 `json:"total_size,omitempty"` +} + +// GetVirtualMachineDiskBackupPoliciesPartSchedule defines model for GetVirtualMachineDiskBackupPoliciesPartSchedule. +type GetVirtualMachineDiskBackupPoliciesPartSchedule struct { + Interval *ScheduleIntervalTypeEnum `json:"interval,omitempty"` + NextInvocationAt *int `json:"next_invocation_at,omitempty"` +} + +// GetVirtualMachineDisks200ResponseDisks defines model for GetVirtualMachineDisks200ResponseDisks. +type GetVirtualMachineDisks200ResponseDisks struct { + AttachOnBoot *bool `json:"attach_on_boot,omitempty"` + Boot *bool `json:"boot,omitempty"` + Disk *GetVirtualMachineDisksPartDisk `json:"disk,omitempty"` + State *VirtualMachineDiskAttachmentStateEnum `json:"state,omitempty"` +} + +// GetVirtualMachineDisksPartDisk defines model for GetVirtualMachineDisksPartDisk. +type GetVirtualMachineDisksPartDisk struct { + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + SizeInGb *int `json:"size_in_gb,omitempty"` + State *DiskStateEnum `json:"state,omitempty"` + Wwn *string `json:"wwn,omitempty"` +} + +// GetVirtualMachineNetworkInterface200ResponseVirtualMachineNetworkInterface defines model for GetVirtualMachineNetworkInterface200ResponseVirtualMachineNetworkInterface. +type GetVirtualMachineNetworkInterface200ResponseVirtualMachineNetworkInterface struct { + Id *string `json:"id,omitempty"` + IpAddresses *[]GetVirtualMachineNetworkInterfacePartIPAddresses `json:"ip_addresses,omitempty"` + MacAddress *string `json:"mac_address,omitempty"` + Name *string `json:"name,omitempty"` + Network *GetVirtualMachineNetworkInterfacePartNetwork `json:"network,omitempty"` + State *string `json:"state,omitempty"` + VirtualMachine *GetVirtualMachineNetworkInterfacePartVirtualMachine `json:"virtual_machine,omitempty"` +} + +// GetVirtualMachineNetworkInterfacePartIPAddresses defines model for GetVirtualMachineNetworkInterfacePartIPAddresses. +type GetVirtualMachineNetworkInterfacePartIPAddresses struct { + Address *string `json:"address,omitempty"` + Id *string `json:"id,omitempty"` +} + +// GetVirtualMachineNetworkInterfacePartNetwork defines model for GetVirtualMachineNetworkInterfacePartNetwork. +type GetVirtualMachineNetworkInterfacePartNetwork struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetVirtualMachineNetworkInterfacePartVirtualMachine defines model for GetVirtualMachineNetworkInterfacePartVirtualMachine. +type GetVirtualMachineNetworkInterfacePartVirtualMachine struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetVirtualMachineNetworkInterfaces200ResponseVirtualMachineNetworkInterfaces defines model for GetVirtualMachineNetworkInterfaces200ResponseVirtualMachineNetworkInterfaces. +type GetVirtualMachineNetworkInterfaces200ResponseVirtualMachineNetworkInterfaces struct { + Id *string `json:"id,omitempty"` + IpAddresses *[]GetVirtualMachineNetworkInterfacesPartIPAddresses `json:"ip_addresses,omitempty"` + Name *string `json:"name,omitempty"` + Network *GetVirtualMachineNetworkInterfacesPartNetwork `json:"network,omitempty"` +} + +// GetVirtualMachineNetworkInterfacesPartIPAddresses defines model for GetVirtualMachineNetworkInterfacesPartIPAddresses. +type GetVirtualMachineNetworkInterfacesPartIPAddresses struct { + Address *string `json:"address,omitempty"` + Id *string `json:"id,omitempty"` +} + +// GetVirtualMachineNetworkInterfacesPartNetwork defines model for GetVirtualMachineNetworkInterfacesPartNetwork. +type GetVirtualMachineNetworkInterfacesPartNetwork struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetVirtualMachinePackages200ResponseVirtualMachinePackages defines model for GetVirtualMachinePackages200ResponseVirtualMachinePackages. +type GetVirtualMachinePackages200ResponseVirtualMachinePackages struct { + CpuCores *int `json:"cpu_cores,omitempty"` + Icon *GetVirtualMachinePackagesPartIcon `json:"icon,omitempty"` + Id *string `json:"id,omitempty"` + Ipv4Addresses *int `json:"ipv4_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` + Privacy *PrivacyTypesEnum `json:"privacy,omitempty"` + StorageInGb *int `json:"storage_in_gb,omitempty"` +} + +// GetVirtualMachinePackagesPartIcon defines model for GetVirtualMachinePackagesPartIcon. +type GetVirtualMachinePackagesPartIcon struct { + Url *string `json:"url,omitempty"` +} + +// GetVirtualMachinePartAttachedISO defines model for GetVirtualMachinePartAttachedISO. +type GetVirtualMachinePartAttachedISO struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + OperatingSystem *GetVirtualMachinePartOperatingSystem `json:"operating_system,omitempty"` +} + +// GetVirtualMachinePartBadge defines model for GetVirtualMachinePartBadge. +type GetVirtualMachinePartBadge struct { + Digest *string `json:"digest,omitempty"` + FileName *string `json:"file_name,omitempty"` + FileSize *int `json:"file_size,omitempty"` + FileType *string `json:"file_type,omitempty"` + Token *string `json:"token,omitempty"` + Url *string `json:"url,omitempty"` +} + +// GetVirtualMachinePartCountry defines model for GetVirtualMachinePartCountry. +type GetVirtualMachinePartCountry struct { + Eu *bool `json:"eu,omitempty"` + Id *string `json:"id,omitempty"` + IsoCode2 *string `json:"iso_code2,omitempty"` + IsoCode3 *string `json:"iso_code3,omitempty"` + Name *string `json:"name,omitempty"` + TimeZone *string `json:"time_zone,omitempty"` +} + +// GetVirtualMachinePartCountryState defines model for GetVirtualMachinePartCountryState. +type GetVirtualMachinePartCountryState struct { + Code *string `json:"code,omitempty"` + Country *GetVirtualMachinePartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetVirtualMachinePartCurrency defines model for GetVirtualMachinePartCurrency. +type GetVirtualMachinePartCurrency struct { + Id *string `json:"id,omitempty"` + IsoCode *string `json:"iso_code,omitempty"` + Name *string `json:"name,omitempty"` + Symbol *string `json:"symbol,omitempty"` +} + +// GetVirtualMachinePartDataCenter defines model for GetVirtualMachinePartDataCenter. +type GetVirtualMachinePartDataCenter struct { + Country *GetVirtualMachinePartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetVirtualMachinePartGPUType defines model for GetVirtualMachinePartGPUType. +type GetVirtualMachinePartGPUType struct { + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetVirtualMachinePartGPUs defines model for GetVirtualMachinePartGPUs. +type GetVirtualMachinePartGPUs struct { + // Available When pending action is "attach", this indicates if there is a GPU of the relevant type available. + Available *bool `json:"available,omitempty"` + + // Id Unique ID for this GPU. Not available when status is "detached". + Id *string `json:"id,omitempty"` + PendingAction *VirtualMachineGPUPendingActionEnum `json:"pending_action,omitempty"` + Status *VirtualMachineGPUStatusEnum `json:"status,omitempty"` + Type *GetVirtualMachinePartType `json:"type,omitempty"` +} + +// GetVirtualMachinePartGroup defines model for GetVirtualMachinePartGroup. +type GetVirtualMachinePartGroup struct { + AutoSegregate *bool `json:"auto_segregate,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Segregate *bool `json:"segregate,omitempty"` +} + +// GetVirtualMachinePartIPAddresses defines model for GetVirtualMachinePartIPAddresses. +type GetVirtualMachinePartIPAddresses struct { + Address *string `json:"address,omitempty"` + AddressWithMask *string `json:"address_with_mask,omitempty"` + AllocationId *string `json:"allocation_id,omitempty"` + AllocationType *string `json:"allocation_type,omitempty"` + Id *string `json:"id,omitempty"` + Label *string `json:"label,omitempty"` + Network *GetVirtualMachinePartNetwork `json:"network,omitempty"` + ReverseDns *string `json:"reverse_dns,omitempty"` + Vip *bool `json:"vip,omitempty"` +} + +// GetVirtualMachinePartIcon defines model for GetVirtualMachinePartIcon. +type GetVirtualMachinePartIcon struct { + Digest *string `json:"digest,omitempty"` + FileName *string `json:"file_name,omitempty"` + FileSize *int `json:"file_size,omitempty"` + FileType *string `json:"file_type,omitempty"` + Token *string `json:"token,omitempty"` + Url *string `json:"url,omitempty"` +} + +// GetVirtualMachinePartNetwork defines model for GetVirtualMachinePartNetwork. +type GetVirtualMachinePartNetwork struct { + DataCenter *GetVirtualMachinePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetVirtualMachinePartOperatingSystem defines model for GetVirtualMachinePartOperatingSystem. +type GetVirtualMachinePartOperatingSystem struct { + Badge *GetVirtualMachinePartBadge `json:"badge,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetVirtualMachinePartOrganization defines model for GetVirtualMachinePartOrganization. +type GetVirtualMachinePartOrganization struct { + Address1 *string `json:"address1,omitempty"` + Address2 *string `json:"address2,omitempty"` + Address3 *string `json:"address3,omitempty"` + Address4 *string `json:"address4,omitempty"` + BillingName *string `json:"billing_name,omitempty"` + Country *GetVirtualMachinePartCountry `json:"country,omitempty"` + CountryState *GetVirtualMachinePartCountryState `json:"country_state,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Currency *GetVirtualMachinePartCurrency `json:"currency,omitempty"` + Id *string `json:"id,omitempty"` + InfrastructureDomain *string `json:"infrastructure_domain,omitempty"` + Managed *bool `json:"managed,omitempty"` + Name *string `json:"name,omitempty"` + PhoneNumber *string `json:"phone_number,omitempty"` + Postcode *string `json:"postcode,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` + Suspended *bool `json:"suspended,omitempty"` + VatNumber *string `json:"vat_number,omitempty"` +} + +// GetVirtualMachinePartPackage defines model for GetVirtualMachinePartPackage. +type GetVirtualMachinePartPackage struct { + CpuCores *int `json:"cpu_cores,omitempty"` + Icon *GetVirtualMachinePartIcon `json:"icon,omitempty"` + Id *string `json:"id,omitempty"` + Ipv4Addresses *int `json:"ipv4_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MonthlyBandwidthAllowanceInGb *int `json:"monthly_bandwidth_allowance_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` + Privacy *PrivacyTypesEnum `json:"privacy,omitempty"` + StorageInGb *int `json:"storage_in_gb,omitempty"` +} + +// GetVirtualMachinePartTags defines model for GetVirtualMachinePartTags. +type GetVirtualMachinePartTags struct { + Color *TagColorsEnum `json:"color,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// GetVirtualMachinePartType defines model for GetVirtualMachinePartType. +type GetVirtualMachinePartType struct { + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetVirtualMachinePartZone defines model for GetVirtualMachinePartZone. +type GetVirtualMachinePartZone struct { + DataCenter *GetVirtualMachinePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetVirtualMachinesBuildsVirtualMachineBuild200ResponseVirtualMachineBuild defines model for GetVirtualMachinesBuildsVirtualMachineBuild200ResponseVirtualMachineBuild. +type GetVirtualMachinesBuildsVirtualMachineBuild200ResponseVirtualMachineBuild struct { + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + SpecXml *string `json:"spec_xml,omitempty"` + State *VirtualMachineBuildStateEnum `json:"state,omitempty"` + VirtualMachine *GetVirtualMachinesBuildsVirtualMachineBuildPartVirtualMachine `json:"virtual_machine,omitempty"` +} + +// GetVirtualMachinesBuildsVirtualMachineBuildPartVirtualMachine defines model for GetVirtualMachinesBuildsVirtualMachineBuildPartVirtualMachine. +type GetVirtualMachinesBuildsVirtualMachineBuildPartVirtualMachine struct { + Fqdn *string `json:"fqdn,omitempty"` + Hostname *string `json:"hostname,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + State *VirtualMachineStateEnum `json:"state,omitempty"` +} + +// GetZones200ResponseZones defines model for GetZones200ResponseZones. +type GetZones200ResponseZones struct { + DataCenter *GetZonesPartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// GetZonesPartDataCenter defines model for GetZonesPartDataCenter. +type GetZonesPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// IPAddress defines model for IPAddress. +type IPAddress struct { + Address *string `json:"address,omitempty"` + AddressWithMask *string `json:"address_with_mask,omitempty"` + AllocationId *string `json:"allocation_id,omitempty"` + AllocationType *string `json:"allocation_type,omitempty"` + Id *string `json:"id,omitempty"` + Label *string `json:"label,omitempty"` + Network *Network `json:"network,omitempty"` + ReverseDns *string `json:"reverse_dns,omitempty"` + Vip *bool `json:"vip,omitempty"` +} + +// IPAddressLookup All 'ip_address[]' params are mutually exclusive, only one can be provided. +type IPAddressLookup struct { + Address *string `json:"address,omitempty"` + Id *string `json:"id,omitempty"` +} + +// IPAddressNotFoundEnum defines model for IPAddressNotFoundEnum. +type IPAddressNotFoundEnum string + +// IPAddressNotFoundSchema No IP addresses were found matching any of the criteria provided in the arguments +type IPAddressNotFoundSchema struct { + Code *IPAddressNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// IPAddressVersionEnum defines model for IPAddressVersionEnum. +type IPAddressVersionEnum string + +// IPAlreadyAllocatedEnum defines model for IPAlreadyAllocatedEnum. +type IPAlreadyAllocatedEnum string + +// IPAlreadyAllocatedSchema This IP address has already been allocated to another resource +type IPAlreadyAllocatedSchema struct { + Code *IPAlreadyAllocatedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// ISO defines model for ISO. +type ISO struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + OperatingSystem *OperatingSystem `json:"operating_system,omitempty"` +} + +// IdentityNotLinkedToWebSessionEnum defines model for IdentityNotLinkedToWebSessionEnum. +type IdentityNotLinkedToWebSessionEnum string + +// IdentityNotLinkedToWebSessionSchema The authenticated identity is not linked to a web session +type IdentityNotLinkedToWebSessionSchema struct { + Code *IdentityNotLinkedToWebSessionEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// InfrastructureDNSZoneCannotBeEditedEnum defines model for InfrastructureDNSZoneCannotBeEditedEnum. +type InfrastructureDNSZoneCannotBeEditedEnum string + +// InfrastructureDNSZoneCannotBeEditedSchema Infrastructure DNS zones cannot be edited through the API. These are managed exclusively by Katapult. +type InfrastructureDNSZoneCannotBeEditedSchema struct { + Code *InfrastructureDNSZoneCannotBeEditedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// InterfaceNotFoundEnum defines model for InterfaceNotFoundEnum. +type InterfaceNotFoundEnum string + +// InterfaceNotFoundSchema An interface could not be found for the specified network +type InterfaceNotFoundSchema struct { + Code *InterfaceNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// InvalidAPIToken defines model for InvalidAPIToken. +type InvalidAPIToken struct { + Details *string `json:"details,omitempty"` +} + +// InvalidAPITokenEnum defines model for InvalidAPITokenEnum. +type InvalidAPITokenEnum string + +// InvalidAPITokenSchema The API token provided was not valid (it may not exist or have expired) +type InvalidAPITokenSchema struct { + Code *InvalidAPITokenEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *InvalidAPIToken `json:"detail,omitempty"` +} + +// InvalidIPEnum defines model for InvalidIPEnum. +type InvalidIPEnum string + +// InvalidIPSchema This IP address is not valid for this network interface. +type InvalidIPSchema struct { + Code *InvalidIPEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// InvalidSpecXML defines model for InvalidSpecXML. +type InvalidSpecXML struct { + // Errors A textual description of the errors with the provided XML + Errors *string `json:"errors,omitempty"` +} + +// InvalidSpecXMLEnum defines model for InvalidSpecXMLEnum. +type InvalidSpecXMLEnum string + +// InvalidSpecXMLSchema The spec XML provided is invalid +type InvalidSpecXMLSchema struct { + Code *InvalidSpecXMLEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *InvalidSpecXML `json:"detail,omitempty"` +} + +// InvalidTimestampEnum defines model for InvalidTimestampEnum. +type InvalidTimestampEnum string + +// InvalidTimestampSchema Timestamp must be at least 5 minutes in the future. If you want to delete something immediately, you use can use the delete endpoint. +type InvalidTimestampSchema struct { + Code *InvalidTimestampEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// IssuerEnum defines model for IssuerEnum. +type IssuerEnum string + +// KeyValue All 'disk_template_options[]' params are mutually exclusive, only one can be provided. +type KeyValue struct { + Key string `json:"key"` + Value *string `json:"value,omitempty"` +} + +// LoadBalancerArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type LoadBalancerArguments struct { + ApiReference *string `json:"api_reference,omitempty"` + + // DataCenter All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenter *DataCenterLookup `json:"data_center,omitempty"` + EnableWeighting *bool `json:"enable_weighting,omitempty"` + HttpsRedirect *bool `json:"https_redirect,omitempty"` + Name *string `json:"name,omitempty"` + ResourceIds *[]string `json:"resource_ids,omitempty"` + ResourceType *LoadBalancerResourceTypesEnum `json:"resource_type,omitempty"` + StandbyVms *[]string `json:"standby_vms,omitempty"` + Weights *[]LoadBalancerWeightsArguments `json:"weights,omitempty"` +} + +// LoadBalancerLookup All 'load_balancer[]' params are mutually exclusive, only one can be provided. +type LoadBalancerLookup struct { + ApiReference *string `json:"api_reference,omitempty"` + Id *string `json:"id,omitempty"` +} + +// LoadBalancerNotFoundEnum defines model for LoadBalancerNotFoundEnum. +type LoadBalancerNotFoundEnum string + +// LoadBalancerResource defines model for LoadBalancerResource. +type LoadBalancerResource struct { + Resources *LoadBalancerResource_Resources `json:"resources,omitempty"` +} + +// LoadBalancerResource_Resources defines model for LoadBalancerResource.Resources. +type LoadBalancerResource_Resources struct { + union json.RawMessage +} + +// LoadBalancerResourceTypesEnum defines model for LoadBalancerResourceTypesEnum. +type LoadBalancerResourceTypesEnum string + +// LoadBalancerRuleAlgorithmEnum defines model for LoadBalancerRuleAlgorithmEnum. +type LoadBalancerRuleAlgorithmEnum string + +// LoadBalancerRuleArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type LoadBalancerRuleArguments struct { + Algorithm *LoadBalancerRuleAlgorithmEnum `json:"algorithm,omitempty"` + BackendSsl *bool `json:"backend_ssl,omitempty"` + Certificates *[]CertificateLookup `json:"certificates,omitempty"` + CheckEnabled *bool `json:"check_enabled,omitempty"` + CheckFall *int `json:"check_fall,omitempty"` + CheckHttpStatuses *LoadBalancerRuleHTTPStatusesEnum `json:"check_http_statuses,omitempty"` + CheckInterval *int `json:"check_interval,omitempty"` + CheckPath *string `json:"check_path,omitempty"` + CheckProtocol *LoadBalancerRuleCheckProtocolEnum `json:"check_protocol,omitempty"` + CheckRise *int `json:"check_rise,omitempty"` + CheckTimeout *int `json:"check_timeout,omitempty"` + DestinationPort *int `json:"destination_port,omitempty"` + ListenPort *int `json:"listen_port,omitempty"` + PassthroughSsl *bool `json:"passthrough_ssl,omitempty"` + Protocol *LoadBalancerRuleProtocolEnum `json:"protocol,omitempty"` + ProxyProtocol *bool `json:"proxy_protocol,omitempty"` +} + +// LoadBalancerRuleCheckProtocolEnum defines model for LoadBalancerRuleCheckProtocolEnum. +type LoadBalancerRuleCheckProtocolEnum string + +// LoadBalancerRuleHTTPStatusesEnum defines model for LoadBalancerRuleHTTPStatusesEnum. +type LoadBalancerRuleHTTPStatusesEnum string + +// LoadBalancerRuleLookup All 'load_balancer_rule[]' params are mutually exclusive, only one can be provided. +type LoadBalancerRuleLookup struct { + Id *string `json:"id,omitempty"` +} + +// LoadBalancerRuleNotFoundEnum defines model for LoadBalancerRuleNotFoundEnum. +type LoadBalancerRuleNotFoundEnum string + +// LoadBalancerRuleProtocolEnum defines model for LoadBalancerRuleProtocolEnum. +type LoadBalancerRuleProtocolEnum string + +// LoadBalancerWeightsArguments All 'weights[]' params are mutually exclusive, only one can be provided. +type LoadBalancerWeightsArguments struct { + VirtualMachineId *string `json:"virtual_machine_id,omitempty"` + Weight *int `json:"weight,omitempty"` +} + +// LocationRequiredEnum defines model for LocationRequiredEnum. +type LocationRequiredEnum string + +// LocationRequiredSchema A zone or a data_center argument must be provided +type LocationRequiredSchema struct { + Code *LocationRequiredEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// MX defines model for MX. +type MX struct { + Host *string `json:"host,omitempty"` + Priority *string `json:"priority,omitempty"` +} + +// MissingAPITokenEnum defines model for MissingAPITokenEnum. +type MissingAPITokenEnum string + +// NS defines model for NS. +type NS struct { + Name *string `json:"name,omitempty"` +} + +// Network defines model for Network. +type Network struct { + DataCenter *DataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// NetworkLookup All 'network[]' params are mutually exclusive, only one can be provided. +type NetworkLookup struct { + Id *string `json:"id,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// NetworkNotFoundEnum defines model for NetworkNotFoundEnum. +type NetworkNotFoundEnum string + +// NetworkNotFoundSchema No network was found matching any of the criteria provided in the arguments +type NetworkNotFoundSchema struct { + Code *NetworkNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// NetworkSpeedProfile defines model for NetworkSpeedProfile. +type NetworkSpeedProfile struct { + DownloadSpeedInMbit *int `json:"download_speed_in_mbit,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` + UploadSpeedInMbit *int `json:"upload_speed_in_mbit,omitempty"` +} + +// NetworkSpeedProfileLookup All 'speed_profile[]' params are mutually exclusive, only one can be provided. +type NetworkSpeedProfileLookup struct { + Id *string `json:"id,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// NetworkSpeedProfileNotFoundEnum defines model for NetworkSpeedProfileNotFoundEnum. +type NetworkSpeedProfileNotFoundEnum string + +// NetworkSpeedProfileNotFoundSchema No network speed profile was found matching any of the criteria provided in the arguments +type NetworkSpeedProfileNotFoundSchema struct { + Code *NetworkSpeedProfileNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// NoAllocationEnum defines model for NoAllocationEnum. +type NoAllocationEnum string + +// NoAvailableAddressesEnum defines model for NoAvailableAddressesEnum. +type NoAvailableAddressesEnum string + +// NoInterfaceAvailableEnum defines model for NoInterfaceAvailableEnum. +type NoInterfaceAvailableEnum string + +// NoInterfaceAvailableSchema This virtual machine does not have a network interface that is compatible with the provided IP address +type NoInterfaceAvailableSchema struct { + Code *NoInterfaceAvailableEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// NoUserAssociatedWithIdentityEnum defines model for NoUserAssociatedWithIdentityEnum. +type NoUserAssociatedWithIdentityEnum string + +// ObjectInTrash defines model for ObjectInTrash. +type ObjectInTrash struct { + TrashObject *TrashObject `json:"trash_object,omitempty"` +} + +// ObjectInTrashEnum defines model for ObjectInTrashEnum. +type ObjectInTrashEnum string + +// ObjectInTrashSchema The object found is in the trash and therefore cannot be manipulated through the API. It should be restored in order to run this operation. +type ObjectInTrashSchema struct { + Code *ObjectInTrashEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *ObjectInTrash `json:"detail,omitempty"` +} + +// OneOfAPIAuthenticator403Response defines model for OneOfAPIAuthenticator403Response. +type OneOfAPIAuthenticator403Response struct { + union json.RawMessage +} + +// OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res defines model for OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res. +type OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res struct { + union json.RawMessage +} + +// OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res defines model for OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res. +type OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res struct { + union json.RawMessage +} + +// OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res defines model for OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res. +type OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res struct { + union json.RawMessage +} + +// OneOfIPAddressNotFoundVirtualMachineNotFound404Res defines model for OneOfIPAddressNotFoundVirtualMachineNotFound404Res. +type OneOfIPAddressNotFoundVirtualMachineNotFound404Res struct { + union json.RawMessage +} + +// OneOfIPAlreadyAllocatedInvalidIP422Res defines model for OneOfIPAlreadyAllocatedInvalidIP422Res. +type OneOfIPAlreadyAllocatedInvalidIP422Res struct { + union json.RawMessage +} + +// OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res defines model for OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res. +type OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res struct { + union json.RawMessage +} + +// OneOfIdentityNotLinkedToWebSession400Res defines model for OneOfIdentityNotLinkedToWebSession400Res. +type OneOfIdentityNotLinkedToWebSession400Res struct { + union json.RawMessage +} + +// OneOfInfrastructureDNSZoneCannotBeEdited403Res defines model for OneOfInfrastructureDNSZoneCannotBeEdited403Res. +type OneOfInfrastructureDNSZoneCannotBeEdited403Res struct { + union json.RawMessage +} + +// OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res defines model for OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res. +type OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res struct { + union json.RawMessage +} + +// OneOfInvalidSpecXML400Res defines model for OneOfInvalidSpecXML400Res. +type OneOfInvalidSpecXML400Res struct { + union json.RawMessage +} + +// OneOfInvalidTimestamp400Res defines model for OneOfInvalidTimestamp400Res. +type OneOfInvalidTimestamp400Res struct { + union json.RawMessage +} + +// OneOfLocationRequiredValidationError422Res defines model for OneOfLocationRequiredValidationError422Res. +type OneOfLocationRequiredValidationError422Res struct { + union json.RawMessage +} + +// OneOfNetworkNotFoundOrganizationNotFound404Res defines model for OneOfNetworkNotFoundOrganizationNotFound404Res. +type OneOfNetworkNotFoundOrganizationNotFound404Res struct { + union json.RawMessage +} + +// OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res defines model for OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res. +type OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res struct { + union json.RawMessage +} + +// OneOfObjectInTrashTaskQueueingError406Res defines model for OneOfObjectInTrashTaskQueueingError406Res. +type OneOfObjectInTrashTaskQueueingError406Res struct { + union json.RawMessage +} + +// OneOfObjectInTrashVirtualMachineMustBeStarted406Res defines model for OneOfObjectInTrashVirtualMachineMustBeStarted406Res. +type OneOfObjectInTrashVirtualMachineMustBeStarted406Res struct { + union json.RawMessage +} + +// OneOfOperatingSystemNotFoundOrganizationNotFound404Res defines model for OneOfOperatingSystemNotFoundOrganizationNotFound404Res. +type OneOfOperatingSystemNotFoundOrganizationNotFound404Res struct { + union json.RawMessage +} + +// OneOfOrganizationLimitReachedValidationError422Res defines model for OneOfOrganizationLimitReachedValidationError422Res. +type OneOfOrganizationLimitReachedValidationError422Res struct { + union json.RawMessage +} + +// OneOfOrganizationNotActivatedOrganizationSuspended403Res defines model for OneOfOrganizationNotActivatedOrganizationSuspended403Res. +type OneOfOrganizationNotActivatedOrganizationSuspended403Res struct { + union json.RawMessage +} + +// OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res defines model for OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res. +type OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res struct { + union json.RawMessage +} + +// OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res defines model for OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res. +type OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res struct { + union json.RawMessage +} + +// OneOfPermissionDenied403Res defines model for OneOfPermissionDenied403Res. +type OneOfPermissionDenied403Res struct { + union json.RawMessage +} + +// OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res defines model for OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res. +type OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res struct { + union json.RawMessage +} + +// OperatingSystem defines model for OperatingSystem. +type OperatingSystem struct { + Badge *Attachment `json:"badge,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// OperatingSystemNotFoundEnum defines model for OperatingSystemNotFoundEnum. +type OperatingSystemNotFoundEnum string + +// OperatingSystemNotFoundSchema No operating system was found matching any of the criteria provided in the arguments +type OperatingSystemNotFoundSchema struct { + Code *OperatingSystemNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// Organization defines model for Organization. +type Organization struct { + Address1 *string `json:"address1,omitempty"` + Address2 *string `json:"address2,omitempty"` + Address3 *string `json:"address3,omitempty"` + Address4 *string `json:"address4,omitempty"` + BillingName *string `json:"billing_name,omitempty"` + Country *Country `json:"country,omitempty"` + CountryState *CountryState `json:"country_state,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Currency *Currency `json:"currency,omitempty"` + Id *string `json:"id,omitempty"` + InfrastructureDomain *string `json:"infrastructure_domain,omitempty"` + Managed *bool `json:"managed,omitempty"` + Name *string `json:"name,omitempty"` + PhoneNumber *string `json:"phone_number,omitempty"` + Postcode *string `json:"postcode,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` + Suspended *bool `json:"suspended,omitempty"` + VatNumber *string `json:"vat_number,omitempty"` +} + +// OrganizationLimitReachedEnum defines model for OrganizationLimitReachedEnum. +type OrganizationLimitReachedEnum string + +// OrganizationLimitReachedSchema The maxmium number of organizations that can be created has been reached +type OrganizationLimitReachedSchema struct { + Code *OrganizationLimitReachedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// OrganizationLookup All 'organization[]' params are mutually exclusive, only one can be provided. +type OrganizationLookup struct { + Id *string `json:"id,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` +} + +// OrganizationNotActivatedEnum defines model for OrganizationNotActivatedEnum. +type OrganizationNotActivatedEnum string + +// OrganizationNotActivatedSchema An organization was found from the arguments provided but it wasn't activated yet +type OrganizationNotActivatedSchema struct { + Code *OrganizationNotActivatedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// OrganizationNotFoundEnum defines model for OrganizationNotFoundEnum. +type OrganizationNotFoundEnum string + +// OrganizationNotFoundSchema No organization was found matching any of the criteria provided in the arguments +type OrganizationNotFoundSchema struct { + Code *OrganizationNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// OrganizationSuspendedEnum defines model for OrganizationSuspendedEnum. +type OrganizationSuspendedEnum string + +// OrganizationSuspendedSchema An organization was found from the arguments provided but it was suspended +type OrganizationSuspendedSchema struct { + Code *OrganizationSuspendedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// PaginationObject defines model for PaginationObject. +type PaginationObject struct { + // CurrentPage The current page + CurrentPage *int `json:"current_page,omitempty"` + + // LargeSet Is this a large set and therefore the total number of records cannot be returned? + LargeSet *bool `json:"large_set,omitempty"` + + // PerPage The number of items per page + PerPage *int `json:"per_page,omitempty"` + + // Total The total number of items across all pages + Total *int `json:"total,omitempty"` + + // TotalPages The total number of pages + TotalPages *int `json:"total_pages,omitempty"` +} + +// PatchDNSRecordsDNSRecord200ResponseDNSRecord defines model for PatchDNSRecordsDNSRecord200ResponseDNSRecord. +type PatchDNSRecordsDNSRecord200ResponseDNSRecord struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Properties *DNSRecordProperties `json:"properties,omitempty"` + RecordType *DNSRecordTypeEnum `json:"record_type,omitempty"` + Ttl *int `json:"ttl,omitempty"` +} + +// PatchDiskBackupPolicy200ResponseDiskBackupPolicy defines model for PatchDiskBackupPolicy200ResponseDiskBackupPolicy. +type PatchDiskBackupPolicy200ResponseDiskBackupPolicy struct { + Id *string `json:"id,omitempty"` + Retention *int `json:"retention,omitempty"` + Schedule *map[string]interface{} `json:"schedule,omitempty"` + Target *DiskBackupPolicyTarget `json:"target,omitempty"` +} + +// PatchFileStorageVolume200ResponseFileStorageVolume defines model for PatchFileStorageVolume200ResponseFileStorageVolume. +type PatchFileStorageVolume200ResponseFileStorageVolume struct { + Associations *[]string `json:"associations,omitempty"` + DataCenter *PatchFileStorageVolumePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + + // NfsLocation The NFS location of where to mount the volume from. + NfsLocation *string `json:"nfs_location,omitempty"` + + // Size The size of the volume in bytes. + Size *int `json:"size,omitempty"` + State *FileStorageVolumeStateEnum `json:"state,omitempty"` +} + +// PatchFileStorageVolumePartDataCenter defines model for PatchFileStorageVolumePartDataCenter. +type PatchFileStorageVolumePartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PatchLoadBalancer200ResponseLoadBalancer defines model for PatchLoadBalancer200ResponseLoadBalancer. +type PatchLoadBalancer200ResponseLoadBalancer struct { + ApiReference *string `json:"api_reference,omitempty"` + BackendCertificate *string `json:"backend_certificate,omitempty"` + BackendCertificateKey *string `json:"backend_certificate_key,omitempty"` + DataCenter *PatchLoadBalancerPartDataCenter `json:"data_center,omitempty"` + EnableWeighting *bool `json:"enable_weighting,omitempty"` + HttpsRedirect *bool `json:"https_redirect,omitempty"` + Id *string `json:"id,omitempty"` + IpAddress *[]PatchLoadBalancerPartIPAddress `json:"ip_address,omitempty"` + Name *string `json:"name,omitempty"` + ResourceIds *[]string `json:"resource_ids,omitempty"` + ResourceType *LoadBalancerResourceTypesEnum `json:"resource_type,omitempty"` + Resources *[]LoadBalancerResource `json:"resources,omitempty"` + StandbyVms *[]string `json:"standby_vms,omitempty"` + Weights *[]PatchLoadBalancerPartWeights `json:"weights,omitempty"` +} + +// PatchLoadBalancerPartDataCenter defines model for PatchLoadBalancerPartDataCenter. +type PatchLoadBalancerPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PatchLoadBalancerPartIPAddress defines model for PatchLoadBalancerPartIPAddress. +type PatchLoadBalancerPartIPAddress struct { + Address *string `json:"address,omitempty"` + Id *string `json:"id,omitempty"` +} + +// PatchLoadBalancerPartWeights defines model for PatchLoadBalancerPartWeights. +type PatchLoadBalancerPartWeights struct { + VirtualMachineId *string `json:"virtual_machine_id,omitempty"` + Weight *int `json:"weight,omitempty"` +} + +// PatchLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule defines model for PatchLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule. +type PatchLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule struct { + Algorithm *LoadBalancerRuleAlgorithmEnum `json:"algorithm,omitempty"` + BackendSsl *bool `json:"backend_ssl,omitempty"` + Certificates *[]PatchLoadBalancersRulesLoadBalancerRulePartCertificates `json:"certificates,omitempty"` + CheckEnabled *bool `json:"check_enabled,omitempty"` + CheckFall *int `json:"check_fall,omitempty"` + CheckHttpStatuses *LoadBalancerRuleHTTPStatusesEnum `json:"check_http_statuses,omitempty"` + CheckInterval *int `json:"check_interval,omitempty"` + CheckPath *string `json:"check_path,omitempty"` + CheckProtocol *LoadBalancerRuleCheckProtocolEnum `json:"check_protocol,omitempty"` + CheckRise *int `json:"check_rise,omitempty"` + CheckTimeout *int `json:"check_timeout,omitempty"` + DestinationPort *int `json:"destination_port,omitempty"` + Id *string `json:"id,omitempty"` + ListenPort *int `json:"listen_port,omitempty"` + LoadBalancer *PatchLoadBalancersRulesLoadBalancerRulePartLoadBalancer `json:"load_balancer,omitempty"` + PassthroughSsl *bool `json:"passthrough_ssl,omitempty"` + Protocol *LoadBalancerRuleProtocolEnum `json:"protocol,omitempty"` + ProxyProtocol *bool `json:"proxy_protocol,omitempty"` +} + +// PatchLoadBalancersRulesLoadBalancerRulePartCertificates defines model for PatchLoadBalancersRulesLoadBalancerRulePartCertificates. +type PatchLoadBalancersRulesLoadBalancerRulePartCertificates struct { + AdditionalNames *[]string `json:"additional_names,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + State *CertificateStateEnum `json:"state,omitempty"` +} + +// PatchLoadBalancersRulesLoadBalancerRulePartLoadBalancer defines model for PatchLoadBalancersRulesLoadBalancerRulePartLoadBalancer. +type PatchLoadBalancersRulesLoadBalancerRulePartLoadBalancer struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PatchSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule defines model for PatchSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule. +type PatchSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule struct { + Action *SecurityGroupRuleActionEnum `json:"action,omitempty"` + Direction *SecurityGroupRuleDirectionEnum `json:"direction,omitempty"` + Id *string `json:"id,omitempty"` + Notes *string `json:"notes,omitempty"` + Ports *string `json:"ports,omitempty"` + Protocol *SecurityGroupRuleProtocolEnum `json:"protocol,omitempty"` + SecurityGroup *PatchSecurityGroupsRulesSecurityGroupRulePartSecurityGroup `json:"security_group,omitempty"` + Targets *[]string `json:"targets,omitempty"` +} + +// PatchSecurityGroupsRulesSecurityGroupRulePartSecurityGroup defines model for PatchSecurityGroupsRulesSecurityGroupRulePartSecurityGroup. +type PatchSecurityGroupsRulesSecurityGroupRulePartSecurityGroup struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PatchVirtualMachine200ResponseVirtualMachine defines model for PatchVirtualMachine200ResponseVirtualMachine. +type PatchVirtualMachine200ResponseVirtualMachine struct { + AttachedIso *PatchVirtualMachinePartAttachedISO `json:"attached_iso,omitempty"` + CpuCores *int `json:"cpu_cores,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Description *string `json:"description,omitempty"` + Fqdn *string `json:"fqdn,omitempty"` + GpuType *PatchVirtualMachinePartGPUType `json:"gpu_type,omitempty"` + Gpus *[]PatchVirtualMachinePartGPUs `json:"gpus,omitempty"` + Group *PatchVirtualMachinePartGroup `json:"group,omitempty"` + Hostname *string `json:"hostname,omitempty"` + Id *string `json:"id,omitempty"` + InitialRootPassword *string `json:"initial_root_password,omitempty"` + IpAddresses *[]PatchVirtualMachinePartIPAddresses `json:"ip_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Organization *PatchVirtualMachinePartOrganization `json:"organization,omitempty"` + Package *PatchVirtualMachinePartPackage `json:"package,omitempty"` + State *VirtualMachineStateEnum `json:"state,omitempty"` + TagNames *[]string `json:"tag_names,omitempty"` + Tags *[]PatchVirtualMachinePartTags `json:"tags,omitempty"` + Zone *PatchVirtualMachinePartZone `json:"zone,omitempty"` +} + +// PatchVirtualMachinePartAttachedISO defines model for PatchVirtualMachinePartAttachedISO. +type PatchVirtualMachinePartAttachedISO struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + OperatingSystem *PatchVirtualMachinePartOperatingSystem `json:"operating_system,omitempty"` +} + +// PatchVirtualMachinePartBadge defines model for PatchVirtualMachinePartBadge. +type PatchVirtualMachinePartBadge struct { + Digest *string `json:"digest,omitempty"` + FileName *string `json:"file_name,omitempty"` + FileSize *int `json:"file_size,omitempty"` + FileType *string `json:"file_type,omitempty"` + Token *string `json:"token,omitempty"` + Url *string `json:"url,omitempty"` +} + +// PatchVirtualMachinePartCountry defines model for PatchVirtualMachinePartCountry. +type PatchVirtualMachinePartCountry struct { + Eu *bool `json:"eu,omitempty"` + Id *string `json:"id,omitempty"` + IsoCode2 *string `json:"iso_code2,omitempty"` + IsoCode3 *string `json:"iso_code3,omitempty"` + Name *string `json:"name,omitempty"` + TimeZone *string `json:"time_zone,omitempty"` +} + +// PatchVirtualMachinePartCountryState defines model for PatchVirtualMachinePartCountryState. +type PatchVirtualMachinePartCountryState struct { + Code *string `json:"code,omitempty"` + Country *PatchVirtualMachinePartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PatchVirtualMachinePartCurrency defines model for PatchVirtualMachinePartCurrency. +type PatchVirtualMachinePartCurrency struct { + Id *string `json:"id,omitempty"` + IsoCode *string `json:"iso_code,omitempty"` + Name *string `json:"name,omitempty"` + Symbol *string `json:"symbol,omitempty"` +} + +// PatchVirtualMachinePartDataCenter defines model for PatchVirtualMachinePartDataCenter. +type PatchVirtualMachinePartDataCenter struct { + Country *PatchVirtualMachinePartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PatchVirtualMachinePartGPUType defines model for PatchVirtualMachinePartGPUType. +type PatchVirtualMachinePartGPUType struct { + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PatchVirtualMachinePartGPUs defines model for PatchVirtualMachinePartGPUs. +type PatchVirtualMachinePartGPUs struct { + // Available When pending action is "attach", this indicates if there is a GPU of the relevant type available. + Available *bool `json:"available,omitempty"` + + // Id Unique ID for this GPU. Not available when status is "detached". + Id *string `json:"id,omitempty"` + PendingAction *VirtualMachineGPUPendingActionEnum `json:"pending_action,omitempty"` + Status *VirtualMachineGPUStatusEnum `json:"status,omitempty"` + Type *PatchVirtualMachinePartType `json:"type,omitempty"` +} + +// PatchVirtualMachinePartGroup defines model for PatchVirtualMachinePartGroup. +type PatchVirtualMachinePartGroup struct { + AutoSegregate *bool `json:"auto_segregate,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Segregate *bool `json:"segregate,omitempty"` +} + +// PatchVirtualMachinePartIPAddresses defines model for PatchVirtualMachinePartIPAddresses. +type PatchVirtualMachinePartIPAddresses struct { + Address *string `json:"address,omitempty"` + AddressWithMask *string `json:"address_with_mask,omitempty"` + AllocationId *string `json:"allocation_id,omitempty"` + AllocationType *string `json:"allocation_type,omitempty"` + Id *string `json:"id,omitempty"` + Label *string `json:"label,omitempty"` + Network *PatchVirtualMachinePartNetwork `json:"network,omitempty"` + ReverseDns *string `json:"reverse_dns,omitempty"` + Vip *bool `json:"vip,omitempty"` +} + +// PatchVirtualMachinePartIcon defines model for PatchVirtualMachinePartIcon. +type PatchVirtualMachinePartIcon struct { + Digest *string `json:"digest,omitempty"` + FileName *string `json:"file_name,omitempty"` + FileSize *int `json:"file_size,omitempty"` + FileType *string `json:"file_type,omitempty"` + Token *string `json:"token,omitempty"` + Url *string `json:"url,omitempty"` +} + +// PatchVirtualMachinePartNetwork defines model for PatchVirtualMachinePartNetwork. +type PatchVirtualMachinePartNetwork struct { + DataCenter *PatchVirtualMachinePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PatchVirtualMachinePartOperatingSystem defines model for PatchVirtualMachinePartOperatingSystem. +type PatchVirtualMachinePartOperatingSystem struct { + Badge *PatchVirtualMachinePartBadge `json:"badge,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PatchVirtualMachinePartOrganization defines model for PatchVirtualMachinePartOrganization. +type PatchVirtualMachinePartOrganization struct { + Address1 *string `json:"address1,omitempty"` + Address2 *string `json:"address2,omitempty"` + Address3 *string `json:"address3,omitempty"` + Address4 *string `json:"address4,omitempty"` + BillingName *string `json:"billing_name,omitempty"` + Country *PatchVirtualMachinePartCountry `json:"country,omitempty"` + CountryState *PatchVirtualMachinePartCountryState `json:"country_state,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Currency *PatchVirtualMachinePartCurrency `json:"currency,omitempty"` + Id *string `json:"id,omitempty"` + InfrastructureDomain *string `json:"infrastructure_domain,omitempty"` + Managed *bool `json:"managed,omitempty"` + Name *string `json:"name,omitempty"` + PhoneNumber *string `json:"phone_number,omitempty"` + Postcode *string `json:"postcode,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` + Suspended *bool `json:"suspended,omitempty"` + VatNumber *string `json:"vat_number,omitempty"` +} + +// PatchVirtualMachinePartPackage defines model for PatchVirtualMachinePartPackage. +type PatchVirtualMachinePartPackage struct { + CpuCores *int `json:"cpu_cores,omitempty"` + Icon *PatchVirtualMachinePartIcon `json:"icon,omitempty"` + Id *string `json:"id,omitempty"` + Ipv4Addresses *int `json:"ipv4_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MonthlyBandwidthAllowanceInGb *int `json:"monthly_bandwidth_allowance_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` + Privacy *PrivacyTypesEnum `json:"privacy,omitempty"` + StorageInGb *int `json:"storage_in_gb,omitempty"` +} + +// PatchVirtualMachinePartTags defines model for PatchVirtualMachinePartTags. +type PatchVirtualMachinePartTags struct { + Color *TagColorsEnum `json:"color,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PatchVirtualMachinePartType defines model for PatchVirtualMachinePartType. +type PatchVirtualMachinePartType struct { + Id *string `json:"id,omitempty"` + Manufacturer *string `json:"manufacturer,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MemoryType *string `json:"memory_type,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PatchVirtualMachinePartZone defines model for PatchVirtualMachinePartZone. +type PatchVirtualMachinePartZone struct { + DataCenter *PatchVirtualMachinePartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PermissionDenied defines model for PermissionDenied. +type PermissionDenied struct { + // Details Additional information regarding the reason why permission was denied + Details *string `json:"details,omitempty"` +} + +// PermissionDeniedEnum defines model for PermissionDeniedEnum. +type PermissionDeniedEnum string + +// PermissionDeniedSchema The authenticated identity is not permitted to perform this action +type PermissionDeniedSchema struct { + Code *PermissionDeniedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *PermissionDenied `json:"detail,omitempty"` +} + +// PostDNSZonesDNSZoneRecords200ResponseDNSRecord defines model for PostDNSZonesDNSZoneRecords200ResponseDNSRecord. +type PostDNSZonesDNSZoneRecords200ResponseDNSRecord struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Properties *DNSRecordProperties `json:"properties,omitempty"` + RecordType *DNSRecordTypeEnum `json:"record_type,omitempty"` + Ttl *int `json:"ttl,omitempty"` +} + +// PostDNSZonesDNSZoneUpdateTTL200ResponseDNSZone defines model for PostDNSZonesDNSZoneUpdateTTL200ResponseDNSZone. +type PostDNSZonesDNSZoneUpdateTTL200ResponseDNSZone struct { + Id *string `json:"id,omitempty"` + InfrastructureZone *bool `json:"infrastructure_zone,omitempty"` + Name *string `json:"name,omitempty"` + Ttl *int `json:"ttl,omitempty"` + Verified *bool `json:"verified,omitempty"` +} + +// PostDiskDiskBackupPolicies200ResponseDiskBackupPolicy defines model for PostDiskDiskBackupPolicies200ResponseDiskBackupPolicy. +type PostDiskDiskBackupPolicies200ResponseDiskBackupPolicy struct { + AutoMoveToTrashAt *int `json:"auto_move_to_trash_at,omitempty"` + Id *string `json:"id,omitempty"` + Retention *int `json:"retention,omitempty"` + Schedule *PostDiskDiskBackupPoliciesPartSchedule `json:"schedule,omitempty"` + Target *DiskBackupPolicyTarget `json:"target,omitempty"` + TotalSize *float32 `json:"total_size,omitempty"` +} + +// PostDiskDiskBackupPoliciesPartSchedule defines model for PostDiskDiskBackupPoliciesPartSchedule. +type PostDiskDiskBackupPoliciesPartSchedule struct { + Frequency *int `json:"frequency,omitempty"` + Interval *ScheduleIntervalTypeEnum `json:"interval,omitempty"` + Minute *int `json:"minute,omitempty"` + NextInvocationAt *int `json:"next_invocation_at,omitempty"` + Time *int `json:"time,omitempty"` +} + +// PostLoadBalancerRules200ResponseLoadBalancerRule defines model for PostLoadBalancerRules200ResponseLoadBalancerRule. +type PostLoadBalancerRules200ResponseLoadBalancerRule struct { + Algorithm *LoadBalancerRuleAlgorithmEnum `json:"algorithm,omitempty"` + BackendSsl *bool `json:"backend_ssl,omitempty"` + Certificates *[]PostLoadBalancerRulesPartCertificates `json:"certificates,omitempty"` + CheckEnabled *bool `json:"check_enabled,omitempty"` + CheckFall *int `json:"check_fall,omitempty"` + CheckHttpStatuses *LoadBalancerRuleHTTPStatusesEnum `json:"check_http_statuses,omitempty"` + CheckInterval *int `json:"check_interval,omitempty"` + CheckPath *string `json:"check_path,omitempty"` + CheckProtocol *LoadBalancerRuleCheckProtocolEnum `json:"check_protocol,omitempty"` + CheckRise *int `json:"check_rise,omitempty"` + CheckTimeout *int `json:"check_timeout,omitempty"` + DestinationPort *int `json:"destination_port,omitempty"` + Id *string `json:"id,omitempty"` + ListenPort *int `json:"listen_port,omitempty"` + LoadBalancer *PostLoadBalancerRulesPartLoadBalancer `json:"load_balancer,omitempty"` + PassthroughSsl *bool `json:"passthrough_ssl,omitempty"` + Protocol *LoadBalancerRuleProtocolEnum `json:"protocol,omitempty"` + ProxyProtocol *bool `json:"proxy_protocol,omitempty"` +} + +// PostLoadBalancerRulesPartCertificates defines model for PostLoadBalancerRulesPartCertificates. +type PostLoadBalancerRulesPartCertificates struct { + AdditionalNames *[]string `json:"additional_names,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + State *CertificateStateEnum `json:"state,omitempty"` +} + +// PostLoadBalancerRulesPartLoadBalancer defines model for PostLoadBalancerRulesPartLoadBalancer. +type PostLoadBalancerRulesPartLoadBalancer struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PostOrganizationDNSZones201ResponseDNSZone defines model for PostOrganizationDNSZones201ResponseDNSZone. +type PostOrganizationDNSZones201ResponseDNSZone struct { + Id *string `json:"id,omitempty"` + InfrastructureZone *bool `json:"infrastructure_zone,omitempty"` + Name *string `json:"name,omitempty"` + Ttl *int `json:"ttl,omitempty"` + Verified *bool `json:"verified,omitempty"` +} + +// PostOrganizationFileStorageVolumes201ResponseFileStorageVolume defines model for PostOrganizationFileStorageVolumes201ResponseFileStorageVolume. +type PostOrganizationFileStorageVolumes201ResponseFileStorageVolume struct { + Associations *[]string `json:"associations,omitempty"` + DataCenter *PostOrganizationFileStorageVolumesPartDataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + + // NfsLocation The NFS location of where to mount the volume from. + NfsLocation *string `json:"nfs_location,omitempty"` + + // Size The size of the volume in bytes. + Size *int `json:"size,omitempty"` + State *FileStorageVolumeStateEnum `json:"state,omitempty"` +} + +// PostOrganizationFileStorageVolumesPartDataCenter defines model for PostOrganizationFileStorageVolumesPartDataCenter. +type PostOrganizationFileStorageVolumesPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PostOrganizationLoadBalancers200ResponseLoadBalancer defines model for PostOrganizationLoadBalancers200ResponseLoadBalancer. +type PostOrganizationLoadBalancers200ResponseLoadBalancer struct { + ApiReference *string `json:"api_reference,omitempty"` + BackendCertificate *string `json:"backend_certificate,omitempty"` + BackendCertificateKey *string `json:"backend_certificate_key,omitempty"` + DataCenter *PostOrganizationLoadBalancersPartDataCenter `json:"data_center,omitempty"` + EnableWeighting *bool `json:"enable_weighting,omitempty"` + HttpsRedirect *bool `json:"https_redirect,omitempty"` + Id *string `json:"id,omitempty"` + IpAddress *[]PostOrganizationLoadBalancersPartIPAddress `json:"ip_address,omitempty"` + Name *string `json:"name,omitempty"` + ResourceIds *[]string `json:"resource_ids,omitempty"` + ResourceType *LoadBalancerResourceTypesEnum `json:"resource_type,omitempty"` + Resources *[]LoadBalancerResource `json:"resources,omitempty"` + StandbyVms *[]string `json:"standby_vms,omitempty"` + Weights *[]PostOrganizationLoadBalancersPartWeights `json:"weights,omitempty"` +} + +// PostOrganizationLoadBalancersPartDataCenter defines model for PostOrganizationLoadBalancersPartDataCenter. +type PostOrganizationLoadBalancersPartDataCenter struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// PostOrganizationLoadBalancersPartIPAddress defines model for PostOrganizationLoadBalancersPartIPAddress. +type PostOrganizationLoadBalancersPartIPAddress struct { + Address *string `json:"address,omitempty"` + Id *string `json:"id,omitempty"` +} + +// PostOrganizationLoadBalancersPartWeights defines model for PostOrganizationLoadBalancersPartWeights. +type PostOrganizationLoadBalancersPartWeights struct { + VirtualMachineId *string `json:"virtual_machine_id,omitempty"` + Weight *int `json:"weight,omitempty"` +} + +// PostOrganizationManaged201ResponseOrganization defines model for PostOrganizationManaged201ResponseOrganization. +type PostOrganizationManaged201ResponseOrganization struct { + Address1 *string `json:"address1,omitempty"` + Address2 *string `json:"address2,omitempty"` + Address3 *string `json:"address3,omitempty"` + Address4 *string `json:"address4,omitempty"` + BillingName *string `json:"billing_name,omitempty"` + Country *PostOrganizationManagedPartCountry `json:"country,omitempty"` + CountryState *PostOrganizationManagedPartCountryState `json:"country_state,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Currency *PostOrganizationManagedPartCurrency `json:"currency,omitempty"` + Id *string `json:"id,omitempty"` + InfrastructureDomain *string `json:"infrastructure_domain,omitempty"` + Managed *bool `json:"managed,omitempty"` + Name *string `json:"name,omitempty"` + PhoneNumber *string `json:"phone_number,omitempty"` + Postcode *string `json:"postcode,omitempty"` + SubDomain *string `json:"sub_domain,omitempty"` + Suspended *bool `json:"suspended,omitempty"` + VatNumber *string `json:"vat_number,omitempty"` +} + +// PostOrganizationManagedPartCountry defines model for PostOrganizationManagedPartCountry. +type PostOrganizationManagedPartCountry struct { + Eu *bool `json:"eu,omitempty"` + Id *string `json:"id,omitempty"` + IsoCode2 *string `json:"iso_code2,omitempty"` + IsoCode3 *string `json:"iso_code3,omitempty"` + Name *string `json:"name,omitempty"` + TimeZone *string `json:"time_zone,omitempty"` +} + +// PostOrganizationManagedPartCountryState defines model for PostOrganizationManagedPartCountryState. +type PostOrganizationManagedPartCountryState struct { + Code *string `json:"code,omitempty"` + Country *PostOrganizationManagedPartCountry `json:"country,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PostOrganizationManagedPartCurrency defines model for PostOrganizationManagedPartCurrency. +type PostOrganizationManagedPartCurrency struct { + Id *string `json:"id,omitempty"` + IsoCode *string `json:"iso_code,omitempty"` + Name *string `json:"name,omitempty"` + Symbol *string `json:"symbol,omitempty"` +} + +// PostOrganizationVirtualMachinesBuild201ResponseBuild defines model for PostOrganizationVirtualMachinesBuild201ResponseBuild. +type PostOrganizationVirtualMachinesBuild201ResponseBuild struct { + Id *string `json:"id,omitempty"` + State *VirtualMachineBuildStateEnum `json:"state,omitempty"` +} + +// PostOrganizationVirtualMachinesBuild201ResponseTask defines model for PostOrganizationVirtualMachinesBuild201ResponseTask. +type PostOrganizationVirtualMachinesBuild201ResponseTask struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Status *TaskStatusEnum `json:"status,omitempty"` +} + +// PostOrganizationVirtualMachinesBuild201ResponseVirtualMachineBuild defines model for PostOrganizationVirtualMachinesBuild201ResponseVirtualMachineBuild. +type PostOrganizationVirtualMachinesBuild201ResponseVirtualMachineBuild struct { + Id *string `json:"id,omitempty"` + State *VirtualMachineBuildStateEnum `json:"state,omitempty"` +} + +// PostOrganizationVirtualMachinesBuildFromSpec201ResponseBuild defines model for PostOrganizationVirtualMachinesBuildFromSpec201ResponseBuild. +type PostOrganizationVirtualMachinesBuildFromSpec201ResponseBuild struct { + Id *string `json:"id,omitempty"` + State *VirtualMachineBuildStateEnum `json:"state,omitempty"` +} + +// PostOrganizationVirtualMachinesBuildFromSpec201ResponseTask defines model for PostOrganizationVirtualMachinesBuildFromSpec201ResponseTask. +type PostOrganizationVirtualMachinesBuildFromSpec201ResponseTask struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Status *TaskStatusEnum `json:"status,omitempty"` +} + +// PostOrganizationVirtualMachinesBuildFromSpec201ResponseVirtualMachineBuild defines model for PostOrganizationVirtualMachinesBuildFromSpec201ResponseVirtualMachineBuild. +type PostOrganizationVirtualMachinesBuildFromSpec201ResponseVirtualMachineBuild struct { + Id *string `json:"id,omitempty"` + State *VirtualMachineBuildStateEnum `json:"state,omitempty"` +} + +// PostOrganizationsOrganizationDNSZones201ResponseDNSZone defines model for PostOrganizationsOrganizationDNSZones201ResponseDNSZone. +type PostOrganizationsOrganizationDNSZones201ResponseDNSZone struct { + DefaultTtl *int `json:"default_ttl,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Verified *bool `json:"verified,omitempty"` +} + +// PostSecurityGroupRules200ResponseSecurityGroupRule defines model for PostSecurityGroupRules200ResponseSecurityGroupRule. +type PostSecurityGroupRules200ResponseSecurityGroupRule struct { + Action *SecurityGroupRuleActionEnum `json:"action,omitempty"` + Direction *SecurityGroupRuleDirectionEnum `json:"direction,omitempty"` + Id *string `json:"id,omitempty"` + Notes *string `json:"notes,omitempty"` + Ports *string `json:"ports,omitempty"` + Protocol *SecurityGroupRuleProtocolEnum `json:"protocol,omitempty"` + SecurityGroup *PostSecurityGroupRulesPartSecurityGroup `json:"security_group,omitempty"` + Targets *[]string `json:"targets,omitempty"` +} + +// PostSecurityGroupRulesPartSecurityGroup defines model for PostSecurityGroupRulesPartSecurityGroup. +type PostSecurityGroupRulesPartSecurityGroup struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PostVirtualMachineConsoleSessions201ResponseConsoleSession defines model for PostVirtualMachineConsoleSessions201ResponseConsoleSession. +type PostVirtualMachineConsoleSessions201ResponseConsoleSession struct { + ExpiresAt *int `json:"expires_at,omitempty"` + Id *string `json:"id,omitempty"` + Url *string `json:"url,omitempty"` + VirtualMachine *PostVirtualMachineConsoleSessionsPartVirtualMachine `json:"virtual_machine,omitempty"` +} + +// PostVirtualMachineConsoleSessionsPartVirtualMachine defines model for PostVirtualMachineConsoleSessionsPartVirtualMachine. +type PostVirtualMachineConsoleSessionsPartVirtualMachine struct { + Fqdn *string `json:"fqdn,omitempty"` + Hostname *string `json:"hostname,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + State *VirtualMachineStateEnum `json:"state,omitempty"` +} + +// PostVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicy defines model for PostVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicy. +type PostVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicy struct { + AutoMoveToTrashAt *int `json:"auto_move_to_trash_at,omitempty"` + Id *string `json:"id,omitempty"` + Retention *int `json:"retention,omitempty"` + Schedule *PostVirtualMachineDiskBackupPoliciesPartSchedule `json:"schedule,omitempty"` + Target *DiskBackupPolicyTarget `json:"target,omitempty"` + TotalSize *float32 `json:"total_size,omitempty"` +} + +// PostVirtualMachineDiskBackupPoliciesPartSchedule defines model for PostVirtualMachineDiskBackupPoliciesPartSchedule. +type PostVirtualMachineDiskBackupPoliciesPartSchedule struct { + Frequency *int `json:"frequency,omitempty"` + Interval *ScheduleIntervalTypeEnum `json:"interval,omitempty"` + Minute *int `json:"minute,omitempty"` + NextInvocationAt *int `json:"next_invocation_at,omitempty"` + Time *int `json:"time,omitempty"` +} + +// PostVirtualMachineNetworkInterfaceAllocateIP200ResponseVirtualMachineNetworkInterface defines model for PostVirtualMachineNetworkInterfaceAllocateIP200ResponseVirtualMachineNetworkInterface. +type PostVirtualMachineNetworkInterfaceAllocateIP200ResponseVirtualMachineNetworkInterface struct { + Id *string `json:"id,omitempty"` + IpAddresses *[]PostVirtualMachineNetworkInterfaceAllocateIPPartIPAddresses `json:"ip_addresses,omitempty"` + MacAddress *string `json:"mac_address,omitempty"` + Name *string `json:"name,omitempty"` + Network *PostVirtualMachineNetworkInterfaceAllocateIPPartNetwork `json:"network,omitempty"` + State *string `json:"state,omitempty"` + VirtualMachine *PostVirtualMachineNetworkInterfaceAllocateIPPartVirtualMachine `json:"virtual_machine,omitempty"` +} + +// PostVirtualMachineNetworkInterfaceAllocateIPPartIPAddresses defines model for PostVirtualMachineNetworkInterfaceAllocateIPPartIPAddresses. +type PostVirtualMachineNetworkInterfaceAllocateIPPartIPAddresses struct { + Address *string `json:"address,omitempty"` + Id *string `json:"id,omitempty"` +} + +// PostVirtualMachineNetworkInterfaceAllocateIPPartNetwork defines model for PostVirtualMachineNetworkInterfaceAllocateIPPartNetwork. +type PostVirtualMachineNetworkInterfaceAllocateIPPartNetwork struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PostVirtualMachineNetworkInterfaceAllocateIPPartVirtualMachine defines model for PostVirtualMachineNetworkInterfaceAllocateIPPartVirtualMachine. +type PostVirtualMachineNetworkInterfaceAllocateIPPartVirtualMachine struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// PostVirtualMachineReset200ResponseTask defines model for PostVirtualMachineReset200ResponseTask. +type PostVirtualMachineReset200ResponseTask struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Status *TaskStatusEnum `json:"status,omitempty"` +} + +// PostVirtualMachineShutdown200ResponseTask defines model for PostVirtualMachineShutdown200ResponseTask. +type PostVirtualMachineShutdown200ResponseTask struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Status *TaskStatusEnum `json:"status,omitempty"` +} + +// PostVirtualMachineStart200ResponseTask defines model for PostVirtualMachineStart200ResponseTask. +type PostVirtualMachineStart200ResponseTask struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Status *TaskStatusEnum `json:"status,omitempty"` +} + +// PostVirtualMachineStop200ResponseTask defines model for PostVirtualMachineStop200ResponseTask. +type PostVirtualMachineStop200ResponseTask struct { + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Status *TaskStatusEnum `json:"status,omitempty"` +} + +// PrivacyTypesEnum defines model for PrivacyTypesEnum. +type PrivacyTypesEnum string + +// PropertyTypeEnum defines model for PropertyTypeEnum. +type PropertyTypeEnum string + +// RateLimitReached defines model for RateLimitReached. +type RateLimitReached struct { + // TotalPermitted The total number of requests per minute that are permitted + TotalPermitted *int `json:"total_permitted,omitempty"` +} + +// RateLimitReachedEnum defines model for RateLimitReachedEnum. +type RateLimitReachedEnum string + +// RecordContentAttributesForA defines model for RecordContentAttributesForA. +type RecordContentAttributesForA struct { + IpAddress *string `json:"ip_address,omitempty"` +} + +// RecordContentAttributesForAAAA defines model for RecordContentAttributesForAAAA. +type RecordContentAttributesForAAAA struct { + IpAddress *string `json:"ip_address,omitempty"` +} + +// RecordContentAttributesForALIAS defines model for RecordContentAttributesForALIAS. +type RecordContentAttributesForALIAS struct { + Hostname *string `json:"hostname,omitempty"` +} + +// RecordContentAttributesForCAA defines model for RecordContentAttributesForCAA. +type RecordContentAttributesForCAA struct { + Flag *string `json:"flag,omitempty"` + Tag *string `json:"tag,omitempty"` + Value *string `json:"value,omitempty"` +} + +// RecordContentAttributesForCNAME defines model for RecordContentAttributesForCNAME. +type RecordContentAttributesForCNAME struct { + Hostname *string `json:"hostname,omitempty"` +} + +// RecordContentAttributesForIPS defines model for RecordContentAttributesForIPS. +type RecordContentAttributesForIPS struct { + IpAddresses *string `json:"ip_addresses,omitempty"` +} + +// RecordContentAttributesForMX defines model for RecordContentAttributesForMX. +type RecordContentAttributesForMX struct { + Hostname *string `json:"hostname,omitempty"` +} + +// RecordContentAttributesForNS defines model for RecordContentAttributesForNS. +type RecordContentAttributesForNS struct { + Hostname *string `json:"hostname,omitempty"` +} + +// RecordContentAttributesForPTR defines model for RecordContentAttributesForPTR. +type RecordContentAttributesForPTR struct { + Hostname *string `json:"hostname,omitempty"` +} + +// RecordContentAttributesForSRV defines model for RecordContentAttributesForSRV. +type RecordContentAttributesForSRV struct { + Port *string `json:"port,omitempty"` + Target *string `json:"target,omitempty"` + Weight *string `json:"weight,omitempty"` +} + +// RecordContentAttributesForSSHFP defines model for RecordContentAttributesForSSHFP. +type RecordContentAttributesForSSHFP struct { + Algorithm *string `json:"algorithm,omitempty"` + Fingerprint *string `json:"fingerprint,omitempty"` + FingerprintType *string `json:"fingerprint_type,omitempty"` +} + +// RecordContentAttributesForTXT defines model for RecordContentAttributesForTXT. +type RecordContentAttributesForTXT struct { + Content *string `json:"content,omitempty"` +} + +// RecordContentAttributesForVirtualMachine defines model for RecordContentAttributesForVirtualMachine. +type RecordContentAttributesForVirtualMachine struct { + VirtualMachine *string `json:"virtual_machine,omitempty"` +} + +// ResourceCreationRestricted defines model for ResourceCreationRestricted. +type ResourceCreationRestricted struct { + Errors *[]string `json:"errors,omitempty"` +} + +// ResourceCreationRestrictedEnum defines model for ResourceCreationRestrictedEnum. +type ResourceCreationRestrictedEnum string + +// ResourceCreationRestrictedSchema The organization chosen is not permitted to create resources +type ResourceCreationRestrictedSchema struct { + Code *ResourceCreationRestrictedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *ResourceCreationRestricted `json:"detail,omitempty"` +} + +// ResourceDoesNotSupportUnallocationEnum defines model for ResourceDoesNotSupportUnallocationEnum. +type ResourceDoesNotSupportUnallocationEnum string + +// SRV defines model for SRV. +type SRV struct { + Port *string `json:"port,omitempty"` + Priority *string `json:"priority,omitempty"` + Target *string `json:"target,omitempty"` + Weight *string `json:"weight,omitempty"` +} + +// SSHFP defines model for SSHFP. +type SSHFP struct { + Algorithm *string `json:"algorithm,omitempty"` + Fingerprint *string `json:"fingerprint,omitempty"` + FingerprintType *string `json:"fingerprint_type,omitempty"` +} + +// SSHKeyNotFoundEnum defines model for SSHKeyNotFoundEnum. +type SSHKeyNotFoundEnum string + +// ScheduleArguments All 'schedule[]' params are mutually exclusive, only one can be provided. +type ScheduleArguments struct { + Frequency *int `json:"frequency,omitempty"` + Interval *ScheduleIntervalTypeEnum `json:"interval,omitempty"` + Minute *int `json:"minute,omitempty"` + Time *int `json:"time,omitempty"` +} + +// ScheduleIntervalTypeEnum defines model for ScheduleIntervalTypeEnum. +type ScheduleIntervalTypeEnum string + +// ScopeNotGrantedError defines model for ScopeNotGrantedError. +type ScopeNotGrantedError struct { + Scopes *[]string `json:"scopes,omitempty"` +} + +// ScopeNotGrantedErrorEnum defines model for ScopeNotGrantedErrorEnum. +type ScopeNotGrantedErrorEnum string + +// ScopeNotGrantedErrorSchema The scope required for this endpoint has not been granted to the authenticating identity +type ScopeNotGrantedErrorSchema struct { + Code *ScopeNotGrantedErrorEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *ScopeNotGrantedError `json:"detail,omitempty"` +} + +// SecurityGroup defines model for SecurityGroup. +type SecurityGroup struct { + AllowAllInbound *bool `json:"allow_all_inbound,omitempty"` + AllowAllOutbound *bool `json:"allow_all_outbound,omitempty"` + Associations *[]string `json:"associations,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// SecurityGroupArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type SecurityGroupArguments struct { + AllowAllInbound *bool `json:"allow_all_inbound,omitempty"` + AllowAllOutbound *bool `json:"allow_all_outbound,omitempty"` + Associations *[]string `json:"associations,omitempty"` + Name *string `json:"name,omitempty"` +} + +// SecurityGroupLookup All 'security_group[]' params are mutually exclusive, only one can be provided. +type SecurityGroupLookup struct { + Id *string `json:"id,omitempty"` +} + +// SecurityGroupNotFoundEnum defines model for SecurityGroupNotFoundEnum. +type SecurityGroupNotFoundEnum string + +// SecurityGroupRuleActionEnum defines model for SecurityGroupRuleActionEnum. +type SecurityGroupRuleActionEnum string + +// SecurityGroupRuleArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type SecurityGroupRuleArguments struct { + Action *SecurityGroupRuleActionEnum `json:"action,omitempty"` + Direction *SecurityGroupRuleDirectionEnum `json:"direction,omitempty"` + Notes *string `json:"notes,omitempty"` + + // Ports Either single port (ie. 80), multi-port (ie. 80,443) or range (ie. 2000-3000). + Ports *string `json:"ports,omitempty"` + Protocol *SecurityGroupRuleProtocolEnum `json:"protocol,omitempty"` + Targets *[]string `json:"targets,omitempty"` +} + +// SecurityGroupRuleDirectionEnum defines model for SecurityGroupRuleDirectionEnum. +type SecurityGroupRuleDirectionEnum string + +// SecurityGroupRuleLookup All 'security_group_rule[]' params are mutually exclusive, only one can be provided. +type SecurityGroupRuleLookup struct { + Id *string `json:"id,omitempty"` +} + +// SecurityGroupRuleNotFoundEnum defines model for SecurityGroupRuleNotFoundEnum. +type SecurityGroupRuleNotFoundEnum string + +// SecurityGroupRuleProtocolEnum defines model for SecurityGroupRuleProtocolEnum. +type SecurityGroupRuleProtocolEnum string + +// SpeedProfileAlreadyAssignedEnum defines model for SpeedProfileAlreadyAssignedEnum. +type SpeedProfileAlreadyAssignedEnum string + +// StorageSpeedEnum defines model for StorageSpeedEnum. +type StorageSpeedEnum string + +// TXT defines model for TXT. +type TXT struct { + Data *string `json:"data,omitempty"` +} + +// Tag defines model for Tag. +type Tag struct { + Color *TagColorsEnum `json:"color,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` +} + +// TagArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type TagArguments struct { + Color *TagColorsEnum `json:"color,omitempty"` + Name *string `json:"name,omitempty"` +} + +// TagColorsEnum defines model for TagColorsEnum. +type TagColorsEnum string + +// TagLookup All 'tag[]' params are mutually exclusive, only one can be provided. +type TagLookup struct { + Id *string `json:"id,omitempty"` +} + +// TagNotFoundEnum defines model for TagNotFoundEnum. +type TagNotFoundEnum string + +// Task defines model for Task. +type Task struct { + CreatedAt *int `json:"created_at,omitempty"` + FinishedAt *int `json:"finished_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Progress *int `json:"progress,omitempty"` + StartedAt *int `json:"started_at,omitempty"` + Status *TaskStatusEnum `json:"status,omitempty"` +} + +// TaskNotFoundEnum defines model for TaskNotFoundEnum. +type TaskNotFoundEnum string + +// TaskQueueingError defines model for TaskQueueingError. +type TaskQueueingError struct { + Details *string `json:"details,omitempty"` +} + +// TaskQueueingErrorEnum defines model for TaskQueueingErrorEnum. +type TaskQueueingErrorEnum string + +// TaskQueueingErrorSchema This error means that a background task that was needed to complete your request could not be queued +type TaskQueueingErrorSchema struct { + Code *TaskQueueingErrorEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *TaskQueueingError `json:"detail,omitempty"` +} + +// TaskStatusEnum defines model for TaskStatusEnum. +type TaskStatusEnum string + +// TemplateSpec defines model for TemplateSpec. +type TemplateSpec struct { + Fields *[]TemplateSpecField `json:"fields,omitempty"` +} + +// TemplateSpecField defines model for TemplateSpecField. +type TemplateSpecField struct { + Description *string `json:"description,omitempty"` + Label *string `json:"label,omitempty"` + Name *string `json:"name,omitempty"` + Placeholder *string `json:"placeholder,omitempty"` + Prefill *string `json:"prefill,omitempty"` + Required *bool `json:"required,omitempty"` + Type *TemplateSpecFieldTypeEnum `json:"type,omitempty"` +} + +// TemplateSpecFieldTypeEnum defines model for TemplateSpecFieldTypeEnum. +type TemplateSpecFieldTypeEnum string + +// TrashObject defines model for TrashObject. +type TrashObject struct { + Id *string `json:"id,omitempty"` + KeepUntil *int `json:"keep_until,omitempty"` + ObjectId *string `json:"object_id,omitempty"` + ObjectType *string `json:"object_type,omitempty"` +} + +// TrashObjectLookup All 'trash_object[]' params are mutually exclusive, only one can be provided. +type TrashObjectLookup struct { + Id *string `json:"id,omitempty"` + ObjectId *string `json:"object_id,omitempty"` +} + +// TrashObjectNotFoundEnum defines model for TrashObjectNotFoundEnum. +type TrashObjectNotFoundEnum string + +// UnauthorizedNetworkForAPIToken defines model for UnauthorizedNetworkForAPIToken. +type UnauthorizedNetworkForAPIToken struct { + // IpAddress The IP address the request was received from + IpAddress *string `json:"ip_address,omitempty"` +} + +// UnauthorizedNetworkForAPITokenEnum defines model for UnauthorizedNetworkForAPITokenEnum. +type UnauthorizedNetworkForAPITokenEnum string + +// UnauthorizedNetworkForAPITokenSchema Network is not allowed to access the API with this API token +type UnauthorizedNetworkForAPITokenSchema struct { + Code *UnauthorizedNetworkForAPITokenEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *UnauthorizedNetworkForAPIToken `json:"detail,omitempty"` +} + +// User defines model for User. +type User struct { + AvatarUrl *string `json:"avatar_url,omitempty"` + FirstName *string `json:"first_name,omitempty"` + Id *string `json:"id,omitempty"` + LastName *string `json:"last_name,omitempty"` +} + +// ValidationError defines model for ValidationError. +type ValidationError struct { + Errors *[]string `json:"errors,omitempty"` +} + +// ValidationErrorEnum defines model for ValidationErrorEnum. +type ValidationErrorEnum string + +// ValidationErrorSchema A validation error occurred with the object that was being created/updated/deleted +type ValidationErrorSchema struct { + Code *ValidationErrorEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *ValidationError `json:"detail,omitempty"` +} + +// VirtualMachine defines model for VirtualMachine. +type VirtualMachine struct { + AttachedIso *ISO `json:"attached_iso,omitempty"` + CpuCores *int `json:"cpu_cores,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Description *string `json:"description,omitempty"` + Fqdn *string `json:"fqdn,omitempty"` + GpuType *GPUType `json:"gpu_type,omitempty"` + Gpus *[]VirtualMachineGPU `json:"gpus,omitempty"` + Group *VirtualMachineGroup `json:"group,omitempty"` + Hostname *string `json:"hostname,omitempty"` + Id *string `json:"id,omitempty"` + InitialRootPassword *string `json:"initial_root_password,omitempty"` + IpAddresses *[]IPAddress `json:"ip_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Organization *Organization `json:"organization,omitempty"` + Package *VirtualMachinePackage `json:"package,omitempty"` + State *VirtualMachineStateEnum `json:"state,omitempty"` + TagNames *[]string `json:"tag_names,omitempty"` + Tags *[]Tag `json:"tags,omitempty"` + Zone *Zone `json:"zone,omitempty"` +} + +// VirtualMachineArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type VirtualMachineArguments struct { + Description *string `json:"description,omitempty"` + + // GpuType All 'gpu_type[]' params are mutually exclusive, only one can be provided. + GpuType *GPUTypeLookup `json:"gpu_type,omitempty"` + + // Group All 'group[]' params are mutually exclusive, only one can be provided. + Group *VirtualMachineGroupLookup `json:"group,omitempty"` + Hostname *string `json:"hostname,omitempty"` + Name *string `json:"name,omitempty"` + TagNames *[]string `json:"tag_names,omitempty"` +} + +// VirtualMachineBuildNotFoundEnum defines model for VirtualMachineBuildNotFoundEnum. +type VirtualMachineBuildNotFoundEnum string + +// VirtualMachineBuildStateEnum defines model for VirtualMachineBuildStateEnum. +type VirtualMachineBuildStateEnum string + +// VirtualMachineDisk defines model for VirtualMachineDisk. +type VirtualMachineDisk struct { + AttachOnBoot *bool `json:"attach_on_boot,omitempty"` + Boot *bool `json:"boot,omitempty"` + Disk *Disk `json:"disk,omitempty"` + State *VirtualMachineDiskAttachmentStateEnum `json:"state,omitempty"` + VirtualMachine *VirtualMachine `json:"virtual_machine,omitempty"` +} + +// VirtualMachineDiskAttachmentStateEnum defines model for VirtualMachineDiskAttachmentStateEnum. +type VirtualMachineDiskAttachmentStateEnum string + +// VirtualMachineFlexibleResources All 'resources[]' params are mutually exclusive, only one can be provided. +type VirtualMachineFlexibleResources struct { + CpuCores int `json:"cpu_cores"` + MemoryInGb int `json:"memory_in_gb"` +} + +// VirtualMachineGPU defines model for VirtualMachineGPU. +type VirtualMachineGPU struct { + // Available When pending action is "attach", this indicates if there is a GPU of the relevant type available. + Available *bool `json:"available,omitempty"` + + // Id Unique ID for this GPU. Not available when status is "detached". + Id *string `json:"id,omitempty"` + PendingAction *VirtualMachineGPUPendingActionEnum `json:"pending_action,omitempty"` + Status *VirtualMachineGPUStatusEnum `json:"status,omitempty"` + Type *GPUType `json:"type,omitempty"` +} + +// VirtualMachineGPUPendingActionEnum defines model for VirtualMachineGPUPendingActionEnum. +type VirtualMachineGPUPendingActionEnum string + +// VirtualMachineGPUStatusEnum defines model for VirtualMachineGPUStatusEnum. +type VirtualMachineGPUStatusEnum string + +// VirtualMachineGroup defines model for VirtualMachineGroup. +type VirtualMachineGroup struct { + AutoSegregate *bool `json:"auto_segregate,omitempty"` + CreatedAt *int `json:"created_at,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Segregate *bool `json:"segregate,omitempty"` +} + +// VirtualMachineGroupArguments All 'properties[]' params are mutually exclusive, only one can be provided. +type VirtualMachineGroupArguments struct { + AutoSegregate *bool `json:"auto_segregate,omitempty"` + Name *string `json:"name,omitempty"` + Segregate *bool `json:"segregate,omitempty"` +} + +// VirtualMachineGroupLookup All 'group[]' params are mutually exclusive, only one can be provided. +type VirtualMachineGroupLookup struct { + Id *string `json:"id,omitempty"` +} + +// VirtualMachineGroupNotFoundEnum defines model for VirtualMachineGroupNotFoundEnum. +type VirtualMachineGroupNotFoundEnum string + +// VirtualMachineLookup All 'virtual_machine[]' params are mutually exclusive, only one can be provided. +type VirtualMachineLookup struct { + Fqdn *string `json:"fqdn,omitempty"` + Id *string `json:"id,omitempty"` +} + +// VirtualMachineMustBeStarted defines model for VirtualMachineMustBeStarted. +type VirtualMachineMustBeStarted struct { + CurrentState *string `json:"current_state,omitempty"` +} + +// VirtualMachineMustBeStartedEnum defines model for VirtualMachineMustBeStartedEnum. +type VirtualMachineMustBeStartedEnum string + +// VirtualMachineMustBeStartedSchema Virtual machines must be in a started state to create console sessions +type VirtualMachineMustBeStartedSchema struct { + Code *VirtualMachineMustBeStartedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *VirtualMachineMustBeStarted `json:"detail,omitempty"` +} + +// VirtualMachineNetworkInterfaceLookup All 'virtual_machine_network_interface[]' params are mutually exclusive, only one can be provided. +type VirtualMachineNetworkInterfaceLookup struct { + Id *string `json:"id,omitempty"` +} + +// VirtualMachineNetworkInterfaceNotFoundEnum defines model for VirtualMachineNetworkInterfaceNotFoundEnum. +type VirtualMachineNetworkInterfaceNotFoundEnum string + +// VirtualMachineNetworkInterfaceNotFoundSchema No network interface was found matching any of the criteria provided in the arguments +type VirtualMachineNetworkInterfaceNotFoundSchema struct { + Code *VirtualMachineNetworkInterfaceNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// VirtualMachineNotFoundEnum defines model for VirtualMachineNotFoundEnum. +type VirtualMachineNotFoundEnum string + +// VirtualMachineNotFoundSchema No virtual machine was found matching any of the criteria provided in the arguments +type VirtualMachineNotFoundSchema struct { + Code *VirtualMachineNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// VirtualMachinePackage defines model for VirtualMachinePackage. +type VirtualMachinePackage struct { + CpuCores *int `json:"cpu_cores,omitempty"` + Icon *Attachment `json:"icon,omitempty"` + Id *string `json:"id,omitempty"` + Ipv4Addresses *int `json:"ipv4_addresses,omitempty"` + MemoryInGb *int `json:"memory_in_gb,omitempty"` + MonthlyBandwidthAllowanceInGb *int `json:"monthly_bandwidth_allowance_in_gb,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` + Privacy *PrivacyTypesEnum `json:"privacy,omitempty"` + StorageInGb *int `json:"storage_in_gb,omitempty"` +} + +// VirtualMachinePackageLookup All 'virtual_machine_package[]' params are mutually exclusive, only one can be provided. +type VirtualMachinePackageLookup struct { + Id *string `json:"id,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// VirtualMachinePackageNotFoundEnum defines model for VirtualMachinePackageNotFoundEnum. +type VirtualMachinePackageNotFoundEnum string + +// VirtualMachinePackageNotFoundSchema No package was found matching any of the criteria provided in the arguments +type VirtualMachinePackageNotFoundSchema struct { + Code *VirtualMachinePackageNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// VirtualMachineStateEnum defines model for VirtualMachineStateEnum. +type VirtualMachineStateEnum string + +// Zone defines model for Zone. +type Zone struct { + DataCenter *DataCenter `json:"data_center,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// ZoneLookup All 'zone[]' params are mutually exclusive, only one can be provided. +type ZoneLookup struct { + Id *string `json:"id,omitempty"` + Permalink *string `json:"permalink,omitempty"` +} + +// ZoneNotFoundEnum defines model for ZoneNotFoundEnum. +type ZoneNotFoundEnum string + +// ZoneNotFoundSchema No zone was found matching any of the criteria provided in the arguments +type ZoneNotFoundSchema struct { + Code *ZoneNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// APIAuthenticator400Response defines model for APIAuthenticator400Response. +type APIAuthenticator400Response struct { + Code *MissingAPITokenEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// APIAuthenticator403Response defines model for APIAuthenticator403Response. +type APIAuthenticator403Response = OneOfAPIAuthenticator403Response + +// APIAuthenticator429Response defines model for APIAuthenticator429Response. +type APIAuthenticator429Response struct { + Code *RateLimitReachedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *RateLimitReached `json:"detail,omitempty"` +} + +// CertificateNotFoundResponse defines model for CertificateNotFoundResponse. +type CertificateNotFoundResponse struct { + Code *CertificateNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// CountryNotFoundResponse defines model for CountryNotFoundResponse. +type CountryNotFoundResponse struct { + Code *CountryNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// CountryStateNotFoundResponse defines model for CountryStateNotFoundResponse. +type CountryStateNotFoundResponse struct { + Code *CountryStateNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// CurrencyNotFoundResponse defines model for CurrencyNotFoundResponse. +type CurrencyNotFoundResponse struct { + Code *CurrencyNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DNSRecordNotFoundResponse defines model for DNSRecordNotFoundResponse. +type DNSRecordNotFoundResponse struct { + Code *DNSRecordNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DNSZoneAlreadyVerifiedResponse defines model for DNSZoneAlreadyVerifiedResponse. +type DNSZoneAlreadyVerifiedResponse struct { + Code *DNSZoneAlreadyVerifiedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DNSZoneNotFoundResponse defines model for DNSZoneNotFoundResponse. +type DNSZoneNotFoundResponse struct { + Code *DNSZoneNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DNSZoneNotVerifiedResponse defines model for DNSZoneNotVerifiedResponse. +type DNSZoneNotVerifiedResponse struct { + Code *DNSZoneNotVerifiedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *DNSZoneNotVerified `json:"detail,omitempty"` +} + +// DataCenterNotFoundResponse defines model for DataCenterNotFoundResponse. +type DataCenterNotFoundResponse struct { + Code *DataCenterNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res defines model for DataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res. +type DataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res = OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res + +// DeletionRestrictedResponse defines model for DeletionRestrictedResponse. +type DeletionRestrictedResponse struct { + Code *DeletionRestrictedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *DeletionRestricted `json:"detail,omitempty"` +} + +// DiskBackupPolicyNotFoundResponse defines model for DiskBackupPolicyNotFoundResponse. +type DiskBackupPolicyNotFoundResponse struct { + Code *DiskBackupPolicyNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DiskNotFoundResponse defines model for DiskNotFoundResponse. +type DiskNotFoundResponse struct { + Code *DiskNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DiskTemplateNotFoundResponse defines model for DiskTemplateNotFoundResponse. +type DiskTemplateNotFoundResponse struct { + Code *DiskTemplateNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// DiskTemplateVersionNotFoundResponse defines model for DiskTemplateVersionNotFoundResponse. +type DiskTemplateVersionNotFoundResponse struct { + Code *DiskTemplateVersionNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// FileStorageVolumeNotFoundResponse defines model for FileStorageVolumeNotFoundResponse. +type FileStorageVolumeNotFoundResponse struct { + Code *FileStorageVolumeNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// FlexibleResourcesUnavailableToOrganizationPermissionDenied403Res defines model for FlexibleResourcesUnavailableToOrganizationPermissionDenied403Res. +type FlexibleResourcesUnavailableToOrganizationPermissionDenied403Res = OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res + +// GPUTypeNotFoundResponse defines model for GPUTypeNotFoundResponse. +type GPUTypeNotFoundResponse struct { + Code *GPUTypeNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// IPAddressNotFoundResponse defines model for IPAddressNotFoundResponse. +type IPAddressNotFoundResponse struct { + Code *IPAddressNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// IPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res defines model for IPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res. +type IPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res = OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res + +// IPAddressNotFoundVirtualMachineNotFound404Res defines model for IPAddressNotFoundVirtualMachineNotFound404Res. +type IPAddressNotFoundVirtualMachineNotFound404Res = OneOfIPAddressNotFoundVirtualMachineNotFound404Res + +// IPAlreadyAllocatedInvalidIP422Res defines model for IPAlreadyAllocatedInvalidIP422Res. +type IPAlreadyAllocatedInvalidIP422Res = OneOfIPAlreadyAllocatedInvalidIP422Res + +// IPAlreadyAllocatedNoInterfaceAvailable422Res defines model for IPAlreadyAllocatedNoInterfaceAvailable422Res. +type IPAlreadyAllocatedNoInterfaceAvailable422Res = OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res + +// IdentityNotLinkedToWebSession400Res defines model for IdentityNotLinkedToWebSession400Res. +type IdentityNotLinkedToWebSession400Res = OneOfIdentityNotLinkedToWebSession400Res + +// InfrastructureDNSZoneCannotBeEdited403Res defines model for InfrastructureDNSZoneCannotBeEdited403Res. +type InfrastructureDNSZoneCannotBeEdited403Res = OneOfInfrastructureDNSZoneCannotBeEdited403Res + +// InterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res defines model for InterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res. +type InterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res = OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res + +// InvalidSpecXML400Res defines model for InvalidSpecXML400Res. +type InvalidSpecXML400Res = OneOfInvalidSpecXML400Res + +// InvalidTimestamp400Res defines model for InvalidTimestamp400Res. +type InvalidTimestamp400Res = OneOfInvalidTimestamp400Res + +// LoadBalancerNotFoundResponse defines model for LoadBalancerNotFoundResponse. +type LoadBalancerNotFoundResponse struct { + Code *LoadBalancerNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// LoadBalancerRuleNotFoundResponse defines model for LoadBalancerRuleNotFoundResponse. +type LoadBalancerRuleNotFoundResponse struct { + Code *LoadBalancerRuleNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// LocationRequiredValidationError422Res defines model for LocationRequiredValidationError422Res. +type LocationRequiredValidationError422Res = OneOfLocationRequiredValidationError422Res + +// NetworkNotFoundOrganizationNotFound404Res defines model for NetworkNotFoundOrganizationNotFound404Res. +type NetworkNotFoundOrganizationNotFound404Res = OneOfNetworkNotFoundOrganizationNotFound404Res + +// NetworkNotFoundResponse defines model for NetworkNotFoundResponse. +type NetworkNotFoundResponse struct { + Code *NetworkNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// NetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res defines model for NetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res. +type NetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res = OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res + +// NoAllocationResponse defines model for NoAllocationResponse. +type NoAllocationResponse struct { + Code *NoAllocationEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// NoAvailableAddressesResponse defines model for NoAvailableAddressesResponse. +type NoAvailableAddressesResponse struct { + Code *NoAvailableAddressesEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// NoUserAssociatedWithIdentityResponse defines model for NoUserAssociatedWithIdentityResponse. +type NoUserAssociatedWithIdentityResponse struct { + Code *NoUserAssociatedWithIdentityEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// ObjectInTrashResponse defines model for ObjectInTrashResponse. +type ObjectInTrashResponse struct { + Code *ObjectInTrashEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *ObjectInTrash `json:"detail,omitempty"` +} + +// ObjectInTrashTaskQueueingError406Res defines model for ObjectInTrashTaskQueueingError406Res. +type ObjectInTrashTaskQueueingError406Res = OneOfObjectInTrashTaskQueueingError406Res + +// ObjectInTrashVirtualMachineMustBeStarted406Res defines model for ObjectInTrashVirtualMachineMustBeStarted406Res. +type ObjectInTrashVirtualMachineMustBeStarted406Res = OneOfObjectInTrashVirtualMachineMustBeStarted406Res + +// OperatingSystemNotFoundOrganizationNotFound404Res defines model for OperatingSystemNotFoundOrganizationNotFound404Res. +type OperatingSystemNotFoundOrganizationNotFound404Res = OneOfOperatingSystemNotFoundOrganizationNotFound404Res + +// OperatingSystemNotFoundResponse defines model for OperatingSystemNotFoundResponse. +type OperatingSystemNotFoundResponse struct { + Code *OperatingSystemNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// OrganizationLimitReachedValidationError422Res defines model for OrganizationLimitReachedValidationError422Res. +type OrganizationLimitReachedValidationError422Res = OneOfOrganizationLimitReachedValidationError422Res + +// OrganizationNotActivatedOrganizationSuspended403Res defines model for OrganizationNotActivatedOrganizationSuspended403Res. +type OrganizationNotActivatedOrganizationSuspended403Res = OneOfOrganizationNotActivatedOrganizationSuspended403Res + +// OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res defines model for OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res. +type OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res = OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + +// OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res defines model for OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res. +type OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res = OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + +// OrganizationNotFoundResponse defines model for OrganizationNotFoundResponse. +type OrganizationNotFoundResponse struct { + Code *OrganizationNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// PermissionDenied403Res defines model for PermissionDenied403Res. +type PermissionDenied403Res = OneOfPermissionDenied403Res + +// ResourceDoesNotSupportUnallocationResponse defines model for ResourceDoesNotSupportUnallocationResponse. +type ResourceDoesNotSupportUnallocationResponse struct { + Code *ResourceDoesNotSupportUnallocationEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// SSHKeyNotFoundResponse defines model for SSHKeyNotFoundResponse. +type SSHKeyNotFoundResponse struct { + Code *SSHKeyNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// SecurityGroupNotFoundResponse defines model for SecurityGroupNotFoundResponse. +type SecurityGroupNotFoundResponse struct { + Code *SecurityGroupNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// SecurityGroupRuleNotFoundResponse defines model for SecurityGroupRuleNotFoundResponse. +type SecurityGroupRuleNotFoundResponse struct { + Code *SecurityGroupRuleNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// SpeedProfileAlreadyAssignedResponse defines model for SpeedProfileAlreadyAssignedResponse. +type SpeedProfileAlreadyAssignedResponse struct { + Code *SpeedProfileAlreadyAssignedEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// TagNotFoundResponse defines model for TagNotFoundResponse. +type TagNotFoundResponse struct { + Code *TagNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// TaskNotFoundResponse defines model for TaskNotFoundResponse. +type TaskNotFoundResponse struct { + Code *TaskNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// TaskQueueingErrorResponse defines model for TaskQueueingErrorResponse. +type TaskQueueingErrorResponse struct { + Code *TaskQueueingErrorEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *TaskQueueingError `json:"detail,omitempty"` +} + +// TrashObjectNotFoundResponse defines model for TrashObjectNotFoundResponse. +type TrashObjectNotFoundResponse struct { + Code *TrashObjectNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// ValidationErrorResponse defines model for ValidationErrorResponse. +type ValidationErrorResponse struct { + Code *ValidationErrorEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *ValidationError `json:"detail,omitempty"` +} + +// VirtualMachineBuildNotFoundResponse defines model for VirtualMachineBuildNotFoundResponse. +type VirtualMachineBuildNotFoundResponse struct { + Code *VirtualMachineBuildNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// VirtualMachineGroupNotFoundResponse defines model for VirtualMachineGroupNotFoundResponse. +type VirtualMachineGroupNotFoundResponse struct { + Code *VirtualMachineGroupNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// VirtualMachineNetworkInterfaceNotFoundResponse defines model for VirtualMachineNetworkInterfaceNotFoundResponse. +type VirtualMachineNetworkInterfaceNotFoundResponse struct { + Code *VirtualMachineNetworkInterfaceNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// VirtualMachineNotFoundResponse defines model for VirtualMachineNotFoundResponse. +type VirtualMachineNotFoundResponse struct { + Code *VirtualMachineNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// VirtualMachineNotFoundVirtualMachinePackageNotFound404Res defines model for VirtualMachineNotFoundVirtualMachinePackageNotFound404Res. +type VirtualMachineNotFoundVirtualMachinePackageNotFound404Res = OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res + +// VirtualMachinePackageNotFoundResponse defines model for VirtualMachinePackageNotFoundResponse. +type VirtualMachinePackageNotFoundResponse struct { + Code *VirtualMachinePackageNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// ZoneNotFoundResponse defines model for ZoneNotFoundResponse. +type ZoneNotFoundResponse struct { + Code *ZoneNotFoundEnum `json:"code,omitempty"` + Description *string `json:"description,omitempty"` + Detail *map[string]interface{} `json:"detail,omitempty"` +} + +// GetCertificateParams defines parameters for GetCertificate. +type GetCertificateParams struct { + // CertificateId All 'certificate[]' params are mutually exclusive, only one can be provided. + CertificateId *string `form:"certificate[id],omitempty" json:"certificate[id],omitempty"` +} + +// GetCountriesParams defines parameters for GetCountries. +type GetCountriesParams struct { + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetCountryParams defines parameters for GetCountry. +type GetCountryParams struct { + // CountryId The country to return. All 'country[]' params are mutually exclusive, only one can be provided. + CountryId *string `form:"country[id],omitempty" json:"country[id],omitempty"` + + // CountryIsoCode2 The country to return. All 'country[]' params are mutually exclusive, only one can be provided. + CountryIsoCode2 *string `form:"country[iso_code2],omitempty" json:"country[iso_code2],omitempty"` + + // CountryIsoCode3 The country to return. All 'country[]' params are mutually exclusive, only one can be provided. + CountryIsoCode3 *string `form:"country[iso_code3],omitempty" json:"country[iso_code3],omitempty"` +} + +// GetCountryCountryStatesParams defines parameters for GetCountryCountryStates. +type GetCountryCountryStatesParams struct { + // CountryId The country to return states for. All 'country[]' params are mutually exclusive, only one can be provided. + CountryId *string `form:"country[id],omitempty" json:"country[id],omitempty"` + + // CountryIsoCode2 The country to return states for. All 'country[]' params are mutually exclusive, only one can be provided. + CountryIsoCode2 *string `form:"country[iso_code2],omitempty" json:"country[iso_code2],omitempty"` + + // CountryIsoCode3 The country to return states for. All 'country[]' params are mutually exclusive, only one can be provided. + CountryIsoCode3 *string `form:"country[iso_code3],omitempty" json:"country[iso_code3],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetCountryStateParams defines parameters for GetCountryState. +type GetCountryStateParams struct { + // CountryStateId The country state to return. All 'country_state[]' params are mutually exclusive, only one can be provided. + CountryStateId *string `form:"country_state[id],omitempty" json:"country_state[id],omitempty"` +} + +// GetCurrenciesParams defines parameters for GetCurrencies. +type GetCurrenciesParams struct { + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetCurrencyParams defines parameters for GetCurrency. +type GetCurrencyParams struct { + // CurrencyId The currency to return. All 'currency[]' params are mutually exclusive, only one can be provided. + CurrencyId *string `form:"currency[id],omitempty" json:"currency[id],omitempty"` + + // CurrencyIsoCode The currency to return. All 'currency[]' params are mutually exclusive, only one can be provided. + CurrencyIsoCode *string `form:"currency[iso_code],omitempty" json:"currency[iso_code],omitempty"` +} + +// GetDataCenterParams defines parameters for GetDataCenter. +type GetDataCenterParams struct { + // DataCenterId All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenterId *string `form:"data_center[id],omitempty" json:"data_center[id],omitempty"` + + // DataCenterPermalink All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenterPermalink *string `form:"data_center[permalink],omitempty" json:"data_center[permalink],omitempty"` +} + +// GetDataCenterDefaultNetworkParams defines parameters for GetDataCenterDefaultNetwork. +type GetDataCenterDefaultNetworkParams struct { + // DataCenterId All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenterId *string `form:"data_center[id],omitempty" json:"data_center[id],omitempty"` + + // DataCenterPermalink All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenterPermalink *string `form:"data_center[permalink],omitempty" json:"data_center[permalink],omitempty"` +} + +// GetDataCenterGpuTypesParams defines parameters for GetDataCenterGpuTypes. +type GetDataCenterGpuTypesParams struct { + // DataCenterId The data center to list GPU types for. All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenterId *string `form:"data_center[id],omitempty" json:"data_center[id],omitempty"` + + // DataCenterPermalink The data center to list GPU types for. All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenterPermalink *string `form:"data_center[permalink],omitempty" json:"data_center[permalink],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// DeleteDiskBackupPolicyJSONBody defines parameters for DeleteDiskBackupPolicy. +type DeleteDiskBackupPolicyJSONBody struct { + // DiskBackupPolicy All 'disk_backup_policy[]' params are mutually exclusive, only one can be provided. + DiskBackupPolicy DiskBackupPolicyLookup `json:"disk_backup_policy"` +} + +// GetDiskBackupPolicyParams defines parameters for GetDiskBackupPolicy. +type GetDiskBackupPolicyParams struct { + // DiskBackupPolicyId The disk backup policy to get information for. All 'disk_backup_policy[]' params are mutually exclusive, only one can be provided. + DiskBackupPolicyId *string `form:"disk_backup_policy[id],omitempty" json:"disk_backup_policy[id],omitempty"` +} + +// PatchDiskBackupPolicyJSONBody defines parameters for PatchDiskBackupPolicy. +type PatchDiskBackupPolicyJSONBody struct { + // DiskBackupPolicy All 'disk_backup_policy[]' params are mutually exclusive, only one can be provided. + DiskBackupPolicy DiskBackupPolicyLookup `json:"disk_backup_policy"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties DiskBackupPolicyArguments `json:"properties"` +} + +// DeleteDiskBackupPolicyScheduleJSONBody defines parameters for DeleteDiskBackupPolicySchedule. +type DeleteDiskBackupPolicyScheduleJSONBody struct { + // DiskBackupPolicy All 'disk_backup_policy[]' params are mutually exclusive, only one can be provided. + DiskBackupPolicy DiskBackupPolicyLookup `json:"disk_backup_policy"` + + // Timestamp The time the disk backup policy will be moved to the trash automatically. + Timestamp int `json:"timestamp"` +} + +// GetDiskTemplateVersionParams defines parameters for GetDiskTemplateVersion. +type GetDiskTemplateVersionParams struct { + // DiskTemplateVersionId The disk template version to return. All 'disk_template_version[]' params are mutually exclusive, only one can be provided. + DiskTemplateVersionId *string `form:"disk_template_version[id],omitempty" json:"disk_template_version[id],omitempty"` +} + +// GetDiskTemplateVersionSpecParams defines parameters for GetDiskTemplateVersionSpec. +type GetDiskTemplateVersionSpecParams struct { + // DiskTemplateVersionId The disk template version to return. All 'disk_template_version[]' params are mutually exclusive, only one can be provided. + DiskTemplateVersionId *string `form:"disk_template_version[id],omitempty" json:"disk_template_version[id],omitempty"` +} + +// GetDiskTemplateParams defines parameters for GetDiskTemplate. +type GetDiskTemplateParams struct { + // DiskTemplateId The disk template to return. All 'disk_template[]' params are mutually exclusive, only one can be provided. + DiskTemplateId *string `form:"disk_template[id],omitempty" json:"disk_template[id],omitempty"` + + // DiskTemplatePermalink The disk template to return. All 'disk_template[]' params are mutually exclusive, only one can be provided. + DiskTemplatePermalink *string `form:"disk_template[permalink],omitempty" json:"disk_template[permalink],omitempty"` +} + +// GetDiskTemplateVersionsParams defines parameters for GetDiskTemplateVersions. +type GetDiskTemplateVersionsParams struct { + // DiskTemplateId The disk template to return the versions for. All 'disk_template[]' params are mutually exclusive, only one can be provided. + DiskTemplateId *string `form:"disk_template[id],omitempty" json:"disk_template[id],omitempty"` + + // DiskTemplatePermalink The disk template to return the versions for. All 'disk_template[]' params are mutually exclusive, only one can be provided. + DiskTemplatePermalink *string `form:"disk_template[permalink],omitempty" json:"disk_template[permalink],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetDiskParams defines parameters for GetDisk. +type GetDiskParams struct { + // DiskId The disk to return. All 'disk[]' params are mutually exclusive, only one can be provided. + DiskId *string `form:"disk[id],omitempty" json:"disk[id],omitempty"` +} + +// GetDiskDiskBackupPoliciesParams defines parameters for GetDiskDiskBackupPolicies. +type GetDiskDiskBackupPoliciesParams struct { + // DiskId The disk to return disk backup policies for. All 'disk[]' params are mutually exclusive, only one can be provided. + DiskId *string `form:"disk[id],omitempty" json:"disk[id],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostDiskDiskBackupPoliciesJSONBody defines parameters for PostDiskDiskBackupPolicies. +type PostDiskDiskBackupPoliciesJSONBody struct { + // Disk All 'disk[]' params are mutually exclusive, only one can be provided. + Disk DiskLookup `json:"disk"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties DiskBackupPolicyArguments `json:"properties"` +} + +// DeleteDnsRecordsDnsRecordJSONBody defines parameters for DeleteDnsRecordsDnsRecord. +type DeleteDnsRecordsDnsRecordJSONBody struct { + // DnsRecord All 'dns_record[]' params are mutually exclusive, only one can be provided. + DnsRecord DNSRecordLookup `json:"dns_record"` +} + +// GetDnsRecordsDnsRecordParams defines parameters for GetDnsRecordsDnsRecord. +type GetDnsRecordsDnsRecordParams struct { + // DnsRecordId The DNS record to return information for. All 'dns_record[]' params are mutually exclusive, only one can be provided. + DnsRecordId *string `form:"dns_record[id],omitempty" json:"dns_record[id],omitempty"` +} + +// PatchDnsRecordsDnsRecordJSONBody defines parameters for PatchDnsRecordsDnsRecord. +type PatchDnsRecordsDnsRecordJSONBody struct { + // Details All 'details[]' params are mutually exclusive, only one can be provided. + Details DNSRecordArguments `json:"details"` + + // DnsRecord All 'dns_record[]' params are mutually exclusive, only one can be provided. + DnsRecord DNSRecordLookup `json:"dns_record"` +} + +// DeleteDnsZonesDnsZoneJSONBody defines parameters for DeleteDnsZonesDnsZone. +type DeleteDnsZonesDnsZoneJSONBody struct { + // DnsZone All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZone DNSZoneLookup `json:"dns_zone"` +} + +// GetDnsZonesDnsZoneParams defines parameters for GetDnsZonesDnsZone. +type GetDnsZonesDnsZoneParams struct { + // DnsZoneId The DNS zone to return information for. All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneId *string `form:"dns_zone[id],omitempty" json:"dns_zone[id],omitempty"` + + // DnsZoneName The DNS zone to return information for. All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneName *string `form:"dns_zone[name],omitempty" json:"dns_zone[name],omitempty"` +} + +// GetDnsZonesDnsZoneRecordsParams defines parameters for GetDnsZonesDnsZoneRecords. +type GetDnsZonesDnsZoneRecordsParams struct { + // DnsZoneId The DNS zone to find all DNS records for. All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneId *string `form:"dns_zone[id],omitempty" json:"dns_zone[id],omitempty"` + + // DnsZoneName The DNS zone to find all DNS records for. All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneName *string `form:"dns_zone[name],omitempty" json:"dns_zone[name],omitempty"` +} + +// PostDnsZonesDnsZoneRecordsJSONBody defines parameters for PostDnsZonesDnsZoneRecords. +type PostDnsZonesDnsZoneRecordsJSONBody struct { + // Details All 'details[]' params are mutually exclusive, only one can be provided. + Details DNSRecordArguments `json:"details"` + + // DnsZone All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZone DNSZoneLookup `json:"dns_zone"` +} + +// PostDnsZonesDnsZoneUpdateTtlJSONBody defines parameters for PostDnsZonesDnsZoneUpdateTtl. +type PostDnsZonesDnsZoneUpdateTtlJSONBody struct { + // DnsZone All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZone DNSZoneLookup `json:"dns_zone"` + + // Ttl The new TTL value for the DNS zone + Ttl int `json:"ttl"` +} + +// GetDnsZonesDnsZoneVerificationDetailsParams defines parameters for GetDnsZonesDnsZoneVerificationDetails. +type GetDnsZonesDnsZoneVerificationDetailsParams struct { + // DnsZoneId The DNS zone to get verification details for. All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneId *string `form:"dns_zone[id],omitempty" json:"dns_zone[id],omitempty"` + + // DnsZoneName The DNS zone to get verification details for. All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneName *string `form:"dns_zone[name],omitempty" json:"dns_zone[name],omitempty"` +} + +// PostDnsZonesDnsZoneVerifyJSONBody defines parameters for PostDnsZonesDnsZoneVerify. +type PostDnsZonesDnsZoneVerifyJSONBody struct { + // DnsZone All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZone DNSZoneLookup `json:"dns_zone"` +} + +// DeleteDnsRecordJSONBody defines parameters for DeleteDnsRecord. +type DeleteDnsRecordJSONBody struct { + // DnsRecord All 'dns_record[]' params are mutually exclusive, only one can be provided. + DnsRecord DNSRecordLookup `json:"dns_record"` +} + +// GetDnsRecordParams defines parameters for GetDnsRecord. +type GetDnsRecordParams struct { + // DnsRecordId All 'dns_record[]' params are mutually exclusive, only one can be provided. + DnsRecordId *string `form:"dns_record[id],omitempty" json:"dns_record[id],omitempty"` +} + +// PatchDnsRecordJSONBody defines parameters for PatchDnsRecord. +type PatchDnsRecordJSONBody struct { + // DnsRecord All 'dns_record[]' params are mutually exclusive, only one can be provided. + DnsRecord DNSRecordLookup `json:"dns_record"` + + // Properties All 'details[]' params are mutually exclusive, only one can be provided. + Properties DNSRecordArguments `json:"properties"` +} + +// DeleteDnsZoneJSONBody defines parameters for DeleteDnsZone. +type DeleteDnsZoneJSONBody struct { + // DnsZone All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZone DNSZoneLookup `json:"dns_zone"` +} + +// GetDnsZoneParams defines parameters for GetDnsZone. +type GetDnsZoneParams struct { + // DnsZoneId All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneId *string `form:"dns_zone[id],omitempty" json:"dns_zone[id],omitempty"` + + // DnsZoneName All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneName *string `form:"dns_zone[name],omitempty" json:"dns_zone[name],omitempty"` +} + +// PatchDnsZoneJSONBody defines parameters for PatchDnsZone. +type PatchDnsZoneJSONBody struct { + // DnsZone All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZone DNSZoneLookup `json:"dns_zone"` + + // Properties All 'details[]' params are mutually exclusive, only one can be provided. + Properties DNSZoneArguments `json:"properties"` +} + +// GetDnsZoneRecordsParams defines parameters for GetDnsZoneRecords. +type GetDnsZoneRecordsParams struct { + // DnsZoneId All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneId *string `form:"dns_zone[id],omitempty" json:"dns_zone[id],omitempty"` + + // DnsZoneName All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZoneName *string `form:"dns_zone[name],omitempty" json:"dns_zone[name],omitempty"` +} + +// PostDnsZoneRecordsJSONBody defines parameters for PostDnsZoneRecords. +type PostDnsZoneRecordsJSONBody struct { + // DnsZone All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZone DNSZoneLookup `json:"dns_zone"` + + // Properties All 'details[]' params are mutually exclusive, only one can be provided. + Properties DNSRecordArguments `json:"properties"` +} + +// PostDnsZoneVerifyJSONBody defines parameters for PostDnsZoneVerify. +type PostDnsZoneVerifyJSONBody struct { + // DnsZone All 'dns_zone[]' params are mutually exclusive, only one can be provided. + DnsZone DNSZoneLookup `json:"dns_zone"` +} + +// DeleteFileStorageVolumeJSONBody defines parameters for DeleteFileStorageVolume. +type DeleteFileStorageVolumeJSONBody struct { + // FileStorageVolume All 'file_storage_volume[]' params are mutually exclusive, only one can be provided. + FileStorageVolume FileStorageVolumeLookup `json:"file_storage_volume"` +} + +// GetFileStorageVolumeParams defines parameters for GetFileStorageVolume. +type GetFileStorageVolumeParams struct { + // FileStorageVolumeId The file storage volume to return. All 'file_storage_volume[]' params are mutually exclusive, only one can be provided. + FileStorageVolumeId *string `form:"file_storage_volume[id],omitempty" json:"file_storage_volume[id],omitempty"` +} + +// PatchFileStorageVolumeJSONBody defines parameters for PatchFileStorageVolume. +type PatchFileStorageVolumeJSONBody struct { + // FileStorageVolume All 'file_storage_volume[]' params are mutually exclusive, only one can be provided. + FileStorageVolume FileStorageVolumeLookup `json:"file_storage_volume"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties FileStorageVolumeArguments `json:"properties"` +} + +// GetGpuTypesParams defines parameters for GetGpuTypes. +type GetGpuTypesParams struct { + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetGpuTypeParams defines parameters for GetGpuType. +type GetGpuTypeParams struct { + // GpuTypeId All 'gpu_type[]' params are mutually exclusive, only one can be provided. + GpuTypeId *string `form:"gpu_type[id],omitempty" json:"gpu_type[id],omitempty"` + + // GpuTypePermalink All 'gpu_type[]' params are mutually exclusive, only one can be provided. + GpuTypePermalink *string `form:"gpu_type[permalink],omitempty" json:"gpu_type[permalink],omitempty"` +} + +// PostInvalidateLinkedWebSessionJSONBody defines parameters for PostInvalidateLinkedWebSession. +type PostInvalidateLinkedWebSessionJSONBody = interface{} + +// DeleteIpAddressJSONBody defines parameters for DeleteIpAddress. +type DeleteIpAddressJSONBody struct { + // IpAddress All 'ip_address[]' params are mutually exclusive, only one can be provided. + IpAddress IPAddressLookup `json:"ip_address"` +} + +// GetIpAddressParams defines parameters for GetIpAddress. +type GetIpAddressParams struct { + // IpAddressId The IP address to find. All 'ip_address[]' params are mutually exclusive, only one can be provided. + IpAddressId *string `form:"ip_address[id],omitempty" json:"ip_address[id],omitempty"` + + // IpAddressAddress The IP address to find. All 'ip_address[]' params are mutually exclusive, only one can be provided. + IpAddressAddress *string `form:"ip_address[address],omitempty" json:"ip_address[address],omitempty"` +} + +// PatchIpAddressJSONBody defines parameters for PatchIpAddress. +type PatchIpAddressJSONBody struct { + // IpAddress All 'ip_address[]' params are mutually exclusive, only one can be provided. + IpAddress IPAddressLookup `json:"ip_address"` + + // Label The label to give this address if setting it as a VIP + Label *string `json:"label,omitempty"` + + // ReverseDns The reverse DNS to set for this IP address + ReverseDns *string `json:"reverse_dns,omitempty"` + + // Vip Whether or not to set this address as a VIP + Vip *bool `json:"vip,omitempty"` +} + +// PostIpAddressUnallocateJSONBody defines parameters for PostIpAddressUnallocate. +type PostIpAddressUnallocateJSONBody struct { + // IpAddress All 'ip_address[]' params are mutually exclusive, only one can be provided. + IpAddress IPAddressLookup `json:"ip_address"` +} + +// DeleteLoadBalancerJSONBody defines parameters for DeleteLoadBalancer. +type DeleteLoadBalancerJSONBody struct { + // LoadBalancer All 'load_balancer[]' params are mutually exclusive, only one can be provided. + LoadBalancer LoadBalancerLookup `json:"load_balancer"` +} + +// GetLoadBalancerParams defines parameters for GetLoadBalancer. +type GetLoadBalancerParams struct { + // LoadBalancerId The load balancer to return the details for. All 'load_balancer[]' params are mutually exclusive, only one can be provided. + LoadBalancerId *string `form:"load_balancer[id],omitempty" json:"load_balancer[id],omitempty"` + + // LoadBalancerApiReference The load balancer to return the details for. All 'load_balancer[]' params are mutually exclusive, only one can be provided. + LoadBalancerApiReference *string `form:"load_balancer[api_reference],omitempty" json:"load_balancer[api_reference],omitempty"` +} + +// PatchLoadBalancerJSONBody defines parameters for PatchLoadBalancer. +type PatchLoadBalancerJSONBody struct { + // LoadBalancer All 'load_balancer[]' params are mutually exclusive, only one can be provided. + LoadBalancer LoadBalancerLookup `json:"load_balancer"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties LoadBalancerArguments `json:"properties"` +} + +// GetLoadBalancerRulesParams defines parameters for GetLoadBalancerRules. +type GetLoadBalancerRulesParams struct { + // LoadBalancerId The load balancer to return all load rules for. All 'load_balancer[]' params are mutually exclusive, only one can be provided. + LoadBalancerId *string `form:"load_balancer[id],omitempty" json:"load_balancer[id],omitempty"` + + // LoadBalancerApiReference The load balancer to return all load rules for. All 'load_balancer[]' params are mutually exclusive, only one can be provided. + LoadBalancerApiReference *string `form:"load_balancer[api_reference],omitempty" json:"load_balancer[api_reference],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostLoadBalancerRulesJSONBody defines parameters for PostLoadBalancerRules. +type PostLoadBalancerRulesJSONBody struct { + // LoadBalancer All 'load_balancer[]' params are mutually exclusive, only one can be provided. + LoadBalancer LoadBalancerLookup `json:"load_balancer"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties LoadBalancerRuleArguments `json:"properties"` +} + +// DeleteLoadBalancersRulesLoadBalancerRuleJSONBody defines parameters for DeleteLoadBalancersRulesLoadBalancerRule. +type DeleteLoadBalancersRulesLoadBalancerRuleJSONBody struct { + // LoadBalancerRule All 'load_balancer_rule[]' params are mutually exclusive, only one can be provided. + LoadBalancerRule LoadBalancerRuleLookup `json:"load_balancer_rule"` +} + +// GetLoadBalancersRulesLoadBalancerRuleParams defines parameters for GetLoadBalancersRulesLoadBalancerRule. +type GetLoadBalancersRulesLoadBalancerRuleParams struct { + // LoadBalancerRuleId The load balancer rule to return the details for. All 'load_balancer_rule[]' params are mutually exclusive, only one can be provided. + LoadBalancerRuleId *string `form:"load_balancer_rule[id],omitempty" json:"load_balancer_rule[id],omitempty"` +} + +// PatchLoadBalancersRulesLoadBalancerRuleJSONBody defines parameters for PatchLoadBalancersRulesLoadBalancerRule. +type PatchLoadBalancersRulesLoadBalancerRuleJSONBody struct { + // LoadBalancerRule All 'load_balancer_rule[]' params are mutually exclusive, only one can be provided. + LoadBalancerRule LoadBalancerRuleLookup `json:"load_balancer_rule"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties LoadBalancerRuleArguments `json:"properties"` +} + +// GetNetworkParams defines parameters for GetNetwork. +type GetNetworkParams struct { + // NetworkId The network to return. All 'network[]' params are mutually exclusive, only one can be provided. + NetworkId *string `form:"network[id],omitempty" json:"network[id],omitempty"` + + // NetworkPermalink The network to return. All 'network[]' params are mutually exclusive, only one can be provided. + NetworkPermalink *string `form:"network[permalink],omitempty" json:"network[permalink],omitempty"` +} + +// GetOperatingSystemsParams defines parameters for GetOperatingSystems. +type GetOperatingSystemsParams struct { + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetOperatingSystemParams defines parameters for GetOperatingSystem. +type GetOperatingSystemParams struct { + // OperatingSystemId The operating system to return. All 'operating_system[]' params are mutually exclusive, only one can be provided. + OperatingSystemId *string `form:"operating_system[id],omitempty" json:"operating_system[id],omitempty"` +} + +// GetOrganizationParams defines parameters for GetOrganization. +type GetOrganizationParams struct { + // OrganizationId All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` +} + +// GetOrganizationAvailableNetworksParams defines parameters for GetOrganizationAvailableNetworks. +type GetOrganizationAvailableNetworksParams struct { + // OrganizationId All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` +} + +// GetOrganizationCertificatesParams defines parameters for GetOrganizationCertificates. +type GetOrganizationCertificatesParams struct { + // OrganizationId All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetOrganizationDiskBackupPoliciesParams defines parameters for GetOrganizationDiskBackupPolicies. +type GetOrganizationDiskBackupPoliciesParams struct { + // OrganizationId The organization to return disk backup policies for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to return disk backup policies for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetOrganizationDiskTemplatesParams defines parameters for GetOrganizationDiskTemplates. +type GetOrganizationDiskTemplatesParams struct { + // OrganizationId The organization to find disk templates for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to find disk templates for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + + // IncludeUniversal Whether or not to include universal templates + IncludeUniversal *bool `form:"include_universal,omitempty" json:"include_universal,omitempty"` + + // OperatingSystemId An operating system to use to filter disk templates. All 'operating_system[]' params are mutually exclusive, only one can be provided. + OperatingSystemId *string `form:"operating_system[id],omitempty" json:"operating_system[id],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetOrganizationDisksParams defines parameters for GetOrganizationDisks. +type GetOrganizationDisksParams struct { + // OrganizationId The organization to find disks for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to find disks for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetOrganizationDnsZonesParams defines parameters for GetOrganizationDnsZones. +type GetOrganizationDnsZonesParams struct { + // OrganizationId The organization to return DNS zones for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to return DNS zones for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationDnsZonesJSONBody defines parameters for PostOrganizationDnsZones. +type PostOrganizationDnsZonesJSONBody struct { + // Details All 'details[]' params are mutually exclusive, only one can be provided. + Details DNSZoneArguments `json:"details"` + + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` +} + +// GetOrganizationsOrganizationdnsZonesParams defines parameters for GetOrganizationsOrganizationdnsZones. +type GetOrganizationsOrganizationdnsZonesParams struct { + // OrganizationId All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationsOrganizationdnsZonesJSONBody defines parameters for PostOrganizationsOrganizationdnsZones. +type PostOrganizationsOrganizationdnsZonesJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + + // Properties All 'details[]' params are mutually exclusive, only one can be provided. + Properties DNSZoneArguments `json:"properties"` +} + +// GetOrganizationDnsZonesNameserversParams defines parameters for GetOrganizationDnsZonesNameservers. +type GetOrganizationDnsZonesNameserversParams struct { + // OrganizationId All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` +} + +// GetOrganizationFileStorageVolumesParams defines parameters for GetOrganizationFileStorageVolumes. +type GetOrganizationFileStorageVolumesParams struct { + // OrganizationId The organization to return all file storage volumes for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to return all file storage volumes for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationFileStorageVolumesJSONBody defines parameters for PostOrganizationFileStorageVolumes. +type PostOrganizationFileStorageVolumesJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties FileStorageVolumeArguments `json:"properties"` +} + +// GetOrganizationIpAddressesParams defines parameters for GetOrganizationIpAddresses. +type GetOrganizationIpAddressesParams struct { + // OrganizationId The organization to use when looking up IP addresses. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to use when looking up IP addresses. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + + // Allocated If true, only return allocated IP addresss. If false, only return unallocated IP addresses. + Allocated *bool `form:"allocated,omitempty" json:"allocated,omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationIpAddressesJSONBody defines parameters for PostOrganizationIpAddresses. +type PostOrganizationIpAddressesJSONBody struct { + // Label The label to give this address if setting it as a VIP + Label *string `json:"label,omitempty"` + + // Network All 'network[]' params are mutually exclusive, only one can be provided. + Network NetworkLookup `json:"network"` + + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + Version IPAddressVersionEnum `json:"version"` + + // Vip Whether or not to set this address as a VIP + Vip *bool `json:"vip,omitempty"` +} + +// GetOrganizationLoadBalancersParams defines parameters for GetOrganizationLoadBalancers. +type GetOrganizationLoadBalancersParams struct { + // OrganizationId The organization to return all load balancers for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to return all load balancers for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationLoadBalancersJSONBody defines parameters for PostOrganizationLoadBalancers. +type PostOrganizationLoadBalancersJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties LoadBalancerArguments `json:"properties"` +} + +// GetOrganizationManagedParams defines parameters for GetOrganizationManaged. +type GetOrganizationManagedParams struct { + // OrganizationId All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationManagedJSONBody defines parameters for PostOrganizationManaged. +type PostOrganizationManagedJSONBody struct { + Name string `json:"name"` + + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + SubDomain string `json:"sub_domain"` +} + +// GetOrganizationNetworkSpeedProfilesParams defines parameters for GetOrganizationNetworkSpeedProfiles. +type GetOrganizationNetworkSpeedProfilesParams struct { + // OrganizationId The organization to use when looking up network speed profiles. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to use when looking up network speed profiles. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetOrganizationSecurityGroupsParams defines parameters for GetOrganizationSecurityGroups. +type GetOrganizationSecurityGroupsParams struct { + // OrganizationId The organization to return all security groups for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to return all security groups for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationSecurityGroupsJSONBody defines parameters for PostOrganizationSecurityGroups. +type PostOrganizationSecurityGroupsJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties SecurityGroupArguments `json:"properties"` +} + +// GetOrganizationSshKeysParams defines parameters for GetOrganizationSshKeys. +type GetOrganizationSshKeysParams struct { + // OrganizationId The organization to list SSH keys for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to list SSH keys for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationSshKeysJSONBody defines parameters for PostOrganizationSshKeys. +type PostOrganizationSshKeysJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + + // SshKey All 'ssh_key[]' params are mutually exclusive, only one can be provided. + SshKey AuthSSHKeyProperties `json:"ssh_key"` +} + +// GetOrganizationTagsParams defines parameters for GetOrganizationTags. +type GetOrganizationTagsParams struct { + // OrganizationId The organization to list the tags for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to list the tags for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationTagsJSONBody defines parameters for PostOrganizationTags. +type PostOrganizationTagsJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties TagArguments `json:"properties"` +} + +// GetOrganizationTrashObjectsParams defines parameters for GetOrganizationTrashObjects. +type GetOrganizationTrashObjectsParams struct { + // OrganizationId The organization to find all trash objects for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to find all trash objects for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationTrashObjectsPurgeAllJSONBody defines parameters for PostOrganizationTrashObjectsPurgeAll. +type PostOrganizationTrashObjectsPurgeAllJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` +} + +// GetOrganizationUsersWithAccessParams defines parameters for GetOrganizationUsersWithAccess. +type GetOrganizationUsersWithAccessParams struct { + // OrganizationId All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetOrganizationVirtualMachineGroupsParams defines parameters for GetOrganizationVirtualMachineGroups. +type GetOrganizationVirtualMachineGroupsParams struct { + // OrganizationId The organization to return groups for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain The organization to return groups for. All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` +} + +// PostOrganizationVirtualMachineGroupsJSONBody defines parameters for PostOrganizationVirtualMachineGroups. +type PostOrganizationVirtualMachineGroupsJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties VirtualMachineGroupArguments `json:"properties"` +} + +// GetOrganizationVirtualMachinesParams defines parameters for GetOrganizationVirtualMachines. +type GetOrganizationVirtualMachinesParams struct { + // OrganizationId All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostOrganizationVirtualMachinesBuildJSONBody defines parameters for PostOrganizationVirtualMachinesBuild. +type PostOrganizationVirtualMachinesBuildJSONBody struct { + // DataCenter All 'data_center[]' params are mutually exclusive, only one can be provided. + DataCenter *DataCenterLookup `json:"data_center,omitempty"` + + // DiskTemplate All 'disk_template[]' params are mutually exclusive, only one can be provided. + DiskTemplate *DiskTemplateLookup `json:"disk_template,omitempty"` + DiskTemplateOptions *[]KeyValue `json:"disk_template_options,omitempty"` + Hostname *string `json:"hostname,omitempty"` + + // Network All 'network[]' params are mutually exclusive, only one can be provided. + Network *NetworkLookup `json:"network,omitempty"` + + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + + // Package All 'virtual_machine_package[]' params are mutually exclusive, only one can be provided. + Package VirtualMachinePackageLookup `json:"package"` + + // Zone All 'zone[]' params are mutually exclusive, only one can be provided. + Zone *ZoneLookup `json:"zone,omitempty"` +} + +// PostOrganizationVirtualMachinesBuildFromSpecJSONBody defines parameters for PostOrganizationVirtualMachinesBuildFromSpec. +type PostOrganizationVirtualMachinesBuildFromSpecJSONBody struct { + // Organization All 'organization[]' params are mutually exclusive, only one can be provided. + Organization OrganizationLookup `json:"organization"` + Xml string `json:"xml"` +} + +// DeleteSecurityGroupJSONBody defines parameters for DeleteSecurityGroup. +type DeleteSecurityGroupJSONBody struct { + // SecurityGroup All 'security_group[]' params are mutually exclusive, only one can be provided. + SecurityGroup SecurityGroupLookup `json:"security_group"` +} + +// GetSecurityGroupParams defines parameters for GetSecurityGroup. +type GetSecurityGroupParams struct { + // SecurityGroupId The security group to return the details for. All 'security_group[]' params are mutually exclusive, only one can be provided. + SecurityGroupId *string `form:"security_group[id],omitempty" json:"security_group[id],omitempty"` +} + +// PatchSecurityGroupJSONBody defines parameters for PatchSecurityGroup. +type PatchSecurityGroupJSONBody struct { + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties SecurityGroupArguments `json:"properties"` + + // SecurityGroup All 'security_group[]' params are mutually exclusive, only one can be provided. + SecurityGroup SecurityGroupLookup `json:"security_group"` +} + +// GetSecurityGroupRulesParams defines parameters for GetSecurityGroupRules. +type GetSecurityGroupRulesParams struct { + // SecurityGroupId The security group to return all load rules for. All 'security_group[]' params are mutually exclusive, only one can be provided. + SecurityGroupId *string `form:"security_group[id],omitempty" json:"security_group[id],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostSecurityGroupRulesJSONBody defines parameters for PostSecurityGroupRules. +type PostSecurityGroupRulesJSONBody struct { + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties SecurityGroupRuleArguments `json:"properties"` + + // SecurityGroup All 'security_group[]' params are mutually exclusive, only one can be provided. + SecurityGroup SecurityGroupLookup `json:"security_group"` +} + +// DeleteSecurityGroupsRulesSecurityGroupRuleJSONBody defines parameters for DeleteSecurityGroupsRulesSecurityGroupRule. +type DeleteSecurityGroupsRulesSecurityGroupRuleJSONBody struct { + // SecurityGroupRule All 'security_group_rule[]' params are mutually exclusive, only one can be provided. + SecurityGroupRule SecurityGroupRuleLookup `json:"security_group_rule"` +} + +// GetSecurityGroupsRulesSecurityGroupRuleParams defines parameters for GetSecurityGroupsRulesSecurityGroupRule. +type GetSecurityGroupsRulesSecurityGroupRuleParams struct { + // SecurityGroupRuleId The security group rule to return the details for. All 'security_group_rule[]' params are mutually exclusive, only one can be provided. + SecurityGroupRuleId *string `form:"security_group_rule[id],omitempty" json:"security_group_rule[id],omitempty"` +} + +// PatchSecurityGroupsRulesSecurityGroupRuleJSONBody defines parameters for PatchSecurityGroupsRulesSecurityGroupRule. +type PatchSecurityGroupsRulesSecurityGroupRuleJSONBody struct { + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties SecurityGroupRuleArguments `json:"properties"` + + // SecurityGroupRule All 'security_group_rule[]' params are mutually exclusive, only one can be provided. + SecurityGroupRule SecurityGroupRuleLookup `json:"security_group_rule"` +} + +// DeleteSshKeyJSONBody defines parameters for DeleteSshKey. +type DeleteSshKeyJSONBody struct { + // SshKey All 'ssh_key[]' params are mutually exclusive, only one can be provided. + SshKey AuthSSHKeyLookup `json:"ssh_key"` +} + +// DeleteTagJSONBody defines parameters for DeleteTag. +type DeleteTagJSONBody struct { + // Tag All 'tag[]' params are mutually exclusive, only one can be provided. + Tag TagLookup `json:"tag"` +} + +// GetTagParams defines parameters for GetTag. +type GetTagParams struct { + // TagId The tag to load the details for. All 'tag[]' params are mutually exclusive, only one can be provided. + TagId *string `form:"tag[id],omitempty" json:"tag[id],omitempty"` +} + +// PatchTagJSONBody defines parameters for PatchTag. +type PatchTagJSONBody struct { + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties TagArguments `json:"properties"` + + // Tag All 'tag[]' params are mutually exclusive, only one can be provided. + Tag TagLookup `json:"tag"` +} + +// GetTaskParams defines parameters for GetTask. +type GetTaskParams struct { + // TaskId All 'task[]' params are mutually exclusive, only one can be provided. + TaskId *string `form:"task[id],omitempty" json:"task[id],omitempty"` +} + +// DeleteTrashObjectJSONBody defines parameters for DeleteTrashObject. +type DeleteTrashObjectJSONBody struct { + // TrashObject All 'trash_object[]' params are mutually exclusive, only one can be provided. + TrashObject TrashObjectLookup `json:"trash_object"` +} + +// GetTrashObjectParams defines parameters for GetTrashObject. +type GetTrashObjectParams struct { + // TrashObjectId The trash object to find. All 'trash_object[]' params are mutually exclusive, only one can be provided. + TrashObjectId *string `form:"trash_object[id],omitempty" json:"trash_object[id],omitempty"` + + // TrashObjectObjectId The trash object to find. All 'trash_object[]' params are mutually exclusive, only one can be provided. + TrashObjectObjectId *string `form:"trash_object[object_id],omitempty" json:"trash_object[object_id],omitempty"` +} + +// PostTrashObjectRestoreJSONBody defines parameters for PostTrashObjectRestore. +type PostTrashObjectRestoreJSONBody struct { + // TrashObject All 'trash_object[]' params are mutually exclusive, only one can be provided. + TrashObject TrashObjectLookup `json:"trash_object"` +} + +// DeleteVirtualMachineGroupJSONBody defines parameters for DeleteVirtualMachineGroup. +type DeleteVirtualMachineGroupJSONBody struct { + // VirtualMachineGroup All 'group[]' params are mutually exclusive, only one can be provided. + VirtualMachineGroup VirtualMachineGroupLookup `json:"virtual_machine_group"` +} + +// GetVirtualMachineGroupParams defines parameters for GetVirtualMachineGroup. +type GetVirtualMachineGroupParams struct { + // VirtualMachineGroupId The virtual machine group to retrieve. All 'virtual_machine_group[]' params are mutually exclusive, only one can be provided. + VirtualMachineGroupId *string `form:"virtual_machine_group[id],omitempty" json:"virtual_machine_group[id],omitempty"` +} + +// PatchVirtualMachineGroupJSONBody defines parameters for PatchVirtualMachineGroup. +type PatchVirtualMachineGroupJSONBody struct { + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties VirtualMachineGroupArguments `json:"properties"` + + // VirtualMachineGroup All 'group[]' params are mutually exclusive, only one can be provided. + VirtualMachineGroup VirtualMachineGroupLookup `json:"virtual_machine_group"` +} + +// GetVMNIVMNIParams defines parameters for GetVMNIVMNI. +type GetVMNIVMNIParams struct { + // VirtualMachineNetworkInterfaceId The network interface to show the information for. All 'virtual_machine_network_interface[]' params are mutually exclusive, only one can be provided. + VirtualMachineNetworkInterfaceId *string `form:"virtual_machine_network_interface[id],omitempty" json:"virtual_machine_network_interface[id],omitempty"` +} + +// PostVirtualMachineNetworkInterfaceAllocateIpJSONBody defines parameters for PostVirtualMachineNetworkInterfaceAllocateIp. +type PostVirtualMachineNetworkInterfaceAllocateIpJSONBody struct { + // IpAddress All 'ip_address[]' params are mutually exclusive, only one can be provided. + IpAddress IPAddressLookup `json:"ip_address"` + + // VirtualMachineNetworkInterface All 'virtual_machine_network_interface[]' params are mutually exclusive, only one can be provided. + VirtualMachineNetworkInterface VirtualMachineNetworkInterfaceLookup `json:"virtual_machine_network_interface"` +} + +// PostVirtualMachineNetworkInterfaceAllocateNewIpJSONBody defines parameters for PostVirtualMachineNetworkInterfaceAllocateNewIp. +type PostVirtualMachineNetworkInterfaceAllocateNewIpJSONBody struct { + AddressVersion IPAddressVersionEnum `json:"address_version"` + + // VirtualMachineNetworkInterface All 'virtual_machine_network_interface[]' params are mutually exclusive, only one can be provided. + VirtualMachineNetworkInterface VirtualMachineNetworkInterfaceLookup `json:"virtual_machine_network_interface"` +} + +// GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionParams defines parameters for GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersion. +type GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionParams struct { + // VirtualMachineNetworkInterfaceId The network interface to get IP addresses for. All 'virtual_machine_network_interface[]' params are mutually exclusive, only one can be provided. + VirtualMachineNetworkInterfaceId *string `form:"virtual_machine_network_interface[id],omitempty" json:"virtual_machine_network_interface[id],omitempty"` + + // AddressVersion The IP address version to return results for + AddressVersion IPAddressVersionEnum `form:"address_version" json:"address_version"` +} + +// PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONBody defines parameters for PatchVirtualMachineNetworkInterfaceUpdateSpeedProfile. +type PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONBody struct { + // SpeedProfile All 'speed_profile[]' params are mutually exclusive, only one can be provided. + SpeedProfile NetworkSpeedProfileLookup `json:"speed_profile"` + + // VirtualMachineNetworkInterface All 'virtual_machine_network_interface[]' params are mutually exclusive, only one can be provided. + VirtualMachineNetworkInterface VirtualMachineNetworkInterfaceLookup `json:"virtual_machine_network_interface"` +} + +// GetVirtualMachinePackagesParams defines parameters for GetVirtualMachinePackages. +type GetVirtualMachinePackagesParams struct { + // OrganizationId Provide an organization to only show packages available to the given organization (otherwise only public packages will be displayed). All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationId *string `form:"organization[id],omitempty" json:"organization[id],omitempty"` + + // OrganizationSubDomain Provide an organization to only show packages available to the given organization (otherwise only public packages will be displayed). All 'organization[]' params are mutually exclusive, only one can be provided. + OrganizationSubDomain *string `form:"organization[sub_domain],omitempty" json:"organization[sub_domain],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetVirtualMachinePackageParams defines parameters for GetVirtualMachinePackage. +type GetVirtualMachinePackageParams struct { + // VirtualMachinePackageId All 'virtual_machine_package[]' params are mutually exclusive, only one can be provided. + VirtualMachinePackageId *string `form:"virtual_machine_package[id],omitempty" json:"virtual_machine_package[id],omitempty"` + + // VirtualMachinePackagePermalink All 'virtual_machine_package[]' params are mutually exclusive, only one can be provided. + VirtualMachinePackagePermalink *string `form:"virtual_machine_package[permalink],omitempty" json:"virtual_machine_package[permalink],omitempty"` +} + +// DeleteVirtualMachineJSONBody defines parameters for DeleteVirtualMachine. +type DeleteVirtualMachineJSONBody struct { + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine *VirtualMachineLookup `json:"virtual_machine,omitempty"` +} + +// GetVirtualMachineParams defines parameters for GetVirtualMachine. +type GetVirtualMachineParams struct { + // VirtualMachineId All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineId *string `form:"virtual_machine[id],omitempty" json:"virtual_machine[id],omitempty"` + + // VirtualMachineFqdn All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineFqdn *string `form:"virtual_machine[fqdn],omitempty" json:"virtual_machine[fqdn],omitempty"` +} + +// PatchVirtualMachineJSONBody defines parameters for PatchVirtualMachine. +type PatchVirtualMachineJSONBody struct { + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties VirtualMachineArguments `json:"properties"` + + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// PostVirtualMachineAllocateIpJSONBody defines parameters for PostVirtualMachineAllocateIp. +type PostVirtualMachineAllocateIpJSONBody struct { + // IpAddress All 'ip_address[]' params are mutually exclusive, only one can be provided. + IpAddress IPAddressLookup `json:"ip_address"` + + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// PostVirtualMachineConsoleSessionsJSONBody defines parameters for PostVirtualMachineConsoleSessions. +type PostVirtualMachineConsoleSessionsJSONBody struct { + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// GetVirtualMachineDiskBackupPoliciesParams defines parameters for GetVirtualMachineDiskBackupPolicies. +type GetVirtualMachineDiskBackupPoliciesParams struct { + // VirtualMachineId The virtual machine to return disk backup policies for. All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineId *string `form:"virtual_machine[id],omitempty" json:"virtual_machine[id],omitempty"` + + // VirtualMachineFqdn The virtual machine to return disk backup policies for. All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineFqdn *string `form:"virtual_machine[fqdn],omitempty" json:"virtual_machine[fqdn],omitempty"` + + // IncludeDisks If true, the returned list will include backup policies owned by disks assigned to this virtual machine in addition to those that belong to the whole virtual machine + IncludeDisks *bool `form:"include_disks,omitempty" json:"include_disks,omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PostVirtualMachineDiskBackupPoliciesJSONBody defines parameters for PostVirtualMachineDiskBackupPolicies. +type PostVirtualMachineDiskBackupPoliciesJSONBody struct { + // Properties All 'properties[]' params are mutually exclusive, only one can be provided. + Properties DiskBackupPolicyArguments `json:"properties"` + + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// GetVirtualMachineDisksParams defines parameters for GetVirtualMachineDisks. +type GetVirtualMachineDisksParams struct { + // VirtualMachineId The virtual machine to find disks for. All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineId *string `form:"virtual_machine[id],omitempty" json:"virtual_machine[id],omitempty"` + + // VirtualMachineFqdn The virtual machine to find disks for. All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineFqdn *string `form:"virtual_machine[fqdn],omitempty" json:"virtual_machine[fqdn],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// PutVirtualMachineFlexibleResourcesJSONBody defines parameters for PutVirtualMachineFlexibleResources. +type PutVirtualMachineFlexibleResourcesJSONBody struct { + // Resources All 'resources[]' params are mutually exclusive, only one can be provided. + Resources VirtualMachineFlexibleResources `json:"resources"` + + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// GetVirtualMachineNetworkInterfacesParams defines parameters for GetVirtualMachineNetworkInterfaces. +type GetVirtualMachineNetworkInterfacesParams struct { + // VirtualMachineId The virtual machine to show network interfaces for. All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineId *string `form:"virtual_machine[id],omitempty" json:"virtual_machine[id],omitempty"` + + // VirtualMachineFqdn The virtual machine to show network interfaces for. All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineFqdn *string `form:"virtual_machine[fqdn],omitempty" json:"virtual_machine[fqdn],omitempty"` + Page *int `form:"page,omitempty" json:"page,omitempty"` + PerPage *int `form:"per_page,omitempty" json:"per_page,omitempty"` +} + +// GetVirtualMachineNetworkInterfaceParams defines parameters for GetVirtualMachineNetworkInterface. +type GetVirtualMachineNetworkInterfaceParams struct { + // VirtualMachineId The virtual machine to find the network interface for. All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineId *string `form:"virtual_machine[id],omitempty" json:"virtual_machine[id],omitempty"` + + // VirtualMachineFqdn The virtual machine to find the network interface for. All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachineFqdn *string `form:"virtual_machine[fqdn],omitempty" json:"virtual_machine[fqdn],omitempty"` + + // NetworkId The network to find the network interface for. All 'network[]' params are mutually exclusive, only one can be provided. + NetworkId *string `form:"network[id],omitempty" json:"network[id],omitempty"` + + // NetworkPermalink The network to find the network interface for. All 'network[]' params are mutually exclusive, only one can be provided. + NetworkPermalink *string `form:"network[permalink],omitempty" json:"network[permalink],omitempty"` +} + +// PutVirtualMachinePackageJSONBody defines parameters for PutVirtualMachinePackage. +type PutVirtualMachinePackageJSONBody struct { + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` + + // VirtualMachinePackage All 'virtual_machine_package[]' params are mutually exclusive, only one can be provided. + VirtualMachinePackage VirtualMachinePackageLookup `json:"virtual_machine_package"` +} + +// PostVirtualMachineResetJSONBody defines parameters for PostVirtualMachineReset. +type PostVirtualMachineResetJSONBody struct { + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// PostVirtualMachineShutdownJSONBody defines parameters for PostVirtualMachineShutdown. +type PostVirtualMachineShutdownJSONBody struct { + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// PostVirtualMachineStartJSONBody defines parameters for PostVirtualMachineStart. +type PostVirtualMachineStartJSONBody struct { + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// PostVirtualMachineStopJSONBody defines parameters for PostVirtualMachineStop. +type PostVirtualMachineStopJSONBody struct { + // VirtualMachine All 'virtual_machine[]' params are mutually exclusive, only one can be provided. + VirtualMachine VirtualMachineLookup `json:"virtual_machine"` +} + +// GetVirtualMachinesBuildsVirtualMachineBuildParams defines parameters for GetVirtualMachinesBuildsVirtualMachineBuild. +type GetVirtualMachinesBuildsVirtualMachineBuildParams struct { + // VirtualMachineBuildId All 'virtual_machine_build[]' params are mutually exclusive, only one can be provided. + VirtualMachineBuildId *string `form:"virtual_machine_build[id],omitempty" json:"virtual_machine_build[id],omitempty"` +} + +// GetZoneParams defines parameters for GetZone. +type GetZoneParams struct { + // ZoneId The zone to find. All 'zone[]' params are mutually exclusive, only one can be provided. + ZoneId *string `form:"zone[id],omitempty" json:"zone[id],omitempty"` + + // ZonePermalink The zone to find. All 'zone[]' params are mutually exclusive, only one can be provided. + ZonePermalink *string `form:"zone[permalink],omitempty" json:"zone[permalink],omitempty"` +} + +// DeleteDiskBackupPolicyJSONRequestBody defines body for DeleteDiskBackupPolicy for application/json ContentType. +type DeleteDiskBackupPolicyJSONRequestBody DeleteDiskBackupPolicyJSONBody + +// PatchDiskBackupPolicyJSONRequestBody defines body for PatchDiskBackupPolicy for application/json ContentType. +type PatchDiskBackupPolicyJSONRequestBody PatchDiskBackupPolicyJSONBody + +// DeleteDiskBackupPolicyScheduleJSONRequestBody defines body for DeleteDiskBackupPolicySchedule for application/json ContentType. +type DeleteDiskBackupPolicyScheduleJSONRequestBody DeleteDiskBackupPolicyScheduleJSONBody + +// PostDiskDiskBackupPoliciesJSONRequestBody defines body for PostDiskDiskBackupPolicies for application/json ContentType. +type PostDiskDiskBackupPoliciesJSONRequestBody PostDiskDiskBackupPoliciesJSONBody + +// DeleteDnsRecordsDnsRecordJSONRequestBody defines body for DeleteDnsRecordsDnsRecord for application/json ContentType. +type DeleteDnsRecordsDnsRecordJSONRequestBody DeleteDnsRecordsDnsRecordJSONBody + +// PatchDnsRecordsDnsRecordJSONRequestBody defines body for PatchDnsRecordsDnsRecord for application/json ContentType. +type PatchDnsRecordsDnsRecordJSONRequestBody PatchDnsRecordsDnsRecordJSONBody + +// DeleteDnsZonesDnsZoneJSONRequestBody defines body for DeleteDnsZonesDnsZone for application/json ContentType. +type DeleteDnsZonesDnsZoneJSONRequestBody DeleteDnsZonesDnsZoneJSONBody + +// PostDnsZonesDnsZoneRecordsJSONRequestBody defines body for PostDnsZonesDnsZoneRecords for application/json ContentType. +type PostDnsZonesDnsZoneRecordsJSONRequestBody PostDnsZonesDnsZoneRecordsJSONBody + +// PostDnsZonesDnsZoneUpdateTtlJSONRequestBody defines body for PostDnsZonesDnsZoneUpdateTtl for application/json ContentType. +type PostDnsZonesDnsZoneUpdateTtlJSONRequestBody PostDnsZonesDnsZoneUpdateTtlJSONBody + +// PostDnsZonesDnsZoneVerifyJSONRequestBody defines body for PostDnsZonesDnsZoneVerify for application/json ContentType. +type PostDnsZonesDnsZoneVerifyJSONRequestBody PostDnsZonesDnsZoneVerifyJSONBody + +// DeleteDnsRecordJSONRequestBody defines body for DeleteDnsRecord for application/json ContentType. +type DeleteDnsRecordJSONRequestBody DeleteDnsRecordJSONBody + +// PatchDnsRecordJSONRequestBody defines body for PatchDnsRecord for application/json ContentType. +type PatchDnsRecordJSONRequestBody PatchDnsRecordJSONBody + +// DeleteDnsZoneJSONRequestBody defines body for DeleteDnsZone for application/json ContentType. +type DeleteDnsZoneJSONRequestBody DeleteDnsZoneJSONBody + +// PatchDnsZoneJSONRequestBody defines body for PatchDnsZone for application/json ContentType. +type PatchDnsZoneJSONRequestBody PatchDnsZoneJSONBody + +// PostDnsZoneRecordsJSONRequestBody defines body for PostDnsZoneRecords for application/json ContentType. +type PostDnsZoneRecordsJSONRequestBody PostDnsZoneRecordsJSONBody + +// PostDnsZoneVerifyJSONRequestBody defines body for PostDnsZoneVerify for application/json ContentType. +type PostDnsZoneVerifyJSONRequestBody PostDnsZoneVerifyJSONBody + +// DeleteFileStorageVolumeJSONRequestBody defines body for DeleteFileStorageVolume for application/json ContentType. +type DeleteFileStorageVolumeJSONRequestBody DeleteFileStorageVolumeJSONBody + +// PatchFileStorageVolumeJSONRequestBody defines body for PatchFileStorageVolume for application/json ContentType. +type PatchFileStorageVolumeJSONRequestBody PatchFileStorageVolumeJSONBody + +// PostInvalidateLinkedWebSessionJSONRequestBody defines body for PostInvalidateLinkedWebSession for application/json ContentType. +type PostInvalidateLinkedWebSessionJSONRequestBody = PostInvalidateLinkedWebSessionJSONBody + +// DeleteIpAddressJSONRequestBody defines body for DeleteIpAddress for application/json ContentType. +type DeleteIpAddressJSONRequestBody DeleteIpAddressJSONBody + +// PatchIpAddressJSONRequestBody defines body for PatchIpAddress for application/json ContentType. +type PatchIpAddressJSONRequestBody PatchIpAddressJSONBody + +// PostIpAddressUnallocateJSONRequestBody defines body for PostIpAddressUnallocate for application/json ContentType. +type PostIpAddressUnallocateJSONRequestBody PostIpAddressUnallocateJSONBody + +// DeleteLoadBalancerJSONRequestBody defines body for DeleteLoadBalancer for application/json ContentType. +type DeleteLoadBalancerJSONRequestBody DeleteLoadBalancerJSONBody + +// PatchLoadBalancerJSONRequestBody defines body for PatchLoadBalancer for application/json ContentType. +type PatchLoadBalancerJSONRequestBody PatchLoadBalancerJSONBody + +// PostLoadBalancerRulesJSONRequestBody defines body for PostLoadBalancerRules for application/json ContentType. +type PostLoadBalancerRulesJSONRequestBody PostLoadBalancerRulesJSONBody + +// DeleteLoadBalancersRulesLoadBalancerRuleJSONRequestBody defines body for DeleteLoadBalancersRulesLoadBalancerRule for application/json ContentType. +type DeleteLoadBalancersRulesLoadBalancerRuleJSONRequestBody DeleteLoadBalancersRulesLoadBalancerRuleJSONBody + +// PatchLoadBalancersRulesLoadBalancerRuleJSONRequestBody defines body for PatchLoadBalancersRulesLoadBalancerRule for application/json ContentType. +type PatchLoadBalancersRulesLoadBalancerRuleJSONRequestBody PatchLoadBalancersRulesLoadBalancerRuleJSONBody + +// PostOrganizationDnsZonesJSONRequestBody defines body for PostOrganizationDnsZones for application/json ContentType. +type PostOrganizationDnsZonesJSONRequestBody PostOrganizationDnsZonesJSONBody + +// PostOrganizationsOrganizationdnsZonesJSONRequestBody defines body for PostOrganizationsOrganizationdnsZones for application/json ContentType. +type PostOrganizationsOrganizationdnsZonesJSONRequestBody PostOrganizationsOrganizationdnsZonesJSONBody + +// PostOrganizationFileStorageVolumesJSONRequestBody defines body for PostOrganizationFileStorageVolumes for application/json ContentType. +type PostOrganizationFileStorageVolumesJSONRequestBody PostOrganizationFileStorageVolumesJSONBody + +// PostOrganizationIpAddressesJSONRequestBody defines body for PostOrganizationIpAddresses for application/json ContentType. +type PostOrganizationIpAddressesJSONRequestBody PostOrganizationIpAddressesJSONBody + +// PostOrganizationLoadBalancersJSONRequestBody defines body for PostOrganizationLoadBalancers for application/json ContentType. +type PostOrganizationLoadBalancersJSONRequestBody PostOrganizationLoadBalancersJSONBody + +// PostOrganizationManagedJSONRequestBody defines body for PostOrganizationManaged for application/json ContentType. +type PostOrganizationManagedJSONRequestBody PostOrganizationManagedJSONBody + +// PostOrganizationSecurityGroupsJSONRequestBody defines body for PostOrganizationSecurityGroups for application/json ContentType. +type PostOrganizationSecurityGroupsJSONRequestBody PostOrganizationSecurityGroupsJSONBody + +// PostOrganizationSshKeysJSONRequestBody defines body for PostOrganizationSshKeys for application/json ContentType. +type PostOrganizationSshKeysJSONRequestBody PostOrganizationSshKeysJSONBody + +// PostOrganizationTagsJSONRequestBody defines body for PostOrganizationTags for application/json ContentType. +type PostOrganizationTagsJSONRequestBody PostOrganizationTagsJSONBody + +// PostOrganizationTrashObjectsPurgeAllJSONRequestBody defines body for PostOrganizationTrashObjectsPurgeAll for application/json ContentType. +type PostOrganizationTrashObjectsPurgeAllJSONRequestBody PostOrganizationTrashObjectsPurgeAllJSONBody + +// PostOrganizationVirtualMachineGroupsJSONRequestBody defines body for PostOrganizationVirtualMachineGroups for application/json ContentType. +type PostOrganizationVirtualMachineGroupsJSONRequestBody PostOrganizationVirtualMachineGroupsJSONBody + +// PostOrganizationVirtualMachinesBuildJSONRequestBody defines body for PostOrganizationVirtualMachinesBuild for application/json ContentType. +type PostOrganizationVirtualMachinesBuildJSONRequestBody PostOrganizationVirtualMachinesBuildJSONBody + +// PostOrganizationVirtualMachinesBuildFromSpecJSONRequestBody defines body for PostOrganizationVirtualMachinesBuildFromSpec for application/json ContentType. +type PostOrganizationVirtualMachinesBuildFromSpecJSONRequestBody PostOrganizationVirtualMachinesBuildFromSpecJSONBody + +// DeleteSecurityGroupJSONRequestBody defines body for DeleteSecurityGroup for application/json ContentType. +type DeleteSecurityGroupJSONRequestBody DeleteSecurityGroupJSONBody + +// PatchSecurityGroupJSONRequestBody defines body for PatchSecurityGroup for application/json ContentType. +type PatchSecurityGroupJSONRequestBody PatchSecurityGroupJSONBody + +// PostSecurityGroupRulesJSONRequestBody defines body for PostSecurityGroupRules for application/json ContentType. +type PostSecurityGroupRulesJSONRequestBody PostSecurityGroupRulesJSONBody + +// DeleteSecurityGroupsRulesSecurityGroupRuleJSONRequestBody defines body for DeleteSecurityGroupsRulesSecurityGroupRule for application/json ContentType. +type DeleteSecurityGroupsRulesSecurityGroupRuleJSONRequestBody DeleteSecurityGroupsRulesSecurityGroupRuleJSONBody + +// PatchSecurityGroupsRulesSecurityGroupRuleJSONRequestBody defines body for PatchSecurityGroupsRulesSecurityGroupRule for application/json ContentType. +type PatchSecurityGroupsRulesSecurityGroupRuleJSONRequestBody PatchSecurityGroupsRulesSecurityGroupRuleJSONBody + +// DeleteSshKeyJSONRequestBody defines body for DeleteSshKey for application/json ContentType. +type DeleteSshKeyJSONRequestBody DeleteSshKeyJSONBody + +// DeleteTagJSONRequestBody defines body for DeleteTag for application/json ContentType. +type DeleteTagJSONRequestBody DeleteTagJSONBody + +// PatchTagJSONRequestBody defines body for PatchTag for application/json ContentType. +type PatchTagJSONRequestBody PatchTagJSONBody + +// DeleteTrashObjectJSONRequestBody defines body for DeleteTrashObject for application/json ContentType. +type DeleteTrashObjectJSONRequestBody DeleteTrashObjectJSONBody + +// PostTrashObjectRestoreJSONRequestBody defines body for PostTrashObjectRestore for application/json ContentType. +type PostTrashObjectRestoreJSONRequestBody PostTrashObjectRestoreJSONBody + +// DeleteVirtualMachineGroupJSONRequestBody defines body for DeleteVirtualMachineGroup for application/json ContentType. +type DeleteVirtualMachineGroupJSONRequestBody DeleteVirtualMachineGroupJSONBody + +// PatchVirtualMachineGroupJSONRequestBody defines body for PatchVirtualMachineGroup for application/json ContentType. +type PatchVirtualMachineGroupJSONRequestBody PatchVirtualMachineGroupJSONBody + +// PostVirtualMachineNetworkInterfaceAllocateIpJSONRequestBody defines body for PostVirtualMachineNetworkInterfaceAllocateIp for application/json ContentType. +type PostVirtualMachineNetworkInterfaceAllocateIpJSONRequestBody PostVirtualMachineNetworkInterfaceAllocateIpJSONBody + +// PostVirtualMachineNetworkInterfaceAllocateNewIpJSONRequestBody defines body for PostVirtualMachineNetworkInterfaceAllocateNewIp for application/json ContentType. +type PostVirtualMachineNetworkInterfaceAllocateNewIpJSONRequestBody PostVirtualMachineNetworkInterfaceAllocateNewIpJSONBody + +// PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONRequestBody defines body for PatchVirtualMachineNetworkInterfaceUpdateSpeedProfile for application/json ContentType. +type PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONRequestBody PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONBody + +// DeleteVirtualMachineJSONRequestBody defines body for DeleteVirtualMachine for application/json ContentType. +type DeleteVirtualMachineJSONRequestBody DeleteVirtualMachineJSONBody + +// PatchVirtualMachineJSONRequestBody defines body for PatchVirtualMachine for application/json ContentType. +type PatchVirtualMachineJSONRequestBody PatchVirtualMachineJSONBody + +// PostVirtualMachineAllocateIpJSONRequestBody defines body for PostVirtualMachineAllocateIp for application/json ContentType. +type PostVirtualMachineAllocateIpJSONRequestBody PostVirtualMachineAllocateIpJSONBody + +// PostVirtualMachineConsoleSessionsJSONRequestBody defines body for PostVirtualMachineConsoleSessions for application/json ContentType. +type PostVirtualMachineConsoleSessionsJSONRequestBody PostVirtualMachineConsoleSessionsJSONBody + +// PostVirtualMachineDiskBackupPoliciesJSONRequestBody defines body for PostVirtualMachineDiskBackupPolicies for application/json ContentType. +type PostVirtualMachineDiskBackupPoliciesJSONRequestBody PostVirtualMachineDiskBackupPoliciesJSONBody + +// PutVirtualMachineFlexibleResourcesJSONRequestBody defines body for PutVirtualMachineFlexibleResources for application/json ContentType. +type PutVirtualMachineFlexibleResourcesJSONRequestBody PutVirtualMachineFlexibleResourcesJSONBody + +// PutVirtualMachinePackageJSONRequestBody defines body for PutVirtualMachinePackage for application/json ContentType. +type PutVirtualMachinePackageJSONRequestBody PutVirtualMachinePackageJSONBody + +// PostVirtualMachineResetJSONRequestBody defines body for PostVirtualMachineReset for application/json ContentType. +type PostVirtualMachineResetJSONRequestBody PostVirtualMachineResetJSONBody + +// PostVirtualMachineShutdownJSONRequestBody defines body for PostVirtualMachineShutdown for application/json ContentType. +type PostVirtualMachineShutdownJSONRequestBody PostVirtualMachineShutdownJSONBody + +// PostVirtualMachineStartJSONRequestBody defines body for PostVirtualMachineStart for application/json ContentType. +type PostVirtualMachineStartJSONRequestBody PostVirtualMachineStartJSONBody + +// PostVirtualMachineStopJSONRequestBody defines body for PostVirtualMachineStop for application/json ContentType. +type PostVirtualMachineStopJSONRequestBody PostVirtualMachineStopJSONBody + +// AsA returns the union data inside the DNSRecordProperties_Properties as a A +func (t DNSRecordProperties_Properties) AsA() (A, error) { + var body A + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromA overwrites any union data inside the DNSRecordProperties_Properties as the provided A +func (t *DNSRecordProperties_Properties) FromA(v A) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeA performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided A +func (t *DNSRecordProperties_Properties) MergeA(v A) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsAAAA returns the union data inside the DNSRecordProperties_Properties as a AAAA +func (t DNSRecordProperties_Properties) AsAAAA() (AAAA, error) { + var body AAAA + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromAAAA overwrites any union data inside the DNSRecordProperties_Properties as the provided AAAA +func (t *DNSRecordProperties_Properties) FromAAAA(v AAAA) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeAAAA performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided AAAA +func (t *DNSRecordProperties_Properties) MergeAAAA(v AAAA) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsCAA returns the union data inside the DNSRecordProperties_Properties as a CAA +func (t DNSRecordProperties_Properties) AsCAA() (CAA, error) { + var body CAA + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromCAA overwrites any union data inside the DNSRecordProperties_Properties as the provided CAA +func (t *DNSRecordProperties_Properties) FromCAA(v CAA) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeCAA performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided CAA +func (t *DNSRecordProperties_Properties) MergeCAA(v CAA) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsCNAME returns the union data inside the DNSRecordProperties_Properties as a CNAME +func (t DNSRecordProperties_Properties) AsCNAME() (CNAME, error) { + var body CNAME + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromCNAME overwrites any union data inside the DNSRecordProperties_Properties as the provided CNAME +func (t *DNSRecordProperties_Properties) FromCNAME(v CNAME) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeCNAME performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided CNAME +func (t *DNSRecordProperties_Properties) MergeCNAME(v CNAME) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsMX returns the union data inside the DNSRecordProperties_Properties as a MX +func (t DNSRecordProperties_Properties) AsMX() (MX, error) { + var body MX + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromMX overwrites any union data inside the DNSRecordProperties_Properties as the provided MX +func (t *DNSRecordProperties_Properties) FromMX(v MX) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeMX performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided MX +func (t *DNSRecordProperties_Properties) MergeMX(v MX) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsNS returns the union data inside the DNSRecordProperties_Properties as a NS +func (t DNSRecordProperties_Properties) AsNS() (NS, error) { + var body NS + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromNS overwrites any union data inside the DNSRecordProperties_Properties as the provided NS +func (t *DNSRecordProperties_Properties) FromNS(v NS) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeNS performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided NS +func (t *DNSRecordProperties_Properties) MergeNS(v NS) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsSRV returns the union data inside the DNSRecordProperties_Properties as a SRV +func (t DNSRecordProperties_Properties) AsSRV() (SRV, error) { + var body SRV + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromSRV overwrites any union data inside the DNSRecordProperties_Properties as the provided SRV +func (t *DNSRecordProperties_Properties) FromSRV(v SRV) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeSRV performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided SRV +func (t *DNSRecordProperties_Properties) MergeSRV(v SRV) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsSSHFP returns the union data inside the DNSRecordProperties_Properties as a SSHFP +func (t DNSRecordProperties_Properties) AsSSHFP() (SSHFP, error) { + var body SSHFP + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromSSHFP overwrites any union data inside the DNSRecordProperties_Properties as the provided SSHFP +func (t *DNSRecordProperties_Properties) FromSSHFP(v SSHFP) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeSSHFP performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided SSHFP +func (t *DNSRecordProperties_Properties) MergeSSHFP(v SSHFP) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsTXT returns the union data inside the DNSRecordProperties_Properties as a TXT +func (t DNSRecordProperties_Properties) AsTXT() (TXT, error) { + var body TXT + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromTXT overwrites any union data inside the DNSRecordProperties_Properties as the provided TXT +func (t *DNSRecordProperties_Properties) FromTXT(v TXT) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeTXT performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided TXT +func (t *DNSRecordProperties_Properties) MergeTXT(v TXT) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsVirtualMachine returns the union data inside the DNSRecordProperties_Properties as a VirtualMachine +func (t DNSRecordProperties_Properties) AsVirtualMachine() (VirtualMachine, error) { + var body VirtualMachine + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachine overwrites any union data inside the DNSRecordProperties_Properties as the provided VirtualMachine +func (t *DNSRecordProperties_Properties) FromVirtualMachine(v VirtualMachine) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachine performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided VirtualMachine +func (t *DNSRecordProperties_Properties) MergeVirtualMachine(v VirtualMachine) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsALIAS returns the union data inside the DNSRecordProperties_Properties as a ALIAS +func (t DNSRecordProperties_Properties) AsALIAS() (ALIAS, error) { + var body ALIAS + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromALIAS overwrites any union data inside the DNSRecordProperties_Properties as the provided ALIAS +func (t *DNSRecordProperties_Properties) FromALIAS(v ALIAS) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeALIAS performs a merge with any union data inside the DNSRecordProperties_Properties, using the provided ALIAS +func (t *DNSRecordProperties_Properties) MergeALIAS(v ALIAS) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t DNSRecordProperties_Properties) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *DNSRecordProperties_Properties) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsVirtualMachine returns the union data inside the DiskBackupPolicyTarget_Target as a VirtualMachine +func (t DiskBackupPolicyTarget_Target) AsVirtualMachine() (VirtualMachine, error) { + var body VirtualMachine + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachine overwrites any union data inside the DiskBackupPolicyTarget_Target as the provided VirtualMachine +func (t *DiskBackupPolicyTarget_Target) FromVirtualMachine(v VirtualMachine) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachine performs a merge with any union data inside the DiskBackupPolicyTarget_Target, using the provided VirtualMachine +func (t *DiskBackupPolicyTarget_Target) MergeVirtualMachine(v VirtualMachine) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsDisk returns the union data inside the DiskBackupPolicyTarget_Target as a Disk +func (t DiskBackupPolicyTarget_Target) AsDisk() (Disk, error) { + var body Disk + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromDisk overwrites any union data inside the DiskBackupPolicyTarget_Target as the provided Disk +func (t *DiskBackupPolicyTarget_Target) FromDisk(v Disk) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeDisk performs a merge with any union data inside the DiskBackupPolicyTarget_Target, using the provided Disk +func (t *DiskBackupPolicyTarget_Target) MergeDisk(v Disk) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t DiskBackupPolicyTarget_Target) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *DiskBackupPolicyTarget_Target) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsVirtualMachine returns the union data inside the LoadBalancerResource_Resources as a VirtualMachine +func (t LoadBalancerResource_Resources) AsVirtualMachine() (VirtualMachine, error) { + var body VirtualMachine + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachine overwrites any union data inside the LoadBalancerResource_Resources as the provided VirtualMachine +func (t *LoadBalancerResource_Resources) FromVirtualMachine(v VirtualMachine) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachine performs a merge with any union data inside the LoadBalancerResource_Resources, using the provided VirtualMachine +func (t *LoadBalancerResource_Resources) MergeVirtualMachine(v VirtualMachine) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsVirtualMachineGroup returns the union data inside the LoadBalancerResource_Resources as a VirtualMachineGroup +func (t LoadBalancerResource_Resources) AsVirtualMachineGroup() (VirtualMachineGroup, error) { + var body VirtualMachineGroup + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachineGroup overwrites any union data inside the LoadBalancerResource_Resources as the provided VirtualMachineGroup +func (t *LoadBalancerResource_Resources) FromVirtualMachineGroup(v VirtualMachineGroup) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachineGroup performs a merge with any union data inside the LoadBalancerResource_Resources, using the provided VirtualMachineGroup +func (t *LoadBalancerResource_Resources) MergeVirtualMachineGroup(v VirtualMachineGroup) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsTag returns the union data inside the LoadBalancerResource_Resources as a Tag +func (t LoadBalancerResource_Resources) AsTag() (Tag, error) { + var body Tag + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromTag overwrites any union data inside the LoadBalancerResource_Resources as the provided Tag +func (t *LoadBalancerResource_Resources) FromTag(v Tag) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeTag performs a merge with any union data inside the LoadBalancerResource_Resources, using the provided Tag +func (t *LoadBalancerResource_Resources) MergeTag(v Tag) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t LoadBalancerResource_Resources) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *LoadBalancerResource_Resources) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsUnauthorizedNetworkForAPITokenSchema returns the union data inside the OneOfAPIAuthenticator403Response as a UnauthorizedNetworkForAPITokenSchema +func (t OneOfAPIAuthenticator403Response) AsUnauthorizedNetworkForAPITokenSchema() (UnauthorizedNetworkForAPITokenSchema, error) { + var body UnauthorizedNetworkForAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromUnauthorizedNetworkForAPITokenSchema overwrites any union data inside the OneOfAPIAuthenticator403Response as the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfAPIAuthenticator403Response) FromUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeUnauthorizedNetworkForAPITokenSchema performs a merge with any union data inside the OneOfAPIAuthenticator403Response, using the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfAPIAuthenticator403Response) MergeUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidAPITokenSchema returns the union data inside the OneOfAPIAuthenticator403Response as a InvalidAPITokenSchema +func (t OneOfAPIAuthenticator403Response) AsInvalidAPITokenSchema() (InvalidAPITokenSchema, error) { + var body InvalidAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidAPITokenSchema overwrites any union data inside the OneOfAPIAuthenticator403Response as the provided InvalidAPITokenSchema +func (t *OneOfAPIAuthenticator403Response) FromInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidAPITokenSchema performs a merge with any union data inside the OneOfAPIAuthenticator403Response, using the provided InvalidAPITokenSchema +func (t *OneOfAPIAuthenticator403Response) MergeInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsScopeNotGrantedErrorSchema returns the union data inside the OneOfAPIAuthenticator403Response as a ScopeNotGrantedErrorSchema +func (t OneOfAPIAuthenticator403Response) AsScopeNotGrantedErrorSchema() (ScopeNotGrantedErrorSchema, error) { + var body ScopeNotGrantedErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromScopeNotGrantedErrorSchema overwrites any union data inside the OneOfAPIAuthenticator403Response as the provided ScopeNotGrantedErrorSchema +func (t *OneOfAPIAuthenticator403Response) FromScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeScopeNotGrantedErrorSchema performs a merge with any union data inside the OneOfAPIAuthenticator403Response, using the provided ScopeNotGrantedErrorSchema +func (t *OneOfAPIAuthenticator403Response) MergeScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfAPIAuthenticator403Response) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfAPIAuthenticator403Response) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsOrganizationNotFoundSchema returns the union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as a OrganizationNotFoundSchema +func (t OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) AsOrganizationNotFoundSchema() (OrganizationNotFoundSchema, error) { + var body OrganizationNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationNotFoundSchema overwrites any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as the provided OrganizationNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) FromOrganizationNotFoundSchema(v OrganizationNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationNotFoundSchema performs a merge with any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res, using the provided OrganizationNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) MergeOrganizationNotFoundSchema(v OrganizationNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsZoneNotFoundSchema returns the union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as a ZoneNotFoundSchema +func (t OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) AsZoneNotFoundSchema() (ZoneNotFoundSchema, error) { + var body ZoneNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromZoneNotFoundSchema overwrites any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as the provided ZoneNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) FromZoneNotFoundSchema(v ZoneNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeZoneNotFoundSchema performs a merge with any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res, using the provided ZoneNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) MergeZoneNotFoundSchema(v ZoneNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsDataCenterNotFoundSchema returns the union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as a DataCenterNotFoundSchema +func (t OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) AsDataCenterNotFoundSchema() (DataCenterNotFoundSchema, error) { + var body DataCenterNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromDataCenterNotFoundSchema overwrites any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as the provided DataCenterNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) FromDataCenterNotFoundSchema(v DataCenterNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeDataCenterNotFoundSchema performs a merge with any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res, using the provided DataCenterNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) MergeDataCenterNotFoundSchema(v DataCenterNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsVirtualMachinePackageNotFoundSchema returns the union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as a VirtualMachinePackageNotFoundSchema +func (t OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) AsVirtualMachinePackageNotFoundSchema() (VirtualMachinePackageNotFoundSchema, error) { + var body VirtualMachinePackageNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachinePackageNotFoundSchema overwrites any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as the provided VirtualMachinePackageNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) FromVirtualMachinePackageNotFoundSchema(v VirtualMachinePackageNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachinePackageNotFoundSchema performs a merge with any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res, using the provided VirtualMachinePackageNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) MergeVirtualMachinePackageNotFoundSchema(v VirtualMachinePackageNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsDiskTemplateNotFoundSchema returns the union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as a DiskTemplateNotFoundSchema +func (t OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) AsDiskTemplateNotFoundSchema() (DiskTemplateNotFoundSchema, error) { + var body DiskTemplateNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromDiskTemplateNotFoundSchema overwrites any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as the provided DiskTemplateNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) FromDiskTemplateNotFoundSchema(v DiskTemplateNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeDiskTemplateNotFoundSchema performs a merge with any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res, using the provided DiskTemplateNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) MergeDiskTemplateNotFoundSchema(v DiskTemplateNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsNetworkNotFoundSchema returns the union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as a NetworkNotFoundSchema +func (t OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) AsNetworkNotFoundSchema() (NetworkNotFoundSchema, error) { + var body NetworkNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromNetworkNotFoundSchema overwrites any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res as the provided NetworkNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) FromNetworkNotFoundSchema(v NetworkNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeNetworkNotFoundSchema performs a merge with any union data inside the OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res, using the provided NetworkNotFoundSchema +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) MergeNetworkNotFoundSchema(v NetworkNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfDataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsUnauthorizedNetworkForAPITokenSchema returns the union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as a UnauthorizedNetworkForAPITokenSchema +func (t OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) AsUnauthorizedNetworkForAPITokenSchema() (UnauthorizedNetworkForAPITokenSchema, error) { + var body UnauthorizedNetworkForAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromUnauthorizedNetworkForAPITokenSchema overwrites any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) FromUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeUnauthorizedNetworkForAPITokenSchema performs a merge with any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res, using the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) MergeUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidAPITokenSchema returns the union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as a InvalidAPITokenSchema +func (t OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) AsInvalidAPITokenSchema() (InvalidAPITokenSchema, error) { + var body InvalidAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidAPITokenSchema overwrites any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as the provided InvalidAPITokenSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) FromInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidAPITokenSchema performs a merge with any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res, using the provided InvalidAPITokenSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) MergeInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsScopeNotGrantedErrorSchema returns the union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as a ScopeNotGrantedErrorSchema +func (t OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) AsScopeNotGrantedErrorSchema() (ScopeNotGrantedErrorSchema, error) { + var body ScopeNotGrantedErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromScopeNotGrantedErrorSchema overwrites any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as the provided ScopeNotGrantedErrorSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) FromScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeScopeNotGrantedErrorSchema performs a merge with any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res, using the provided ScopeNotGrantedErrorSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) MergeScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsPermissionDeniedSchema returns the union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as a PermissionDeniedSchema +func (t OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) AsPermissionDeniedSchema() (PermissionDeniedSchema, error) { + var body PermissionDeniedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromPermissionDeniedSchema overwrites any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as the provided PermissionDeniedSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) FromPermissionDeniedSchema(v PermissionDeniedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergePermissionDeniedSchema performs a merge with any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res, using the provided PermissionDeniedSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) MergePermissionDeniedSchema(v PermissionDeniedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsFlexibleResourcesUnavailableToOrganizationSchema returns the union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as a FlexibleResourcesUnavailableToOrganizationSchema +func (t OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) AsFlexibleResourcesUnavailableToOrganizationSchema() (FlexibleResourcesUnavailableToOrganizationSchema, error) { + var body FlexibleResourcesUnavailableToOrganizationSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromFlexibleResourcesUnavailableToOrganizationSchema overwrites any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res as the provided FlexibleResourcesUnavailableToOrganizationSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) FromFlexibleResourcesUnavailableToOrganizationSchema(v FlexibleResourcesUnavailableToOrganizationSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeFlexibleResourcesUnavailableToOrganizationSchema performs a merge with any union data inside the OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res, using the provided FlexibleResourcesUnavailableToOrganizationSchema +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) MergeFlexibleResourcesUnavailableToOrganizationSchema(v FlexibleResourcesUnavailableToOrganizationSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfFlexibleResourcesUnavailableToOrganizationPermissionDenied403Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsVirtualMachineNetworkInterfaceNotFoundSchema returns the union data inside the OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res as a VirtualMachineNetworkInterfaceNotFoundSchema +func (t OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res) AsVirtualMachineNetworkInterfaceNotFoundSchema() (VirtualMachineNetworkInterfaceNotFoundSchema, error) { + var body VirtualMachineNetworkInterfaceNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachineNetworkInterfaceNotFoundSchema overwrites any union data inside the OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res as the provided VirtualMachineNetworkInterfaceNotFoundSchema +func (t *OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res) FromVirtualMachineNetworkInterfaceNotFoundSchema(v VirtualMachineNetworkInterfaceNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachineNetworkInterfaceNotFoundSchema performs a merge with any union data inside the OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res, using the provided VirtualMachineNetworkInterfaceNotFoundSchema +func (t *OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res) MergeVirtualMachineNetworkInterfaceNotFoundSchema(v VirtualMachineNetworkInterfaceNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsIPAddressNotFoundSchema returns the union data inside the OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res as a IPAddressNotFoundSchema +func (t OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res) AsIPAddressNotFoundSchema() (IPAddressNotFoundSchema, error) { + var body IPAddressNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromIPAddressNotFoundSchema overwrites any union data inside the OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res as the provided IPAddressNotFoundSchema +func (t *OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res) FromIPAddressNotFoundSchema(v IPAddressNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeIPAddressNotFoundSchema performs a merge with any union data inside the OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res, using the provided IPAddressNotFoundSchema +func (t *OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res) MergeIPAddressNotFoundSchema(v IPAddressNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfIPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsVirtualMachineNotFoundSchema returns the union data inside the OneOfIPAddressNotFoundVirtualMachineNotFound404Res as a VirtualMachineNotFoundSchema +func (t OneOfIPAddressNotFoundVirtualMachineNotFound404Res) AsVirtualMachineNotFoundSchema() (VirtualMachineNotFoundSchema, error) { + var body VirtualMachineNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachineNotFoundSchema overwrites any union data inside the OneOfIPAddressNotFoundVirtualMachineNotFound404Res as the provided VirtualMachineNotFoundSchema +func (t *OneOfIPAddressNotFoundVirtualMachineNotFound404Res) FromVirtualMachineNotFoundSchema(v VirtualMachineNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachineNotFoundSchema performs a merge with any union data inside the OneOfIPAddressNotFoundVirtualMachineNotFound404Res, using the provided VirtualMachineNotFoundSchema +func (t *OneOfIPAddressNotFoundVirtualMachineNotFound404Res) MergeVirtualMachineNotFoundSchema(v VirtualMachineNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsIPAddressNotFoundSchema returns the union data inside the OneOfIPAddressNotFoundVirtualMachineNotFound404Res as a IPAddressNotFoundSchema +func (t OneOfIPAddressNotFoundVirtualMachineNotFound404Res) AsIPAddressNotFoundSchema() (IPAddressNotFoundSchema, error) { + var body IPAddressNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromIPAddressNotFoundSchema overwrites any union data inside the OneOfIPAddressNotFoundVirtualMachineNotFound404Res as the provided IPAddressNotFoundSchema +func (t *OneOfIPAddressNotFoundVirtualMachineNotFound404Res) FromIPAddressNotFoundSchema(v IPAddressNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeIPAddressNotFoundSchema performs a merge with any union data inside the OneOfIPAddressNotFoundVirtualMachineNotFound404Res, using the provided IPAddressNotFoundSchema +func (t *OneOfIPAddressNotFoundVirtualMachineNotFound404Res) MergeIPAddressNotFoundSchema(v IPAddressNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfIPAddressNotFoundVirtualMachineNotFound404Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfIPAddressNotFoundVirtualMachineNotFound404Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsIPAlreadyAllocatedSchema returns the union data inside the OneOfIPAlreadyAllocatedInvalidIP422Res as a IPAlreadyAllocatedSchema +func (t OneOfIPAlreadyAllocatedInvalidIP422Res) AsIPAlreadyAllocatedSchema() (IPAlreadyAllocatedSchema, error) { + var body IPAlreadyAllocatedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromIPAlreadyAllocatedSchema overwrites any union data inside the OneOfIPAlreadyAllocatedInvalidIP422Res as the provided IPAlreadyAllocatedSchema +func (t *OneOfIPAlreadyAllocatedInvalidIP422Res) FromIPAlreadyAllocatedSchema(v IPAlreadyAllocatedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeIPAlreadyAllocatedSchema performs a merge with any union data inside the OneOfIPAlreadyAllocatedInvalidIP422Res, using the provided IPAlreadyAllocatedSchema +func (t *OneOfIPAlreadyAllocatedInvalidIP422Res) MergeIPAlreadyAllocatedSchema(v IPAlreadyAllocatedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidIPSchema returns the union data inside the OneOfIPAlreadyAllocatedInvalidIP422Res as a InvalidIPSchema +func (t OneOfIPAlreadyAllocatedInvalidIP422Res) AsInvalidIPSchema() (InvalidIPSchema, error) { + var body InvalidIPSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidIPSchema overwrites any union data inside the OneOfIPAlreadyAllocatedInvalidIP422Res as the provided InvalidIPSchema +func (t *OneOfIPAlreadyAllocatedInvalidIP422Res) FromInvalidIPSchema(v InvalidIPSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidIPSchema performs a merge with any union data inside the OneOfIPAlreadyAllocatedInvalidIP422Res, using the provided InvalidIPSchema +func (t *OneOfIPAlreadyAllocatedInvalidIP422Res) MergeInvalidIPSchema(v InvalidIPSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfIPAlreadyAllocatedInvalidIP422Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfIPAlreadyAllocatedInvalidIP422Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsNoInterfaceAvailableSchema returns the union data inside the OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res as a NoInterfaceAvailableSchema +func (t OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res) AsNoInterfaceAvailableSchema() (NoInterfaceAvailableSchema, error) { + var body NoInterfaceAvailableSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromNoInterfaceAvailableSchema overwrites any union data inside the OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res as the provided NoInterfaceAvailableSchema +func (t *OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res) FromNoInterfaceAvailableSchema(v NoInterfaceAvailableSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeNoInterfaceAvailableSchema performs a merge with any union data inside the OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res, using the provided NoInterfaceAvailableSchema +func (t *OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res) MergeNoInterfaceAvailableSchema(v NoInterfaceAvailableSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsIPAlreadyAllocatedSchema returns the union data inside the OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res as a IPAlreadyAllocatedSchema +func (t OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res) AsIPAlreadyAllocatedSchema() (IPAlreadyAllocatedSchema, error) { + var body IPAlreadyAllocatedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromIPAlreadyAllocatedSchema overwrites any union data inside the OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res as the provided IPAlreadyAllocatedSchema +func (t *OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res) FromIPAlreadyAllocatedSchema(v IPAlreadyAllocatedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeIPAlreadyAllocatedSchema performs a merge with any union data inside the OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res, using the provided IPAlreadyAllocatedSchema +func (t *OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res) MergeIPAlreadyAllocatedSchema(v IPAlreadyAllocatedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfIPAlreadyAllocatedNoInterfaceAvailable422Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsAPIAuthenticator400Schema returns the union data inside the OneOfIdentityNotLinkedToWebSession400Res as a APIAuthenticator400Schema +func (t OneOfIdentityNotLinkedToWebSession400Res) AsAPIAuthenticator400Schema() (APIAuthenticator400Schema, error) { + var body APIAuthenticator400Schema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromAPIAuthenticator400Schema overwrites any union data inside the OneOfIdentityNotLinkedToWebSession400Res as the provided APIAuthenticator400Schema +func (t *OneOfIdentityNotLinkedToWebSession400Res) FromAPIAuthenticator400Schema(v APIAuthenticator400Schema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeAPIAuthenticator400Schema performs a merge with any union data inside the OneOfIdentityNotLinkedToWebSession400Res, using the provided APIAuthenticator400Schema +func (t *OneOfIdentityNotLinkedToWebSession400Res) MergeAPIAuthenticator400Schema(v APIAuthenticator400Schema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsIdentityNotLinkedToWebSessionSchema returns the union data inside the OneOfIdentityNotLinkedToWebSession400Res as a IdentityNotLinkedToWebSessionSchema +func (t OneOfIdentityNotLinkedToWebSession400Res) AsIdentityNotLinkedToWebSessionSchema() (IdentityNotLinkedToWebSessionSchema, error) { + var body IdentityNotLinkedToWebSessionSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromIdentityNotLinkedToWebSessionSchema overwrites any union data inside the OneOfIdentityNotLinkedToWebSession400Res as the provided IdentityNotLinkedToWebSessionSchema +func (t *OneOfIdentityNotLinkedToWebSession400Res) FromIdentityNotLinkedToWebSessionSchema(v IdentityNotLinkedToWebSessionSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeIdentityNotLinkedToWebSessionSchema performs a merge with any union data inside the OneOfIdentityNotLinkedToWebSession400Res, using the provided IdentityNotLinkedToWebSessionSchema +func (t *OneOfIdentityNotLinkedToWebSession400Res) MergeIdentityNotLinkedToWebSessionSchema(v IdentityNotLinkedToWebSessionSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfIdentityNotLinkedToWebSession400Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfIdentityNotLinkedToWebSession400Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsUnauthorizedNetworkForAPITokenSchema returns the union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res as a UnauthorizedNetworkForAPITokenSchema +func (t OneOfInfrastructureDNSZoneCannotBeEdited403Res) AsUnauthorizedNetworkForAPITokenSchema() (UnauthorizedNetworkForAPITokenSchema, error) { + var body UnauthorizedNetworkForAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromUnauthorizedNetworkForAPITokenSchema overwrites any union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res as the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) FromUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeUnauthorizedNetworkForAPITokenSchema performs a merge with any union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res, using the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) MergeUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidAPITokenSchema returns the union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res as a InvalidAPITokenSchema +func (t OneOfInfrastructureDNSZoneCannotBeEdited403Res) AsInvalidAPITokenSchema() (InvalidAPITokenSchema, error) { + var body InvalidAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidAPITokenSchema overwrites any union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res as the provided InvalidAPITokenSchema +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) FromInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidAPITokenSchema performs a merge with any union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res, using the provided InvalidAPITokenSchema +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) MergeInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsScopeNotGrantedErrorSchema returns the union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res as a ScopeNotGrantedErrorSchema +func (t OneOfInfrastructureDNSZoneCannotBeEdited403Res) AsScopeNotGrantedErrorSchema() (ScopeNotGrantedErrorSchema, error) { + var body ScopeNotGrantedErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromScopeNotGrantedErrorSchema overwrites any union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res as the provided ScopeNotGrantedErrorSchema +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) FromScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeScopeNotGrantedErrorSchema performs a merge with any union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res, using the provided ScopeNotGrantedErrorSchema +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) MergeScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInfrastructureDNSZoneCannotBeEditedSchema returns the union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res as a InfrastructureDNSZoneCannotBeEditedSchema +func (t OneOfInfrastructureDNSZoneCannotBeEdited403Res) AsInfrastructureDNSZoneCannotBeEditedSchema() (InfrastructureDNSZoneCannotBeEditedSchema, error) { + var body InfrastructureDNSZoneCannotBeEditedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInfrastructureDNSZoneCannotBeEditedSchema overwrites any union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res as the provided InfrastructureDNSZoneCannotBeEditedSchema +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) FromInfrastructureDNSZoneCannotBeEditedSchema(v InfrastructureDNSZoneCannotBeEditedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInfrastructureDNSZoneCannotBeEditedSchema performs a merge with any union data inside the OneOfInfrastructureDNSZoneCannotBeEdited403Res, using the provided InfrastructureDNSZoneCannotBeEditedSchema +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) MergeInfrastructureDNSZoneCannotBeEditedSchema(v InfrastructureDNSZoneCannotBeEditedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfInfrastructureDNSZoneCannotBeEdited403Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfInfrastructureDNSZoneCannotBeEdited403Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsVirtualMachineNotFoundSchema returns the union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res as a VirtualMachineNotFoundSchema +func (t OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) AsVirtualMachineNotFoundSchema() (VirtualMachineNotFoundSchema, error) { + var body VirtualMachineNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachineNotFoundSchema overwrites any union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res as the provided VirtualMachineNotFoundSchema +func (t *OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) FromVirtualMachineNotFoundSchema(v VirtualMachineNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachineNotFoundSchema performs a merge with any union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res, using the provided VirtualMachineNotFoundSchema +func (t *OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) MergeVirtualMachineNotFoundSchema(v VirtualMachineNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsNetworkNotFoundSchema returns the union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res as a NetworkNotFoundSchema +func (t OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) AsNetworkNotFoundSchema() (NetworkNotFoundSchema, error) { + var body NetworkNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromNetworkNotFoundSchema overwrites any union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res as the provided NetworkNotFoundSchema +func (t *OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) FromNetworkNotFoundSchema(v NetworkNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeNetworkNotFoundSchema performs a merge with any union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res, using the provided NetworkNotFoundSchema +func (t *OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) MergeNetworkNotFoundSchema(v NetworkNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInterfaceNotFoundSchema returns the union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res as a InterfaceNotFoundSchema +func (t OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) AsInterfaceNotFoundSchema() (InterfaceNotFoundSchema, error) { + var body InterfaceNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInterfaceNotFoundSchema overwrites any union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res as the provided InterfaceNotFoundSchema +func (t *OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) FromInterfaceNotFoundSchema(v InterfaceNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInterfaceNotFoundSchema performs a merge with any union data inside the OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res, using the provided InterfaceNotFoundSchema +func (t *OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) MergeInterfaceNotFoundSchema(v InterfaceNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfInterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsAPIAuthenticator400Schema returns the union data inside the OneOfInvalidSpecXML400Res as a APIAuthenticator400Schema +func (t OneOfInvalidSpecXML400Res) AsAPIAuthenticator400Schema() (APIAuthenticator400Schema, error) { + var body APIAuthenticator400Schema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromAPIAuthenticator400Schema overwrites any union data inside the OneOfInvalidSpecXML400Res as the provided APIAuthenticator400Schema +func (t *OneOfInvalidSpecXML400Res) FromAPIAuthenticator400Schema(v APIAuthenticator400Schema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeAPIAuthenticator400Schema performs a merge with any union data inside the OneOfInvalidSpecXML400Res, using the provided APIAuthenticator400Schema +func (t *OneOfInvalidSpecXML400Res) MergeAPIAuthenticator400Schema(v APIAuthenticator400Schema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidSpecXMLSchema returns the union data inside the OneOfInvalidSpecXML400Res as a InvalidSpecXMLSchema +func (t OneOfInvalidSpecXML400Res) AsInvalidSpecXMLSchema() (InvalidSpecXMLSchema, error) { + var body InvalidSpecXMLSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidSpecXMLSchema overwrites any union data inside the OneOfInvalidSpecXML400Res as the provided InvalidSpecXMLSchema +func (t *OneOfInvalidSpecXML400Res) FromInvalidSpecXMLSchema(v InvalidSpecXMLSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidSpecXMLSchema performs a merge with any union data inside the OneOfInvalidSpecXML400Res, using the provided InvalidSpecXMLSchema +func (t *OneOfInvalidSpecXML400Res) MergeInvalidSpecXMLSchema(v InvalidSpecXMLSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfInvalidSpecXML400Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfInvalidSpecXML400Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsAPIAuthenticator400Schema returns the union data inside the OneOfInvalidTimestamp400Res as a APIAuthenticator400Schema +func (t OneOfInvalidTimestamp400Res) AsAPIAuthenticator400Schema() (APIAuthenticator400Schema, error) { + var body APIAuthenticator400Schema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromAPIAuthenticator400Schema overwrites any union data inside the OneOfInvalidTimestamp400Res as the provided APIAuthenticator400Schema +func (t *OneOfInvalidTimestamp400Res) FromAPIAuthenticator400Schema(v APIAuthenticator400Schema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeAPIAuthenticator400Schema performs a merge with any union data inside the OneOfInvalidTimestamp400Res, using the provided APIAuthenticator400Schema +func (t *OneOfInvalidTimestamp400Res) MergeAPIAuthenticator400Schema(v APIAuthenticator400Schema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidTimestampSchema returns the union data inside the OneOfInvalidTimestamp400Res as a InvalidTimestampSchema +func (t OneOfInvalidTimestamp400Res) AsInvalidTimestampSchema() (InvalidTimestampSchema, error) { + var body InvalidTimestampSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidTimestampSchema overwrites any union data inside the OneOfInvalidTimestamp400Res as the provided InvalidTimestampSchema +func (t *OneOfInvalidTimestamp400Res) FromInvalidTimestampSchema(v InvalidTimestampSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidTimestampSchema performs a merge with any union data inside the OneOfInvalidTimestamp400Res, using the provided InvalidTimestampSchema +func (t *OneOfInvalidTimestamp400Res) MergeInvalidTimestampSchema(v InvalidTimestampSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfInvalidTimestamp400Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfInvalidTimestamp400Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsValidationErrorSchema returns the union data inside the OneOfLocationRequiredValidationError422Res as a ValidationErrorSchema +func (t OneOfLocationRequiredValidationError422Res) AsValidationErrorSchema() (ValidationErrorSchema, error) { + var body ValidationErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromValidationErrorSchema overwrites any union data inside the OneOfLocationRequiredValidationError422Res as the provided ValidationErrorSchema +func (t *OneOfLocationRequiredValidationError422Res) FromValidationErrorSchema(v ValidationErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeValidationErrorSchema performs a merge with any union data inside the OneOfLocationRequiredValidationError422Res, using the provided ValidationErrorSchema +func (t *OneOfLocationRequiredValidationError422Res) MergeValidationErrorSchema(v ValidationErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsLocationRequiredSchema returns the union data inside the OneOfLocationRequiredValidationError422Res as a LocationRequiredSchema +func (t OneOfLocationRequiredValidationError422Res) AsLocationRequiredSchema() (LocationRequiredSchema, error) { + var body LocationRequiredSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromLocationRequiredSchema overwrites any union data inside the OneOfLocationRequiredValidationError422Res as the provided LocationRequiredSchema +func (t *OneOfLocationRequiredValidationError422Res) FromLocationRequiredSchema(v LocationRequiredSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeLocationRequiredSchema performs a merge with any union data inside the OneOfLocationRequiredValidationError422Res, using the provided LocationRequiredSchema +func (t *OneOfLocationRequiredValidationError422Res) MergeLocationRequiredSchema(v LocationRequiredSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfLocationRequiredValidationError422Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfLocationRequiredValidationError422Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsOrganizationNotFoundSchema returns the union data inside the OneOfNetworkNotFoundOrganizationNotFound404Res as a OrganizationNotFoundSchema +func (t OneOfNetworkNotFoundOrganizationNotFound404Res) AsOrganizationNotFoundSchema() (OrganizationNotFoundSchema, error) { + var body OrganizationNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationNotFoundSchema overwrites any union data inside the OneOfNetworkNotFoundOrganizationNotFound404Res as the provided OrganizationNotFoundSchema +func (t *OneOfNetworkNotFoundOrganizationNotFound404Res) FromOrganizationNotFoundSchema(v OrganizationNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationNotFoundSchema performs a merge with any union data inside the OneOfNetworkNotFoundOrganizationNotFound404Res, using the provided OrganizationNotFoundSchema +func (t *OneOfNetworkNotFoundOrganizationNotFound404Res) MergeOrganizationNotFoundSchema(v OrganizationNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsNetworkNotFoundSchema returns the union data inside the OneOfNetworkNotFoundOrganizationNotFound404Res as a NetworkNotFoundSchema +func (t OneOfNetworkNotFoundOrganizationNotFound404Res) AsNetworkNotFoundSchema() (NetworkNotFoundSchema, error) { + var body NetworkNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromNetworkNotFoundSchema overwrites any union data inside the OneOfNetworkNotFoundOrganizationNotFound404Res as the provided NetworkNotFoundSchema +func (t *OneOfNetworkNotFoundOrganizationNotFound404Res) FromNetworkNotFoundSchema(v NetworkNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeNetworkNotFoundSchema performs a merge with any union data inside the OneOfNetworkNotFoundOrganizationNotFound404Res, using the provided NetworkNotFoundSchema +func (t *OneOfNetworkNotFoundOrganizationNotFound404Res) MergeNetworkNotFoundSchema(v NetworkNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfNetworkNotFoundOrganizationNotFound404Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfNetworkNotFoundOrganizationNotFound404Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsVirtualMachineNetworkInterfaceNotFoundSchema returns the union data inside the OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res as a VirtualMachineNetworkInterfaceNotFoundSchema +func (t OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res) AsVirtualMachineNetworkInterfaceNotFoundSchema() (VirtualMachineNetworkInterfaceNotFoundSchema, error) { + var body VirtualMachineNetworkInterfaceNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachineNetworkInterfaceNotFoundSchema overwrites any union data inside the OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res as the provided VirtualMachineNetworkInterfaceNotFoundSchema +func (t *OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res) FromVirtualMachineNetworkInterfaceNotFoundSchema(v VirtualMachineNetworkInterfaceNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachineNetworkInterfaceNotFoundSchema performs a merge with any union data inside the OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res, using the provided VirtualMachineNetworkInterfaceNotFoundSchema +func (t *OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res) MergeVirtualMachineNetworkInterfaceNotFoundSchema(v VirtualMachineNetworkInterfaceNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsNetworkSpeedProfileNotFoundSchema returns the union data inside the OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res as a NetworkSpeedProfileNotFoundSchema +func (t OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res) AsNetworkSpeedProfileNotFoundSchema() (NetworkSpeedProfileNotFoundSchema, error) { + var body NetworkSpeedProfileNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromNetworkSpeedProfileNotFoundSchema overwrites any union data inside the OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res as the provided NetworkSpeedProfileNotFoundSchema +func (t *OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res) FromNetworkSpeedProfileNotFoundSchema(v NetworkSpeedProfileNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeNetworkSpeedProfileNotFoundSchema performs a merge with any union data inside the OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res, using the provided NetworkSpeedProfileNotFoundSchema +func (t *OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res) MergeNetworkSpeedProfileNotFoundSchema(v NetworkSpeedProfileNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfNetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsObjectInTrashSchema returns the union data inside the OneOfObjectInTrashTaskQueueingError406Res as a ObjectInTrashSchema +func (t OneOfObjectInTrashTaskQueueingError406Res) AsObjectInTrashSchema() (ObjectInTrashSchema, error) { + var body ObjectInTrashSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromObjectInTrashSchema overwrites any union data inside the OneOfObjectInTrashTaskQueueingError406Res as the provided ObjectInTrashSchema +func (t *OneOfObjectInTrashTaskQueueingError406Res) FromObjectInTrashSchema(v ObjectInTrashSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeObjectInTrashSchema performs a merge with any union data inside the OneOfObjectInTrashTaskQueueingError406Res, using the provided ObjectInTrashSchema +func (t *OneOfObjectInTrashTaskQueueingError406Res) MergeObjectInTrashSchema(v ObjectInTrashSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsTaskQueueingErrorSchema returns the union data inside the OneOfObjectInTrashTaskQueueingError406Res as a TaskQueueingErrorSchema +func (t OneOfObjectInTrashTaskQueueingError406Res) AsTaskQueueingErrorSchema() (TaskQueueingErrorSchema, error) { + var body TaskQueueingErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromTaskQueueingErrorSchema overwrites any union data inside the OneOfObjectInTrashTaskQueueingError406Res as the provided TaskQueueingErrorSchema +func (t *OneOfObjectInTrashTaskQueueingError406Res) FromTaskQueueingErrorSchema(v TaskQueueingErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeTaskQueueingErrorSchema performs a merge with any union data inside the OneOfObjectInTrashTaskQueueingError406Res, using the provided TaskQueueingErrorSchema +func (t *OneOfObjectInTrashTaskQueueingError406Res) MergeTaskQueueingErrorSchema(v TaskQueueingErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfObjectInTrashTaskQueueingError406Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfObjectInTrashTaskQueueingError406Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsObjectInTrashSchema returns the union data inside the OneOfObjectInTrashVirtualMachineMustBeStarted406Res as a ObjectInTrashSchema +func (t OneOfObjectInTrashVirtualMachineMustBeStarted406Res) AsObjectInTrashSchema() (ObjectInTrashSchema, error) { + var body ObjectInTrashSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromObjectInTrashSchema overwrites any union data inside the OneOfObjectInTrashVirtualMachineMustBeStarted406Res as the provided ObjectInTrashSchema +func (t *OneOfObjectInTrashVirtualMachineMustBeStarted406Res) FromObjectInTrashSchema(v ObjectInTrashSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeObjectInTrashSchema performs a merge with any union data inside the OneOfObjectInTrashVirtualMachineMustBeStarted406Res, using the provided ObjectInTrashSchema +func (t *OneOfObjectInTrashVirtualMachineMustBeStarted406Res) MergeObjectInTrashSchema(v ObjectInTrashSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsVirtualMachineMustBeStartedSchema returns the union data inside the OneOfObjectInTrashVirtualMachineMustBeStarted406Res as a VirtualMachineMustBeStartedSchema +func (t OneOfObjectInTrashVirtualMachineMustBeStarted406Res) AsVirtualMachineMustBeStartedSchema() (VirtualMachineMustBeStartedSchema, error) { + var body VirtualMachineMustBeStartedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachineMustBeStartedSchema overwrites any union data inside the OneOfObjectInTrashVirtualMachineMustBeStarted406Res as the provided VirtualMachineMustBeStartedSchema +func (t *OneOfObjectInTrashVirtualMachineMustBeStarted406Res) FromVirtualMachineMustBeStartedSchema(v VirtualMachineMustBeStartedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachineMustBeStartedSchema performs a merge with any union data inside the OneOfObjectInTrashVirtualMachineMustBeStarted406Res, using the provided VirtualMachineMustBeStartedSchema +func (t *OneOfObjectInTrashVirtualMachineMustBeStarted406Res) MergeVirtualMachineMustBeStartedSchema(v VirtualMachineMustBeStartedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfObjectInTrashVirtualMachineMustBeStarted406Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfObjectInTrashVirtualMachineMustBeStarted406Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsOrganizationNotFoundSchema returns the union data inside the OneOfOperatingSystemNotFoundOrganizationNotFound404Res as a OrganizationNotFoundSchema +func (t OneOfOperatingSystemNotFoundOrganizationNotFound404Res) AsOrganizationNotFoundSchema() (OrganizationNotFoundSchema, error) { + var body OrganizationNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationNotFoundSchema overwrites any union data inside the OneOfOperatingSystemNotFoundOrganizationNotFound404Res as the provided OrganizationNotFoundSchema +func (t *OneOfOperatingSystemNotFoundOrganizationNotFound404Res) FromOrganizationNotFoundSchema(v OrganizationNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationNotFoundSchema performs a merge with any union data inside the OneOfOperatingSystemNotFoundOrganizationNotFound404Res, using the provided OrganizationNotFoundSchema +func (t *OneOfOperatingSystemNotFoundOrganizationNotFound404Res) MergeOrganizationNotFoundSchema(v OrganizationNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsOperatingSystemNotFoundSchema returns the union data inside the OneOfOperatingSystemNotFoundOrganizationNotFound404Res as a OperatingSystemNotFoundSchema +func (t OneOfOperatingSystemNotFoundOrganizationNotFound404Res) AsOperatingSystemNotFoundSchema() (OperatingSystemNotFoundSchema, error) { + var body OperatingSystemNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOperatingSystemNotFoundSchema overwrites any union data inside the OneOfOperatingSystemNotFoundOrganizationNotFound404Res as the provided OperatingSystemNotFoundSchema +func (t *OneOfOperatingSystemNotFoundOrganizationNotFound404Res) FromOperatingSystemNotFoundSchema(v OperatingSystemNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOperatingSystemNotFoundSchema performs a merge with any union data inside the OneOfOperatingSystemNotFoundOrganizationNotFound404Res, using the provided OperatingSystemNotFoundSchema +func (t *OneOfOperatingSystemNotFoundOrganizationNotFound404Res) MergeOperatingSystemNotFoundSchema(v OperatingSystemNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfOperatingSystemNotFoundOrganizationNotFound404Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfOperatingSystemNotFoundOrganizationNotFound404Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsOrganizationLimitReachedSchema returns the union data inside the OneOfOrganizationLimitReachedValidationError422Res as a OrganizationLimitReachedSchema +func (t OneOfOrganizationLimitReachedValidationError422Res) AsOrganizationLimitReachedSchema() (OrganizationLimitReachedSchema, error) { + var body OrganizationLimitReachedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationLimitReachedSchema overwrites any union data inside the OneOfOrganizationLimitReachedValidationError422Res as the provided OrganizationLimitReachedSchema +func (t *OneOfOrganizationLimitReachedValidationError422Res) FromOrganizationLimitReachedSchema(v OrganizationLimitReachedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationLimitReachedSchema performs a merge with any union data inside the OneOfOrganizationLimitReachedValidationError422Res, using the provided OrganizationLimitReachedSchema +func (t *OneOfOrganizationLimitReachedValidationError422Res) MergeOrganizationLimitReachedSchema(v OrganizationLimitReachedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsValidationErrorSchema returns the union data inside the OneOfOrganizationLimitReachedValidationError422Res as a ValidationErrorSchema +func (t OneOfOrganizationLimitReachedValidationError422Res) AsValidationErrorSchema() (ValidationErrorSchema, error) { + var body ValidationErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromValidationErrorSchema overwrites any union data inside the OneOfOrganizationLimitReachedValidationError422Res as the provided ValidationErrorSchema +func (t *OneOfOrganizationLimitReachedValidationError422Res) FromValidationErrorSchema(v ValidationErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeValidationErrorSchema performs a merge with any union data inside the OneOfOrganizationLimitReachedValidationError422Res, using the provided ValidationErrorSchema +func (t *OneOfOrganizationLimitReachedValidationError422Res) MergeValidationErrorSchema(v ValidationErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfOrganizationLimitReachedValidationError422Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfOrganizationLimitReachedValidationError422Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsUnauthorizedNetworkForAPITokenSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as a UnauthorizedNetworkForAPITokenSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspended403Res) AsUnauthorizedNetworkForAPITokenSchema() (UnauthorizedNetworkForAPITokenSchema, error) { + var body UnauthorizedNetworkForAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromUnauthorizedNetworkForAPITokenSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) FromUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeUnauthorizedNetworkForAPITokenSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res, using the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) MergeUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidAPITokenSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as a InvalidAPITokenSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspended403Res) AsInvalidAPITokenSchema() (InvalidAPITokenSchema, error) { + var body InvalidAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidAPITokenSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as the provided InvalidAPITokenSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) FromInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidAPITokenSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res, using the provided InvalidAPITokenSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) MergeInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsScopeNotGrantedErrorSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as a ScopeNotGrantedErrorSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspended403Res) AsScopeNotGrantedErrorSchema() (ScopeNotGrantedErrorSchema, error) { + var body ScopeNotGrantedErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromScopeNotGrantedErrorSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as the provided ScopeNotGrantedErrorSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) FromScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeScopeNotGrantedErrorSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res, using the provided ScopeNotGrantedErrorSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) MergeScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsOrganizationSuspendedSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as a OrganizationSuspendedSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspended403Res) AsOrganizationSuspendedSchema() (OrganizationSuspendedSchema, error) { + var body OrganizationSuspendedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationSuspendedSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as the provided OrganizationSuspendedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) FromOrganizationSuspendedSchema(v OrganizationSuspendedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationSuspendedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res, using the provided OrganizationSuspendedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) MergeOrganizationSuspendedSchema(v OrganizationSuspendedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsOrganizationNotActivatedSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as a OrganizationNotActivatedSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspended403Res) AsOrganizationNotActivatedSchema() (OrganizationNotActivatedSchema, error) { + var body OrganizationNotActivatedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationNotActivatedSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res as the provided OrganizationNotActivatedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) FromOrganizationNotActivatedSchema(v OrganizationNotActivatedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationNotActivatedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspended403Res, using the provided OrganizationNotActivatedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) MergeOrganizationNotActivatedSchema(v OrganizationNotActivatedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfOrganizationNotActivatedOrganizationSuspended403Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfOrganizationNotActivatedOrganizationSuspended403Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsUnauthorizedNetworkForAPITokenSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as a UnauthorizedNetworkForAPITokenSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) AsUnauthorizedNetworkForAPITokenSchema() (UnauthorizedNetworkForAPITokenSchema, error) { + var body UnauthorizedNetworkForAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromUnauthorizedNetworkForAPITokenSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) FromUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeUnauthorizedNetworkForAPITokenSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res, using the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) MergeUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidAPITokenSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as a InvalidAPITokenSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) AsInvalidAPITokenSchema() (InvalidAPITokenSchema, error) { + var body InvalidAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidAPITokenSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as the provided InvalidAPITokenSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) FromInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidAPITokenSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res, using the provided InvalidAPITokenSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) MergeInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsScopeNotGrantedErrorSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as a ScopeNotGrantedErrorSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) AsScopeNotGrantedErrorSchema() (ScopeNotGrantedErrorSchema, error) { + var body ScopeNotGrantedErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromScopeNotGrantedErrorSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as the provided ScopeNotGrantedErrorSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) FromScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeScopeNotGrantedErrorSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res, using the provided ScopeNotGrantedErrorSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) MergeScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsOrganizationSuspendedSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as a OrganizationSuspendedSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) AsOrganizationSuspendedSchema() (OrganizationSuspendedSchema, error) { + var body OrganizationSuspendedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationSuspendedSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as the provided OrganizationSuspendedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) FromOrganizationSuspendedSchema(v OrganizationSuspendedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationSuspendedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res, using the provided OrganizationSuspendedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) MergeOrganizationSuspendedSchema(v OrganizationSuspendedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsOrganizationNotActivatedSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as a OrganizationNotActivatedSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) AsOrganizationNotActivatedSchema() (OrganizationNotActivatedSchema, error) { + var body OrganizationNotActivatedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationNotActivatedSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as the provided OrganizationNotActivatedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) FromOrganizationNotActivatedSchema(v OrganizationNotActivatedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationNotActivatedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res, using the provided OrganizationNotActivatedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) MergeOrganizationNotActivatedSchema(v OrganizationNotActivatedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsPermissionDeniedSchema returns the union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as a PermissionDeniedSchema +func (t OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) AsPermissionDeniedSchema() (PermissionDeniedSchema, error) { + var body PermissionDeniedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromPermissionDeniedSchema overwrites any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res as the provided PermissionDeniedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) FromPermissionDeniedSchema(v PermissionDeniedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergePermissionDeniedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res, using the provided PermissionDeniedSchema +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) MergePermissionDeniedSchema(v PermissionDeniedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfOrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsUnauthorizedNetworkForAPITokenSchema returns the union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as a UnauthorizedNetworkForAPITokenSchema +func (t OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) AsUnauthorizedNetworkForAPITokenSchema() (UnauthorizedNetworkForAPITokenSchema, error) { + var body UnauthorizedNetworkForAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromUnauthorizedNetworkForAPITokenSchema overwrites any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) FromUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeUnauthorizedNetworkForAPITokenSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res, using the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) MergeUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidAPITokenSchema returns the union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as a InvalidAPITokenSchema +func (t OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) AsInvalidAPITokenSchema() (InvalidAPITokenSchema, error) { + var body InvalidAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidAPITokenSchema overwrites any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as the provided InvalidAPITokenSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) FromInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidAPITokenSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res, using the provided InvalidAPITokenSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) MergeInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsScopeNotGrantedErrorSchema returns the union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as a ScopeNotGrantedErrorSchema +func (t OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) AsScopeNotGrantedErrorSchema() (ScopeNotGrantedErrorSchema, error) { + var body ScopeNotGrantedErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromScopeNotGrantedErrorSchema overwrites any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as the provided ScopeNotGrantedErrorSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) FromScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeScopeNotGrantedErrorSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res, using the provided ScopeNotGrantedErrorSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) MergeScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsOrganizationSuspendedSchema returns the union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as a OrganizationSuspendedSchema +func (t OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) AsOrganizationSuspendedSchema() (OrganizationSuspendedSchema, error) { + var body OrganizationSuspendedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationSuspendedSchema overwrites any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as the provided OrganizationSuspendedSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) FromOrganizationSuspendedSchema(v OrganizationSuspendedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationSuspendedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res, using the provided OrganizationSuspendedSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) MergeOrganizationSuspendedSchema(v OrganizationSuspendedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsOrganizationNotActivatedSchema returns the union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as a OrganizationNotActivatedSchema +func (t OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) AsOrganizationNotActivatedSchema() (OrganizationNotActivatedSchema, error) { + var body OrganizationNotActivatedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromOrganizationNotActivatedSchema overwrites any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as the provided OrganizationNotActivatedSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) FromOrganizationNotActivatedSchema(v OrganizationNotActivatedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeOrganizationNotActivatedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res, using the provided OrganizationNotActivatedSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) MergeOrganizationNotActivatedSchema(v OrganizationNotActivatedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsPermissionDeniedSchema returns the union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as a PermissionDeniedSchema +func (t OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) AsPermissionDeniedSchema() (PermissionDeniedSchema, error) { + var body PermissionDeniedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromPermissionDeniedSchema overwrites any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as the provided PermissionDeniedSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) FromPermissionDeniedSchema(v PermissionDeniedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergePermissionDeniedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res, using the provided PermissionDeniedSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) MergePermissionDeniedSchema(v PermissionDeniedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsResourceCreationRestrictedSchema returns the union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as a ResourceCreationRestrictedSchema +func (t OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) AsResourceCreationRestrictedSchema() (ResourceCreationRestrictedSchema, error) { + var body ResourceCreationRestrictedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromResourceCreationRestrictedSchema overwrites any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res as the provided ResourceCreationRestrictedSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) FromResourceCreationRestrictedSchema(v ResourceCreationRestrictedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeResourceCreationRestrictedSchema performs a merge with any union data inside the OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res, using the provided ResourceCreationRestrictedSchema +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) MergeResourceCreationRestrictedSchema(v ResourceCreationRestrictedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfOrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsUnauthorizedNetworkForAPITokenSchema returns the union data inside the OneOfPermissionDenied403Res as a UnauthorizedNetworkForAPITokenSchema +func (t OneOfPermissionDenied403Res) AsUnauthorizedNetworkForAPITokenSchema() (UnauthorizedNetworkForAPITokenSchema, error) { + var body UnauthorizedNetworkForAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromUnauthorizedNetworkForAPITokenSchema overwrites any union data inside the OneOfPermissionDenied403Res as the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfPermissionDenied403Res) FromUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeUnauthorizedNetworkForAPITokenSchema performs a merge with any union data inside the OneOfPermissionDenied403Res, using the provided UnauthorizedNetworkForAPITokenSchema +func (t *OneOfPermissionDenied403Res) MergeUnauthorizedNetworkForAPITokenSchema(v UnauthorizedNetworkForAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsInvalidAPITokenSchema returns the union data inside the OneOfPermissionDenied403Res as a InvalidAPITokenSchema +func (t OneOfPermissionDenied403Res) AsInvalidAPITokenSchema() (InvalidAPITokenSchema, error) { + var body InvalidAPITokenSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromInvalidAPITokenSchema overwrites any union data inside the OneOfPermissionDenied403Res as the provided InvalidAPITokenSchema +func (t *OneOfPermissionDenied403Res) FromInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeInvalidAPITokenSchema performs a merge with any union data inside the OneOfPermissionDenied403Res, using the provided InvalidAPITokenSchema +func (t *OneOfPermissionDenied403Res) MergeInvalidAPITokenSchema(v InvalidAPITokenSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsScopeNotGrantedErrorSchema returns the union data inside the OneOfPermissionDenied403Res as a ScopeNotGrantedErrorSchema +func (t OneOfPermissionDenied403Res) AsScopeNotGrantedErrorSchema() (ScopeNotGrantedErrorSchema, error) { + var body ScopeNotGrantedErrorSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromScopeNotGrantedErrorSchema overwrites any union data inside the OneOfPermissionDenied403Res as the provided ScopeNotGrantedErrorSchema +func (t *OneOfPermissionDenied403Res) FromScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeScopeNotGrantedErrorSchema performs a merge with any union data inside the OneOfPermissionDenied403Res, using the provided ScopeNotGrantedErrorSchema +func (t *OneOfPermissionDenied403Res) MergeScopeNotGrantedErrorSchema(v ScopeNotGrantedErrorSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsPermissionDeniedSchema returns the union data inside the OneOfPermissionDenied403Res as a PermissionDeniedSchema +func (t OneOfPermissionDenied403Res) AsPermissionDeniedSchema() (PermissionDeniedSchema, error) { + var body PermissionDeniedSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromPermissionDeniedSchema overwrites any union data inside the OneOfPermissionDenied403Res as the provided PermissionDeniedSchema +func (t *OneOfPermissionDenied403Res) FromPermissionDeniedSchema(v PermissionDeniedSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergePermissionDeniedSchema performs a merge with any union data inside the OneOfPermissionDenied403Res, using the provided PermissionDeniedSchema +func (t *OneOfPermissionDenied403Res) MergePermissionDeniedSchema(v PermissionDeniedSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfPermissionDenied403Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfPermissionDenied403Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +// AsVirtualMachineNotFoundSchema returns the union data inside the OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res as a VirtualMachineNotFoundSchema +func (t OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res) AsVirtualMachineNotFoundSchema() (VirtualMachineNotFoundSchema, error) { + var body VirtualMachineNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachineNotFoundSchema overwrites any union data inside the OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res as the provided VirtualMachineNotFoundSchema +func (t *OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res) FromVirtualMachineNotFoundSchema(v VirtualMachineNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachineNotFoundSchema performs a merge with any union data inside the OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res, using the provided VirtualMachineNotFoundSchema +func (t *OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res) MergeVirtualMachineNotFoundSchema(v VirtualMachineNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +// AsVirtualMachinePackageNotFoundSchema returns the union data inside the OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res as a VirtualMachinePackageNotFoundSchema +func (t OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res) AsVirtualMachinePackageNotFoundSchema() (VirtualMachinePackageNotFoundSchema, error) { + var body VirtualMachinePackageNotFoundSchema + err := json.Unmarshal(t.union, &body) + return body, err +} + +// FromVirtualMachinePackageNotFoundSchema overwrites any union data inside the OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res as the provided VirtualMachinePackageNotFoundSchema +func (t *OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res) FromVirtualMachinePackageNotFoundSchema(v VirtualMachinePackageNotFoundSchema) error { + b, err := json.Marshal(v) + t.union = b + return err +} + +// MergeVirtualMachinePackageNotFoundSchema performs a merge with any union data inside the OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res, using the provided VirtualMachinePackageNotFoundSchema +func (t *OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res) MergeVirtualMachinePackageNotFoundSchema(v VirtualMachinePackageNotFoundSchema) error { + b, err := json.Marshal(v) + if err != nil { + return err + } + + merged, err := runtime.JsonMerge(t.union, b) + t.union = merged + return err +} + +func (t OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res) MarshalJSON() ([]byte, error) { + b, err := t.union.MarshalJSON() + return b, err +} + +func (t *OneOfVirtualMachineNotFoundVirtualMachinePackageNotFound404Res) UnmarshalJSON(b []byte) error { + err := t.union.UnmarshalJSON(b) + return err +} + +const ( + clientVersion = "0.2.0" // x-release-please-version +) + +// RequestEditorFn is the function signature for the RequestEditor callback function +type RequestEditorFn func(ctx context.Context, req *http.Request) error + +// Doer performs HTTP requests. +// +// The standard http.Client implements this interface. +type HttpRequestDoer interface { + Do(req *http.Request) (*http.Response, error) +} + +// Client which conforms to the OpenAPI3 specification for this service. +type Client struct { + // The endpoint of the server conforming to this interface, with scheme, + // https://api.deepmap.com for example. This can contain a path relative + // to the server, such as https://api.deepmap.com/dev-test, and all the + // paths in the swagger spec will be appended to the server. + Server string + + // Doer for performing requests, typically a *http.Client with any + // customized settings, such as certificate chains. + Client HttpRequestDoer + + // A list of callbacks for modifying requests which are generated before sending over + // the network. + RequestEditors []RequestEditorFn +} + +// ClientOption allows setting custom parameters during construction +type ClientOption func(*Client) error + +// Creates a new Client, with reasonable defaults +func NewClient(server string, token string, opts ...ClientOption) (*Client, error) { + // create a client with sane default values + client := Client{ + Server: server, + } + + bearerTokenProvider, bearerTokenProviderErr := securityprovider.NewSecurityProviderBearerToken(token) + if bearerTokenProviderErr != nil { + return nil, bearerTokenProviderErr + } + + client.RequestEditors = append(client.RequestEditors, bearerTokenProvider.Intercept) + client.RequestEditors = append(client.RequestEditors, func(ctx context.Context, req *http.Request) error { + req.Header.Set("User-Agent", "go-katapult/"+clientVersion) + + return nil + }) + + // mutate client and add all optional params + for _, o := range opts { + if err := o(&client); err != nil { + return nil, err + } + } + + // ensure the server URL always has a trailing slash + if !strings.HasSuffix(client.Server, "/") { + client.Server += "/" + } + // create httpClient, if not already present + if client.Client == nil { + client.Client = &http.Client{} + } + return &client, nil +} + +// WithHTTPClient allows overriding the default Doer, which is +// automatically created using http.Client. This is useful for tests. +func WithHTTPClient(doer HttpRequestDoer) ClientOption { + return func(c *Client) error { + c.Client = doer + return nil + } +} + +// WithRequestEditorFn allows setting up a callback function, which will be +// called right before sending the request. This can be used to mutate the request. +func WithRequestEditorFn(fn RequestEditorFn) ClientOption { + return func(c *Client) error { + c.RequestEditors = append(c.RequestEditors, fn) + return nil + } +} + +// The interface specification for the client above. +type ClientInterface interface { + // GetCertificate request + GetCertificate(ctx context.Context, params *GetCertificateParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetCountries request + GetCountries(ctx context.Context, params *GetCountriesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetCountry request + GetCountry(ctx context.Context, params *GetCountryParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetCountryCountryStates request + GetCountryCountryStates(ctx context.Context, params *GetCountryCountryStatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetCountryState request + GetCountryState(ctx context.Context, params *GetCountryStateParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetCurrencies request + GetCurrencies(ctx context.Context, params *GetCurrenciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetCurrency request + GetCurrency(ctx context.Context, params *GetCurrencyParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDataCenters request + GetDataCenters(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDataCenter request + GetDataCenter(ctx context.Context, params *GetDataCenterParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDataCenterDefaultNetwork request + GetDataCenterDefaultNetwork(ctx context.Context, params *GetDataCenterDefaultNetworkParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDataCenterGpuTypes request + GetDataCenterGpuTypes(ctx context.Context, params *GetDataCenterGpuTypesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteDiskBackupPolicyWithBody request with any body + DeleteDiskBackupPolicyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteDiskBackupPolicy(ctx context.Context, body DeleteDiskBackupPolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDiskBackupPolicy request + GetDiskBackupPolicy(ctx context.Context, params *GetDiskBackupPolicyParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchDiskBackupPolicyWithBody request with any body + PatchDiskBackupPolicyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchDiskBackupPolicy(ctx context.Context, body PatchDiskBackupPolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteDiskBackupPolicyScheduleWithBody request with any body + DeleteDiskBackupPolicyScheduleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteDiskBackupPolicySchedule(ctx context.Context, body DeleteDiskBackupPolicyScheduleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDiskTemplateVersion request + GetDiskTemplateVersion(ctx context.Context, params *GetDiskTemplateVersionParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDiskTemplateVersionSpec request + GetDiskTemplateVersionSpec(ctx context.Context, params *GetDiskTemplateVersionSpecParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDiskTemplate request + GetDiskTemplate(ctx context.Context, params *GetDiskTemplateParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDiskTemplateVersions request + GetDiskTemplateVersions(ctx context.Context, params *GetDiskTemplateVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDisk request + GetDisk(ctx context.Context, params *GetDiskParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDiskDiskBackupPolicies request + GetDiskDiskBackupPolicies(ctx context.Context, params *GetDiskDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostDiskDiskBackupPoliciesWithBody request with any body + PostDiskDiskBackupPoliciesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostDiskDiskBackupPolicies(ctx context.Context, body PostDiskDiskBackupPoliciesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteDnsRecordsDnsRecordWithBody request with any body + DeleteDnsRecordsDnsRecordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteDnsRecordsDnsRecord(ctx context.Context, body DeleteDnsRecordsDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDnsRecordsDnsRecord request + GetDnsRecordsDnsRecord(ctx context.Context, params *GetDnsRecordsDnsRecordParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchDnsRecordsDnsRecordWithBody request with any body + PatchDnsRecordsDnsRecordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchDnsRecordsDnsRecord(ctx context.Context, body PatchDnsRecordsDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteDnsZonesDnsZoneWithBody request with any body + DeleteDnsZonesDnsZoneWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteDnsZonesDnsZone(ctx context.Context, body DeleteDnsZonesDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDnsZonesDnsZone request + GetDnsZonesDnsZone(ctx context.Context, params *GetDnsZonesDnsZoneParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDnsZonesDnsZoneRecords request + GetDnsZonesDnsZoneRecords(ctx context.Context, params *GetDnsZonesDnsZoneRecordsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostDnsZonesDnsZoneRecordsWithBody request with any body + PostDnsZonesDnsZoneRecordsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostDnsZonesDnsZoneRecords(ctx context.Context, body PostDnsZonesDnsZoneRecordsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostDnsZonesDnsZoneUpdateTtlWithBody request with any body + PostDnsZonesDnsZoneUpdateTtlWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostDnsZonesDnsZoneUpdateTtl(ctx context.Context, body PostDnsZonesDnsZoneUpdateTtlJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDnsZonesDnsZoneVerificationDetails request + GetDnsZonesDnsZoneVerificationDetails(ctx context.Context, params *GetDnsZonesDnsZoneVerificationDetailsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostDnsZonesDnsZoneVerifyWithBody request with any body + PostDnsZonesDnsZoneVerifyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostDnsZonesDnsZoneVerify(ctx context.Context, body PostDnsZonesDnsZoneVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteDnsRecordWithBody request with any body + DeleteDnsRecordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteDnsRecord(ctx context.Context, body DeleteDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDnsRecord request + GetDnsRecord(ctx context.Context, params *GetDnsRecordParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchDnsRecordWithBody request with any body + PatchDnsRecordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchDnsRecord(ctx context.Context, body PatchDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteDnsZoneWithBody request with any body + DeleteDnsZoneWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteDnsZone(ctx context.Context, body DeleteDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDnsZone request + GetDnsZone(ctx context.Context, params *GetDnsZoneParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchDnsZoneWithBody request with any body + PatchDnsZoneWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchDnsZone(ctx context.Context, body PatchDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetDnsZoneRecords request + GetDnsZoneRecords(ctx context.Context, params *GetDnsZoneRecordsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostDnsZoneRecordsWithBody request with any body + PostDnsZoneRecordsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostDnsZoneRecords(ctx context.Context, body PostDnsZoneRecordsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostDnsZoneVerifyWithBody request with any body + PostDnsZoneVerifyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostDnsZoneVerify(ctx context.Context, body PostDnsZoneVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteFileStorageVolumeWithBody request with any body + DeleteFileStorageVolumeWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteFileStorageVolume(ctx context.Context, body DeleteFileStorageVolumeJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetFileStorageVolume request + GetFileStorageVolume(ctx context.Context, params *GetFileStorageVolumeParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchFileStorageVolumeWithBody request with any body + PatchFileStorageVolumeWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchFileStorageVolume(ctx context.Context, body PatchFileStorageVolumeJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetGpuTypes request + GetGpuTypes(ctx context.Context, params *GetGpuTypesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetGpuType request + GetGpuType(ctx context.Context, params *GetGpuTypeParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostInvalidateLinkedWebSessionWithBody request with any body + PostInvalidateLinkedWebSessionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostInvalidateLinkedWebSession(ctx context.Context, body PostInvalidateLinkedWebSessionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteIpAddressWithBody request with any body + DeleteIpAddressWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteIpAddress(ctx context.Context, body DeleteIpAddressJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetIpAddress request + GetIpAddress(ctx context.Context, params *GetIpAddressParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchIpAddressWithBody request with any body + PatchIpAddressWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchIpAddress(ctx context.Context, body PatchIpAddressJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostIpAddressUnallocateWithBody request with any body + PostIpAddressUnallocateWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostIpAddressUnallocate(ctx context.Context, body PostIpAddressUnallocateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteLoadBalancerWithBody request with any body + DeleteLoadBalancerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteLoadBalancer(ctx context.Context, body DeleteLoadBalancerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetLoadBalancer request + GetLoadBalancer(ctx context.Context, params *GetLoadBalancerParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchLoadBalancerWithBody request with any body + PatchLoadBalancerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchLoadBalancer(ctx context.Context, body PatchLoadBalancerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetLoadBalancerRules request + GetLoadBalancerRules(ctx context.Context, params *GetLoadBalancerRulesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostLoadBalancerRulesWithBody request with any body + PostLoadBalancerRulesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostLoadBalancerRules(ctx context.Context, body PostLoadBalancerRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteLoadBalancersRulesLoadBalancerRuleWithBody request with any body + DeleteLoadBalancersRulesLoadBalancerRuleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteLoadBalancersRulesLoadBalancerRule(ctx context.Context, body DeleteLoadBalancersRulesLoadBalancerRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetLoadBalancersRulesLoadBalancerRule request + GetLoadBalancersRulesLoadBalancerRule(ctx context.Context, params *GetLoadBalancersRulesLoadBalancerRuleParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchLoadBalancersRulesLoadBalancerRuleWithBody request with any body + PatchLoadBalancersRulesLoadBalancerRuleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchLoadBalancersRulesLoadBalancerRule(ctx context.Context, body PatchLoadBalancersRulesLoadBalancerRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetNetwork request + GetNetwork(ctx context.Context, params *GetNetworkParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOperatingSystems request + GetOperatingSystems(ctx context.Context, params *GetOperatingSystemsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOperatingSystem request + GetOperatingSystem(ctx context.Context, params *GetOperatingSystemParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizations request + GetOrganizations(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganization request + GetOrganization(ctx context.Context, params *GetOrganizationParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationAvailableNetworks request + GetOrganizationAvailableNetworks(ctx context.Context, params *GetOrganizationAvailableNetworksParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationCertificates request + GetOrganizationCertificates(ctx context.Context, params *GetOrganizationCertificatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationDiskBackupPolicies request + GetOrganizationDiskBackupPolicies(ctx context.Context, params *GetOrganizationDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationDiskTemplates request + GetOrganizationDiskTemplates(ctx context.Context, params *GetOrganizationDiskTemplatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationDisks request + GetOrganizationDisks(ctx context.Context, params *GetOrganizationDisksParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationDnsZones request + GetOrganizationDnsZones(ctx context.Context, params *GetOrganizationDnsZonesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationDnsZonesWithBody request with any body + PostOrganizationDnsZonesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationDnsZones(ctx context.Context, body PostOrganizationDnsZonesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationsOrganizationdnsZones request + GetOrganizationsOrganizationdnsZones(ctx context.Context, params *GetOrganizationsOrganizationdnsZonesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationsOrganizationdnsZonesWithBody request with any body + PostOrganizationsOrganizationdnsZonesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationsOrganizationdnsZones(ctx context.Context, body PostOrganizationsOrganizationdnsZonesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationDnsZonesNameservers request + GetOrganizationDnsZonesNameservers(ctx context.Context, params *GetOrganizationDnsZonesNameserversParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationFileStorageVolumes request + GetOrganizationFileStorageVolumes(ctx context.Context, params *GetOrganizationFileStorageVolumesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationFileStorageVolumesWithBody request with any body + PostOrganizationFileStorageVolumesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationFileStorageVolumes(ctx context.Context, body PostOrganizationFileStorageVolumesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationIpAddresses request + GetOrganizationIpAddresses(ctx context.Context, params *GetOrganizationIpAddressesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationIpAddressesWithBody request with any body + PostOrganizationIpAddressesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationIpAddresses(ctx context.Context, body PostOrganizationIpAddressesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationLoadBalancers request + GetOrganizationLoadBalancers(ctx context.Context, params *GetOrganizationLoadBalancersParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationLoadBalancersWithBody request with any body + PostOrganizationLoadBalancersWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationLoadBalancers(ctx context.Context, body PostOrganizationLoadBalancersJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationManaged request + GetOrganizationManaged(ctx context.Context, params *GetOrganizationManagedParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationManagedWithBody request with any body + PostOrganizationManagedWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationManaged(ctx context.Context, body PostOrganizationManagedJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationNetworkSpeedProfiles request + GetOrganizationNetworkSpeedProfiles(ctx context.Context, params *GetOrganizationNetworkSpeedProfilesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationSecurityGroups request + GetOrganizationSecurityGroups(ctx context.Context, params *GetOrganizationSecurityGroupsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationSecurityGroupsWithBody request with any body + PostOrganizationSecurityGroupsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationSecurityGroups(ctx context.Context, body PostOrganizationSecurityGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationSshKeys request + GetOrganizationSshKeys(ctx context.Context, params *GetOrganizationSshKeysParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationSshKeysWithBody request with any body + PostOrganizationSshKeysWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationSshKeys(ctx context.Context, body PostOrganizationSshKeysJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationTags request + GetOrganizationTags(ctx context.Context, params *GetOrganizationTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationTagsWithBody request with any body + PostOrganizationTagsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationTags(ctx context.Context, body PostOrganizationTagsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationTrashObjects request + GetOrganizationTrashObjects(ctx context.Context, params *GetOrganizationTrashObjectsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationTrashObjectsPurgeAllWithBody request with any body + PostOrganizationTrashObjectsPurgeAllWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationTrashObjectsPurgeAll(ctx context.Context, body PostOrganizationTrashObjectsPurgeAllJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationUsersWithAccess request + GetOrganizationUsersWithAccess(ctx context.Context, params *GetOrganizationUsersWithAccessParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationVirtualMachineGroups request + GetOrganizationVirtualMachineGroups(ctx context.Context, params *GetOrganizationVirtualMachineGroupsParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationVirtualMachineGroupsWithBody request with any body + PostOrganizationVirtualMachineGroupsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationVirtualMachineGroups(ctx context.Context, body PostOrganizationVirtualMachineGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetOrganizationVirtualMachines request + GetOrganizationVirtualMachines(ctx context.Context, params *GetOrganizationVirtualMachinesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationVirtualMachinesBuildWithBody request with any body + PostOrganizationVirtualMachinesBuildWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationVirtualMachinesBuild(ctx context.Context, body PostOrganizationVirtualMachinesBuildJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostOrganizationVirtualMachinesBuildFromSpecWithBody request with any body + PostOrganizationVirtualMachinesBuildFromSpecWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostOrganizationVirtualMachinesBuildFromSpec(ctx context.Context, body PostOrganizationVirtualMachinesBuildFromSpecJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteSecurityGroupWithBody request with any body + DeleteSecurityGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteSecurityGroup(ctx context.Context, body DeleteSecurityGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetSecurityGroup request + GetSecurityGroup(ctx context.Context, params *GetSecurityGroupParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchSecurityGroupWithBody request with any body + PatchSecurityGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchSecurityGroup(ctx context.Context, body PatchSecurityGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetSecurityGroupRules request + GetSecurityGroupRules(ctx context.Context, params *GetSecurityGroupRulesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostSecurityGroupRulesWithBody request with any body + PostSecurityGroupRulesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostSecurityGroupRules(ctx context.Context, body PostSecurityGroupRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteSecurityGroupsRulesSecurityGroupRuleWithBody request with any body + DeleteSecurityGroupsRulesSecurityGroupRuleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteSecurityGroupsRulesSecurityGroupRule(ctx context.Context, body DeleteSecurityGroupsRulesSecurityGroupRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetSecurityGroupsRulesSecurityGroupRule request + GetSecurityGroupsRulesSecurityGroupRule(ctx context.Context, params *GetSecurityGroupsRulesSecurityGroupRuleParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchSecurityGroupsRulesSecurityGroupRuleWithBody request with any body + PatchSecurityGroupsRulesSecurityGroupRuleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchSecurityGroupsRulesSecurityGroupRule(ctx context.Context, body PatchSecurityGroupsRulesSecurityGroupRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteSshKeyWithBody request with any body + DeleteSshKeyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteSshKey(ctx context.Context, body DeleteSshKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteTagWithBody request with any body + DeleteTagWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteTag(ctx context.Context, body DeleteTagJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetTag request + GetTag(ctx context.Context, params *GetTagParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchTagWithBody request with any body + PatchTagWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchTag(ctx context.Context, body PatchTagJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetTask request + GetTask(ctx context.Context, params *GetTaskParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteTrashObjectWithBody request with any body + DeleteTrashObjectWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteTrashObject(ctx context.Context, body DeleteTrashObjectJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetTrashObject request + GetTrashObject(ctx context.Context, params *GetTrashObjectParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostTrashObjectRestoreWithBody request with any body + PostTrashObjectRestoreWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostTrashObjectRestore(ctx context.Context, body PostTrashObjectRestoreJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetUsersCurrent request + GetUsersCurrent(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteVirtualMachineGroupWithBody request with any body + DeleteVirtualMachineGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteVirtualMachineGroup(ctx context.Context, body DeleteVirtualMachineGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachineGroup request + GetVirtualMachineGroup(ctx context.Context, params *GetVirtualMachineGroupParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchVirtualMachineGroupWithBody request with any body + PatchVirtualMachineGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchVirtualMachineGroup(ctx context.Context, body PatchVirtualMachineGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVMNIVMNI request + GetVMNIVMNI(ctx context.Context, params *GetVMNIVMNIParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineNetworkInterfaceAllocateIpWithBody request with any body + PostVirtualMachineNetworkInterfaceAllocateIpWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineNetworkInterfaceAllocateIp(ctx context.Context, body PostVirtualMachineNetworkInterfaceAllocateIpJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineNetworkInterfaceAllocateNewIpWithBody request with any body + PostVirtualMachineNetworkInterfaceAllocateNewIpWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineNetworkInterfaceAllocateNewIp(ctx context.Context, body PostVirtualMachineNetworkInterfaceAllocateNewIpJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersion request + GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersion(ctx context.Context, params *GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithBody request with any body + PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchVirtualMachineNetworkInterfaceUpdateSpeedProfile(ctx context.Context, body PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachinePackages request + GetVirtualMachinePackages(ctx context.Context, params *GetVirtualMachinePackagesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachinePackage request + GetVirtualMachinePackage(ctx context.Context, params *GetVirtualMachinePackageParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // DeleteVirtualMachineWithBody request with any body + DeleteVirtualMachineWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + DeleteVirtualMachine(ctx context.Context, body DeleteVirtualMachineJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachine request + GetVirtualMachine(ctx context.Context, params *GetVirtualMachineParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PatchVirtualMachineWithBody request with any body + PatchVirtualMachineWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PatchVirtualMachine(ctx context.Context, body PatchVirtualMachineJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineAllocateIpWithBody request with any body + PostVirtualMachineAllocateIpWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineAllocateIp(ctx context.Context, body PostVirtualMachineAllocateIpJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineConsoleSessionsWithBody request with any body + PostVirtualMachineConsoleSessionsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineConsoleSessions(ctx context.Context, body PostVirtualMachineConsoleSessionsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachineDiskBackupPolicies request + GetVirtualMachineDiskBackupPolicies(ctx context.Context, params *GetVirtualMachineDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineDiskBackupPoliciesWithBody request with any body + PostVirtualMachineDiskBackupPoliciesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineDiskBackupPolicies(ctx context.Context, body PostVirtualMachineDiskBackupPoliciesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachineDisks request + GetVirtualMachineDisks(ctx context.Context, params *GetVirtualMachineDisksParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PutVirtualMachineFlexibleResourcesWithBody request with any body + PutVirtualMachineFlexibleResourcesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PutVirtualMachineFlexibleResources(ctx context.Context, body PutVirtualMachineFlexibleResourcesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachineNetworkInterfaces request + GetVirtualMachineNetworkInterfaces(ctx context.Context, params *GetVirtualMachineNetworkInterfacesParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachineNetworkInterface request + GetVirtualMachineNetworkInterface(ctx context.Context, params *GetVirtualMachineNetworkInterfaceParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PutVirtualMachinePackageWithBody request with any body + PutVirtualMachinePackageWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PutVirtualMachinePackage(ctx context.Context, body PutVirtualMachinePackageJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineResetWithBody request with any body + PostVirtualMachineResetWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineReset(ctx context.Context, body PostVirtualMachineResetJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineShutdownWithBody request with any body + PostVirtualMachineShutdownWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineShutdown(ctx context.Context, body PostVirtualMachineShutdownJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineStartWithBody request with any body + PostVirtualMachineStartWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineStart(ctx context.Context, body PostVirtualMachineStartJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // PostVirtualMachineStopWithBody request with any body + PostVirtualMachineStopWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) + + PostVirtualMachineStop(ctx context.Context, body PostVirtualMachineStopJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetVirtualMachinesBuildsVirtualMachineBuild request + GetVirtualMachinesBuildsVirtualMachineBuild(ctx context.Context, params *GetVirtualMachinesBuildsVirtualMachineBuildParams, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetZones request + GetZones(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) + + // GetZone request + GetZone(ctx context.Context, params *GetZoneParams, reqEditors ...RequestEditorFn) (*http.Response, error) +} + +func (c *Client) GetCertificate(ctx context.Context, params *GetCertificateParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCertificateRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetCountries(ctx context.Context, params *GetCountriesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCountriesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetCountry(ctx context.Context, params *GetCountryParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCountryRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetCountryCountryStates(ctx context.Context, params *GetCountryCountryStatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCountryCountryStatesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetCountryState(ctx context.Context, params *GetCountryStateParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCountryStateRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetCurrencies(ctx context.Context, params *GetCurrenciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCurrenciesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetCurrency(ctx context.Context, params *GetCurrencyParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetCurrencyRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDataCenters(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDataCentersRequest(c.Server) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDataCenter(ctx context.Context, params *GetDataCenterParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDataCenterRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDataCenterDefaultNetwork(ctx context.Context, params *GetDataCenterDefaultNetworkParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDataCenterDefaultNetworkRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDataCenterGpuTypes(ctx context.Context, params *GetDataCenterGpuTypesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDataCenterGpuTypesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDiskBackupPolicyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDiskBackupPolicyRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDiskBackupPolicy(ctx context.Context, body DeleteDiskBackupPolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDiskBackupPolicyRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDiskBackupPolicy(ctx context.Context, params *GetDiskBackupPolicyParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDiskBackupPolicyRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchDiskBackupPolicyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchDiskBackupPolicyRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchDiskBackupPolicy(ctx context.Context, body PatchDiskBackupPolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchDiskBackupPolicyRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDiskBackupPolicyScheduleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDiskBackupPolicyScheduleRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDiskBackupPolicySchedule(ctx context.Context, body DeleteDiskBackupPolicyScheduleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDiskBackupPolicyScheduleRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDiskTemplateVersion(ctx context.Context, params *GetDiskTemplateVersionParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDiskTemplateVersionRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDiskTemplateVersionSpec(ctx context.Context, params *GetDiskTemplateVersionSpecParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDiskTemplateVersionSpecRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDiskTemplate(ctx context.Context, params *GetDiskTemplateParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDiskTemplateRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDiskTemplateVersions(ctx context.Context, params *GetDiskTemplateVersionsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDiskTemplateVersionsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDisk(ctx context.Context, params *GetDiskParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDiskRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDiskDiskBackupPolicies(ctx context.Context, params *GetDiskDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDiskDiskBackupPoliciesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDiskDiskBackupPoliciesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDiskDiskBackupPoliciesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDiskDiskBackupPolicies(ctx context.Context, body PostDiskDiskBackupPoliciesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDiskDiskBackupPoliciesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDnsRecordsDnsRecordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDnsRecordsDnsRecordRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDnsRecordsDnsRecord(ctx context.Context, body DeleteDnsRecordsDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDnsRecordsDnsRecordRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDnsRecordsDnsRecord(ctx context.Context, params *GetDnsRecordsDnsRecordParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDnsRecordsDnsRecordRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchDnsRecordsDnsRecordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchDnsRecordsDnsRecordRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchDnsRecordsDnsRecord(ctx context.Context, body PatchDnsRecordsDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchDnsRecordsDnsRecordRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDnsZonesDnsZoneWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDnsZonesDnsZoneRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDnsZonesDnsZone(ctx context.Context, body DeleteDnsZonesDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDnsZonesDnsZoneRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDnsZonesDnsZone(ctx context.Context, params *GetDnsZonesDnsZoneParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDnsZonesDnsZoneRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDnsZonesDnsZoneRecords(ctx context.Context, params *GetDnsZonesDnsZoneRecordsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDnsZonesDnsZoneRecordsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZonesDnsZoneRecordsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZonesDnsZoneRecordsRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZonesDnsZoneRecords(ctx context.Context, body PostDnsZonesDnsZoneRecordsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZonesDnsZoneRecordsRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZonesDnsZoneUpdateTtlWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZonesDnsZoneUpdateTtlRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZonesDnsZoneUpdateTtl(ctx context.Context, body PostDnsZonesDnsZoneUpdateTtlJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZonesDnsZoneUpdateTtlRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDnsZonesDnsZoneVerificationDetails(ctx context.Context, params *GetDnsZonesDnsZoneVerificationDetailsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDnsZonesDnsZoneVerificationDetailsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZonesDnsZoneVerifyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZonesDnsZoneVerifyRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZonesDnsZoneVerify(ctx context.Context, body PostDnsZonesDnsZoneVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZonesDnsZoneVerifyRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDnsRecordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDnsRecordRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDnsRecord(ctx context.Context, body DeleteDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDnsRecordRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDnsRecord(ctx context.Context, params *GetDnsRecordParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDnsRecordRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchDnsRecordWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchDnsRecordRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchDnsRecord(ctx context.Context, body PatchDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchDnsRecordRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDnsZoneWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDnsZoneRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteDnsZone(ctx context.Context, body DeleteDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteDnsZoneRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDnsZone(ctx context.Context, params *GetDnsZoneParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDnsZoneRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchDnsZoneWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchDnsZoneRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchDnsZone(ctx context.Context, body PatchDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchDnsZoneRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetDnsZoneRecords(ctx context.Context, params *GetDnsZoneRecordsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetDnsZoneRecordsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZoneRecordsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZoneRecordsRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZoneRecords(ctx context.Context, body PostDnsZoneRecordsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZoneRecordsRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZoneVerifyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZoneVerifyRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostDnsZoneVerify(ctx context.Context, body PostDnsZoneVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostDnsZoneVerifyRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteFileStorageVolumeWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteFileStorageVolumeRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteFileStorageVolume(ctx context.Context, body DeleteFileStorageVolumeJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteFileStorageVolumeRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetFileStorageVolume(ctx context.Context, params *GetFileStorageVolumeParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetFileStorageVolumeRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchFileStorageVolumeWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchFileStorageVolumeRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchFileStorageVolume(ctx context.Context, body PatchFileStorageVolumeJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchFileStorageVolumeRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetGpuTypes(ctx context.Context, params *GetGpuTypesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetGpuTypesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetGpuType(ctx context.Context, params *GetGpuTypeParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetGpuTypeRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostInvalidateLinkedWebSessionWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostInvalidateLinkedWebSessionRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostInvalidateLinkedWebSession(ctx context.Context, body PostInvalidateLinkedWebSessionJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostInvalidateLinkedWebSessionRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteIpAddressWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteIpAddressRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteIpAddress(ctx context.Context, body DeleteIpAddressJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteIpAddressRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetIpAddress(ctx context.Context, params *GetIpAddressParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetIpAddressRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchIpAddressWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchIpAddressRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchIpAddress(ctx context.Context, body PatchIpAddressJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchIpAddressRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostIpAddressUnallocateWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostIpAddressUnallocateRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostIpAddressUnallocate(ctx context.Context, body PostIpAddressUnallocateJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostIpAddressUnallocateRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteLoadBalancerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteLoadBalancerRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteLoadBalancer(ctx context.Context, body DeleteLoadBalancerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteLoadBalancerRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetLoadBalancer(ctx context.Context, params *GetLoadBalancerParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetLoadBalancerRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchLoadBalancerWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchLoadBalancerRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchLoadBalancer(ctx context.Context, body PatchLoadBalancerJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchLoadBalancerRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetLoadBalancerRules(ctx context.Context, params *GetLoadBalancerRulesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetLoadBalancerRulesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostLoadBalancerRulesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostLoadBalancerRulesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostLoadBalancerRules(ctx context.Context, body PostLoadBalancerRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostLoadBalancerRulesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteLoadBalancersRulesLoadBalancerRuleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteLoadBalancersRulesLoadBalancerRuleRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteLoadBalancersRulesLoadBalancerRule(ctx context.Context, body DeleteLoadBalancersRulesLoadBalancerRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteLoadBalancersRulesLoadBalancerRuleRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetLoadBalancersRulesLoadBalancerRule(ctx context.Context, params *GetLoadBalancersRulesLoadBalancerRuleParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetLoadBalancersRulesLoadBalancerRuleRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchLoadBalancersRulesLoadBalancerRuleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchLoadBalancersRulesLoadBalancerRuleRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchLoadBalancersRulesLoadBalancerRule(ctx context.Context, body PatchLoadBalancersRulesLoadBalancerRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchLoadBalancersRulesLoadBalancerRuleRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetNetwork(ctx context.Context, params *GetNetworkParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetNetworkRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOperatingSystems(ctx context.Context, params *GetOperatingSystemsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOperatingSystemsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOperatingSystem(ctx context.Context, params *GetOperatingSystemParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOperatingSystemRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizations(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationsRequest(c.Server) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganization(ctx context.Context, params *GetOrganizationParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationAvailableNetworks(ctx context.Context, params *GetOrganizationAvailableNetworksParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationAvailableNetworksRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationCertificates(ctx context.Context, params *GetOrganizationCertificatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationCertificatesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationDiskBackupPolicies(ctx context.Context, params *GetOrganizationDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationDiskBackupPoliciesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationDiskTemplates(ctx context.Context, params *GetOrganizationDiskTemplatesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationDiskTemplatesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationDisks(ctx context.Context, params *GetOrganizationDisksParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationDisksRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationDnsZones(ctx context.Context, params *GetOrganizationDnsZonesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationDnsZonesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationDnsZonesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationDnsZonesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationDnsZones(ctx context.Context, body PostOrganizationDnsZonesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationDnsZonesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationsOrganizationdnsZones(ctx context.Context, params *GetOrganizationsOrganizationdnsZonesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationsOrganizationdnsZonesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationsOrganizationdnsZonesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationsOrganizationdnsZonesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationsOrganizationdnsZones(ctx context.Context, body PostOrganizationsOrganizationdnsZonesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationsOrganizationdnsZonesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationDnsZonesNameservers(ctx context.Context, params *GetOrganizationDnsZonesNameserversParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationDnsZonesNameserversRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationFileStorageVolumes(ctx context.Context, params *GetOrganizationFileStorageVolumesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationFileStorageVolumesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationFileStorageVolumesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationFileStorageVolumesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationFileStorageVolumes(ctx context.Context, body PostOrganizationFileStorageVolumesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationFileStorageVolumesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationIpAddresses(ctx context.Context, params *GetOrganizationIpAddressesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationIpAddressesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationIpAddressesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationIpAddressesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationIpAddresses(ctx context.Context, body PostOrganizationIpAddressesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationIpAddressesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationLoadBalancers(ctx context.Context, params *GetOrganizationLoadBalancersParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationLoadBalancersRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationLoadBalancersWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationLoadBalancersRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationLoadBalancers(ctx context.Context, body PostOrganizationLoadBalancersJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationLoadBalancersRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationManaged(ctx context.Context, params *GetOrganizationManagedParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationManagedRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationManagedWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationManagedRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationManaged(ctx context.Context, body PostOrganizationManagedJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationManagedRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationNetworkSpeedProfiles(ctx context.Context, params *GetOrganizationNetworkSpeedProfilesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationNetworkSpeedProfilesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationSecurityGroups(ctx context.Context, params *GetOrganizationSecurityGroupsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationSecurityGroupsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationSecurityGroupsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationSecurityGroupsRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationSecurityGroups(ctx context.Context, body PostOrganizationSecurityGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationSecurityGroupsRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationSshKeys(ctx context.Context, params *GetOrganizationSshKeysParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationSshKeysRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationSshKeysWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationSshKeysRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationSshKeys(ctx context.Context, body PostOrganizationSshKeysJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationSshKeysRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationTags(ctx context.Context, params *GetOrganizationTagsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationTagsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationTagsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationTagsRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationTags(ctx context.Context, body PostOrganizationTagsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationTagsRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationTrashObjects(ctx context.Context, params *GetOrganizationTrashObjectsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationTrashObjectsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationTrashObjectsPurgeAllWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationTrashObjectsPurgeAllRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationTrashObjectsPurgeAll(ctx context.Context, body PostOrganizationTrashObjectsPurgeAllJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationTrashObjectsPurgeAllRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationUsersWithAccess(ctx context.Context, params *GetOrganizationUsersWithAccessParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationUsersWithAccessRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationVirtualMachineGroups(ctx context.Context, params *GetOrganizationVirtualMachineGroupsParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationVirtualMachineGroupsRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationVirtualMachineGroupsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationVirtualMachineGroupsRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationVirtualMachineGroups(ctx context.Context, body PostOrganizationVirtualMachineGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationVirtualMachineGroupsRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetOrganizationVirtualMachines(ctx context.Context, params *GetOrganizationVirtualMachinesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetOrganizationVirtualMachinesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationVirtualMachinesBuildWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationVirtualMachinesBuildRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationVirtualMachinesBuild(ctx context.Context, body PostOrganizationVirtualMachinesBuildJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationVirtualMachinesBuildRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationVirtualMachinesBuildFromSpecWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationVirtualMachinesBuildFromSpecRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostOrganizationVirtualMachinesBuildFromSpec(ctx context.Context, body PostOrganizationVirtualMachinesBuildFromSpecJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostOrganizationVirtualMachinesBuildFromSpecRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteSecurityGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSecurityGroupRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteSecurityGroup(ctx context.Context, body DeleteSecurityGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSecurityGroupRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetSecurityGroup(ctx context.Context, params *GetSecurityGroupParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSecurityGroupRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchSecurityGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchSecurityGroupRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchSecurityGroup(ctx context.Context, body PatchSecurityGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchSecurityGroupRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetSecurityGroupRules(ctx context.Context, params *GetSecurityGroupRulesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSecurityGroupRulesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostSecurityGroupRulesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostSecurityGroupRulesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostSecurityGroupRules(ctx context.Context, body PostSecurityGroupRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostSecurityGroupRulesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteSecurityGroupsRulesSecurityGroupRuleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSecurityGroupsRulesSecurityGroupRuleRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteSecurityGroupsRulesSecurityGroupRule(ctx context.Context, body DeleteSecurityGroupsRulesSecurityGroupRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSecurityGroupsRulesSecurityGroupRuleRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetSecurityGroupsRulesSecurityGroupRule(ctx context.Context, params *GetSecurityGroupsRulesSecurityGroupRuleParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetSecurityGroupsRulesSecurityGroupRuleRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchSecurityGroupsRulesSecurityGroupRuleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchSecurityGroupsRulesSecurityGroupRuleRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchSecurityGroupsRulesSecurityGroupRule(ctx context.Context, body PatchSecurityGroupsRulesSecurityGroupRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchSecurityGroupsRulesSecurityGroupRuleRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteSshKeyWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSshKeyRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteSshKey(ctx context.Context, body DeleteSshKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteSshKeyRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteTagWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteTagRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteTag(ctx context.Context, body DeleteTagJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteTagRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetTag(ctx context.Context, params *GetTagParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetTagRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchTagWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchTagRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchTag(ctx context.Context, body PatchTagJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchTagRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetTask(ctx context.Context, params *GetTaskParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetTaskRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteTrashObjectWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteTrashObjectRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteTrashObject(ctx context.Context, body DeleteTrashObjectJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteTrashObjectRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetTrashObject(ctx context.Context, params *GetTrashObjectParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetTrashObjectRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostTrashObjectRestoreWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostTrashObjectRestoreRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostTrashObjectRestore(ctx context.Context, body PostTrashObjectRestoreJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostTrashObjectRestoreRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetUsersCurrent(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetUsersCurrentRequest(c.Server) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteVirtualMachineGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteVirtualMachineGroupRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteVirtualMachineGroup(ctx context.Context, body DeleteVirtualMachineGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteVirtualMachineGroupRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachineGroup(ctx context.Context, params *GetVirtualMachineGroupParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachineGroupRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchVirtualMachineGroupWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchVirtualMachineGroupRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchVirtualMachineGroup(ctx context.Context, body PatchVirtualMachineGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchVirtualMachineGroupRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVMNIVMNI(ctx context.Context, params *GetVMNIVMNIParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVMNIVMNIRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineNetworkInterfaceAllocateIpWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineNetworkInterfaceAllocateIpRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineNetworkInterfaceAllocateIp(ctx context.Context, body PostVirtualMachineNetworkInterfaceAllocateIpJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineNetworkInterfaceAllocateIpRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineNetworkInterfaceAllocateNewIpWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineNetworkInterfaceAllocateNewIpRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineNetworkInterfaceAllocateNewIp(ctx context.Context, body PostVirtualMachineNetworkInterfaceAllocateNewIpJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineNetworkInterfaceAllocateNewIpRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersion(ctx context.Context, params *GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchVirtualMachineNetworkInterfaceUpdateSpeedProfileRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchVirtualMachineNetworkInterfaceUpdateSpeedProfile(ctx context.Context, body PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchVirtualMachineNetworkInterfaceUpdateSpeedProfileRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachinePackages(ctx context.Context, params *GetVirtualMachinePackagesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachinePackagesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachinePackage(ctx context.Context, params *GetVirtualMachinePackageParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachinePackageRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteVirtualMachineWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteVirtualMachineRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) DeleteVirtualMachine(ctx context.Context, body DeleteVirtualMachineJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewDeleteVirtualMachineRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachine(ctx context.Context, params *GetVirtualMachineParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachineRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchVirtualMachineWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchVirtualMachineRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PatchVirtualMachine(ctx context.Context, body PatchVirtualMachineJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPatchVirtualMachineRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineAllocateIpWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineAllocateIpRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineAllocateIp(ctx context.Context, body PostVirtualMachineAllocateIpJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineAllocateIpRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineConsoleSessionsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineConsoleSessionsRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineConsoleSessions(ctx context.Context, body PostVirtualMachineConsoleSessionsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineConsoleSessionsRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachineDiskBackupPolicies(ctx context.Context, params *GetVirtualMachineDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachineDiskBackupPoliciesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineDiskBackupPoliciesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineDiskBackupPoliciesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineDiskBackupPolicies(ctx context.Context, body PostVirtualMachineDiskBackupPoliciesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineDiskBackupPoliciesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachineDisks(ctx context.Context, params *GetVirtualMachineDisksParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachineDisksRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PutVirtualMachineFlexibleResourcesWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPutVirtualMachineFlexibleResourcesRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PutVirtualMachineFlexibleResources(ctx context.Context, body PutVirtualMachineFlexibleResourcesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPutVirtualMachineFlexibleResourcesRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachineNetworkInterfaces(ctx context.Context, params *GetVirtualMachineNetworkInterfacesParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachineNetworkInterfacesRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachineNetworkInterface(ctx context.Context, params *GetVirtualMachineNetworkInterfaceParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachineNetworkInterfaceRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PutVirtualMachinePackageWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPutVirtualMachinePackageRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PutVirtualMachinePackage(ctx context.Context, body PutVirtualMachinePackageJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPutVirtualMachinePackageRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineResetWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineResetRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineReset(ctx context.Context, body PostVirtualMachineResetJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineResetRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineShutdownWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineShutdownRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineShutdown(ctx context.Context, body PostVirtualMachineShutdownJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineShutdownRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineStartWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineStartRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineStart(ctx context.Context, body PostVirtualMachineStartJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineStartRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineStopWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineStopRequestWithBody(c.Server, contentType, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) PostVirtualMachineStop(ctx context.Context, body PostVirtualMachineStopJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewPostVirtualMachineStopRequest(c.Server, body) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetVirtualMachinesBuildsVirtualMachineBuild(ctx context.Context, params *GetVirtualMachinesBuildsVirtualMachineBuildParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetVirtualMachinesBuildsVirtualMachineBuildRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetZones(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetZonesRequest(c.Server) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +func (c *Client) GetZone(ctx context.Context, params *GetZoneParams, reqEditors ...RequestEditorFn) (*http.Response, error) { + req, err := NewGetZoneRequest(c.Server, params) + if err != nil { + return nil, err + } + req = req.WithContext(ctx) + if err := c.applyEditors(ctx, req, reqEditors); err != nil { + return nil, err + } + return c.Client.Do(req) +} + +// NewGetCertificateRequest generates requests for GetCertificate +func NewGetCertificateRequest(server string, params *GetCertificateParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/certificates/:certificate") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.CertificateId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "certificate[id]", runtime.ParamLocationQuery, *params.CertificateId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetCountriesRequest generates requests for GetCountries +func NewGetCountriesRequest(server string, params *GetCountriesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/countries") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetCountryRequest generates requests for GetCountry +func NewGetCountryRequest(server string, params *GetCountryParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/countries/:country") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.CountryId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "country[id]", runtime.ParamLocationQuery, *params.CountryId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.CountryIsoCode2 != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "country[iso_code2]", runtime.ParamLocationQuery, *params.CountryIsoCode2); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.CountryIsoCode3 != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "country[iso_code3]", runtime.ParamLocationQuery, *params.CountryIsoCode3); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetCountryCountryStatesRequest generates requests for GetCountryCountryStates +func NewGetCountryCountryStatesRequest(server string, params *GetCountryCountryStatesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/countries/:country/country_states") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.CountryId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "country[id]", runtime.ParamLocationQuery, *params.CountryId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.CountryIsoCode2 != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "country[iso_code2]", runtime.ParamLocationQuery, *params.CountryIsoCode2); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.CountryIsoCode3 != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "country[iso_code3]", runtime.ParamLocationQuery, *params.CountryIsoCode3); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetCountryStateRequest generates requests for GetCountryState +func NewGetCountryStateRequest(server string, params *GetCountryStateParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/country_states/:country_state") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.CountryStateId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "country_state[id]", runtime.ParamLocationQuery, *params.CountryStateId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetCurrenciesRequest generates requests for GetCurrencies +func NewGetCurrenciesRequest(server string, params *GetCurrenciesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/currencies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetCurrencyRequest generates requests for GetCurrency +func NewGetCurrencyRequest(server string, params *GetCurrencyParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/currencies/:currency") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.CurrencyId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "currency[id]", runtime.ParamLocationQuery, *params.CurrencyId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.CurrencyIsoCode != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "currency[iso_code]", runtime.ParamLocationQuery, *params.CurrencyIsoCode); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDataCentersRequest generates requests for GetDataCenters +func NewGetDataCentersRequest(server string) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/data_centers") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDataCenterRequest generates requests for GetDataCenter +func NewGetDataCenterRequest(server string, params *GetDataCenterParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/data_centers/:data_center") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DataCenterId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "data_center[id]", runtime.ParamLocationQuery, *params.DataCenterId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DataCenterPermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "data_center[permalink]", runtime.ParamLocationQuery, *params.DataCenterPermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDataCenterDefaultNetworkRequest generates requests for GetDataCenterDefaultNetwork +func NewGetDataCenterDefaultNetworkRequest(server string, params *GetDataCenterDefaultNetworkParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/data_centers/:data_center/default_network") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DataCenterId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "data_center[id]", runtime.ParamLocationQuery, *params.DataCenterId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DataCenterPermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "data_center[permalink]", runtime.ParamLocationQuery, *params.DataCenterPermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDataCenterGpuTypesRequest generates requests for GetDataCenterGpuTypes +func NewGetDataCenterGpuTypesRequest(server string, params *GetDataCenterGpuTypesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/data_centers/:data_center/gpu_types") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DataCenterId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "data_center[id]", runtime.ParamLocationQuery, *params.DataCenterId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DataCenterPermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "data_center[permalink]", runtime.ParamLocationQuery, *params.DataCenterPermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewDeleteDiskBackupPolicyRequest calls the generic DeleteDiskBackupPolicy builder with application/json body +func NewDeleteDiskBackupPolicyRequest(server string, body DeleteDiskBackupPolicyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteDiskBackupPolicyRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteDiskBackupPolicyRequestWithBody generates requests for DeleteDiskBackupPolicy with any type of body +func NewDeleteDiskBackupPolicyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disk_backup_policies/:disk_backup_policy") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetDiskBackupPolicyRequest generates requests for GetDiskBackupPolicy +func NewGetDiskBackupPolicyRequest(server string, params *GetDiskBackupPolicyParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disk_backup_policies/:disk_backup_policy") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DiskBackupPolicyId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk_backup_policy[id]", runtime.ParamLocationQuery, *params.DiskBackupPolicyId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchDiskBackupPolicyRequest calls the generic PatchDiskBackupPolicy builder with application/json body +func NewPatchDiskBackupPolicyRequest(server string, body PatchDiskBackupPolicyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchDiskBackupPolicyRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchDiskBackupPolicyRequestWithBody generates requests for PatchDiskBackupPolicy with any type of body +func NewPatchDiskBackupPolicyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disk_backup_policies/:disk_backup_policy") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteDiskBackupPolicyScheduleRequest calls the generic DeleteDiskBackupPolicySchedule builder with application/json body +func NewDeleteDiskBackupPolicyScheduleRequest(server string, body DeleteDiskBackupPolicyScheduleJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteDiskBackupPolicyScheduleRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteDiskBackupPolicyScheduleRequestWithBody generates requests for DeleteDiskBackupPolicySchedule with any type of body +func NewDeleteDiskBackupPolicyScheduleRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disk_backup_policies/:disk_backup_policy/schedule") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetDiskTemplateVersionRequest generates requests for GetDiskTemplateVersion +func NewGetDiskTemplateVersionRequest(server string, params *GetDiskTemplateVersionParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disk_template_versions/:disk_template_version") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DiskTemplateVersionId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk_template_version[id]", runtime.ParamLocationQuery, *params.DiskTemplateVersionId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDiskTemplateVersionSpecRequest generates requests for GetDiskTemplateVersionSpec +func NewGetDiskTemplateVersionSpecRequest(server string, params *GetDiskTemplateVersionSpecParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disk_template_versions/:disk_template_version/spec") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DiskTemplateVersionId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk_template_version[id]", runtime.ParamLocationQuery, *params.DiskTemplateVersionId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDiskTemplateRequest generates requests for GetDiskTemplate +func NewGetDiskTemplateRequest(server string, params *GetDiskTemplateParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disk_templates/:disk_template") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DiskTemplateId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk_template[id]", runtime.ParamLocationQuery, *params.DiskTemplateId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DiskTemplatePermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk_template[permalink]", runtime.ParamLocationQuery, *params.DiskTemplatePermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDiskTemplateVersionsRequest generates requests for GetDiskTemplateVersions +func NewGetDiskTemplateVersionsRequest(server string, params *GetDiskTemplateVersionsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disk_templates/:disk_template/versions") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DiskTemplateId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk_template[id]", runtime.ParamLocationQuery, *params.DiskTemplateId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DiskTemplatePermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk_template[permalink]", runtime.ParamLocationQuery, *params.DiskTemplatePermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDiskRequest generates requests for GetDisk +func NewGetDiskRequest(server string, params *GetDiskParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disks/:disk") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DiskId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk[id]", runtime.ParamLocationQuery, *params.DiskId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDiskDiskBackupPoliciesRequest generates requests for GetDiskDiskBackupPolicies +func NewGetDiskDiskBackupPoliciesRequest(server string, params *GetDiskDiskBackupPoliciesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disks/:disk/disk_backup_policies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DiskId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "disk[id]", runtime.ParamLocationQuery, *params.DiskId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostDiskDiskBackupPoliciesRequest calls the generic PostDiskDiskBackupPolicies builder with application/json body +func NewPostDiskDiskBackupPoliciesRequest(server string, body PostDiskDiskBackupPoliciesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostDiskDiskBackupPoliciesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostDiskDiskBackupPoliciesRequestWithBody generates requests for PostDiskDiskBackupPolicies with any type of body +func NewPostDiskDiskBackupPoliciesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/disks/:disk/disk_backup_policies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteDnsRecordsDnsRecordRequest calls the generic DeleteDnsRecordsDnsRecord builder with application/json body +func NewDeleteDnsRecordsDnsRecordRequest(server string, body DeleteDnsRecordsDnsRecordJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteDnsRecordsDnsRecordRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteDnsRecordsDnsRecordRequestWithBody generates requests for DeleteDnsRecordsDnsRecord with any type of body +func NewDeleteDnsRecordsDnsRecordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/records/:dns_record") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetDnsRecordsDnsRecordRequest generates requests for GetDnsRecordsDnsRecord +func NewGetDnsRecordsDnsRecordRequest(server string, params *GetDnsRecordsDnsRecordParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/records/:dns_record") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DnsRecordId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_record[id]", runtime.ParamLocationQuery, *params.DnsRecordId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchDnsRecordsDnsRecordRequest calls the generic PatchDnsRecordsDnsRecord builder with application/json body +func NewPatchDnsRecordsDnsRecordRequest(server string, body PatchDnsRecordsDnsRecordJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchDnsRecordsDnsRecordRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchDnsRecordsDnsRecordRequestWithBody generates requests for PatchDnsRecordsDnsRecord with any type of body +func NewPatchDnsRecordsDnsRecordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/records/:dns_record") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteDnsZonesDnsZoneRequest calls the generic DeleteDnsZonesDnsZone builder with application/json body +func NewDeleteDnsZonesDnsZoneRequest(server string, body DeleteDnsZonesDnsZoneJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteDnsZonesDnsZoneRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteDnsZonesDnsZoneRequestWithBody generates requests for DeleteDnsZonesDnsZone with any type of body +func NewDeleteDnsZonesDnsZoneRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/zones/:dns_zone") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetDnsZonesDnsZoneRequest generates requests for GetDnsZonesDnsZone +func NewGetDnsZonesDnsZoneRequest(server string, params *GetDnsZonesDnsZoneParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/zones/:dns_zone") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DnsZoneId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[id]", runtime.ParamLocationQuery, *params.DnsZoneId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DnsZoneName != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[name]", runtime.ParamLocationQuery, *params.DnsZoneName); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetDnsZonesDnsZoneRecordsRequest generates requests for GetDnsZonesDnsZoneRecords +func NewGetDnsZonesDnsZoneRecordsRequest(server string, params *GetDnsZonesDnsZoneRecordsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/zones/:dns_zone/records") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DnsZoneId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[id]", runtime.ParamLocationQuery, *params.DnsZoneId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DnsZoneName != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[name]", runtime.ParamLocationQuery, *params.DnsZoneName); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostDnsZonesDnsZoneRecordsRequest calls the generic PostDnsZonesDnsZoneRecords builder with application/json body +func NewPostDnsZonesDnsZoneRecordsRequest(server string, body PostDnsZonesDnsZoneRecordsJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostDnsZonesDnsZoneRecordsRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostDnsZonesDnsZoneRecordsRequestWithBody generates requests for PostDnsZonesDnsZoneRecords with any type of body +func NewPostDnsZonesDnsZoneRecordsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/zones/:dns_zone/records") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostDnsZonesDnsZoneUpdateTtlRequest calls the generic PostDnsZonesDnsZoneUpdateTtl builder with application/json body +func NewPostDnsZonesDnsZoneUpdateTtlRequest(server string, body PostDnsZonesDnsZoneUpdateTtlJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostDnsZonesDnsZoneUpdateTtlRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostDnsZonesDnsZoneUpdateTtlRequestWithBody generates requests for PostDnsZonesDnsZoneUpdateTtl with any type of body +func NewPostDnsZonesDnsZoneUpdateTtlRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/zones/:dns_zone/update_ttl") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetDnsZonesDnsZoneVerificationDetailsRequest generates requests for GetDnsZonesDnsZoneVerificationDetails +func NewGetDnsZonesDnsZoneVerificationDetailsRequest(server string, params *GetDnsZonesDnsZoneVerificationDetailsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/zones/:dns_zone/verification_details") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DnsZoneId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[id]", runtime.ParamLocationQuery, *params.DnsZoneId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DnsZoneName != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[name]", runtime.ParamLocationQuery, *params.DnsZoneName); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostDnsZonesDnsZoneVerifyRequest calls the generic PostDnsZonesDnsZoneVerify builder with application/json body +func NewPostDnsZonesDnsZoneVerifyRequest(server string, body PostDnsZonesDnsZoneVerifyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostDnsZonesDnsZoneVerifyRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostDnsZonesDnsZoneVerifyRequestWithBody generates requests for PostDnsZonesDnsZoneVerify with any type of body +func NewPostDnsZonesDnsZoneVerifyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns/zones/:dns_zone/verify") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteDnsRecordRequest calls the generic DeleteDnsRecord builder with application/json body +func NewDeleteDnsRecordRequest(server string, body DeleteDnsRecordJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteDnsRecordRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteDnsRecordRequestWithBody generates requests for DeleteDnsRecord with any type of body +func NewDeleteDnsRecordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_records/:dns_record") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetDnsRecordRequest generates requests for GetDnsRecord +func NewGetDnsRecordRequest(server string, params *GetDnsRecordParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_records/:dns_record") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DnsRecordId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_record[id]", runtime.ParamLocationQuery, *params.DnsRecordId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchDnsRecordRequest calls the generic PatchDnsRecord builder with application/json body +func NewPatchDnsRecordRequest(server string, body PatchDnsRecordJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchDnsRecordRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchDnsRecordRequestWithBody generates requests for PatchDnsRecord with any type of body +func NewPatchDnsRecordRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_records/:dns_record") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteDnsZoneRequest calls the generic DeleteDnsZone builder with application/json body +func NewDeleteDnsZoneRequest(server string, body DeleteDnsZoneJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteDnsZoneRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteDnsZoneRequestWithBody generates requests for DeleteDnsZone with any type of body +func NewDeleteDnsZoneRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_zones/:dns_zone") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetDnsZoneRequest generates requests for GetDnsZone +func NewGetDnsZoneRequest(server string, params *GetDnsZoneParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_zones/:dns_zone") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DnsZoneId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[id]", runtime.ParamLocationQuery, *params.DnsZoneId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DnsZoneName != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[name]", runtime.ParamLocationQuery, *params.DnsZoneName); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchDnsZoneRequest calls the generic PatchDnsZone builder with application/json body +func NewPatchDnsZoneRequest(server string, body PatchDnsZoneJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchDnsZoneRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchDnsZoneRequestWithBody generates requests for PatchDnsZone with any type of body +func NewPatchDnsZoneRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_zones/:dns_zone") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetDnsZoneRecordsRequest generates requests for GetDnsZoneRecords +func NewGetDnsZoneRecordsRequest(server string, params *GetDnsZoneRecordsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_zones/:dns_zone/records") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.DnsZoneId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[id]", runtime.ParamLocationQuery, *params.DnsZoneId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.DnsZoneName != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "dns_zone[name]", runtime.ParamLocationQuery, *params.DnsZoneName); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostDnsZoneRecordsRequest calls the generic PostDnsZoneRecords builder with application/json body +func NewPostDnsZoneRecordsRequest(server string, body PostDnsZoneRecordsJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostDnsZoneRecordsRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostDnsZoneRecordsRequestWithBody generates requests for PostDnsZoneRecords with any type of body +func NewPostDnsZoneRecordsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_zones/:dns_zone/records") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostDnsZoneVerifyRequest calls the generic PostDnsZoneVerify builder with application/json body +func NewPostDnsZoneVerifyRequest(server string, body PostDnsZoneVerifyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostDnsZoneVerifyRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostDnsZoneVerifyRequestWithBody generates requests for PostDnsZoneVerify with any type of body +func NewPostDnsZoneVerifyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/dns_zones/:dns_zone/verify") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteFileStorageVolumeRequest calls the generic DeleteFileStorageVolume builder with application/json body +func NewDeleteFileStorageVolumeRequest(server string, body DeleteFileStorageVolumeJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteFileStorageVolumeRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteFileStorageVolumeRequestWithBody generates requests for DeleteFileStorageVolume with any type of body +func NewDeleteFileStorageVolumeRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/file_storage_volumes/:file_storage_volume") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetFileStorageVolumeRequest generates requests for GetFileStorageVolume +func NewGetFileStorageVolumeRequest(server string, params *GetFileStorageVolumeParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/file_storage_volumes/:file_storage_volume") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.FileStorageVolumeId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "file_storage_volume[id]", runtime.ParamLocationQuery, *params.FileStorageVolumeId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchFileStorageVolumeRequest calls the generic PatchFileStorageVolume builder with application/json body +func NewPatchFileStorageVolumeRequest(server string, body PatchFileStorageVolumeJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchFileStorageVolumeRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchFileStorageVolumeRequestWithBody generates requests for PatchFileStorageVolume with any type of body +func NewPatchFileStorageVolumeRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/file_storage_volumes/:file_storage_volume") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetGpuTypesRequest generates requests for GetGpuTypes +func NewGetGpuTypesRequest(server string, params *GetGpuTypesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/gpu_types") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetGpuTypeRequest generates requests for GetGpuType +func NewGetGpuTypeRequest(server string, params *GetGpuTypeParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/gpu_types/:gpu_type") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.GpuTypeId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "gpu_type[id]", runtime.ParamLocationQuery, *params.GpuTypeId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.GpuTypePermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "gpu_type[permalink]", runtime.ParamLocationQuery, *params.GpuTypePermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostInvalidateLinkedWebSessionRequest calls the generic PostInvalidateLinkedWebSession builder with application/json body +func NewPostInvalidateLinkedWebSessionRequest(server string, body PostInvalidateLinkedWebSessionJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostInvalidateLinkedWebSessionRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostInvalidateLinkedWebSessionRequestWithBody generates requests for PostInvalidateLinkedWebSession with any type of body +func NewPostInvalidateLinkedWebSessionRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/invalidate_linked_web_session") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteIpAddressRequest calls the generic DeleteIpAddress builder with application/json body +func NewDeleteIpAddressRequest(server string, body DeleteIpAddressJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteIpAddressRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteIpAddressRequestWithBody generates requests for DeleteIpAddress with any type of body +func NewDeleteIpAddressRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/ip_addresses/:ip_address") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetIpAddressRequest generates requests for GetIpAddress +func NewGetIpAddressRequest(server string, params *GetIpAddressParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/ip_addresses/:ip_address") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.IpAddressId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "ip_address[id]", runtime.ParamLocationQuery, *params.IpAddressId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.IpAddressAddress != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "ip_address[address]", runtime.ParamLocationQuery, *params.IpAddressAddress); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchIpAddressRequest calls the generic PatchIpAddress builder with application/json body +func NewPatchIpAddressRequest(server string, body PatchIpAddressJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchIpAddressRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchIpAddressRequestWithBody generates requests for PatchIpAddress with any type of body +func NewPatchIpAddressRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/ip_addresses/:ip_address") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostIpAddressUnallocateRequest calls the generic PostIpAddressUnallocate builder with application/json body +func NewPostIpAddressUnallocateRequest(server string, body PostIpAddressUnallocateJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostIpAddressUnallocateRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostIpAddressUnallocateRequestWithBody generates requests for PostIpAddressUnallocate with any type of body +func NewPostIpAddressUnallocateRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/ip_addresses/:ip_address/unallocate") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteLoadBalancerRequest calls the generic DeleteLoadBalancer builder with application/json body +func NewDeleteLoadBalancerRequest(server string, body DeleteLoadBalancerJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteLoadBalancerRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteLoadBalancerRequestWithBody generates requests for DeleteLoadBalancer with any type of body +func NewDeleteLoadBalancerRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/load_balancers/:load_balancer") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetLoadBalancerRequest generates requests for GetLoadBalancer +func NewGetLoadBalancerRequest(server string, params *GetLoadBalancerParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/load_balancers/:load_balancer") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.LoadBalancerId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "load_balancer[id]", runtime.ParamLocationQuery, *params.LoadBalancerId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.LoadBalancerApiReference != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "load_balancer[api_reference]", runtime.ParamLocationQuery, *params.LoadBalancerApiReference); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchLoadBalancerRequest calls the generic PatchLoadBalancer builder with application/json body +func NewPatchLoadBalancerRequest(server string, body PatchLoadBalancerJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchLoadBalancerRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchLoadBalancerRequestWithBody generates requests for PatchLoadBalancer with any type of body +func NewPatchLoadBalancerRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/load_balancers/:load_balancer") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetLoadBalancerRulesRequest generates requests for GetLoadBalancerRules +func NewGetLoadBalancerRulesRequest(server string, params *GetLoadBalancerRulesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/load_balancers/:load_balancer/rules") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.LoadBalancerId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "load_balancer[id]", runtime.ParamLocationQuery, *params.LoadBalancerId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.LoadBalancerApiReference != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "load_balancer[api_reference]", runtime.ParamLocationQuery, *params.LoadBalancerApiReference); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostLoadBalancerRulesRequest calls the generic PostLoadBalancerRules builder with application/json body +func NewPostLoadBalancerRulesRequest(server string, body PostLoadBalancerRulesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostLoadBalancerRulesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostLoadBalancerRulesRequestWithBody generates requests for PostLoadBalancerRules with any type of body +func NewPostLoadBalancerRulesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/load_balancers/:load_balancer/rules") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteLoadBalancersRulesLoadBalancerRuleRequest calls the generic DeleteLoadBalancersRulesLoadBalancerRule builder with application/json body +func NewDeleteLoadBalancersRulesLoadBalancerRuleRequest(server string, body DeleteLoadBalancersRulesLoadBalancerRuleJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteLoadBalancersRulesLoadBalancerRuleRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteLoadBalancersRulesLoadBalancerRuleRequestWithBody generates requests for DeleteLoadBalancersRulesLoadBalancerRule with any type of body +func NewDeleteLoadBalancersRulesLoadBalancerRuleRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/load_balancers/rules/:load_balancer_rule") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetLoadBalancersRulesLoadBalancerRuleRequest generates requests for GetLoadBalancersRulesLoadBalancerRule +func NewGetLoadBalancersRulesLoadBalancerRuleRequest(server string, params *GetLoadBalancersRulesLoadBalancerRuleParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/load_balancers/rules/:load_balancer_rule") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.LoadBalancerRuleId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "load_balancer_rule[id]", runtime.ParamLocationQuery, *params.LoadBalancerRuleId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchLoadBalancersRulesLoadBalancerRuleRequest calls the generic PatchLoadBalancersRulesLoadBalancerRule builder with application/json body +func NewPatchLoadBalancersRulesLoadBalancerRuleRequest(server string, body PatchLoadBalancersRulesLoadBalancerRuleJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchLoadBalancersRulesLoadBalancerRuleRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchLoadBalancersRulesLoadBalancerRuleRequestWithBody generates requests for PatchLoadBalancersRulesLoadBalancerRule with any type of body +func NewPatchLoadBalancersRulesLoadBalancerRuleRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/load_balancers/rules/:load_balancer_rule") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetNetworkRequest generates requests for GetNetwork +func NewGetNetworkRequest(server string, params *GetNetworkParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/networks/:network") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.NetworkId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "network[id]", runtime.ParamLocationQuery, *params.NetworkId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.NetworkPermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "network[permalink]", runtime.ParamLocationQuery, *params.NetworkPermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOperatingSystemsRequest generates requests for GetOperatingSystems +func NewGetOperatingSystemsRequest(server string, params *GetOperatingSystemsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/operating_systems") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOperatingSystemRequest generates requests for GetOperatingSystem +func NewGetOperatingSystemRequest(server string, params *GetOperatingSystemParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/operating_systems/:operating_system") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OperatingSystemId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "operating_system[id]", runtime.ParamLocationQuery, *params.OperatingSystemId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationsRequest generates requests for GetOrganizations +func NewGetOrganizationsRequest(server string) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationRequest generates requests for GetOrganization +func NewGetOrganizationRequest(server string, params *GetOrganizationParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationAvailableNetworksRequest generates requests for GetOrganizationAvailableNetworks +func NewGetOrganizationAvailableNetworksRequest(server string, params *GetOrganizationAvailableNetworksParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/available_networks") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationCertificatesRequest generates requests for GetOrganizationCertificates +func NewGetOrganizationCertificatesRequest(server string, params *GetOrganizationCertificatesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/certificates") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationDiskBackupPoliciesRequest generates requests for GetOrganizationDiskBackupPolicies +func NewGetOrganizationDiskBackupPoliciesRequest(server string, params *GetOrganizationDiskBackupPoliciesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/disk_backup_policies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationDiskTemplatesRequest generates requests for GetOrganizationDiskTemplates +func NewGetOrganizationDiskTemplatesRequest(server string, params *GetOrganizationDiskTemplatesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/disk_templates") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.IncludeUniversal != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_universal", runtime.ParamLocationQuery, *params.IncludeUniversal); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OperatingSystemId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "operating_system[id]", runtime.ParamLocationQuery, *params.OperatingSystemId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationDisksRequest generates requests for GetOrganizationDisks +func NewGetOrganizationDisksRequest(server string, params *GetOrganizationDisksParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/disks") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationDnsZonesRequest generates requests for GetOrganizationDnsZones +func NewGetOrganizationDnsZonesRequest(server string, params *GetOrganizationDnsZonesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/dns/zones") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationDnsZonesRequest calls the generic PostOrganizationDnsZones builder with application/json body +func NewPostOrganizationDnsZonesRequest(server string, body PostOrganizationDnsZonesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationDnsZonesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationDnsZonesRequestWithBody generates requests for PostOrganizationDnsZones with any type of body +func NewPostOrganizationDnsZonesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/dns/zones") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationsOrganizationdnsZonesRequest generates requests for GetOrganizationsOrganizationdnsZones +func NewGetOrganizationsOrganizationdnsZonesRequest(server string, params *GetOrganizationsOrganizationdnsZonesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/dns_zones") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationsOrganizationdnsZonesRequest calls the generic PostOrganizationsOrganizationdnsZones builder with application/json body +func NewPostOrganizationsOrganizationdnsZonesRequest(server string, body PostOrganizationsOrganizationdnsZonesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationsOrganizationdnsZonesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationsOrganizationdnsZonesRequestWithBody generates requests for PostOrganizationsOrganizationdnsZones with any type of body +func NewPostOrganizationsOrganizationdnsZonesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/dns_zones") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationDnsZonesNameserversRequest generates requests for GetOrganizationDnsZonesNameservers +func NewGetOrganizationDnsZonesNameserversRequest(server string, params *GetOrganizationDnsZonesNameserversParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/dns_zones/nameservers") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationFileStorageVolumesRequest generates requests for GetOrganizationFileStorageVolumes +func NewGetOrganizationFileStorageVolumesRequest(server string, params *GetOrganizationFileStorageVolumesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/file_storage_volumes") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationFileStorageVolumesRequest calls the generic PostOrganizationFileStorageVolumes builder with application/json body +func NewPostOrganizationFileStorageVolumesRequest(server string, body PostOrganizationFileStorageVolumesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationFileStorageVolumesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationFileStorageVolumesRequestWithBody generates requests for PostOrganizationFileStorageVolumes with any type of body +func NewPostOrganizationFileStorageVolumesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/file_storage_volumes") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationIpAddressesRequest generates requests for GetOrganizationIpAddresses +func NewGetOrganizationIpAddressesRequest(server string, params *GetOrganizationIpAddressesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/ip_addresses") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Allocated != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "allocated", runtime.ParamLocationQuery, *params.Allocated); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationIpAddressesRequest calls the generic PostOrganizationIpAddresses builder with application/json body +func NewPostOrganizationIpAddressesRequest(server string, body PostOrganizationIpAddressesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationIpAddressesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationIpAddressesRequestWithBody generates requests for PostOrganizationIpAddresses with any type of body +func NewPostOrganizationIpAddressesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/ip_addresses") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationLoadBalancersRequest generates requests for GetOrganizationLoadBalancers +func NewGetOrganizationLoadBalancersRequest(server string, params *GetOrganizationLoadBalancersParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/load_balancers") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationLoadBalancersRequest calls the generic PostOrganizationLoadBalancers builder with application/json body +func NewPostOrganizationLoadBalancersRequest(server string, body PostOrganizationLoadBalancersJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationLoadBalancersRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationLoadBalancersRequestWithBody generates requests for PostOrganizationLoadBalancers with any type of body +func NewPostOrganizationLoadBalancersRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/load_balancers") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationManagedRequest generates requests for GetOrganizationManaged +func NewGetOrganizationManagedRequest(server string, params *GetOrganizationManagedParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/managed") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationManagedRequest calls the generic PostOrganizationManaged builder with application/json body +func NewPostOrganizationManagedRequest(server string, body PostOrganizationManagedJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationManagedRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationManagedRequestWithBody generates requests for PostOrganizationManaged with any type of body +func NewPostOrganizationManagedRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/managed") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationNetworkSpeedProfilesRequest generates requests for GetOrganizationNetworkSpeedProfiles +func NewGetOrganizationNetworkSpeedProfilesRequest(server string, params *GetOrganizationNetworkSpeedProfilesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/network_speed_profiles") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationSecurityGroupsRequest generates requests for GetOrganizationSecurityGroups +func NewGetOrganizationSecurityGroupsRequest(server string, params *GetOrganizationSecurityGroupsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/security_groups") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationSecurityGroupsRequest calls the generic PostOrganizationSecurityGroups builder with application/json body +func NewPostOrganizationSecurityGroupsRequest(server string, body PostOrganizationSecurityGroupsJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationSecurityGroupsRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationSecurityGroupsRequestWithBody generates requests for PostOrganizationSecurityGroups with any type of body +func NewPostOrganizationSecurityGroupsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/security_groups") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationSshKeysRequest generates requests for GetOrganizationSshKeys +func NewGetOrganizationSshKeysRequest(server string, params *GetOrganizationSshKeysParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/ssh_keys") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationSshKeysRequest calls the generic PostOrganizationSshKeys builder with application/json body +func NewPostOrganizationSshKeysRequest(server string, body PostOrganizationSshKeysJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationSshKeysRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationSshKeysRequestWithBody generates requests for PostOrganizationSshKeys with any type of body +func NewPostOrganizationSshKeysRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/ssh_keys") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationTagsRequest generates requests for GetOrganizationTags +func NewGetOrganizationTagsRequest(server string, params *GetOrganizationTagsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/tags") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationTagsRequest calls the generic PostOrganizationTags builder with application/json body +func NewPostOrganizationTagsRequest(server string, body PostOrganizationTagsJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationTagsRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationTagsRequestWithBody generates requests for PostOrganizationTags with any type of body +func NewPostOrganizationTagsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/tags") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationTrashObjectsRequest generates requests for GetOrganizationTrashObjects +func NewGetOrganizationTrashObjectsRequest(server string, params *GetOrganizationTrashObjectsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/trash_objects") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationTrashObjectsPurgeAllRequest calls the generic PostOrganizationTrashObjectsPurgeAll builder with application/json body +func NewPostOrganizationTrashObjectsPurgeAllRequest(server string, body PostOrganizationTrashObjectsPurgeAllJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationTrashObjectsPurgeAllRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationTrashObjectsPurgeAllRequestWithBody generates requests for PostOrganizationTrashObjectsPurgeAll with any type of body +func NewPostOrganizationTrashObjectsPurgeAllRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/trash_objects/purge_all") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationUsersWithAccessRequest generates requests for GetOrganizationUsersWithAccess +func NewGetOrganizationUsersWithAccessRequest(server string, params *GetOrganizationUsersWithAccessParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/users_with_access") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetOrganizationVirtualMachineGroupsRequest generates requests for GetOrganizationVirtualMachineGroups +func NewGetOrganizationVirtualMachineGroupsRequest(server string, params *GetOrganizationVirtualMachineGroupsParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/virtual_machine_groups") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationVirtualMachineGroupsRequest calls the generic PostOrganizationVirtualMachineGroups builder with application/json body +func NewPostOrganizationVirtualMachineGroupsRequest(server string, body PostOrganizationVirtualMachineGroupsJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationVirtualMachineGroupsRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationVirtualMachineGroupsRequestWithBody generates requests for PostOrganizationVirtualMachineGroups with any type of body +func NewPostOrganizationVirtualMachineGroupsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/virtual_machine_groups") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetOrganizationVirtualMachinesRequest generates requests for GetOrganizationVirtualMachines +func NewGetOrganizationVirtualMachinesRequest(server string, params *GetOrganizationVirtualMachinesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/virtual_machines") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostOrganizationVirtualMachinesBuildRequest calls the generic PostOrganizationVirtualMachinesBuild builder with application/json body +func NewPostOrganizationVirtualMachinesBuildRequest(server string, body PostOrganizationVirtualMachinesBuildJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationVirtualMachinesBuildRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationVirtualMachinesBuildRequestWithBody generates requests for PostOrganizationVirtualMachinesBuild with any type of body +func NewPostOrganizationVirtualMachinesBuildRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/virtual_machines/build") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostOrganizationVirtualMachinesBuildFromSpecRequest calls the generic PostOrganizationVirtualMachinesBuildFromSpec builder with application/json body +func NewPostOrganizationVirtualMachinesBuildFromSpecRequest(server string, body PostOrganizationVirtualMachinesBuildFromSpecJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostOrganizationVirtualMachinesBuildFromSpecRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostOrganizationVirtualMachinesBuildFromSpecRequestWithBody generates requests for PostOrganizationVirtualMachinesBuildFromSpec with any type of body +func NewPostOrganizationVirtualMachinesBuildFromSpecRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/organizations/:organization/virtual_machines/build_from_spec") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteSecurityGroupRequest calls the generic DeleteSecurityGroup builder with application/json body +func NewDeleteSecurityGroupRequest(server string, body DeleteSecurityGroupJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteSecurityGroupRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteSecurityGroupRequestWithBody generates requests for DeleteSecurityGroup with any type of body +func NewDeleteSecurityGroupRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/security_groups/:security_group") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetSecurityGroupRequest generates requests for GetSecurityGroup +func NewGetSecurityGroupRequest(server string, params *GetSecurityGroupParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/security_groups/:security_group") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.SecurityGroupId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "security_group[id]", runtime.ParamLocationQuery, *params.SecurityGroupId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchSecurityGroupRequest calls the generic PatchSecurityGroup builder with application/json body +func NewPatchSecurityGroupRequest(server string, body PatchSecurityGroupJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchSecurityGroupRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchSecurityGroupRequestWithBody generates requests for PatchSecurityGroup with any type of body +func NewPatchSecurityGroupRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/security_groups/:security_group") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetSecurityGroupRulesRequest generates requests for GetSecurityGroupRules +func NewGetSecurityGroupRulesRequest(server string, params *GetSecurityGroupRulesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/security_groups/:security_group/rules") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.SecurityGroupId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "security_group[id]", runtime.ParamLocationQuery, *params.SecurityGroupId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostSecurityGroupRulesRequest calls the generic PostSecurityGroupRules builder with application/json body +func NewPostSecurityGroupRulesRequest(server string, body PostSecurityGroupRulesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostSecurityGroupRulesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostSecurityGroupRulesRequestWithBody generates requests for PostSecurityGroupRules with any type of body +func NewPostSecurityGroupRulesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/security_groups/:security_group/rules") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteSecurityGroupsRulesSecurityGroupRuleRequest calls the generic DeleteSecurityGroupsRulesSecurityGroupRule builder with application/json body +func NewDeleteSecurityGroupsRulesSecurityGroupRuleRequest(server string, body DeleteSecurityGroupsRulesSecurityGroupRuleJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteSecurityGroupsRulesSecurityGroupRuleRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteSecurityGroupsRulesSecurityGroupRuleRequestWithBody generates requests for DeleteSecurityGroupsRulesSecurityGroupRule with any type of body +func NewDeleteSecurityGroupsRulesSecurityGroupRuleRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/security_groups/rules/:security_group_rule") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetSecurityGroupsRulesSecurityGroupRuleRequest generates requests for GetSecurityGroupsRulesSecurityGroupRule +func NewGetSecurityGroupsRulesSecurityGroupRuleRequest(server string, params *GetSecurityGroupsRulesSecurityGroupRuleParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/security_groups/rules/:security_group_rule") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.SecurityGroupRuleId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "security_group_rule[id]", runtime.ParamLocationQuery, *params.SecurityGroupRuleId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchSecurityGroupsRulesSecurityGroupRuleRequest calls the generic PatchSecurityGroupsRulesSecurityGroupRule builder with application/json body +func NewPatchSecurityGroupsRulesSecurityGroupRuleRequest(server string, body PatchSecurityGroupsRulesSecurityGroupRuleJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchSecurityGroupsRulesSecurityGroupRuleRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchSecurityGroupsRulesSecurityGroupRuleRequestWithBody generates requests for PatchSecurityGroupsRulesSecurityGroupRule with any type of body +func NewPatchSecurityGroupsRulesSecurityGroupRuleRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/security_groups/rules/:security_group_rule") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteSshKeyRequest calls the generic DeleteSshKey builder with application/json body +func NewDeleteSshKeyRequest(server string, body DeleteSshKeyJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteSshKeyRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteSshKeyRequestWithBody generates requests for DeleteSshKey with any type of body +func NewDeleteSshKeyRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/ssh_keys/:ssh_key") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewDeleteTagRequest calls the generic DeleteTag builder with application/json body +func NewDeleteTagRequest(server string, body DeleteTagJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteTagRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteTagRequestWithBody generates requests for DeleteTag with any type of body +func NewDeleteTagRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/tags/:tag") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetTagRequest generates requests for GetTag +func NewGetTagRequest(server string, params *GetTagParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/tags/:tag") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.TagId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "tag[id]", runtime.ParamLocationQuery, *params.TagId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchTagRequest calls the generic PatchTag builder with application/json body +func NewPatchTagRequest(server string, body PatchTagJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchTagRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchTagRequestWithBody generates requests for PatchTag with any type of body +func NewPatchTagRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/tags/:tag") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetTaskRequest generates requests for GetTask +func NewGetTaskRequest(server string, params *GetTaskParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/tasks/:task") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.TaskId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "task[id]", runtime.ParamLocationQuery, *params.TaskId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewDeleteTrashObjectRequest calls the generic DeleteTrashObject builder with application/json body +func NewDeleteTrashObjectRequest(server string, body DeleteTrashObjectJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteTrashObjectRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteTrashObjectRequestWithBody generates requests for DeleteTrashObject with any type of body +func NewDeleteTrashObjectRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/trash_objects/:trash_object") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetTrashObjectRequest generates requests for GetTrashObject +func NewGetTrashObjectRequest(server string, params *GetTrashObjectParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/trash_objects/:trash_object") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.TrashObjectId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "trash_object[id]", runtime.ParamLocationQuery, *params.TrashObjectId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.TrashObjectObjectId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "trash_object[object_id]", runtime.ParamLocationQuery, *params.TrashObjectObjectId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostTrashObjectRestoreRequest calls the generic PostTrashObjectRestore builder with application/json body +func NewPostTrashObjectRestoreRequest(server string, body PostTrashObjectRestoreJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostTrashObjectRestoreRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostTrashObjectRestoreRequestWithBody generates requests for PostTrashObjectRestore with any type of body +func NewPostTrashObjectRestoreRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/trash_objects/:trash_object/restore") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetUsersCurrentRequest generates requests for GetUsersCurrent +func NewGetUsersCurrentRequest(server string) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/users/current") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewDeleteVirtualMachineGroupRequest calls the generic DeleteVirtualMachineGroup builder with application/json body +func NewDeleteVirtualMachineGroupRequest(server string, body DeleteVirtualMachineGroupJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteVirtualMachineGroupRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteVirtualMachineGroupRequestWithBody generates requests for DeleteVirtualMachineGroup with any type of body +func NewDeleteVirtualMachineGroupRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_groups/:virtual_machine_group") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVirtualMachineGroupRequest generates requests for GetVirtualMachineGroup +func NewGetVirtualMachineGroupRequest(server string, params *GetVirtualMachineGroupParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_groups/:virtual_machine_group") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineGroupId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine_group[id]", runtime.ParamLocationQuery, *params.VirtualMachineGroupId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchVirtualMachineGroupRequest calls the generic PatchVirtualMachineGroup builder with application/json body +func NewPatchVirtualMachineGroupRequest(server string, body PatchVirtualMachineGroupJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchVirtualMachineGroupRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchVirtualMachineGroupRequestWithBody generates requests for PatchVirtualMachineGroup with any type of body +func NewPatchVirtualMachineGroupRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_groups/:virtual_machine_group") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVMNIVMNIRequest generates requests for GetVMNIVMNI +func NewGetVMNIVMNIRequest(server string, params *GetVMNIVMNIParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_network_interfaces/:virtual_machine_network_interface") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineNetworkInterfaceId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine_network_interface[id]", runtime.ParamLocationQuery, *params.VirtualMachineNetworkInterfaceId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostVirtualMachineNetworkInterfaceAllocateIpRequest calls the generic PostVirtualMachineNetworkInterfaceAllocateIp builder with application/json body +func NewPostVirtualMachineNetworkInterfaceAllocateIpRequest(server string, body PostVirtualMachineNetworkInterfaceAllocateIpJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineNetworkInterfaceAllocateIpRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineNetworkInterfaceAllocateIpRequestWithBody generates requests for PostVirtualMachineNetworkInterfaceAllocateIp with any type of body +func NewPostVirtualMachineNetworkInterfaceAllocateIpRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_network_interfaces/:virtual_machine_network_interface/allocate_ip") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostVirtualMachineNetworkInterfaceAllocateNewIpRequest calls the generic PostVirtualMachineNetworkInterfaceAllocateNewIp builder with application/json body +func NewPostVirtualMachineNetworkInterfaceAllocateNewIpRequest(server string, body PostVirtualMachineNetworkInterfaceAllocateNewIpJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineNetworkInterfaceAllocateNewIpRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineNetworkInterfaceAllocateNewIpRequestWithBody generates requests for PostVirtualMachineNetworkInterfaceAllocateNewIp with any type of body +func NewPostVirtualMachineNetworkInterfaceAllocateNewIpRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_network_interfaces/:virtual_machine_network_interface/allocate_new_ip") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionRequest generates requests for GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersion +func NewGetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionRequest(server string, params *GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_network_interfaces/:virtual_machine_network_interface/available_ips/:address_version") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineNetworkInterfaceId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine_network_interface[id]", runtime.ParamLocationQuery, *params.VirtualMachineNetworkInterfaceId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "address_version", runtime.ParamLocationQuery, params.AddressVersion); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchVirtualMachineNetworkInterfaceUpdateSpeedProfileRequest calls the generic PatchVirtualMachineNetworkInterfaceUpdateSpeedProfile builder with application/json body +func NewPatchVirtualMachineNetworkInterfaceUpdateSpeedProfileRequest(server string, body PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchVirtualMachineNetworkInterfaceUpdateSpeedProfileRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchVirtualMachineNetworkInterfaceUpdateSpeedProfileRequestWithBody generates requests for PatchVirtualMachineNetworkInterfaceUpdateSpeedProfile with any type of body +func NewPatchVirtualMachineNetworkInterfaceUpdateSpeedProfileRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_network_interfaces/:virtual_machine_network_interface/update_speed_profile") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVirtualMachinePackagesRequest generates requests for GetVirtualMachinePackages +func NewGetVirtualMachinePackagesRequest(server string, params *GetVirtualMachinePackagesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_packages") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.OrganizationId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[id]", runtime.ParamLocationQuery, *params.OrganizationId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.OrganizationSubDomain != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "organization[sub_domain]", runtime.ParamLocationQuery, *params.OrganizationSubDomain); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetVirtualMachinePackageRequest generates requests for GetVirtualMachinePackage +func NewGetVirtualMachinePackageRequest(server string, params *GetVirtualMachinePackageParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machine_packages/:virtual_machine_package") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachinePackageId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine_package[id]", runtime.ParamLocationQuery, *params.VirtualMachinePackageId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.VirtualMachinePackagePermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine_package[permalink]", runtime.ParamLocationQuery, *params.VirtualMachinePackagePermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewDeleteVirtualMachineRequest calls the generic DeleteVirtualMachine builder with application/json body +func NewDeleteVirtualMachineRequest(server string, body DeleteVirtualMachineJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewDeleteVirtualMachineRequestWithBody(server, "application/json", bodyReader) +} + +// NewDeleteVirtualMachineRequestWithBody generates requests for DeleteVirtualMachine with any type of body +func NewDeleteVirtualMachineRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("DELETE", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVirtualMachineRequest generates requests for GetVirtualMachine +func NewGetVirtualMachineRequest(server string, params *GetVirtualMachineParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[id]", runtime.ParamLocationQuery, *params.VirtualMachineId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.VirtualMachineFqdn != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[fqdn]", runtime.ParamLocationQuery, *params.VirtualMachineFqdn); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPatchVirtualMachineRequest calls the generic PatchVirtualMachine builder with application/json body +func NewPatchVirtualMachineRequest(server string, body PatchVirtualMachineJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPatchVirtualMachineRequestWithBody(server, "application/json", bodyReader) +} + +// NewPatchVirtualMachineRequestWithBody generates requests for PatchVirtualMachine with any type of body +func NewPatchVirtualMachineRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PATCH", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostVirtualMachineAllocateIpRequest calls the generic PostVirtualMachineAllocateIp builder with application/json body +func NewPostVirtualMachineAllocateIpRequest(server string, body PostVirtualMachineAllocateIpJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineAllocateIpRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineAllocateIpRequestWithBody generates requests for PostVirtualMachineAllocateIp with any type of body +func NewPostVirtualMachineAllocateIpRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/allocate_ip") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostVirtualMachineConsoleSessionsRequest calls the generic PostVirtualMachineConsoleSessions builder with application/json body +func NewPostVirtualMachineConsoleSessionsRequest(server string, body PostVirtualMachineConsoleSessionsJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineConsoleSessionsRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineConsoleSessionsRequestWithBody generates requests for PostVirtualMachineConsoleSessions with any type of body +func NewPostVirtualMachineConsoleSessionsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/console_sessions") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVirtualMachineDiskBackupPoliciesRequest generates requests for GetVirtualMachineDiskBackupPolicies +func NewGetVirtualMachineDiskBackupPoliciesRequest(server string, params *GetVirtualMachineDiskBackupPoliciesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/disk_backup_policies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[id]", runtime.ParamLocationQuery, *params.VirtualMachineId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.VirtualMachineFqdn != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[fqdn]", runtime.ParamLocationQuery, *params.VirtualMachineFqdn); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.IncludeDisks != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "include_disks", runtime.ParamLocationQuery, *params.IncludeDisks); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPostVirtualMachineDiskBackupPoliciesRequest calls the generic PostVirtualMachineDiskBackupPolicies builder with application/json body +func NewPostVirtualMachineDiskBackupPoliciesRequest(server string, body PostVirtualMachineDiskBackupPoliciesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineDiskBackupPoliciesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineDiskBackupPoliciesRequestWithBody generates requests for PostVirtualMachineDiskBackupPolicies with any type of body +func NewPostVirtualMachineDiskBackupPoliciesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/disk_backup_policies") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVirtualMachineDisksRequest generates requests for GetVirtualMachineDisks +func NewGetVirtualMachineDisksRequest(server string, params *GetVirtualMachineDisksParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/disks") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[id]", runtime.ParamLocationQuery, *params.VirtualMachineId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.VirtualMachineFqdn != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[fqdn]", runtime.ParamLocationQuery, *params.VirtualMachineFqdn); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPutVirtualMachineFlexibleResourcesRequest calls the generic PutVirtualMachineFlexibleResources builder with application/json body +func NewPutVirtualMachineFlexibleResourcesRequest(server string, body PutVirtualMachineFlexibleResourcesJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPutVirtualMachineFlexibleResourcesRequestWithBody(server, "application/json", bodyReader) +} + +// NewPutVirtualMachineFlexibleResourcesRequestWithBody generates requests for PutVirtualMachineFlexibleResources with any type of body +func NewPutVirtualMachineFlexibleResourcesRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/flexible_resources") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PUT", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVirtualMachineNetworkInterfacesRequest generates requests for GetVirtualMachineNetworkInterfaces +func NewGetVirtualMachineNetworkInterfacesRequest(server string, params *GetVirtualMachineNetworkInterfacesParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/network_interfaces") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[id]", runtime.ParamLocationQuery, *params.VirtualMachineId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.VirtualMachineFqdn != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[fqdn]", runtime.ParamLocationQuery, *params.VirtualMachineFqdn); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.Page != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "page", runtime.ParamLocationQuery, *params.Page); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.PerPage != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "per_page", runtime.ParamLocationQuery, *params.PerPage); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetVirtualMachineNetworkInterfaceRequest generates requests for GetVirtualMachineNetworkInterface +func NewGetVirtualMachineNetworkInterfaceRequest(server string, params *GetVirtualMachineNetworkInterfaceParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/networks/:network/interface") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[id]", runtime.ParamLocationQuery, *params.VirtualMachineId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.VirtualMachineFqdn != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine[fqdn]", runtime.ParamLocationQuery, *params.VirtualMachineFqdn); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.NetworkId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "network[id]", runtime.ParamLocationQuery, *params.NetworkId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.NetworkPermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "network[permalink]", runtime.ParamLocationQuery, *params.NetworkPermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewPutVirtualMachinePackageRequest calls the generic PutVirtualMachinePackage builder with application/json body +func NewPutVirtualMachinePackageRequest(server string, body PutVirtualMachinePackageJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPutVirtualMachinePackageRequestWithBody(server, "application/json", bodyReader) +} + +// NewPutVirtualMachinePackageRequestWithBody generates requests for PutVirtualMachinePackage with any type of body +func NewPutVirtualMachinePackageRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/package") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("PUT", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostVirtualMachineResetRequest calls the generic PostVirtualMachineReset builder with application/json body +func NewPostVirtualMachineResetRequest(server string, body PostVirtualMachineResetJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineResetRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineResetRequestWithBody generates requests for PostVirtualMachineReset with any type of body +func NewPostVirtualMachineResetRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/reset") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostVirtualMachineShutdownRequest calls the generic PostVirtualMachineShutdown builder with application/json body +func NewPostVirtualMachineShutdownRequest(server string, body PostVirtualMachineShutdownJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineShutdownRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineShutdownRequestWithBody generates requests for PostVirtualMachineShutdown with any type of body +func NewPostVirtualMachineShutdownRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/shutdown") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostVirtualMachineStartRequest calls the generic PostVirtualMachineStart builder with application/json body +func NewPostVirtualMachineStartRequest(server string, body PostVirtualMachineStartJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineStartRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineStartRequestWithBody generates requests for PostVirtualMachineStart with any type of body +func NewPostVirtualMachineStartRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/start") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewPostVirtualMachineStopRequest calls the generic PostVirtualMachineStop builder with application/json body +func NewPostVirtualMachineStopRequest(server string, body PostVirtualMachineStopJSONRequestBody) (*http.Request, error) { + var bodyReader io.Reader + buf, err := json.Marshal(body) + if err != nil { + return nil, err + } + bodyReader = bytes.NewReader(buf) + return NewPostVirtualMachineStopRequestWithBody(server, "application/json", bodyReader) +} + +// NewPostVirtualMachineStopRequestWithBody generates requests for PostVirtualMachineStop with any type of body +func NewPostVirtualMachineStopRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/:virtual_machine/stop") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("POST", queryURL.String(), body) + if err != nil { + return nil, err + } + + req.Header.Add("Content-Type", contentType) + + return req, nil +} + +// NewGetVirtualMachinesBuildsVirtualMachineBuildRequest generates requests for GetVirtualMachinesBuildsVirtualMachineBuild +func NewGetVirtualMachinesBuildsVirtualMachineBuildRequest(server string, params *GetVirtualMachinesBuildsVirtualMachineBuildParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/virtual_machines/builds/:virtual_machine_build") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.VirtualMachineBuildId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "virtual_machine_build[id]", runtime.ParamLocationQuery, *params.VirtualMachineBuildId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetZonesRequest generates requests for GetZones +func NewGetZonesRequest(server string) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/zones") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +// NewGetZoneRequest generates requests for GetZone +func NewGetZoneRequest(server string, params *GetZoneParams) (*http.Request, error) { + var err error + + serverURL, err := url.Parse(server) + if err != nil { + return nil, err + } + + operationPath := fmt.Sprintf("/zones/:zone") + if operationPath[0] == '/' { + operationPath = "." + operationPath + } + + queryURL, err := serverURL.Parse(operationPath) + if err != nil { + return nil, err + } + + if params != nil { + queryValues := queryURL.Query() + + if params.ZoneId != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "zone[id]", runtime.ParamLocationQuery, *params.ZoneId); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + if params.ZonePermalink != nil { + + if queryFrag, err := runtime.StyleParamWithLocation("form", true, "zone[permalink]", runtime.ParamLocationQuery, *params.ZonePermalink); err != nil { + return nil, err + } else if parsed, err := url.ParseQuery(queryFrag); err != nil { + return nil, err + } else { + for k, v := range parsed { + for _, v2 := range v { + queryValues.Add(k, v2) + } + } + } + + } + + queryURL.RawQuery = queryValues.Encode() + } + + req, err := http.NewRequest("GET", queryURL.String(), nil) + if err != nil { + return nil, err + } + + return req, nil +} + +func (c *Client) applyEditors(ctx context.Context, req *http.Request, additionalEditors []RequestEditorFn) error { + for _, r := range c.RequestEditors { + if err := r(ctx, req); err != nil { + return err + } + } + for _, r := range additionalEditors { + if err := r(ctx, req); err != nil { + return err + } + } + return nil +} // ClientWithResponses builds on ClientInterface to offer response payloads +type ClientWithResponses struct { + ClientInterface +} + +// NewClientWithResponses creates a new ClientWithResponses, which wraps +// Client with return type handling +func NewClientWithResponses(server string, token string, opts ...ClientOption) (*ClientWithResponses, error) { + client, err := NewClient(server, token, opts...) + if err != nil { + return nil, err + } + return &ClientWithResponses{client}, nil +} + +// WithBaseURL overrides the baseURL. +func WithBaseURL(baseURL string) ClientOption { + return func(c *Client) error { + newBaseURL, err := url.Parse(baseURL) + if err != nil { + return err + } + c.Server = newBaseURL.String() + return nil + } +} + +// ClientWithResponsesInterface is the interface specification for the client with responses above. +type ClientWithResponsesInterface interface { + // GetCertificateWithResponse request + GetCertificateWithResponse(ctx context.Context, params *GetCertificateParams, reqEditors ...RequestEditorFn) (*GetCertificateResponse, error) + + // GetCountriesWithResponse request + GetCountriesWithResponse(ctx context.Context, params *GetCountriesParams, reqEditors ...RequestEditorFn) (*GetCountriesResponse, error) + + // GetCountryWithResponse request + GetCountryWithResponse(ctx context.Context, params *GetCountryParams, reqEditors ...RequestEditorFn) (*GetCountryResponse, error) + + // GetCountryCountryStatesWithResponse request + GetCountryCountryStatesWithResponse(ctx context.Context, params *GetCountryCountryStatesParams, reqEditors ...RequestEditorFn) (*GetCountryCountryStatesResponse, error) + + // GetCountryStateWithResponse request + GetCountryStateWithResponse(ctx context.Context, params *GetCountryStateParams, reqEditors ...RequestEditorFn) (*GetCountryStateResponse, error) + + // GetCurrenciesWithResponse request + GetCurrenciesWithResponse(ctx context.Context, params *GetCurrenciesParams, reqEditors ...RequestEditorFn) (*GetCurrenciesResponse, error) + + // GetCurrencyWithResponse request + GetCurrencyWithResponse(ctx context.Context, params *GetCurrencyParams, reqEditors ...RequestEditorFn) (*GetCurrencyResponse, error) + + // GetDataCentersWithResponse request + GetDataCentersWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetDataCentersResponse, error) + + // GetDataCenterWithResponse request + GetDataCenterWithResponse(ctx context.Context, params *GetDataCenterParams, reqEditors ...RequestEditorFn) (*GetDataCenterResponse, error) + + // GetDataCenterDefaultNetworkWithResponse request + GetDataCenterDefaultNetworkWithResponse(ctx context.Context, params *GetDataCenterDefaultNetworkParams, reqEditors ...RequestEditorFn) (*GetDataCenterDefaultNetworkResponse, error) + + // GetDataCenterGpuTypesWithResponse request + GetDataCenterGpuTypesWithResponse(ctx context.Context, params *GetDataCenterGpuTypesParams, reqEditors ...RequestEditorFn) (*GetDataCenterGpuTypesResponse, error) + + // DeleteDiskBackupPolicyWithBodyWithResponse request with any body + DeleteDiskBackupPolicyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDiskBackupPolicyResponse, error) + + DeleteDiskBackupPolicyWithResponse(ctx context.Context, body DeleteDiskBackupPolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDiskBackupPolicyResponse, error) + + // GetDiskBackupPolicyWithResponse request + GetDiskBackupPolicyWithResponse(ctx context.Context, params *GetDiskBackupPolicyParams, reqEditors ...RequestEditorFn) (*GetDiskBackupPolicyResponse, error) + + // PatchDiskBackupPolicyWithBodyWithResponse request with any body + PatchDiskBackupPolicyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchDiskBackupPolicyResponse, error) + + PatchDiskBackupPolicyWithResponse(ctx context.Context, body PatchDiskBackupPolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchDiskBackupPolicyResponse, error) + + // DeleteDiskBackupPolicyScheduleWithBodyWithResponse request with any body + DeleteDiskBackupPolicyScheduleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDiskBackupPolicyScheduleResponse, error) + + DeleteDiskBackupPolicyScheduleWithResponse(ctx context.Context, body DeleteDiskBackupPolicyScheduleJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDiskBackupPolicyScheduleResponse, error) + + // GetDiskTemplateVersionWithResponse request + GetDiskTemplateVersionWithResponse(ctx context.Context, params *GetDiskTemplateVersionParams, reqEditors ...RequestEditorFn) (*GetDiskTemplateVersionResponse, error) + + // GetDiskTemplateVersionSpecWithResponse request + GetDiskTemplateVersionSpecWithResponse(ctx context.Context, params *GetDiskTemplateVersionSpecParams, reqEditors ...RequestEditorFn) (*GetDiskTemplateVersionSpecResponse, error) + + // GetDiskTemplateWithResponse request + GetDiskTemplateWithResponse(ctx context.Context, params *GetDiskTemplateParams, reqEditors ...RequestEditorFn) (*GetDiskTemplateResponse, error) + + // GetDiskTemplateVersionsWithResponse request + GetDiskTemplateVersionsWithResponse(ctx context.Context, params *GetDiskTemplateVersionsParams, reqEditors ...RequestEditorFn) (*GetDiskTemplateVersionsResponse, error) + + // GetDiskWithResponse request + GetDiskWithResponse(ctx context.Context, params *GetDiskParams, reqEditors ...RequestEditorFn) (*GetDiskResponse, error) + + // GetDiskDiskBackupPoliciesWithResponse request + GetDiskDiskBackupPoliciesWithResponse(ctx context.Context, params *GetDiskDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*GetDiskDiskBackupPoliciesResponse, error) + + // PostDiskDiskBackupPoliciesWithBodyWithResponse request with any body + PostDiskDiskBackupPoliciesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDiskDiskBackupPoliciesResponse, error) + + PostDiskDiskBackupPoliciesWithResponse(ctx context.Context, body PostDiskDiskBackupPoliciesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDiskDiskBackupPoliciesResponse, error) + + // DeleteDnsRecordsDnsRecordWithBodyWithResponse request with any body + DeleteDnsRecordsDnsRecordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDnsRecordsDnsRecordResponse, error) + + DeleteDnsRecordsDnsRecordWithResponse(ctx context.Context, body DeleteDnsRecordsDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDnsRecordsDnsRecordResponse, error) + + // GetDnsRecordsDnsRecordWithResponse request + GetDnsRecordsDnsRecordWithResponse(ctx context.Context, params *GetDnsRecordsDnsRecordParams, reqEditors ...RequestEditorFn) (*GetDnsRecordsDnsRecordResponse, error) + + // PatchDnsRecordsDnsRecordWithBodyWithResponse request with any body + PatchDnsRecordsDnsRecordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchDnsRecordsDnsRecordResponse, error) + + PatchDnsRecordsDnsRecordWithResponse(ctx context.Context, body PatchDnsRecordsDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchDnsRecordsDnsRecordResponse, error) + + // DeleteDnsZonesDnsZoneWithBodyWithResponse request with any body + DeleteDnsZonesDnsZoneWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDnsZonesDnsZoneResponse, error) + + DeleteDnsZonesDnsZoneWithResponse(ctx context.Context, body DeleteDnsZonesDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDnsZonesDnsZoneResponse, error) + + // GetDnsZonesDnsZoneWithResponse request + GetDnsZonesDnsZoneWithResponse(ctx context.Context, params *GetDnsZonesDnsZoneParams, reqEditors ...RequestEditorFn) (*GetDnsZonesDnsZoneResponse, error) + + // GetDnsZonesDnsZoneRecordsWithResponse request + GetDnsZonesDnsZoneRecordsWithResponse(ctx context.Context, params *GetDnsZonesDnsZoneRecordsParams, reqEditors ...RequestEditorFn) (*GetDnsZonesDnsZoneRecordsResponse, error) + + // PostDnsZonesDnsZoneRecordsWithBodyWithResponse request with any body + PostDnsZonesDnsZoneRecordsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneRecordsResponse, error) + + PostDnsZonesDnsZoneRecordsWithResponse(ctx context.Context, body PostDnsZonesDnsZoneRecordsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneRecordsResponse, error) + + // PostDnsZonesDnsZoneUpdateTtlWithBodyWithResponse request with any body + PostDnsZonesDnsZoneUpdateTtlWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneUpdateTtlResponse, error) + + PostDnsZonesDnsZoneUpdateTtlWithResponse(ctx context.Context, body PostDnsZonesDnsZoneUpdateTtlJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneUpdateTtlResponse, error) + + // GetDnsZonesDnsZoneVerificationDetailsWithResponse request + GetDnsZonesDnsZoneVerificationDetailsWithResponse(ctx context.Context, params *GetDnsZonesDnsZoneVerificationDetailsParams, reqEditors ...RequestEditorFn) (*GetDnsZonesDnsZoneVerificationDetailsResponse, error) + + // PostDnsZonesDnsZoneVerifyWithBodyWithResponse request with any body + PostDnsZonesDnsZoneVerifyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneVerifyResponse, error) + + PostDnsZonesDnsZoneVerifyWithResponse(ctx context.Context, body PostDnsZonesDnsZoneVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneVerifyResponse, error) + + // DeleteDnsRecordWithBodyWithResponse request with any body + DeleteDnsRecordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDnsRecordResponse, error) + + DeleteDnsRecordWithResponse(ctx context.Context, body DeleteDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDnsRecordResponse, error) + + // GetDnsRecordWithResponse request + GetDnsRecordWithResponse(ctx context.Context, params *GetDnsRecordParams, reqEditors ...RequestEditorFn) (*GetDnsRecordResponse, error) + + // PatchDnsRecordWithBodyWithResponse request with any body + PatchDnsRecordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchDnsRecordResponse, error) + + PatchDnsRecordWithResponse(ctx context.Context, body PatchDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchDnsRecordResponse, error) + + // DeleteDnsZoneWithBodyWithResponse request with any body + DeleteDnsZoneWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDnsZoneResponse, error) + + DeleteDnsZoneWithResponse(ctx context.Context, body DeleteDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDnsZoneResponse, error) + + // GetDnsZoneWithResponse request + GetDnsZoneWithResponse(ctx context.Context, params *GetDnsZoneParams, reqEditors ...RequestEditorFn) (*GetDnsZoneResponse, error) + + // PatchDnsZoneWithBodyWithResponse request with any body + PatchDnsZoneWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchDnsZoneResponse, error) + + PatchDnsZoneWithResponse(ctx context.Context, body PatchDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchDnsZoneResponse, error) + + // GetDnsZoneRecordsWithResponse request + GetDnsZoneRecordsWithResponse(ctx context.Context, params *GetDnsZoneRecordsParams, reqEditors ...RequestEditorFn) (*GetDnsZoneRecordsResponse, error) + + // PostDnsZoneRecordsWithBodyWithResponse request with any body + PostDnsZoneRecordsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZoneRecordsResponse, error) + + PostDnsZoneRecordsWithResponse(ctx context.Context, body PostDnsZoneRecordsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZoneRecordsResponse, error) + + // PostDnsZoneVerifyWithBodyWithResponse request with any body + PostDnsZoneVerifyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZoneVerifyResponse, error) + + PostDnsZoneVerifyWithResponse(ctx context.Context, body PostDnsZoneVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZoneVerifyResponse, error) + + // DeleteFileStorageVolumeWithBodyWithResponse request with any body + DeleteFileStorageVolumeWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteFileStorageVolumeResponse, error) + + DeleteFileStorageVolumeWithResponse(ctx context.Context, body DeleteFileStorageVolumeJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteFileStorageVolumeResponse, error) + + // GetFileStorageVolumeWithResponse request + GetFileStorageVolumeWithResponse(ctx context.Context, params *GetFileStorageVolumeParams, reqEditors ...RequestEditorFn) (*GetFileStorageVolumeResponse, error) + + // PatchFileStorageVolumeWithBodyWithResponse request with any body + PatchFileStorageVolumeWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchFileStorageVolumeResponse, error) + + PatchFileStorageVolumeWithResponse(ctx context.Context, body PatchFileStorageVolumeJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchFileStorageVolumeResponse, error) + + // GetGpuTypesWithResponse request + GetGpuTypesWithResponse(ctx context.Context, params *GetGpuTypesParams, reqEditors ...RequestEditorFn) (*GetGpuTypesResponse, error) + + // GetGpuTypeWithResponse request + GetGpuTypeWithResponse(ctx context.Context, params *GetGpuTypeParams, reqEditors ...RequestEditorFn) (*GetGpuTypeResponse, error) + + // PostInvalidateLinkedWebSessionWithBodyWithResponse request with any body + PostInvalidateLinkedWebSessionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostInvalidateLinkedWebSessionResponse, error) + + PostInvalidateLinkedWebSessionWithResponse(ctx context.Context, body PostInvalidateLinkedWebSessionJSONRequestBody, reqEditors ...RequestEditorFn) (*PostInvalidateLinkedWebSessionResponse, error) + + // DeleteIpAddressWithBodyWithResponse request with any body + DeleteIpAddressWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteIpAddressResponse, error) + + DeleteIpAddressWithResponse(ctx context.Context, body DeleteIpAddressJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteIpAddressResponse, error) + + // GetIpAddressWithResponse request + GetIpAddressWithResponse(ctx context.Context, params *GetIpAddressParams, reqEditors ...RequestEditorFn) (*GetIpAddressResponse, error) + + // PatchIpAddressWithBodyWithResponse request with any body + PatchIpAddressWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchIpAddressResponse, error) + + PatchIpAddressWithResponse(ctx context.Context, body PatchIpAddressJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchIpAddressResponse, error) + + // PostIpAddressUnallocateWithBodyWithResponse request with any body + PostIpAddressUnallocateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostIpAddressUnallocateResponse, error) + + PostIpAddressUnallocateWithResponse(ctx context.Context, body PostIpAddressUnallocateJSONRequestBody, reqEditors ...RequestEditorFn) (*PostIpAddressUnallocateResponse, error) + + // DeleteLoadBalancerWithBodyWithResponse request with any body + DeleteLoadBalancerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteLoadBalancerResponse, error) + + DeleteLoadBalancerWithResponse(ctx context.Context, body DeleteLoadBalancerJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteLoadBalancerResponse, error) + + // GetLoadBalancerWithResponse request + GetLoadBalancerWithResponse(ctx context.Context, params *GetLoadBalancerParams, reqEditors ...RequestEditorFn) (*GetLoadBalancerResponse, error) + + // PatchLoadBalancerWithBodyWithResponse request with any body + PatchLoadBalancerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchLoadBalancerResponse, error) + + PatchLoadBalancerWithResponse(ctx context.Context, body PatchLoadBalancerJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchLoadBalancerResponse, error) + + // GetLoadBalancerRulesWithResponse request + GetLoadBalancerRulesWithResponse(ctx context.Context, params *GetLoadBalancerRulesParams, reqEditors ...RequestEditorFn) (*GetLoadBalancerRulesResponse, error) + + // PostLoadBalancerRulesWithBodyWithResponse request with any body + PostLoadBalancerRulesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostLoadBalancerRulesResponse, error) + + PostLoadBalancerRulesWithResponse(ctx context.Context, body PostLoadBalancerRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostLoadBalancerRulesResponse, error) + + // DeleteLoadBalancersRulesLoadBalancerRuleWithBodyWithResponse request with any body + DeleteLoadBalancersRulesLoadBalancerRuleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteLoadBalancersRulesLoadBalancerRuleResponse, error) + + DeleteLoadBalancersRulesLoadBalancerRuleWithResponse(ctx context.Context, body DeleteLoadBalancersRulesLoadBalancerRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteLoadBalancersRulesLoadBalancerRuleResponse, error) + + // GetLoadBalancersRulesLoadBalancerRuleWithResponse request + GetLoadBalancersRulesLoadBalancerRuleWithResponse(ctx context.Context, params *GetLoadBalancersRulesLoadBalancerRuleParams, reqEditors ...RequestEditorFn) (*GetLoadBalancersRulesLoadBalancerRuleResponse, error) + + // PatchLoadBalancersRulesLoadBalancerRuleWithBodyWithResponse request with any body + PatchLoadBalancersRulesLoadBalancerRuleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchLoadBalancersRulesLoadBalancerRuleResponse, error) + + PatchLoadBalancersRulesLoadBalancerRuleWithResponse(ctx context.Context, body PatchLoadBalancersRulesLoadBalancerRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchLoadBalancersRulesLoadBalancerRuleResponse, error) + + // GetNetworkWithResponse request + GetNetworkWithResponse(ctx context.Context, params *GetNetworkParams, reqEditors ...RequestEditorFn) (*GetNetworkResponse, error) + + // GetOperatingSystemsWithResponse request + GetOperatingSystemsWithResponse(ctx context.Context, params *GetOperatingSystemsParams, reqEditors ...RequestEditorFn) (*GetOperatingSystemsResponse, error) + + // GetOperatingSystemWithResponse request + GetOperatingSystemWithResponse(ctx context.Context, params *GetOperatingSystemParams, reqEditors ...RequestEditorFn) (*GetOperatingSystemResponse, error) + + // GetOrganizationsWithResponse request + GetOrganizationsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetOrganizationsResponse, error) + + // GetOrganizationWithResponse request + GetOrganizationWithResponse(ctx context.Context, params *GetOrganizationParams, reqEditors ...RequestEditorFn) (*GetOrganizationResponse, error) + + // GetOrganizationAvailableNetworksWithResponse request + GetOrganizationAvailableNetworksWithResponse(ctx context.Context, params *GetOrganizationAvailableNetworksParams, reqEditors ...RequestEditorFn) (*GetOrganizationAvailableNetworksResponse, error) + + // GetOrganizationCertificatesWithResponse request + GetOrganizationCertificatesWithResponse(ctx context.Context, params *GetOrganizationCertificatesParams, reqEditors ...RequestEditorFn) (*GetOrganizationCertificatesResponse, error) + + // GetOrganizationDiskBackupPoliciesWithResponse request + GetOrganizationDiskBackupPoliciesWithResponse(ctx context.Context, params *GetOrganizationDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*GetOrganizationDiskBackupPoliciesResponse, error) + + // GetOrganizationDiskTemplatesWithResponse request + GetOrganizationDiskTemplatesWithResponse(ctx context.Context, params *GetOrganizationDiskTemplatesParams, reqEditors ...RequestEditorFn) (*GetOrganizationDiskTemplatesResponse, error) + + // GetOrganizationDisksWithResponse request + GetOrganizationDisksWithResponse(ctx context.Context, params *GetOrganizationDisksParams, reqEditors ...RequestEditorFn) (*GetOrganizationDisksResponse, error) + + // GetOrganizationDnsZonesWithResponse request + GetOrganizationDnsZonesWithResponse(ctx context.Context, params *GetOrganizationDnsZonesParams, reqEditors ...RequestEditorFn) (*GetOrganizationDnsZonesResponse, error) + + // PostOrganizationDnsZonesWithBodyWithResponse request with any body + PostOrganizationDnsZonesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationDnsZonesResponse, error) + + PostOrganizationDnsZonesWithResponse(ctx context.Context, body PostOrganizationDnsZonesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationDnsZonesResponse, error) + + // GetOrganizationsOrganizationdnsZonesWithResponse request + GetOrganizationsOrganizationdnsZonesWithResponse(ctx context.Context, params *GetOrganizationsOrganizationdnsZonesParams, reqEditors ...RequestEditorFn) (*GetOrganizationsOrganizationdnsZonesResponse, error) + + // PostOrganizationsOrganizationdnsZonesWithBodyWithResponse request with any body + PostOrganizationsOrganizationdnsZonesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationsOrganizationdnsZonesResponse, error) + + PostOrganizationsOrganizationdnsZonesWithResponse(ctx context.Context, body PostOrganizationsOrganizationdnsZonesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationsOrganizationdnsZonesResponse, error) + + // GetOrganizationDnsZonesNameserversWithResponse request + GetOrganizationDnsZonesNameserversWithResponse(ctx context.Context, params *GetOrganizationDnsZonesNameserversParams, reqEditors ...RequestEditorFn) (*GetOrganizationDnsZonesNameserversResponse, error) + + // GetOrganizationFileStorageVolumesWithResponse request + GetOrganizationFileStorageVolumesWithResponse(ctx context.Context, params *GetOrganizationFileStorageVolumesParams, reqEditors ...RequestEditorFn) (*GetOrganizationFileStorageVolumesResponse, error) + + // PostOrganizationFileStorageVolumesWithBodyWithResponse request with any body + PostOrganizationFileStorageVolumesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationFileStorageVolumesResponse, error) + + PostOrganizationFileStorageVolumesWithResponse(ctx context.Context, body PostOrganizationFileStorageVolumesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationFileStorageVolumesResponse, error) + + // GetOrganizationIpAddressesWithResponse request + GetOrganizationIpAddressesWithResponse(ctx context.Context, params *GetOrganizationIpAddressesParams, reqEditors ...RequestEditorFn) (*GetOrganizationIpAddressesResponse, error) + + // PostOrganizationIpAddressesWithBodyWithResponse request with any body + PostOrganizationIpAddressesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationIpAddressesResponse, error) + + PostOrganizationIpAddressesWithResponse(ctx context.Context, body PostOrganizationIpAddressesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationIpAddressesResponse, error) + + // GetOrganizationLoadBalancersWithResponse request + GetOrganizationLoadBalancersWithResponse(ctx context.Context, params *GetOrganizationLoadBalancersParams, reqEditors ...RequestEditorFn) (*GetOrganizationLoadBalancersResponse, error) + + // PostOrganizationLoadBalancersWithBodyWithResponse request with any body + PostOrganizationLoadBalancersWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationLoadBalancersResponse, error) + + PostOrganizationLoadBalancersWithResponse(ctx context.Context, body PostOrganizationLoadBalancersJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationLoadBalancersResponse, error) + + // GetOrganizationManagedWithResponse request + GetOrganizationManagedWithResponse(ctx context.Context, params *GetOrganizationManagedParams, reqEditors ...RequestEditorFn) (*GetOrganizationManagedResponse, error) + + // PostOrganizationManagedWithBodyWithResponse request with any body + PostOrganizationManagedWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationManagedResponse, error) + + PostOrganizationManagedWithResponse(ctx context.Context, body PostOrganizationManagedJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationManagedResponse, error) + + // GetOrganizationNetworkSpeedProfilesWithResponse request + GetOrganizationNetworkSpeedProfilesWithResponse(ctx context.Context, params *GetOrganizationNetworkSpeedProfilesParams, reqEditors ...RequestEditorFn) (*GetOrganizationNetworkSpeedProfilesResponse, error) + + // GetOrganizationSecurityGroupsWithResponse request + GetOrganizationSecurityGroupsWithResponse(ctx context.Context, params *GetOrganizationSecurityGroupsParams, reqEditors ...RequestEditorFn) (*GetOrganizationSecurityGroupsResponse, error) + + // PostOrganizationSecurityGroupsWithBodyWithResponse request with any body + PostOrganizationSecurityGroupsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationSecurityGroupsResponse, error) + + PostOrganizationSecurityGroupsWithResponse(ctx context.Context, body PostOrganizationSecurityGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationSecurityGroupsResponse, error) + + // GetOrganizationSshKeysWithResponse request + GetOrganizationSshKeysWithResponse(ctx context.Context, params *GetOrganizationSshKeysParams, reqEditors ...RequestEditorFn) (*GetOrganizationSshKeysResponse, error) + + // PostOrganizationSshKeysWithBodyWithResponse request with any body + PostOrganizationSshKeysWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationSshKeysResponse, error) + + PostOrganizationSshKeysWithResponse(ctx context.Context, body PostOrganizationSshKeysJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationSshKeysResponse, error) + + // GetOrganizationTagsWithResponse request + GetOrganizationTagsWithResponse(ctx context.Context, params *GetOrganizationTagsParams, reqEditors ...RequestEditorFn) (*GetOrganizationTagsResponse, error) + + // PostOrganizationTagsWithBodyWithResponse request with any body + PostOrganizationTagsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationTagsResponse, error) + + PostOrganizationTagsWithResponse(ctx context.Context, body PostOrganizationTagsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationTagsResponse, error) + + // GetOrganizationTrashObjectsWithResponse request + GetOrganizationTrashObjectsWithResponse(ctx context.Context, params *GetOrganizationTrashObjectsParams, reqEditors ...RequestEditorFn) (*GetOrganizationTrashObjectsResponse, error) + + // PostOrganizationTrashObjectsPurgeAllWithBodyWithResponse request with any body + PostOrganizationTrashObjectsPurgeAllWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationTrashObjectsPurgeAllResponse, error) + + PostOrganizationTrashObjectsPurgeAllWithResponse(ctx context.Context, body PostOrganizationTrashObjectsPurgeAllJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationTrashObjectsPurgeAllResponse, error) + + // GetOrganizationUsersWithAccessWithResponse request + GetOrganizationUsersWithAccessWithResponse(ctx context.Context, params *GetOrganizationUsersWithAccessParams, reqEditors ...RequestEditorFn) (*GetOrganizationUsersWithAccessResponse, error) + + // GetOrganizationVirtualMachineGroupsWithResponse request + GetOrganizationVirtualMachineGroupsWithResponse(ctx context.Context, params *GetOrganizationVirtualMachineGroupsParams, reqEditors ...RequestEditorFn) (*GetOrganizationVirtualMachineGroupsResponse, error) + + // PostOrganizationVirtualMachineGroupsWithBodyWithResponse request with any body + PostOrganizationVirtualMachineGroupsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachineGroupsResponse, error) + + PostOrganizationVirtualMachineGroupsWithResponse(ctx context.Context, body PostOrganizationVirtualMachineGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachineGroupsResponse, error) + + // GetOrganizationVirtualMachinesWithResponse request + GetOrganizationVirtualMachinesWithResponse(ctx context.Context, params *GetOrganizationVirtualMachinesParams, reqEditors ...RequestEditorFn) (*GetOrganizationVirtualMachinesResponse, error) + + // PostOrganizationVirtualMachinesBuildWithBodyWithResponse request with any body + PostOrganizationVirtualMachinesBuildWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachinesBuildResponse, error) + + PostOrganizationVirtualMachinesBuildWithResponse(ctx context.Context, body PostOrganizationVirtualMachinesBuildJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachinesBuildResponse, error) + + // PostOrganizationVirtualMachinesBuildFromSpecWithBodyWithResponse request with any body + PostOrganizationVirtualMachinesBuildFromSpecWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachinesBuildFromSpecResponse, error) + + PostOrganizationVirtualMachinesBuildFromSpecWithResponse(ctx context.Context, body PostOrganizationVirtualMachinesBuildFromSpecJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachinesBuildFromSpecResponse, error) + + // DeleteSecurityGroupWithBodyWithResponse request with any body + DeleteSecurityGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteSecurityGroupResponse, error) + + DeleteSecurityGroupWithResponse(ctx context.Context, body DeleteSecurityGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteSecurityGroupResponse, error) + + // GetSecurityGroupWithResponse request + GetSecurityGroupWithResponse(ctx context.Context, params *GetSecurityGroupParams, reqEditors ...RequestEditorFn) (*GetSecurityGroupResponse, error) + + // PatchSecurityGroupWithBodyWithResponse request with any body + PatchSecurityGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchSecurityGroupResponse, error) + + PatchSecurityGroupWithResponse(ctx context.Context, body PatchSecurityGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchSecurityGroupResponse, error) + + // GetSecurityGroupRulesWithResponse request + GetSecurityGroupRulesWithResponse(ctx context.Context, params *GetSecurityGroupRulesParams, reqEditors ...RequestEditorFn) (*GetSecurityGroupRulesResponse, error) + + // PostSecurityGroupRulesWithBodyWithResponse request with any body + PostSecurityGroupRulesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostSecurityGroupRulesResponse, error) + + PostSecurityGroupRulesWithResponse(ctx context.Context, body PostSecurityGroupRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostSecurityGroupRulesResponse, error) + + // DeleteSecurityGroupsRulesSecurityGroupRuleWithBodyWithResponse request with any body + DeleteSecurityGroupsRulesSecurityGroupRuleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteSecurityGroupsRulesSecurityGroupRuleResponse, error) + + DeleteSecurityGroupsRulesSecurityGroupRuleWithResponse(ctx context.Context, body DeleteSecurityGroupsRulesSecurityGroupRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteSecurityGroupsRulesSecurityGroupRuleResponse, error) + + // GetSecurityGroupsRulesSecurityGroupRuleWithResponse request + GetSecurityGroupsRulesSecurityGroupRuleWithResponse(ctx context.Context, params *GetSecurityGroupsRulesSecurityGroupRuleParams, reqEditors ...RequestEditorFn) (*GetSecurityGroupsRulesSecurityGroupRuleResponse, error) + + // PatchSecurityGroupsRulesSecurityGroupRuleWithBodyWithResponse request with any body + PatchSecurityGroupsRulesSecurityGroupRuleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchSecurityGroupsRulesSecurityGroupRuleResponse, error) + + PatchSecurityGroupsRulesSecurityGroupRuleWithResponse(ctx context.Context, body PatchSecurityGroupsRulesSecurityGroupRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchSecurityGroupsRulesSecurityGroupRuleResponse, error) + + // DeleteSshKeyWithBodyWithResponse request with any body + DeleteSshKeyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteSshKeyResponse, error) + + DeleteSshKeyWithResponse(ctx context.Context, body DeleteSshKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteSshKeyResponse, error) + + // DeleteTagWithBodyWithResponse request with any body + DeleteTagWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteTagResponse, error) + + DeleteTagWithResponse(ctx context.Context, body DeleteTagJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteTagResponse, error) + + // GetTagWithResponse request + GetTagWithResponse(ctx context.Context, params *GetTagParams, reqEditors ...RequestEditorFn) (*GetTagResponse, error) + + // PatchTagWithBodyWithResponse request with any body + PatchTagWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchTagResponse, error) + + PatchTagWithResponse(ctx context.Context, body PatchTagJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchTagResponse, error) + + // GetTaskWithResponse request + GetTaskWithResponse(ctx context.Context, params *GetTaskParams, reqEditors ...RequestEditorFn) (*GetTaskResponse, error) + + // DeleteTrashObjectWithBodyWithResponse request with any body + DeleteTrashObjectWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteTrashObjectResponse, error) + + DeleteTrashObjectWithResponse(ctx context.Context, body DeleteTrashObjectJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteTrashObjectResponse, error) + + // GetTrashObjectWithResponse request + GetTrashObjectWithResponse(ctx context.Context, params *GetTrashObjectParams, reqEditors ...RequestEditorFn) (*GetTrashObjectResponse, error) + + // PostTrashObjectRestoreWithBodyWithResponse request with any body + PostTrashObjectRestoreWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostTrashObjectRestoreResponse, error) + + PostTrashObjectRestoreWithResponse(ctx context.Context, body PostTrashObjectRestoreJSONRequestBody, reqEditors ...RequestEditorFn) (*PostTrashObjectRestoreResponse, error) + + // GetUsersCurrentWithResponse request + GetUsersCurrentWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetUsersCurrentResponse, error) + + // DeleteVirtualMachineGroupWithBodyWithResponse request with any body + DeleteVirtualMachineGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteVirtualMachineGroupResponse, error) + + DeleteVirtualMachineGroupWithResponse(ctx context.Context, body DeleteVirtualMachineGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteVirtualMachineGroupResponse, error) + + // GetVirtualMachineGroupWithResponse request + GetVirtualMachineGroupWithResponse(ctx context.Context, params *GetVirtualMachineGroupParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineGroupResponse, error) + + // PatchVirtualMachineGroupWithBodyWithResponse request with any body + PatchVirtualMachineGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchVirtualMachineGroupResponse, error) + + PatchVirtualMachineGroupWithResponse(ctx context.Context, body PatchVirtualMachineGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchVirtualMachineGroupResponse, error) + + // GetVMNIVMNIWithResponse request + GetVMNIVMNIWithResponse(ctx context.Context, params *GetVMNIVMNIParams, reqEditors ...RequestEditorFn) (*GetVMNIVMNIResponse, error) + + // PostVirtualMachineNetworkInterfaceAllocateIpWithBodyWithResponse request with any body + PostVirtualMachineNetworkInterfaceAllocateIpWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineNetworkInterfaceAllocateIpResponse, error) + + PostVirtualMachineNetworkInterfaceAllocateIpWithResponse(ctx context.Context, body PostVirtualMachineNetworkInterfaceAllocateIpJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineNetworkInterfaceAllocateIpResponse, error) + + // PostVirtualMachineNetworkInterfaceAllocateNewIpWithBodyWithResponse request with any body + PostVirtualMachineNetworkInterfaceAllocateNewIpWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineNetworkInterfaceAllocateNewIpResponse, error) + + PostVirtualMachineNetworkInterfaceAllocateNewIpWithResponse(ctx context.Context, body PostVirtualMachineNetworkInterfaceAllocateNewIpJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineNetworkInterfaceAllocateNewIpResponse, error) + + // GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionWithResponse request + GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionWithResponse(ctx context.Context, params *GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse, error) + + // PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithBodyWithResponse request with any body + PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse, error) + + PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithResponse(ctx context.Context, body PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse, error) + + // GetVirtualMachinePackagesWithResponse request + GetVirtualMachinePackagesWithResponse(ctx context.Context, params *GetVirtualMachinePackagesParams, reqEditors ...RequestEditorFn) (*GetVirtualMachinePackagesResponse, error) + + // GetVirtualMachinePackageWithResponse request + GetVirtualMachinePackageWithResponse(ctx context.Context, params *GetVirtualMachinePackageParams, reqEditors ...RequestEditorFn) (*GetVirtualMachinePackageResponse, error) + + // DeleteVirtualMachineWithBodyWithResponse request with any body + DeleteVirtualMachineWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteVirtualMachineResponse, error) + + DeleteVirtualMachineWithResponse(ctx context.Context, body DeleteVirtualMachineJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteVirtualMachineResponse, error) + + // GetVirtualMachineWithResponse request + GetVirtualMachineWithResponse(ctx context.Context, params *GetVirtualMachineParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineResponse, error) + + // PatchVirtualMachineWithBodyWithResponse request with any body + PatchVirtualMachineWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchVirtualMachineResponse, error) + + PatchVirtualMachineWithResponse(ctx context.Context, body PatchVirtualMachineJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchVirtualMachineResponse, error) + + // PostVirtualMachineAllocateIpWithBodyWithResponse request with any body + PostVirtualMachineAllocateIpWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineAllocateIpResponse, error) + + PostVirtualMachineAllocateIpWithResponse(ctx context.Context, body PostVirtualMachineAllocateIpJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineAllocateIpResponse, error) + + // PostVirtualMachineConsoleSessionsWithBodyWithResponse request with any body + PostVirtualMachineConsoleSessionsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineConsoleSessionsResponse, error) + + PostVirtualMachineConsoleSessionsWithResponse(ctx context.Context, body PostVirtualMachineConsoleSessionsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineConsoleSessionsResponse, error) + + // GetVirtualMachineDiskBackupPoliciesWithResponse request + GetVirtualMachineDiskBackupPoliciesWithResponse(ctx context.Context, params *GetVirtualMachineDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineDiskBackupPoliciesResponse, error) + + // PostVirtualMachineDiskBackupPoliciesWithBodyWithResponse request with any body + PostVirtualMachineDiskBackupPoliciesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineDiskBackupPoliciesResponse, error) + + PostVirtualMachineDiskBackupPoliciesWithResponse(ctx context.Context, body PostVirtualMachineDiskBackupPoliciesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineDiskBackupPoliciesResponse, error) + + // GetVirtualMachineDisksWithResponse request + GetVirtualMachineDisksWithResponse(ctx context.Context, params *GetVirtualMachineDisksParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineDisksResponse, error) + + // PutVirtualMachineFlexibleResourcesWithBodyWithResponse request with any body + PutVirtualMachineFlexibleResourcesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutVirtualMachineFlexibleResourcesResponse, error) + + PutVirtualMachineFlexibleResourcesWithResponse(ctx context.Context, body PutVirtualMachineFlexibleResourcesJSONRequestBody, reqEditors ...RequestEditorFn) (*PutVirtualMachineFlexibleResourcesResponse, error) + + // GetVirtualMachineNetworkInterfacesWithResponse request + GetVirtualMachineNetworkInterfacesWithResponse(ctx context.Context, params *GetVirtualMachineNetworkInterfacesParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineNetworkInterfacesResponse, error) + + // GetVirtualMachineNetworkInterfaceWithResponse request + GetVirtualMachineNetworkInterfaceWithResponse(ctx context.Context, params *GetVirtualMachineNetworkInterfaceParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineNetworkInterfaceResponse, error) + + // PutVirtualMachinePackageWithBodyWithResponse request with any body + PutVirtualMachinePackageWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutVirtualMachinePackageResponse, error) + + PutVirtualMachinePackageWithResponse(ctx context.Context, body PutVirtualMachinePackageJSONRequestBody, reqEditors ...RequestEditorFn) (*PutVirtualMachinePackageResponse, error) + + // PostVirtualMachineResetWithBodyWithResponse request with any body + PostVirtualMachineResetWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineResetResponse, error) + + PostVirtualMachineResetWithResponse(ctx context.Context, body PostVirtualMachineResetJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineResetResponse, error) + + // PostVirtualMachineShutdownWithBodyWithResponse request with any body + PostVirtualMachineShutdownWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineShutdownResponse, error) + + PostVirtualMachineShutdownWithResponse(ctx context.Context, body PostVirtualMachineShutdownJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineShutdownResponse, error) + + // PostVirtualMachineStartWithBodyWithResponse request with any body + PostVirtualMachineStartWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineStartResponse, error) + + PostVirtualMachineStartWithResponse(ctx context.Context, body PostVirtualMachineStartJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineStartResponse, error) + + // PostVirtualMachineStopWithBodyWithResponse request with any body + PostVirtualMachineStopWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineStopResponse, error) + + PostVirtualMachineStopWithResponse(ctx context.Context, body PostVirtualMachineStopJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineStopResponse, error) + + // GetVirtualMachinesBuildsVirtualMachineBuildWithResponse request + GetVirtualMachinesBuildsVirtualMachineBuildWithResponse(ctx context.Context, params *GetVirtualMachinesBuildsVirtualMachineBuildParams, reqEditors ...RequestEditorFn) (*GetVirtualMachinesBuildsVirtualMachineBuildResponse, error) + + // GetZonesWithResponse request + GetZonesWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetZonesResponse, error) + + // GetZoneWithResponse request + GetZoneWithResponse(ctx context.Context, params *GetZoneParams, reqEditors ...RequestEditorFn) (*GetZoneResponse, error) +} + +type GetCertificateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Certificate []Certificate `json:"certificate"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *CertificateNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetCertificateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetCertificateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetCountriesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Countries The list of countries + Countries []GetCountries200ResponseCountries `json:"countries"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetCountriesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetCountriesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetCountryResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Country The country details + Country Country `json:"country"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *CountryNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetCountryResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetCountryResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetCountryCountryStatesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // CountryStates The list of country states for the given country + CountryStates []GetCountryCountryStates200ResponseCountryStates `json:"country_states"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *CountryNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetCountryCountryStatesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetCountryCountryStatesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetCountryStateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // CountryState The country state details + CountryState CountryState `json:"country_state"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *CountryStateNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetCountryStateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetCountryStateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetCurrenciesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Currencies The list of currencies + Currencies []GetCurrencies200ResponseCurrencies `json:"currencies"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetCurrenciesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetCurrenciesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetCurrencyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Currency The currency details + Currency Currency `json:"currency"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *CurrencyNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetCurrencyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetCurrencyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDataCentersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + DataCenters []GetDataCenters200ResponseDataCenters `json:"data_centers"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDataCentersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDataCentersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDataCenterResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + DataCenter GetDataCenter200ResponseDataCenter `json:"data_center"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DataCenterNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDataCenterResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDataCenterResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDataCenterDefaultNetworkResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Network The details for the requested network + Network GetDataCenterDefaultNetwork200ResponseNetwork `json:"network"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DataCenterNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDataCenterDefaultNetworkResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDataCenterDefaultNetworkResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDataCenterGpuTypesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + GpuTypes []GetDataCenterGPUTypes200ResponseGPUTypes `json:"gpu_types"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DataCenterNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDataCenterGpuTypesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDataCenterGpuTypesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteDiskBackupPolicyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicy The disk backup policy that has been destroyed + DiskBackupPolicy DeleteDiskBackupPolicy200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *DiskBackupPolicyNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteDiskBackupPolicyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteDiskBackupPolicyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDiskBackupPolicyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicy The located disk backup policy + DiskBackupPolicy GetDiskBackupPolicy200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DiskBackupPolicyNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDiskBackupPolicyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDiskBackupPolicyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchDiskBackupPolicyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicy The disk backup policy that has been updated + DiskBackupPolicy PatchDiskBackupPolicy200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *DiskBackupPolicyNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchDiskBackupPolicyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchDiskBackupPolicyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteDiskBackupPolicyScheduleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicy The disk backup policy that has been scheduled for deletion + DiskBackupPolicy DeleteDiskBackupPolicySchedule200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + JSON400 *InvalidTimestamp400Res + JSON403 *PermissionDenied403Res + JSON404 *DiskBackupPolicyNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteDiskBackupPolicyScheduleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteDiskBackupPolicyScheduleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDiskTemplateVersionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskTemplateVersion The disk template version details + DiskTemplateVersion GetDiskTemplateVersion200ResponseDiskTemplateVersion `json:"disk_template_version"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DiskTemplateVersionNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDiskTemplateVersionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDiskTemplateVersionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDiskTemplateVersionSpecResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskTemplateVersion The disk template version details + DiskTemplateVersion GetDiskTemplateVersionSpec200ResponseDiskTemplateVersion `json:"disk_template_version"` + Spec TemplateSpec `json:"spec"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DiskTemplateVersionNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDiskTemplateVersionSpecResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDiskTemplateVersionSpecResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDiskTemplateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskTemplate The disk template details + DiskTemplate GetDiskTemplate200ResponseDiskTemplate `json:"disk_template"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DiskTemplateNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDiskTemplateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDiskTemplateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDiskTemplateVersionsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + DiskTemplate GetDiskTemplateVersions200ResponseDiskTemplate `json:"disk_template"` + + // DiskTemplateVersions The disk template versions for the provided template + DiskTemplateVersions []GetDiskTemplateVersions200ResponseDiskTemplateVersions `json:"disk_template_versions"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DiskTemplateNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDiskTemplateVersionsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDiskTemplateVersionsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDiskResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Disk The disk details + Disk GetDisk200ResponseDisk `json:"disk"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DiskNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDiskResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDiskResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDiskDiskBackupPoliciesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicies The disk backup policies for the provided disk + DiskBackupPolicies []GetDiskDiskBackupPolicies200ResponseDiskBackupPolicies `json:"disk_backup_policies"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *DiskNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDiskDiskBackupPoliciesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDiskDiskBackupPoliciesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostDiskDiskBackupPoliciesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicy The new disk backup policy that has been created + DiskBackupPolicy PostDiskDiskBackupPolicies200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *DiskNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostDiskDiskBackupPoliciesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostDiskDiskBackupPoliciesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteDnsRecordsDnsRecordResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Success bool `json:"success"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSRecordNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteDnsRecordsDnsRecordResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteDnsRecordsDnsRecordResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDnsRecordsDnsRecordResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsRecord The DNS record details + DnsRecord GetDNSRecordsDNSRecord200ResponseDNSRecord `json:"dns_record"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSRecordNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDnsRecordsDnsRecordResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDnsRecordsDnsRecordResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchDnsRecordsDnsRecordResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsRecord The updated DNS record + DnsRecord PatchDNSRecordsDNSRecord200ResponseDNSRecord `json:"dns_record"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSRecordNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchDnsRecordsDnsRecordResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchDnsRecordsDnsRecordResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteDnsZonesDnsZoneResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZone The DNS zone that has been destroyed + DnsZone DeleteDNSZonesDNSZone200ResponseDNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSZoneNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteDnsZonesDnsZoneResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteDnsZonesDnsZoneResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDnsZonesDnsZoneResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZone The DNS zone object + DnsZone DNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSZoneNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDnsZonesDnsZoneResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDnsZonesDnsZoneResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDnsZonesDnsZoneRecordsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsRecords The DNS records that belong to this DNS zone + DnsRecords []GetDNSZonesDNSZoneRecords200ResponseDNSRecords `json:"dns_records"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSZoneNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDnsZonesDnsZoneRecordsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDnsZonesDnsZoneRecordsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostDnsZonesDnsZoneRecordsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsRecord The new DNS record that has been created + DnsRecord PostDNSZonesDNSZoneRecords200ResponseDNSRecord `json:"dns_record"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *DNSZoneNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostDnsZonesDnsZoneRecordsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostDnsZonesDnsZoneRecordsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostDnsZonesDnsZoneUpdateTtlResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZone The DNS zone with the new TTL value + DnsZone PostDNSZonesDNSZoneUpdateTTL200ResponseDNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *InfrastructureDNSZoneCannotBeEdited403Res + JSON404 *DNSZoneNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostDnsZonesDnsZoneUpdateTtlResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostDnsZonesDnsZoneUpdateTtlResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDnsZonesDnsZoneVerificationDetailsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Details DNSZoneVerificationDetails `json:"details"` + } + JSON400 *APIAuthenticator400Response + JSON403 *InfrastructureDNSZoneCannotBeEdited403Res + JSON404 *DNSZoneNotFoundResponse + JSON422 *DNSZoneAlreadyVerifiedResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDnsZonesDnsZoneVerificationDetailsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDnsZonesDnsZoneVerificationDetailsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostDnsZonesDnsZoneVerifyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZone The DNS zone that has been verified + DnsZone DNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSZoneNotFoundResponse + JSON422 *DNSZoneNotVerifiedResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostDnsZonesDnsZoneVerifyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostDnsZonesDnsZoneVerifyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteDnsRecordResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Deleted bool `json:"deleted"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSRecordNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteDnsRecordResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteDnsRecordResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDnsRecordResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsRecord The DNS record for the provided organization + DnsRecord DNSRecord `json:"dns_record"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSRecordNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDnsRecordResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDnsRecordResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchDnsRecordResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsRecord The DNS record that has been updated + DnsRecord DNSRecord `json:"dns_record"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSRecordNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchDnsRecordResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchDnsRecordResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteDnsZoneResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Deleted bool `json:"deleted"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSZoneNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteDnsZoneResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteDnsZoneResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDnsZoneResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZone The DNS zones for the provided organization + DnsZone DNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSZoneNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDnsZoneResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDnsZoneResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchDnsZoneResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZone The DNS zones for the provided organization + DnsZone DNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSZoneNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchDnsZoneResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchDnsZoneResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetDnsZoneRecordsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsRecords The DNS record for the provided zone + DnsRecords []DNSRecord `json:"dns_records"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *DNSZoneNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetDnsZoneRecordsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetDnsZoneRecordsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostDnsZoneRecordsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + DnsRecord DNSRecord `json:"dns_record"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *DNSZoneNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostDnsZoneRecordsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostDnsZoneRecordsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostDnsZoneVerifyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZone The DNS zones for the provided organization + DnsZone DNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *DNSZoneNotFoundResponse + JSON422 *DNSZoneNotVerifiedResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostDnsZoneVerifyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostDnsZoneVerifyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteFileStorageVolumeResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // FileStorageVolume The file storage volume that has been destroyed. + FileStorageVolume DeleteFileStorageVolume200ResponseFileStorageVolume `json:"file_storage_volume"` + TrashObject TrashObject `json:"trash_object"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *FileStorageVolumeNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteFileStorageVolumeResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteFileStorageVolumeResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetFileStorageVolumeResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // FileStorageVolume The file storage volume. + FileStorageVolume GetFileStorageVolume200ResponseFileStorageVolume `json:"file_storage_volume"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *FileStorageVolumeNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetFileStorageVolumeResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetFileStorageVolumeResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchFileStorageVolumeResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // FileStorageVolume The file storage volume. + FileStorageVolume PatchFileStorageVolume200ResponseFileStorageVolume `json:"file_storage_volume"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *FileStorageVolumeNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchFileStorageVolumeResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchFileStorageVolumeResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetGpuTypesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + GpuTypes []GetGPUTypes200ResponseGPUTypes `json:"gpu_types"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetGpuTypesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetGpuTypesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetGpuTypeResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + GpuType GetGPUType200ResponseGPUType `json:"gpu_type"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *GPUTypeNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetGpuTypeResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetGpuTypeResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostInvalidateLinkedWebSessionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Status bool `json:"status"` + } + JSON400 *IdentityNotLinkedToWebSession400Res + JSON403 *APIAuthenticator403Response + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostInvalidateLinkedWebSessionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostInvalidateLinkedWebSessionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteIpAddressResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *interface{} + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *IPAddressNotFoundResponse + JSON409 *ResourceDoesNotSupportUnallocationResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteIpAddressResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteIpAddressResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetIpAddressResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Allocation The resource this address is allocated to + Allocation *GetIPAddress200ResponseAllocation `json:"allocation"` + + // IpAddress The IP address that has been located + IpAddress IPAddress `json:"ip_address"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *IPAddressNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetIpAddressResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetIpAddressResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchIpAddressResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // IpAddress The IP address that has been updated + IpAddress IPAddress `json:"ip_address"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *IPAddressNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchIpAddressResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchIpAddressResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostIpAddressUnallocateResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *interface{} + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *IPAddressNotFoundResponse + JSON409 *ResourceDoesNotSupportUnallocationResponse + JSON422 *NoAllocationResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostIpAddressUnallocateResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostIpAddressUnallocateResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteLoadBalancerResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancer The load balancer that has been destroyed + LoadBalancer DeleteLoadBalancer200ResponseLoadBalancer `json:"load_balancer"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *LoadBalancerNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteLoadBalancerResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteLoadBalancerResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetLoadBalancerResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancer The load balancer + LoadBalancer GetLoadBalancer200ResponseLoadBalancer `json:"load_balancer"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *LoadBalancerNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetLoadBalancerResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetLoadBalancerResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchLoadBalancerResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancer The load balancer that has been updated + LoadBalancer PatchLoadBalancer200ResponseLoadBalancer `json:"load_balancer"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *LoadBalancerNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchLoadBalancerResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchLoadBalancerResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetLoadBalancerRulesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancerRules The load balancer rules for this load balancer + LoadBalancerRules []GetLoadBalancerRules200ResponseLoadBalancerRules `json:"load_balancer_rules"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *LoadBalancerNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetLoadBalancerRulesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetLoadBalancerRulesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostLoadBalancerRulesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancerRule The load balancer rule that has been created + LoadBalancerRule PostLoadBalancerRules200ResponseLoadBalancerRule `json:"load_balancer_rule"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *LoadBalancerNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostLoadBalancerRulesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostLoadBalancerRulesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteLoadBalancersRulesLoadBalancerRuleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancerRule The load balancer rule that has been destroyed + LoadBalancerRule DeleteLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule `json:"load_balancer_rule"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *LoadBalancerRuleNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteLoadBalancersRulesLoadBalancerRuleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteLoadBalancersRulesLoadBalancerRuleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetLoadBalancersRulesLoadBalancerRuleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancerRule The resolved load balancer rule + LoadBalancerRule GetLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule `json:"load_balancer_rule"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *LoadBalancerRuleNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetLoadBalancersRulesLoadBalancerRuleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetLoadBalancersRulesLoadBalancerRuleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchLoadBalancersRulesLoadBalancerRuleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancerRule The load balancer that has been updated + LoadBalancerRule PatchLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule `json:"load_balancer_rule"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *LoadBalancerRuleNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchLoadBalancersRulesLoadBalancerRuleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchLoadBalancersRulesLoadBalancerRuleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetNetworkResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Network The details for the requested network + Network Network `json:"network"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *NetworkNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetNetworkResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetNetworkResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOperatingSystemsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // OperatingSystems The list of available operating systems + OperatingSystems []GetOperatingSystems200ResponseOperatingSystems `json:"operating_systems"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOperatingSystemsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOperatingSystemsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOperatingSystemResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // OperatingSystem The operating system details + OperatingSystem OperatingSystem `json:"operating_system"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *OperatingSystemNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOperatingSystemResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOperatingSystemResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Organizations []GetOrganizations200ResponseOrganizations `json:"organizations"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Organization Organization `json:"organization"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationAvailableNetworksResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Networks []GetOrganizationAvailableNetworks200ResponseNetworks `json:"networks"` + VirtualNetworks []GetOrganizationAvailableNetworks200ResponseVirtualNetworks `json:"virtual_networks"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationAvailableNetworksResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationAvailableNetworksResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationCertificatesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Certificates []GetOrganizationCertificates200ResponseCertificates `json:"certificates"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationCertificatesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationCertificatesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationDiskBackupPoliciesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicies The disk backup policies for the provided organization + DiskBackupPolicies []GetOrganizationDiskBackupPolicies200ResponseDiskBackupPolicies `json:"disk_backup_policies"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationDiskBackupPoliciesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationDiskBackupPoliciesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationDiskTemplatesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskTemplates The list of disk templates + DiskTemplates []GetOrganizationDiskTemplates200ResponseDiskTemplates `json:"disk_templates"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OperatingSystemNotFoundOrganizationNotFound404Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationDiskTemplatesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationDiskTemplatesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationDisksResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Disk The list of disks + Disk []GetOrganizationDisks200ResponseDisk `json:"disk"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationDisksResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationDisksResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationDnsZonesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZones The DNS zones for the provided organization + DnsZones []DNSZone `json:"dns_zones"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationDnsZonesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationDnsZonesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationDnsZonesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + // DnsZone The new DNS zone that has been created + DnsZone PostOrganizationDNSZones201ResponseDNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationDnsZonesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationDnsZonesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationsOrganizationdnsZonesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DnsZones The DNS zones for the provided organization + DnsZones []DNSZone `json:"dns_zones"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationsOrganizationdnsZonesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationsOrganizationdnsZonesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationsOrganizationdnsZonesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + // DnsZone The new DNS zone that has been created + DnsZone PostOrganizationsOrganizationDNSZones201ResponseDNSZone `json:"dns_zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationsOrganizationdnsZonesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationsOrganizationdnsZonesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationDnsZonesNameserversResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Nameservers []string `json:"nameservers"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationDnsZonesNameserversResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationDnsZonesNameserversResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationFileStorageVolumesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // FileStorageVolumes A list of all file storage volumes for the given organization. + FileStorageVolumes []GetOrganizationFileStorageVolumes200ResponseFileStorageVolumes `json:"file_storage_volumes"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationFileStorageVolumesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationFileStorageVolumesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationFileStorageVolumesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + // FileStorageVolume The file storage volume. + FileStorageVolume PostOrganizationFileStorageVolumes201ResponseFileStorageVolume `json:"file_storage_volume"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationFileStorageVolumesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationFileStorageVolumesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationIpAddressesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // IpAddresses The IP addresses belonging to this organization + IpAddresses []GetOrganizationIPAddresses200ResponseIPAddresses `json:"ip_addresses"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationIpAddressesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationIpAddressesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationIpAddressesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // IpAddress The newly allocated IP address + IpAddress IPAddress `json:"ip_address"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *NetworkNotFoundOrganizationNotFound404Res + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response + JSON503 *NoAvailableAddressesResponse +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationIpAddressesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationIpAddressesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationLoadBalancersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancers The load balancers owned by this organization + LoadBalancers []GetOrganizationLoadBalancers200ResponseLoadBalancers `json:"load_balancers"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationLoadBalancersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationLoadBalancersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationLoadBalancersResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // LoadBalancer The load balancer that has been created + LoadBalancer PostOrganizationLoadBalancers200ResponseLoadBalancer `json:"load_balancer"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationLoadBalancersResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationLoadBalancersResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationManagedResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Organizations []GetOrganizationManaged200ResponseOrganizations `json:"organizations"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationManagedResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationManagedResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationManagedResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + Organization PostOrganizationManaged201ResponseOrganization `json:"organization"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *OrganizationLimitReachedValidationError422Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationManagedResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationManagedResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationNetworkSpeedProfilesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // NetworkSpeedProfiles The network speed profiles available to this organization + NetworkSpeedProfiles []NetworkSpeedProfile `json:"network_speed_profiles"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationNetworkSpeedProfilesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationNetworkSpeedProfilesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationSecurityGroupsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + + // SecurityGroups The security groups owned by this organization + SecurityGroups []SecurityGroup `json:"security_groups"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationSecurityGroupsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationSecurityGroupsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationSecurityGroupsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // SecurityGroup The security group that has been created + SecurityGroup SecurityGroup `json:"security_group"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationSecurityGroupsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationSecurityGroupsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationSshKeysResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + SshKeys []AuthSSHKey `json:"ssh_keys"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationSshKeysResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationSshKeysResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationSshKeysResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + SshKey AuthSSHKey `json:"ssh_key"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationSshKeysResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationSshKeysResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationTagsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + + // Tags The details for the tags on the organization + Tags []GetOrganizationTags200ResponseTags `json:"tags"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationTagsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationTagsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationTagsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Tag The newly created tag + Tag Tag `json:"tag"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationTagsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationTagsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationTrashObjectsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + + // TrashObjects The trash objects that belong to this organization + TrashObjects []TrashObject `json:"trash_objects"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationTrashObjectsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationTrashObjectsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationTrashObjectsPurgeAllResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task Task `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON406 *TaskQueueingErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationTrashObjectsPurgeAllResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationTrashObjectsPurgeAllResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationUsersWithAccessResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + Users []GetOrganizationUsersWithAccess200ResponseUsers `json:"users"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationUsersWithAccessResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationUsersWithAccessResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationVirtualMachineGroupsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachineGroups The virtual machine groups for the provided organization + VirtualMachineGroups []VirtualMachineGroup `json:"virtual_machine_groups"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationVirtualMachineGroupsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationVirtualMachineGroupsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationVirtualMachineGroupsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachineGroup The new virtual machine group details + VirtualMachineGroup VirtualMachineGroup `json:"virtual_machine_group"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationVirtualMachineGroupsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationVirtualMachineGroupsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetOrganizationVirtualMachinesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + VirtualMachines []GetOrganizationVirtualMachines200ResponseVirtualMachines `json:"virtual_machines"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetOrganizationVirtualMachinesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetOrganizationVirtualMachinesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationVirtualMachinesBuildResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + // Build Deprecated, please use "virtual_machine_build" instead + Build PostOrganizationVirtualMachinesBuild201ResponseBuild `json:"build"` + Hostname string `json:"hostname"` + Task PostOrganizationVirtualMachinesBuild201ResponseTask `json:"task"` + VirtualMachineBuild PostOrganizationVirtualMachinesBuild201ResponseVirtualMachineBuild `json:"virtual_machine_build"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + JSON404 *DataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res + JSON422 *LocationRequiredValidationError422Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationVirtualMachinesBuildResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationVirtualMachinesBuildResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostOrganizationVirtualMachinesBuildFromSpecResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + // Build Deprecated, please use "virtual_machine_build" instead + Build PostOrganizationVirtualMachinesBuildFromSpec201ResponseBuild `json:"build"` + Hostname string `json:"hostname"` + Task PostOrganizationVirtualMachinesBuildFromSpec201ResponseTask `json:"task"` + VirtualMachineBuild PostOrganizationVirtualMachinesBuildFromSpec201ResponseVirtualMachineBuild `json:"virtual_machine_build"` + } + JSON400 *InvalidSpecXML400Res + JSON403 *OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + JSON404 *OrganizationNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostOrganizationVirtualMachinesBuildFromSpecResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostOrganizationVirtualMachinesBuildFromSpecResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteSecurityGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // SecurityGroup The security group that has been destroyed + SecurityGroup DeleteSecurityGroup200ResponseSecurityGroup `json:"security_group"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *SecurityGroupNotFoundResponse + JSON409 *DeletionRestrictedResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteSecurityGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSecurityGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetSecurityGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // SecurityGroup The security group + SecurityGroup SecurityGroup `json:"security_group"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *SecurityGroupNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetSecurityGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetSecurityGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchSecurityGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // SecurityGroup The security group that has been updated + SecurityGroup SecurityGroup `json:"security_group"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *SecurityGroupNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchSecurityGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchSecurityGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetSecurityGroupRulesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + + // SecurityGroupRules The security group rules for this security group + SecurityGroupRules []GetSecurityGroupRules200ResponseSecurityGroupRules `json:"security_group_rules"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *SecurityGroupNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetSecurityGroupRulesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetSecurityGroupRulesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostSecurityGroupRulesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // SecurityGroupRule The security group rule that has been created + SecurityGroupRule PostSecurityGroupRules200ResponseSecurityGroupRule `json:"security_group_rule"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *SecurityGroupNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostSecurityGroupRulesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostSecurityGroupRulesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteSecurityGroupsRulesSecurityGroupRuleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // SecurityGroupRule The security group rule that has been destroyed + SecurityGroupRule DeleteSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule `json:"security_group_rule"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *SecurityGroupRuleNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteSecurityGroupsRulesSecurityGroupRuleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSecurityGroupsRulesSecurityGroupRuleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetSecurityGroupsRulesSecurityGroupRuleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // SecurityGroupRule The resolved security group rule + SecurityGroupRule GetSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule `json:"security_group_rule"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *SecurityGroupRuleNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetSecurityGroupsRulesSecurityGroupRuleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetSecurityGroupsRulesSecurityGroupRuleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchSecurityGroupsRulesSecurityGroupRuleResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // SecurityGroupRule The security group that has been updated + SecurityGroupRule PatchSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule `json:"security_group_rule"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *SecurityGroupRuleNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchSecurityGroupsRulesSecurityGroupRuleResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchSecurityGroupsRulesSecurityGroupRuleResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteSshKeyResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + SshKey AuthSSHKey `json:"ssh_key"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *SSHKeyNotFoundResponse + JSON409 *DeletionRestrictedResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteSshKeyResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteSshKeyResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteTagResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Tag The newly deleted tag + Tag Tag `json:"tag"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *TagNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteTagResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteTagResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetTagResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Tag The details for the requested tag + Tag Tag `json:"tag"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *TagNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetTagResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetTagResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchTagResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Tag The newly updated tag + Tag Tag `json:"tag"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *TagNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchTagResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchTagResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetTaskResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task Task `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *TaskNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetTaskResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetTaskResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteTrashObjectResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task Task `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *TrashObjectNotFoundResponse + JSON406 *TaskQueueingErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteTrashObjectResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteTrashObjectResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetTrashObjectResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // TrashObject The requested trash object + TrashObject TrashObject `json:"trash_object"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *TrashObjectNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetTrashObjectResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetTrashObjectResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostTrashObjectRestoreResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // TrashObject The requested trash object + TrashObject TrashObject `json:"trash_object"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *TrashObjectNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostTrashObjectRestoreResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostTrashObjectRestoreResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetUsersCurrentResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + ApiTokenId string `json:"api_token_id"` + Organizations []GetUsersCurrent200ResponseOrganizations `json:"organizations"` + User User `json:"user"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *NoUserAssociatedWithIdentityResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetUsersCurrentResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetUsersCurrentResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteVirtualMachineGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachineGroup The details for the deleted virtual machine group + VirtualMachineGroup VirtualMachineGroup `json:"virtual_machine_group"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineGroupNotFoundResponse + JSON409 *DeletionRestrictedResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteVirtualMachineGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteVirtualMachineGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachineGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachineGroup The virtual machine group details + VirtualMachineGroup VirtualMachineGroup `json:"virtual_machine_group"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineGroupNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachineGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachineGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchVirtualMachineGroupResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachineGroup The updated virtual machine group details + VirtualMachineGroup VirtualMachineGroup `json:"virtual_machine_group"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineGroupNotFoundResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchVirtualMachineGroupResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchVirtualMachineGroupResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVMNIVMNIResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachineNetworkInterface The network interface details + VirtualMachineNetworkInterface GetVMNIVMNI200ResponseVirtualMachineNetworkInterface `json:"virtual_machine_network_interface"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *VirtualMachineNetworkInterfaceNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVMNIVMNIResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVMNIVMNIResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineNetworkInterfaceAllocateIpResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachineNetworkInterface The network interface details + VirtualMachineNetworkInterface PostVirtualMachineNetworkInterfaceAllocateIP200ResponseVirtualMachineNetworkInterface `json:"virtual_machine_network_interface"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *IPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res + JSON422 *IPAlreadyAllocatedInvalidIP422Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineNetworkInterfaceAllocateIpResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineNetworkInterfaceAllocateIpResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineNetworkInterfaceAllocateNewIpResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // IpAddress The newly allocated IP address + IpAddress IPAddress `json:"ip_address"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNetworkInterfaceNotFoundResponse + JSON429 *APIAuthenticator429Response + JSON503 *NoAvailableAddressesResponse +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineNetworkInterfaceAllocateNewIpResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineNetworkInterfaceAllocateNewIpResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // IpAddresses The IP addresses available for this network interface + IpAddresses []IPAddress `json:"ip_addresses"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *VirtualMachineNetworkInterfaceNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Task The task responsible for updating the virtual machine network interface speed profile + Task Task `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *NetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res + JSON406 *TaskQueueingErrorResponse + JSON422 *SpeedProfileAlreadyAssignedResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachinePackagesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + VirtualMachinePackages []GetVirtualMachinePackages200ResponseVirtualMachinePackages `json:"virtual_machine_packages"` + } + JSON400 *APIAuthenticator400Response + JSON403 *OrganizationNotActivatedOrganizationSuspended403Res + JSON404 *OrganizationNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachinePackagesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachinePackagesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachinePackageResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + VirtualMachinePackage VirtualMachinePackage `json:"virtual_machine_package"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *VirtualMachinePackageNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachinePackageResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachinePackageResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type DeleteVirtualMachineResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + TrashObject TrashObject `json:"trash_object"` + VirtualMachine DeleteVirtualMachine200ResponseVirtualMachine `json:"virtual_machine"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r DeleteVirtualMachineResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r DeleteVirtualMachineResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachineResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + VirtualMachine GetVirtualMachine200ResponseVirtualMachine `json:"virtual_machine"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachineResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachineResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PatchVirtualMachineResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachine The newly updated virtual machine + VirtualMachine PatchVirtualMachine200ResponseVirtualMachine `json:"virtual_machine"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PatchVirtualMachineResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PatchVirtualMachineResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineAllocateIpResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // IpAddress The newly allocated IP address + IpAddress IPAddress `json:"ip_address"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *IPAddressNotFoundVirtualMachineNotFound404Res + JSON406 *ObjectInTrashResponse + JSON422 *IPAlreadyAllocatedNoInterfaceAvailable422Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineAllocateIpResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineAllocateIpResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineConsoleSessionsResponse struct { + Body []byte + HTTPResponse *http.Response + JSON201 *struct { + ConsoleSession PostVirtualMachineConsoleSessions201ResponseConsoleSession `json:"console_session"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashVirtualMachineMustBeStarted406Res + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineConsoleSessionsResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineConsoleSessionsResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachineDiskBackupPoliciesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicies The disk backup policies for the provided virtual machine + DiskBackupPolicies []GetVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicies `json:"disk_backup_policies"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachineDiskBackupPoliciesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachineDiskBackupPoliciesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineDiskBackupPoliciesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // DiskBackupPolicy The new disk backup policy that has been created + DiskBackupPolicy PostVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON422 *ValidationErrorResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineDiskBackupPoliciesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineDiskBackupPoliciesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachineDisksResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Disks The list of disks + Disks []GetVirtualMachineDisks200ResponseDisks `json:"disks"` + Pagination PaginationObject `json:"pagination"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachineDisksResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachineDisksResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PutVirtualMachineFlexibleResourcesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task Task `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *FlexibleResourcesUnavailableToOrganizationPermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashTaskQueueingError406Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PutVirtualMachineFlexibleResourcesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PutVirtualMachineFlexibleResourcesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachineNetworkInterfacesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Pagination PaginationObject `json:"pagination"` + + // VirtualMachineNetworkInterfaces The network interfaces for this virtual machine + VirtualMachineNetworkInterfaces []GetVirtualMachineNetworkInterfaces200ResponseVirtualMachineNetworkInterfaces `json:"virtual_machine_network_interfaces"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachineNetworkInterfacesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachineNetworkInterfacesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachineNetworkInterfaceResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // VirtualMachineNetworkInterface The network interface details + VirtualMachineNetworkInterface GetVirtualMachineNetworkInterface200ResponseVirtualMachineNetworkInterface `json:"virtual_machine_network_interface"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *InterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res + JSON406 *ObjectInTrashResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachineNetworkInterfaceResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachineNetworkInterfaceResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PutVirtualMachinePackageResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task Task `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundVirtualMachinePackageNotFound404Res + JSON406 *ObjectInTrashTaskQueueingError406Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PutVirtualMachinePackageResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PutVirtualMachinePackageResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineResetResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task PostVirtualMachineReset200ResponseTask `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashTaskQueueingError406Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineResetResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineResetResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineShutdownResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task PostVirtualMachineShutdown200ResponseTask `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashTaskQueueingError406Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineShutdownResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineShutdownResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineStartResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task PostVirtualMachineStart200ResponseTask `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashTaskQueueingError406Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineStartResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineStartResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type PostVirtualMachineStopResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + Task PostVirtualMachineStop200ResponseTask `json:"task"` + } + JSON400 *APIAuthenticator400Response + JSON403 *PermissionDenied403Res + JSON404 *VirtualMachineNotFoundResponse + JSON406 *ObjectInTrashTaskQueueingError406Res + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r PostVirtualMachineStopResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r PostVirtualMachineStopResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetVirtualMachinesBuildsVirtualMachineBuildResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + VirtualMachineBuild GetVirtualMachinesBuildsVirtualMachineBuild200ResponseVirtualMachineBuild `json:"virtual_machine_build"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *VirtualMachineBuildNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetVirtualMachinesBuildsVirtualMachineBuildResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetVirtualMachinesBuildsVirtualMachineBuildResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetZonesResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Zones The zones available to the current identity + Zones []GetZones200ResponseZones `json:"zones"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetZonesResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetZonesResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +type GetZoneResponse struct { + Body []byte + HTTPResponse *http.Response + JSON200 *struct { + // Zone The zone details + Zone Zone `json:"zone"` + } + JSON400 *APIAuthenticator400Response + JSON403 *APIAuthenticator403Response + JSON404 *ZoneNotFoundResponse + JSON429 *APIAuthenticator429Response +} + +// Status returns HTTPResponse.Status +func (r GetZoneResponse) Status() string { + if r.HTTPResponse != nil { + return r.HTTPResponse.Status + } + return http.StatusText(0) +} + +// StatusCode returns HTTPResponse.StatusCode +func (r GetZoneResponse) StatusCode() int { + if r.HTTPResponse != nil { + return r.HTTPResponse.StatusCode + } + return 0 +} + +// GetCertificateWithResponse request returning *GetCertificateResponse +func (c *ClientWithResponses) GetCertificateWithResponse(ctx context.Context, params *GetCertificateParams, reqEditors ...RequestEditorFn) (*GetCertificateResponse, error) { + rsp, err := c.GetCertificate(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetCertificateResponse(rsp) +} + +// GetCountriesWithResponse request returning *GetCountriesResponse +func (c *ClientWithResponses) GetCountriesWithResponse(ctx context.Context, params *GetCountriesParams, reqEditors ...RequestEditorFn) (*GetCountriesResponse, error) { + rsp, err := c.GetCountries(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetCountriesResponse(rsp) +} + +// GetCountryWithResponse request returning *GetCountryResponse +func (c *ClientWithResponses) GetCountryWithResponse(ctx context.Context, params *GetCountryParams, reqEditors ...RequestEditorFn) (*GetCountryResponse, error) { + rsp, err := c.GetCountry(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetCountryResponse(rsp) +} + +// GetCountryCountryStatesWithResponse request returning *GetCountryCountryStatesResponse +func (c *ClientWithResponses) GetCountryCountryStatesWithResponse(ctx context.Context, params *GetCountryCountryStatesParams, reqEditors ...RequestEditorFn) (*GetCountryCountryStatesResponse, error) { + rsp, err := c.GetCountryCountryStates(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetCountryCountryStatesResponse(rsp) +} + +// GetCountryStateWithResponse request returning *GetCountryStateResponse +func (c *ClientWithResponses) GetCountryStateWithResponse(ctx context.Context, params *GetCountryStateParams, reqEditors ...RequestEditorFn) (*GetCountryStateResponse, error) { + rsp, err := c.GetCountryState(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetCountryStateResponse(rsp) +} + +// GetCurrenciesWithResponse request returning *GetCurrenciesResponse +func (c *ClientWithResponses) GetCurrenciesWithResponse(ctx context.Context, params *GetCurrenciesParams, reqEditors ...RequestEditorFn) (*GetCurrenciesResponse, error) { + rsp, err := c.GetCurrencies(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetCurrenciesResponse(rsp) +} + +// GetCurrencyWithResponse request returning *GetCurrencyResponse +func (c *ClientWithResponses) GetCurrencyWithResponse(ctx context.Context, params *GetCurrencyParams, reqEditors ...RequestEditorFn) (*GetCurrencyResponse, error) { + rsp, err := c.GetCurrency(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetCurrencyResponse(rsp) +} + +// GetDataCentersWithResponse request returning *GetDataCentersResponse +func (c *ClientWithResponses) GetDataCentersWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetDataCentersResponse, error) { + rsp, err := c.GetDataCenters(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDataCentersResponse(rsp) +} + +// GetDataCenterWithResponse request returning *GetDataCenterResponse +func (c *ClientWithResponses) GetDataCenterWithResponse(ctx context.Context, params *GetDataCenterParams, reqEditors ...RequestEditorFn) (*GetDataCenterResponse, error) { + rsp, err := c.GetDataCenter(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDataCenterResponse(rsp) +} + +// GetDataCenterDefaultNetworkWithResponse request returning *GetDataCenterDefaultNetworkResponse +func (c *ClientWithResponses) GetDataCenterDefaultNetworkWithResponse(ctx context.Context, params *GetDataCenterDefaultNetworkParams, reqEditors ...RequestEditorFn) (*GetDataCenterDefaultNetworkResponse, error) { + rsp, err := c.GetDataCenterDefaultNetwork(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDataCenterDefaultNetworkResponse(rsp) +} + +// GetDataCenterGpuTypesWithResponse request returning *GetDataCenterGpuTypesResponse +func (c *ClientWithResponses) GetDataCenterGpuTypesWithResponse(ctx context.Context, params *GetDataCenterGpuTypesParams, reqEditors ...RequestEditorFn) (*GetDataCenterGpuTypesResponse, error) { + rsp, err := c.GetDataCenterGpuTypes(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDataCenterGpuTypesResponse(rsp) +} + +// DeleteDiskBackupPolicyWithBodyWithResponse request with arbitrary body returning *DeleteDiskBackupPolicyResponse +func (c *ClientWithResponses) DeleteDiskBackupPolicyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDiskBackupPolicyResponse, error) { + rsp, err := c.DeleteDiskBackupPolicyWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDiskBackupPolicyResponse(rsp) +} + +func (c *ClientWithResponses) DeleteDiskBackupPolicyWithResponse(ctx context.Context, body DeleteDiskBackupPolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDiskBackupPolicyResponse, error) { + rsp, err := c.DeleteDiskBackupPolicy(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDiskBackupPolicyResponse(rsp) +} + +// GetDiskBackupPolicyWithResponse request returning *GetDiskBackupPolicyResponse +func (c *ClientWithResponses) GetDiskBackupPolicyWithResponse(ctx context.Context, params *GetDiskBackupPolicyParams, reqEditors ...RequestEditorFn) (*GetDiskBackupPolicyResponse, error) { + rsp, err := c.GetDiskBackupPolicy(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDiskBackupPolicyResponse(rsp) +} + +// PatchDiskBackupPolicyWithBodyWithResponse request with arbitrary body returning *PatchDiskBackupPolicyResponse +func (c *ClientWithResponses) PatchDiskBackupPolicyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchDiskBackupPolicyResponse, error) { + rsp, err := c.PatchDiskBackupPolicyWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchDiskBackupPolicyResponse(rsp) +} + +func (c *ClientWithResponses) PatchDiskBackupPolicyWithResponse(ctx context.Context, body PatchDiskBackupPolicyJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchDiskBackupPolicyResponse, error) { + rsp, err := c.PatchDiskBackupPolicy(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchDiskBackupPolicyResponse(rsp) +} + +// DeleteDiskBackupPolicyScheduleWithBodyWithResponse request with arbitrary body returning *DeleteDiskBackupPolicyScheduleResponse +func (c *ClientWithResponses) DeleteDiskBackupPolicyScheduleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDiskBackupPolicyScheduleResponse, error) { + rsp, err := c.DeleteDiskBackupPolicyScheduleWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDiskBackupPolicyScheduleResponse(rsp) +} + +func (c *ClientWithResponses) DeleteDiskBackupPolicyScheduleWithResponse(ctx context.Context, body DeleteDiskBackupPolicyScheduleJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDiskBackupPolicyScheduleResponse, error) { + rsp, err := c.DeleteDiskBackupPolicySchedule(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDiskBackupPolicyScheduleResponse(rsp) +} + +// GetDiskTemplateVersionWithResponse request returning *GetDiskTemplateVersionResponse +func (c *ClientWithResponses) GetDiskTemplateVersionWithResponse(ctx context.Context, params *GetDiskTemplateVersionParams, reqEditors ...RequestEditorFn) (*GetDiskTemplateVersionResponse, error) { + rsp, err := c.GetDiskTemplateVersion(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDiskTemplateVersionResponse(rsp) +} + +// GetDiskTemplateVersionSpecWithResponse request returning *GetDiskTemplateVersionSpecResponse +func (c *ClientWithResponses) GetDiskTemplateVersionSpecWithResponse(ctx context.Context, params *GetDiskTemplateVersionSpecParams, reqEditors ...RequestEditorFn) (*GetDiskTemplateVersionSpecResponse, error) { + rsp, err := c.GetDiskTemplateVersionSpec(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDiskTemplateVersionSpecResponse(rsp) +} + +// GetDiskTemplateWithResponse request returning *GetDiskTemplateResponse +func (c *ClientWithResponses) GetDiskTemplateWithResponse(ctx context.Context, params *GetDiskTemplateParams, reqEditors ...RequestEditorFn) (*GetDiskTemplateResponse, error) { + rsp, err := c.GetDiskTemplate(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDiskTemplateResponse(rsp) +} + +// GetDiskTemplateVersionsWithResponse request returning *GetDiskTemplateVersionsResponse +func (c *ClientWithResponses) GetDiskTemplateVersionsWithResponse(ctx context.Context, params *GetDiskTemplateVersionsParams, reqEditors ...RequestEditorFn) (*GetDiskTemplateVersionsResponse, error) { + rsp, err := c.GetDiskTemplateVersions(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDiskTemplateVersionsResponse(rsp) +} + +// GetDiskWithResponse request returning *GetDiskResponse +func (c *ClientWithResponses) GetDiskWithResponse(ctx context.Context, params *GetDiskParams, reqEditors ...RequestEditorFn) (*GetDiskResponse, error) { + rsp, err := c.GetDisk(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDiskResponse(rsp) +} + +// GetDiskDiskBackupPoliciesWithResponse request returning *GetDiskDiskBackupPoliciesResponse +func (c *ClientWithResponses) GetDiskDiskBackupPoliciesWithResponse(ctx context.Context, params *GetDiskDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*GetDiskDiskBackupPoliciesResponse, error) { + rsp, err := c.GetDiskDiskBackupPolicies(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDiskDiskBackupPoliciesResponse(rsp) +} + +// PostDiskDiskBackupPoliciesWithBodyWithResponse request with arbitrary body returning *PostDiskDiskBackupPoliciesResponse +func (c *ClientWithResponses) PostDiskDiskBackupPoliciesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDiskDiskBackupPoliciesResponse, error) { + rsp, err := c.PostDiskDiskBackupPoliciesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDiskDiskBackupPoliciesResponse(rsp) +} + +func (c *ClientWithResponses) PostDiskDiskBackupPoliciesWithResponse(ctx context.Context, body PostDiskDiskBackupPoliciesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDiskDiskBackupPoliciesResponse, error) { + rsp, err := c.PostDiskDiskBackupPolicies(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDiskDiskBackupPoliciesResponse(rsp) +} + +// DeleteDnsRecordsDnsRecordWithBodyWithResponse request with arbitrary body returning *DeleteDnsRecordsDnsRecordResponse +func (c *ClientWithResponses) DeleteDnsRecordsDnsRecordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDnsRecordsDnsRecordResponse, error) { + rsp, err := c.DeleteDnsRecordsDnsRecordWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDnsRecordsDnsRecordResponse(rsp) +} + +func (c *ClientWithResponses) DeleteDnsRecordsDnsRecordWithResponse(ctx context.Context, body DeleteDnsRecordsDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDnsRecordsDnsRecordResponse, error) { + rsp, err := c.DeleteDnsRecordsDnsRecord(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDnsRecordsDnsRecordResponse(rsp) +} + +// GetDnsRecordsDnsRecordWithResponse request returning *GetDnsRecordsDnsRecordResponse +func (c *ClientWithResponses) GetDnsRecordsDnsRecordWithResponse(ctx context.Context, params *GetDnsRecordsDnsRecordParams, reqEditors ...RequestEditorFn) (*GetDnsRecordsDnsRecordResponse, error) { + rsp, err := c.GetDnsRecordsDnsRecord(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDnsRecordsDnsRecordResponse(rsp) +} + +// PatchDnsRecordsDnsRecordWithBodyWithResponse request with arbitrary body returning *PatchDnsRecordsDnsRecordResponse +func (c *ClientWithResponses) PatchDnsRecordsDnsRecordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchDnsRecordsDnsRecordResponse, error) { + rsp, err := c.PatchDnsRecordsDnsRecordWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchDnsRecordsDnsRecordResponse(rsp) +} + +func (c *ClientWithResponses) PatchDnsRecordsDnsRecordWithResponse(ctx context.Context, body PatchDnsRecordsDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchDnsRecordsDnsRecordResponse, error) { + rsp, err := c.PatchDnsRecordsDnsRecord(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchDnsRecordsDnsRecordResponse(rsp) +} + +// DeleteDnsZonesDnsZoneWithBodyWithResponse request with arbitrary body returning *DeleteDnsZonesDnsZoneResponse +func (c *ClientWithResponses) DeleteDnsZonesDnsZoneWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDnsZonesDnsZoneResponse, error) { + rsp, err := c.DeleteDnsZonesDnsZoneWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDnsZonesDnsZoneResponse(rsp) +} + +func (c *ClientWithResponses) DeleteDnsZonesDnsZoneWithResponse(ctx context.Context, body DeleteDnsZonesDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDnsZonesDnsZoneResponse, error) { + rsp, err := c.DeleteDnsZonesDnsZone(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDnsZonesDnsZoneResponse(rsp) +} + +// GetDnsZonesDnsZoneWithResponse request returning *GetDnsZonesDnsZoneResponse +func (c *ClientWithResponses) GetDnsZonesDnsZoneWithResponse(ctx context.Context, params *GetDnsZonesDnsZoneParams, reqEditors ...RequestEditorFn) (*GetDnsZonesDnsZoneResponse, error) { + rsp, err := c.GetDnsZonesDnsZone(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDnsZonesDnsZoneResponse(rsp) +} + +// GetDnsZonesDnsZoneRecordsWithResponse request returning *GetDnsZonesDnsZoneRecordsResponse +func (c *ClientWithResponses) GetDnsZonesDnsZoneRecordsWithResponse(ctx context.Context, params *GetDnsZonesDnsZoneRecordsParams, reqEditors ...RequestEditorFn) (*GetDnsZonesDnsZoneRecordsResponse, error) { + rsp, err := c.GetDnsZonesDnsZoneRecords(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDnsZonesDnsZoneRecordsResponse(rsp) +} + +// PostDnsZonesDnsZoneRecordsWithBodyWithResponse request with arbitrary body returning *PostDnsZonesDnsZoneRecordsResponse +func (c *ClientWithResponses) PostDnsZonesDnsZoneRecordsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneRecordsResponse, error) { + rsp, err := c.PostDnsZonesDnsZoneRecordsWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZonesDnsZoneRecordsResponse(rsp) +} + +func (c *ClientWithResponses) PostDnsZonesDnsZoneRecordsWithResponse(ctx context.Context, body PostDnsZonesDnsZoneRecordsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneRecordsResponse, error) { + rsp, err := c.PostDnsZonesDnsZoneRecords(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZonesDnsZoneRecordsResponse(rsp) +} + +// PostDnsZonesDnsZoneUpdateTtlWithBodyWithResponse request with arbitrary body returning *PostDnsZonesDnsZoneUpdateTtlResponse +func (c *ClientWithResponses) PostDnsZonesDnsZoneUpdateTtlWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneUpdateTtlResponse, error) { + rsp, err := c.PostDnsZonesDnsZoneUpdateTtlWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZonesDnsZoneUpdateTtlResponse(rsp) +} + +func (c *ClientWithResponses) PostDnsZonesDnsZoneUpdateTtlWithResponse(ctx context.Context, body PostDnsZonesDnsZoneUpdateTtlJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneUpdateTtlResponse, error) { + rsp, err := c.PostDnsZonesDnsZoneUpdateTtl(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZonesDnsZoneUpdateTtlResponse(rsp) +} + +// GetDnsZonesDnsZoneVerificationDetailsWithResponse request returning *GetDnsZonesDnsZoneVerificationDetailsResponse +func (c *ClientWithResponses) GetDnsZonesDnsZoneVerificationDetailsWithResponse(ctx context.Context, params *GetDnsZonesDnsZoneVerificationDetailsParams, reqEditors ...RequestEditorFn) (*GetDnsZonesDnsZoneVerificationDetailsResponse, error) { + rsp, err := c.GetDnsZonesDnsZoneVerificationDetails(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDnsZonesDnsZoneVerificationDetailsResponse(rsp) +} + +// PostDnsZonesDnsZoneVerifyWithBodyWithResponse request with arbitrary body returning *PostDnsZonesDnsZoneVerifyResponse +func (c *ClientWithResponses) PostDnsZonesDnsZoneVerifyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneVerifyResponse, error) { + rsp, err := c.PostDnsZonesDnsZoneVerifyWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZonesDnsZoneVerifyResponse(rsp) +} + +func (c *ClientWithResponses) PostDnsZonesDnsZoneVerifyWithResponse(ctx context.Context, body PostDnsZonesDnsZoneVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZonesDnsZoneVerifyResponse, error) { + rsp, err := c.PostDnsZonesDnsZoneVerify(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZonesDnsZoneVerifyResponse(rsp) +} + +// DeleteDnsRecordWithBodyWithResponse request with arbitrary body returning *DeleteDnsRecordResponse +func (c *ClientWithResponses) DeleteDnsRecordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDnsRecordResponse, error) { + rsp, err := c.DeleteDnsRecordWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDnsRecordResponse(rsp) +} + +func (c *ClientWithResponses) DeleteDnsRecordWithResponse(ctx context.Context, body DeleteDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDnsRecordResponse, error) { + rsp, err := c.DeleteDnsRecord(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDnsRecordResponse(rsp) +} + +// GetDnsRecordWithResponse request returning *GetDnsRecordResponse +func (c *ClientWithResponses) GetDnsRecordWithResponse(ctx context.Context, params *GetDnsRecordParams, reqEditors ...RequestEditorFn) (*GetDnsRecordResponse, error) { + rsp, err := c.GetDnsRecord(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDnsRecordResponse(rsp) +} + +// PatchDnsRecordWithBodyWithResponse request with arbitrary body returning *PatchDnsRecordResponse +func (c *ClientWithResponses) PatchDnsRecordWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchDnsRecordResponse, error) { + rsp, err := c.PatchDnsRecordWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchDnsRecordResponse(rsp) +} + +func (c *ClientWithResponses) PatchDnsRecordWithResponse(ctx context.Context, body PatchDnsRecordJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchDnsRecordResponse, error) { + rsp, err := c.PatchDnsRecord(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchDnsRecordResponse(rsp) +} + +// DeleteDnsZoneWithBodyWithResponse request with arbitrary body returning *DeleteDnsZoneResponse +func (c *ClientWithResponses) DeleteDnsZoneWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteDnsZoneResponse, error) { + rsp, err := c.DeleteDnsZoneWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDnsZoneResponse(rsp) +} + +func (c *ClientWithResponses) DeleteDnsZoneWithResponse(ctx context.Context, body DeleteDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteDnsZoneResponse, error) { + rsp, err := c.DeleteDnsZone(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteDnsZoneResponse(rsp) +} + +// GetDnsZoneWithResponse request returning *GetDnsZoneResponse +func (c *ClientWithResponses) GetDnsZoneWithResponse(ctx context.Context, params *GetDnsZoneParams, reqEditors ...RequestEditorFn) (*GetDnsZoneResponse, error) { + rsp, err := c.GetDnsZone(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDnsZoneResponse(rsp) +} + +// PatchDnsZoneWithBodyWithResponse request with arbitrary body returning *PatchDnsZoneResponse +func (c *ClientWithResponses) PatchDnsZoneWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchDnsZoneResponse, error) { + rsp, err := c.PatchDnsZoneWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchDnsZoneResponse(rsp) +} + +func (c *ClientWithResponses) PatchDnsZoneWithResponse(ctx context.Context, body PatchDnsZoneJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchDnsZoneResponse, error) { + rsp, err := c.PatchDnsZone(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchDnsZoneResponse(rsp) +} + +// GetDnsZoneRecordsWithResponse request returning *GetDnsZoneRecordsResponse +func (c *ClientWithResponses) GetDnsZoneRecordsWithResponse(ctx context.Context, params *GetDnsZoneRecordsParams, reqEditors ...RequestEditorFn) (*GetDnsZoneRecordsResponse, error) { + rsp, err := c.GetDnsZoneRecords(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetDnsZoneRecordsResponse(rsp) +} + +// PostDnsZoneRecordsWithBodyWithResponse request with arbitrary body returning *PostDnsZoneRecordsResponse +func (c *ClientWithResponses) PostDnsZoneRecordsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZoneRecordsResponse, error) { + rsp, err := c.PostDnsZoneRecordsWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZoneRecordsResponse(rsp) +} + +func (c *ClientWithResponses) PostDnsZoneRecordsWithResponse(ctx context.Context, body PostDnsZoneRecordsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZoneRecordsResponse, error) { + rsp, err := c.PostDnsZoneRecords(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZoneRecordsResponse(rsp) +} + +// PostDnsZoneVerifyWithBodyWithResponse request with arbitrary body returning *PostDnsZoneVerifyResponse +func (c *ClientWithResponses) PostDnsZoneVerifyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostDnsZoneVerifyResponse, error) { + rsp, err := c.PostDnsZoneVerifyWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZoneVerifyResponse(rsp) +} + +func (c *ClientWithResponses) PostDnsZoneVerifyWithResponse(ctx context.Context, body PostDnsZoneVerifyJSONRequestBody, reqEditors ...RequestEditorFn) (*PostDnsZoneVerifyResponse, error) { + rsp, err := c.PostDnsZoneVerify(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostDnsZoneVerifyResponse(rsp) +} + +// DeleteFileStorageVolumeWithBodyWithResponse request with arbitrary body returning *DeleteFileStorageVolumeResponse +func (c *ClientWithResponses) DeleteFileStorageVolumeWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteFileStorageVolumeResponse, error) { + rsp, err := c.DeleteFileStorageVolumeWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteFileStorageVolumeResponse(rsp) +} + +func (c *ClientWithResponses) DeleteFileStorageVolumeWithResponse(ctx context.Context, body DeleteFileStorageVolumeJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteFileStorageVolumeResponse, error) { + rsp, err := c.DeleteFileStorageVolume(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteFileStorageVolumeResponse(rsp) +} + +// GetFileStorageVolumeWithResponse request returning *GetFileStorageVolumeResponse +func (c *ClientWithResponses) GetFileStorageVolumeWithResponse(ctx context.Context, params *GetFileStorageVolumeParams, reqEditors ...RequestEditorFn) (*GetFileStorageVolumeResponse, error) { + rsp, err := c.GetFileStorageVolume(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetFileStorageVolumeResponse(rsp) +} + +// PatchFileStorageVolumeWithBodyWithResponse request with arbitrary body returning *PatchFileStorageVolumeResponse +func (c *ClientWithResponses) PatchFileStorageVolumeWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchFileStorageVolumeResponse, error) { + rsp, err := c.PatchFileStorageVolumeWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchFileStorageVolumeResponse(rsp) +} + +func (c *ClientWithResponses) PatchFileStorageVolumeWithResponse(ctx context.Context, body PatchFileStorageVolumeJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchFileStorageVolumeResponse, error) { + rsp, err := c.PatchFileStorageVolume(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchFileStorageVolumeResponse(rsp) +} + +// GetGpuTypesWithResponse request returning *GetGpuTypesResponse +func (c *ClientWithResponses) GetGpuTypesWithResponse(ctx context.Context, params *GetGpuTypesParams, reqEditors ...RequestEditorFn) (*GetGpuTypesResponse, error) { + rsp, err := c.GetGpuTypes(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetGpuTypesResponse(rsp) +} + +// GetGpuTypeWithResponse request returning *GetGpuTypeResponse +func (c *ClientWithResponses) GetGpuTypeWithResponse(ctx context.Context, params *GetGpuTypeParams, reqEditors ...RequestEditorFn) (*GetGpuTypeResponse, error) { + rsp, err := c.GetGpuType(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetGpuTypeResponse(rsp) +} + +// PostInvalidateLinkedWebSessionWithBodyWithResponse request with arbitrary body returning *PostInvalidateLinkedWebSessionResponse +func (c *ClientWithResponses) PostInvalidateLinkedWebSessionWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostInvalidateLinkedWebSessionResponse, error) { + rsp, err := c.PostInvalidateLinkedWebSessionWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostInvalidateLinkedWebSessionResponse(rsp) +} + +func (c *ClientWithResponses) PostInvalidateLinkedWebSessionWithResponse(ctx context.Context, body PostInvalidateLinkedWebSessionJSONRequestBody, reqEditors ...RequestEditorFn) (*PostInvalidateLinkedWebSessionResponse, error) { + rsp, err := c.PostInvalidateLinkedWebSession(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostInvalidateLinkedWebSessionResponse(rsp) +} + +// DeleteIpAddressWithBodyWithResponse request with arbitrary body returning *DeleteIpAddressResponse +func (c *ClientWithResponses) DeleteIpAddressWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteIpAddressResponse, error) { + rsp, err := c.DeleteIpAddressWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteIpAddressResponse(rsp) +} + +func (c *ClientWithResponses) DeleteIpAddressWithResponse(ctx context.Context, body DeleteIpAddressJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteIpAddressResponse, error) { + rsp, err := c.DeleteIpAddress(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteIpAddressResponse(rsp) +} + +// GetIpAddressWithResponse request returning *GetIpAddressResponse +func (c *ClientWithResponses) GetIpAddressWithResponse(ctx context.Context, params *GetIpAddressParams, reqEditors ...RequestEditorFn) (*GetIpAddressResponse, error) { + rsp, err := c.GetIpAddress(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetIpAddressResponse(rsp) +} + +// PatchIpAddressWithBodyWithResponse request with arbitrary body returning *PatchIpAddressResponse +func (c *ClientWithResponses) PatchIpAddressWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchIpAddressResponse, error) { + rsp, err := c.PatchIpAddressWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchIpAddressResponse(rsp) +} + +func (c *ClientWithResponses) PatchIpAddressWithResponse(ctx context.Context, body PatchIpAddressJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchIpAddressResponse, error) { + rsp, err := c.PatchIpAddress(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchIpAddressResponse(rsp) +} + +// PostIpAddressUnallocateWithBodyWithResponse request with arbitrary body returning *PostIpAddressUnallocateResponse +func (c *ClientWithResponses) PostIpAddressUnallocateWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostIpAddressUnallocateResponse, error) { + rsp, err := c.PostIpAddressUnallocateWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostIpAddressUnallocateResponse(rsp) +} + +func (c *ClientWithResponses) PostIpAddressUnallocateWithResponse(ctx context.Context, body PostIpAddressUnallocateJSONRequestBody, reqEditors ...RequestEditorFn) (*PostIpAddressUnallocateResponse, error) { + rsp, err := c.PostIpAddressUnallocate(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostIpAddressUnallocateResponse(rsp) +} + +// DeleteLoadBalancerWithBodyWithResponse request with arbitrary body returning *DeleteLoadBalancerResponse +func (c *ClientWithResponses) DeleteLoadBalancerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteLoadBalancerResponse, error) { + rsp, err := c.DeleteLoadBalancerWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteLoadBalancerResponse(rsp) +} + +func (c *ClientWithResponses) DeleteLoadBalancerWithResponse(ctx context.Context, body DeleteLoadBalancerJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteLoadBalancerResponse, error) { + rsp, err := c.DeleteLoadBalancer(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteLoadBalancerResponse(rsp) +} + +// GetLoadBalancerWithResponse request returning *GetLoadBalancerResponse +func (c *ClientWithResponses) GetLoadBalancerWithResponse(ctx context.Context, params *GetLoadBalancerParams, reqEditors ...RequestEditorFn) (*GetLoadBalancerResponse, error) { + rsp, err := c.GetLoadBalancer(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetLoadBalancerResponse(rsp) +} + +// PatchLoadBalancerWithBodyWithResponse request with arbitrary body returning *PatchLoadBalancerResponse +func (c *ClientWithResponses) PatchLoadBalancerWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchLoadBalancerResponse, error) { + rsp, err := c.PatchLoadBalancerWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchLoadBalancerResponse(rsp) +} + +func (c *ClientWithResponses) PatchLoadBalancerWithResponse(ctx context.Context, body PatchLoadBalancerJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchLoadBalancerResponse, error) { + rsp, err := c.PatchLoadBalancer(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchLoadBalancerResponse(rsp) +} + +// GetLoadBalancerRulesWithResponse request returning *GetLoadBalancerRulesResponse +func (c *ClientWithResponses) GetLoadBalancerRulesWithResponse(ctx context.Context, params *GetLoadBalancerRulesParams, reqEditors ...RequestEditorFn) (*GetLoadBalancerRulesResponse, error) { + rsp, err := c.GetLoadBalancerRules(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetLoadBalancerRulesResponse(rsp) +} + +// PostLoadBalancerRulesWithBodyWithResponse request with arbitrary body returning *PostLoadBalancerRulesResponse +func (c *ClientWithResponses) PostLoadBalancerRulesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostLoadBalancerRulesResponse, error) { + rsp, err := c.PostLoadBalancerRulesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostLoadBalancerRulesResponse(rsp) +} + +func (c *ClientWithResponses) PostLoadBalancerRulesWithResponse(ctx context.Context, body PostLoadBalancerRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostLoadBalancerRulesResponse, error) { + rsp, err := c.PostLoadBalancerRules(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostLoadBalancerRulesResponse(rsp) +} + +// DeleteLoadBalancersRulesLoadBalancerRuleWithBodyWithResponse request with arbitrary body returning *DeleteLoadBalancersRulesLoadBalancerRuleResponse +func (c *ClientWithResponses) DeleteLoadBalancersRulesLoadBalancerRuleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteLoadBalancersRulesLoadBalancerRuleResponse, error) { + rsp, err := c.DeleteLoadBalancersRulesLoadBalancerRuleWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteLoadBalancersRulesLoadBalancerRuleResponse(rsp) +} + +func (c *ClientWithResponses) DeleteLoadBalancersRulesLoadBalancerRuleWithResponse(ctx context.Context, body DeleteLoadBalancersRulesLoadBalancerRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteLoadBalancersRulesLoadBalancerRuleResponse, error) { + rsp, err := c.DeleteLoadBalancersRulesLoadBalancerRule(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteLoadBalancersRulesLoadBalancerRuleResponse(rsp) +} + +// GetLoadBalancersRulesLoadBalancerRuleWithResponse request returning *GetLoadBalancersRulesLoadBalancerRuleResponse +func (c *ClientWithResponses) GetLoadBalancersRulesLoadBalancerRuleWithResponse(ctx context.Context, params *GetLoadBalancersRulesLoadBalancerRuleParams, reqEditors ...RequestEditorFn) (*GetLoadBalancersRulesLoadBalancerRuleResponse, error) { + rsp, err := c.GetLoadBalancersRulesLoadBalancerRule(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetLoadBalancersRulesLoadBalancerRuleResponse(rsp) +} + +// PatchLoadBalancersRulesLoadBalancerRuleWithBodyWithResponse request with arbitrary body returning *PatchLoadBalancersRulesLoadBalancerRuleResponse +func (c *ClientWithResponses) PatchLoadBalancersRulesLoadBalancerRuleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchLoadBalancersRulesLoadBalancerRuleResponse, error) { + rsp, err := c.PatchLoadBalancersRulesLoadBalancerRuleWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchLoadBalancersRulesLoadBalancerRuleResponse(rsp) +} + +func (c *ClientWithResponses) PatchLoadBalancersRulesLoadBalancerRuleWithResponse(ctx context.Context, body PatchLoadBalancersRulesLoadBalancerRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchLoadBalancersRulesLoadBalancerRuleResponse, error) { + rsp, err := c.PatchLoadBalancersRulesLoadBalancerRule(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchLoadBalancersRulesLoadBalancerRuleResponse(rsp) +} + +// GetNetworkWithResponse request returning *GetNetworkResponse +func (c *ClientWithResponses) GetNetworkWithResponse(ctx context.Context, params *GetNetworkParams, reqEditors ...RequestEditorFn) (*GetNetworkResponse, error) { + rsp, err := c.GetNetwork(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetNetworkResponse(rsp) +} + +// GetOperatingSystemsWithResponse request returning *GetOperatingSystemsResponse +func (c *ClientWithResponses) GetOperatingSystemsWithResponse(ctx context.Context, params *GetOperatingSystemsParams, reqEditors ...RequestEditorFn) (*GetOperatingSystemsResponse, error) { + rsp, err := c.GetOperatingSystems(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOperatingSystemsResponse(rsp) +} + +// GetOperatingSystemWithResponse request returning *GetOperatingSystemResponse +func (c *ClientWithResponses) GetOperatingSystemWithResponse(ctx context.Context, params *GetOperatingSystemParams, reqEditors ...RequestEditorFn) (*GetOperatingSystemResponse, error) { + rsp, err := c.GetOperatingSystem(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOperatingSystemResponse(rsp) +} + +// GetOrganizationsWithResponse request returning *GetOrganizationsResponse +func (c *ClientWithResponses) GetOrganizationsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetOrganizationsResponse, error) { + rsp, err := c.GetOrganizations(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationsResponse(rsp) +} + +// GetOrganizationWithResponse request returning *GetOrganizationResponse +func (c *ClientWithResponses) GetOrganizationWithResponse(ctx context.Context, params *GetOrganizationParams, reqEditors ...RequestEditorFn) (*GetOrganizationResponse, error) { + rsp, err := c.GetOrganization(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationResponse(rsp) +} + +// GetOrganizationAvailableNetworksWithResponse request returning *GetOrganizationAvailableNetworksResponse +func (c *ClientWithResponses) GetOrganizationAvailableNetworksWithResponse(ctx context.Context, params *GetOrganizationAvailableNetworksParams, reqEditors ...RequestEditorFn) (*GetOrganizationAvailableNetworksResponse, error) { + rsp, err := c.GetOrganizationAvailableNetworks(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationAvailableNetworksResponse(rsp) +} + +// GetOrganizationCertificatesWithResponse request returning *GetOrganizationCertificatesResponse +func (c *ClientWithResponses) GetOrganizationCertificatesWithResponse(ctx context.Context, params *GetOrganizationCertificatesParams, reqEditors ...RequestEditorFn) (*GetOrganizationCertificatesResponse, error) { + rsp, err := c.GetOrganizationCertificates(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationCertificatesResponse(rsp) +} + +// GetOrganizationDiskBackupPoliciesWithResponse request returning *GetOrganizationDiskBackupPoliciesResponse +func (c *ClientWithResponses) GetOrganizationDiskBackupPoliciesWithResponse(ctx context.Context, params *GetOrganizationDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*GetOrganizationDiskBackupPoliciesResponse, error) { + rsp, err := c.GetOrganizationDiskBackupPolicies(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationDiskBackupPoliciesResponse(rsp) +} + +// GetOrganizationDiskTemplatesWithResponse request returning *GetOrganizationDiskTemplatesResponse +func (c *ClientWithResponses) GetOrganizationDiskTemplatesWithResponse(ctx context.Context, params *GetOrganizationDiskTemplatesParams, reqEditors ...RequestEditorFn) (*GetOrganizationDiskTemplatesResponse, error) { + rsp, err := c.GetOrganizationDiskTemplates(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationDiskTemplatesResponse(rsp) +} + +// GetOrganizationDisksWithResponse request returning *GetOrganizationDisksResponse +func (c *ClientWithResponses) GetOrganizationDisksWithResponse(ctx context.Context, params *GetOrganizationDisksParams, reqEditors ...RequestEditorFn) (*GetOrganizationDisksResponse, error) { + rsp, err := c.GetOrganizationDisks(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationDisksResponse(rsp) +} + +// GetOrganizationDnsZonesWithResponse request returning *GetOrganizationDnsZonesResponse +func (c *ClientWithResponses) GetOrganizationDnsZonesWithResponse(ctx context.Context, params *GetOrganizationDnsZonesParams, reqEditors ...RequestEditorFn) (*GetOrganizationDnsZonesResponse, error) { + rsp, err := c.GetOrganizationDnsZones(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationDnsZonesResponse(rsp) +} + +// PostOrganizationDnsZonesWithBodyWithResponse request with arbitrary body returning *PostOrganizationDnsZonesResponse +func (c *ClientWithResponses) PostOrganizationDnsZonesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationDnsZonesResponse, error) { + rsp, err := c.PostOrganizationDnsZonesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationDnsZonesResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationDnsZonesWithResponse(ctx context.Context, body PostOrganizationDnsZonesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationDnsZonesResponse, error) { + rsp, err := c.PostOrganizationDnsZones(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationDnsZonesResponse(rsp) +} + +// GetOrganizationsOrganizationdnsZonesWithResponse request returning *GetOrganizationsOrganizationdnsZonesResponse +func (c *ClientWithResponses) GetOrganizationsOrganizationdnsZonesWithResponse(ctx context.Context, params *GetOrganizationsOrganizationdnsZonesParams, reqEditors ...RequestEditorFn) (*GetOrganizationsOrganizationdnsZonesResponse, error) { + rsp, err := c.GetOrganizationsOrganizationdnsZones(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationsOrganizationdnsZonesResponse(rsp) +} + +// PostOrganizationsOrganizationdnsZonesWithBodyWithResponse request with arbitrary body returning *PostOrganizationsOrganizationdnsZonesResponse +func (c *ClientWithResponses) PostOrganizationsOrganizationdnsZonesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationsOrganizationdnsZonesResponse, error) { + rsp, err := c.PostOrganizationsOrganizationdnsZonesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationsOrganizationdnsZonesResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationsOrganizationdnsZonesWithResponse(ctx context.Context, body PostOrganizationsOrganizationdnsZonesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationsOrganizationdnsZonesResponse, error) { + rsp, err := c.PostOrganizationsOrganizationdnsZones(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationsOrganizationdnsZonesResponse(rsp) +} + +// GetOrganizationDnsZonesNameserversWithResponse request returning *GetOrganizationDnsZonesNameserversResponse +func (c *ClientWithResponses) GetOrganizationDnsZonesNameserversWithResponse(ctx context.Context, params *GetOrganizationDnsZonesNameserversParams, reqEditors ...RequestEditorFn) (*GetOrganizationDnsZonesNameserversResponse, error) { + rsp, err := c.GetOrganizationDnsZonesNameservers(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationDnsZonesNameserversResponse(rsp) +} + +// GetOrganizationFileStorageVolumesWithResponse request returning *GetOrganizationFileStorageVolumesResponse +func (c *ClientWithResponses) GetOrganizationFileStorageVolumesWithResponse(ctx context.Context, params *GetOrganizationFileStorageVolumesParams, reqEditors ...RequestEditorFn) (*GetOrganizationFileStorageVolumesResponse, error) { + rsp, err := c.GetOrganizationFileStorageVolumes(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationFileStorageVolumesResponse(rsp) +} + +// PostOrganizationFileStorageVolumesWithBodyWithResponse request with arbitrary body returning *PostOrganizationFileStorageVolumesResponse +func (c *ClientWithResponses) PostOrganizationFileStorageVolumesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationFileStorageVolumesResponse, error) { + rsp, err := c.PostOrganizationFileStorageVolumesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationFileStorageVolumesResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationFileStorageVolumesWithResponse(ctx context.Context, body PostOrganizationFileStorageVolumesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationFileStorageVolumesResponse, error) { + rsp, err := c.PostOrganizationFileStorageVolumes(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationFileStorageVolumesResponse(rsp) +} + +// GetOrganizationIpAddressesWithResponse request returning *GetOrganizationIpAddressesResponse +func (c *ClientWithResponses) GetOrganizationIpAddressesWithResponse(ctx context.Context, params *GetOrganizationIpAddressesParams, reqEditors ...RequestEditorFn) (*GetOrganizationIpAddressesResponse, error) { + rsp, err := c.GetOrganizationIpAddresses(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationIpAddressesResponse(rsp) +} + +// PostOrganizationIpAddressesWithBodyWithResponse request with arbitrary body returning *PostOrganizationIpAddressesResponse +func (c *ClientWithResponses) PostOrganizationIpAddressesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationIpAddressesResponse, error) { + rsp, err := c.PostOrganizationIpAddressesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationIpAddressesResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationIpAddressesWithResponse(ctx context.Context, body PostOrganizationIpAddressesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationIpAddressesResponse, error) { + rsp, err := c.PostOrganizationIpAddresses(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationIpAddressesResponse(rsp) +} + +// GetOrganizationLoadBalancersWithResponse request returning *GetOrganizationLoadBalancersResponse +func (c *ClientWithResponses) GetOrganizationLoadBalancersWithResponse(ctx context.Context, params *GetOrganizationLoadBalancersParams, reqEditors ...RequestEditorFn) (*GetOrganizationLoadBalancersResponse, error) { + rsp, err := c.GetOrganizationLoadBalancers(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationLoadBalancersResponse(rsp) +} + +// PostOrganizationLoadBalancersWithBodyWithResponse request with arbitrary body returning *PostOrganizationLoadBalancersResponse +func (c *ClientWithResponses) PostOrganizationLoadBalancersWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationLoadBalancersResponse, error) { + rsp, err := c.PostOrganizationLoadBalancersWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationLoadBalancersResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationLoadBalancersWithResponse(ctx context.Context, body PostOrganizationLoadBalancersJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationLoadBalancersResponse, error) { + rsp, err := c.PostOrganizationLoadBalancers(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationLoadBalancersResponse(rsp) +} + +// GetOrganizationManagedWithResponse request returning *GetOrganizationManagedResponse +func (c *ClientWithResponses) GetOrganizationManagedWithResponse(ctx context.Context, params *GetOrganizationManagedParams, reqEditors ...RequestEditorFn) (*GetOrganizationManagedResponse, error) { + rsp, err := c.GetOrganizationManaged(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationManagedResponse(rsp) +} + +// PostOrganizationManagedWithBodyWithResponse request with arbitrary body returning *PostOrganizationManagedResponse +func (c *ClientWithResponses) PostOrganizationManagedWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationManagedResponse, error) { + rsp, err := c.PostOrganizationManagedWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationManagedResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationManagedWithResponse(ctx context.Context, body PostOrganizationManagedJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationManagedResponse, error) { + rsp, err := c.PostOrganizationManaged(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationManagedResponse(rsp) +} + +// GetOrganizationNetworkSpeedProfilesWithResponse request returning *GetOrganizationNetworkSpeedProfilesResponse +func (c *ClientWithResponses) GetOrganizationNetworkSpeedProfilesWithResponse(ctx context.Context, params *GetOrganizationNetworkSpeedProfilesParams, reqEditors ...RequestEditorFn) (*GetOrganizationNetworkSpeedProfilesResponse, error) { + rsp, err := c.GetOrganizationNetworkSpeedProfiles(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationNetworkSpeedProfilesResponse(rsp) +} + +// GetOrganizationSecurityGroupsWithResponse request returning *GetOrganizationSecurityGroupsResponse +func (c *ClientWithResponses) GetOrganizationSecurityGroupsWithResponse(ctx context.Context, params *GetOrganizationSecurityGroupsParams, reqEditors ...RequestEditorFn) (*GetOrganizationSecurityGroupsResponse, error) { + rsp, err := c.GetOrganizationSecurityGroups(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationSecurityGroupsResponse(rsp) +} + +// PostOrganizationSecurityGroupsWithBodyWithResponse request with arbitrary body returning *PostOrganizationSecurityGroupsResponse +func (c *ClientWithResponses) PostOrganizationSecurityGroupsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationSecurityGroupsResponse, error) { + rsp, err := c.PostOrganizationSecurityGroupsWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationSecurityGroupsResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationSecurityGroupsWithResponse(ctx context.Context, body PostOrganizationSecurityGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationSecurityGroupsResponse, error) { + rsp, err := c.PostOrganizationSecurityGroups(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationSecurityGroupsResponse(rsp) +} + +// GetOrganizationSshKeysWithResponse request returning *GetOrganizationSshKeysResponse +func (c *ClientWithResponses) GetOrganizationSshKeysWithResponse(ctx context.Context, params *GetOrganizationSshKeysParams, reqEditors ...RequestEditorFn) (*GetOrganizationSshKeysResponse, error) { + rsp, err := c.GetOrganizationSshKeys(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationSshKeysResponse(rsp) +} + +// PostOrganizationSshKeysWithBodyWithResponse request with arbitrary body returning *PostOrganizationSshKeysResponse +func (c *ClientWithResponses) PostOrganizationSshKeysWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationSshKeysResponse, error) { + rsp, err := c.PostOrganizationSshKeysWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationSshKeysResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationSshKeysWithResponse(ctx context.Context, body PostOrganizationSshKeysJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationSshKeysResponse, error) { + rsp, err := c.PostOrganizationSshKeys(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationSshKeysResponse(rsp) +} + +// GetOrganizationTagsWithResponse request returning *GetOrganizationTagsResponse +func (c *ClientWithResponses) GetOrganizationTagsWithResponse(ctx context.Context, params *GetOrganizationTagsParams, reqEditors ...RequestEditorFn) (*GetOrganizationTagsResponse, error) { + rsp, err := c.GetOrganizationTags(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationTagsResponse(rsp) +} + +// PostOrganizationTagsWithBodyWithResponse request with arbitrary body returning *PostOrganizationTagsResponse +func (c *ClientWithResponses) PostOrganizationTagsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationTagsResponse, error) { + rsp, err := c.PostOrganizationTagsWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationTagsResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationTagsWithResponse(ctx context.Context, body PostOrganizationTagsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationTagsResponse, error) { + rsp, err := c.PostOrganizationTags(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationTagsResponse(rsp) +} + +// GetOrganizationTrashObjectsWithResponse request returning *GetOrganizationTrashObjectsResponse +func (c *ClientWithResponses) GetOrganizationTrashObjectsWithResponse(ctx context.Context, params *GetOrganizationTrashObjectsParams, reqEditors ...RequestEditorFn) (*GetOrganizationTrashObjectsResponse, error) { + rsp, err := c.GetOrganizationTrashObjects(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationTrashObjectsResponse(rsp) +} + +// PostOrganizationTrashObjectsPurgeAllWithBodyWithResponse request with arbitrary body returning *PostOrganizationTrashObjectsPurgeAllResponse +func (c *ClientWithResponses) PostOrganizationTrashObjectsPurgeAllWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationTrashObjectsPurgeAllResponse, error) { + rsp, err := c.PostOrganizationTrashObjectsPurgeAllWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationTrashObjectsPurgeAllResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationTrashObjectsPurgeAllWithResponse(ctx context.Context, body PostOrganizationTrashObjectsPurgeAllJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationTrashObjectsPurgeAllResponse, error) { + rsp, err := c.PostOrganizationTrashObjectsPurgeAll(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationTrashObjectsPurgeAllResponse(rsp) +} + +// GetOrganizationUsersWithAccessWithResponse request returning *GetOrganizationUsersWithAccessResponse +func (c *ClientWithResponses) GetOrganizationUsersWithAccessWithResponse(ctx context.Context, params *GetOrganizationUsersWithAccessParams, reqEditors ...RequestEditorFn) (*GetOrganizationUsersWithAccessResponse, error) { + rsp, err := c.GetOrganizationUsersWithAccess(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationUsersWithAccessResponse(rsp) +} + +// GetOrganizationVirtualMachineGroupsWithResponse request returning *GetOrganizationVirtualMachineGroupsResponse +func (c *ClientWithResponses) GetOrganizationVirtualMachineGroupsWithResponse(ctx context.Context, params *GetOrganizationVirtualMachineGroupsParams, reqEditors ...RequestEditorFn) (*GetOrganizationVirtualMachineGroupsResponse, error) { + rsp, err := c.GetOrganizationVirtualMachineGroups(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationVirtualMachineGroupsResponse(rsp) +} + +// PostOrganizationVirtualMachineGroupsWithBodyWithResponse request with arbitrary body returning *PostOrganizationVirtualMachineGroupsResponse +func (c *ClientWithResponses) PostOrganizationVirtualMachineGroupsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachineGroupsResponse, error) { + rsp, err := c.PostOrganizationVirtualMachineGroupsWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationVirtualMachineGroupsResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationVirtualMachineGroupsWithResponse(ctx context.Context, body PostOrganizationVirtualMachineGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachineGroupsResponse, error) { + rsp, err := c.PostOrganizationVirtualMachineGroups(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationVirtualMachineGroupsResponse(rsp) +} + +// GetOrganizationVirtualMachinesWithResponse request returning *GetOrganizationVirtualMachinesResponse +func (c *ClientWithResponses) GetOrganizationVirtualMachinesWithResponse(ctx context.Context, params *GetOrganizationVirtualMachinesParams, reqEditors ...RequestEditorFn) (*GetOrganizationVirtualMachinesResponse, error) { + rsp, err := c.GetOrganizationVirtualMachines(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetOrganizationVirtualMachinesResponse(rsp) +} + +// PostOrganizationVirtualMachinesBuildWithBodyWithResponse request with arbitrary body returning *PostOrganizationVirtualMachinesBuildResponse +func (c *ClientWithResponses) PostOrganizationVirtualMachinesBuildWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachinesBuildResponse, error) { + rsp, err := c.PostOrganizationVirtualMachinesBuildWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationVirtualMachinesBuildResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationVirtualMachinesBuildWithResponse(ctx context.Context, body PostOrganizationVirtualMachinesBuildJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachinesBuildResponse, error) { + rsp, err := c.PostOrganizationVirtualMachinesBuild(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationVirtualMachinesBuildResponse(rsp) +} + +// PostOrganizationVirtualMachinesBuildFromSpecWithBodyWithResponse request with arbitrary body returning *PostOrganizationVirtualMachinesBuildFromSpecResponse +func (c *ClientWithResponses) PostOrganizationVirtualMachinesBuildFromSpecWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachinesBuildFromSpecResponse, error) { + rsp, err := c.PostOrganizationVirtualMachinesBuildFromSpecWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationVirtualMachinesBuildFromSpecResponse(rsp) +} + +func (c *ClientWithResponses) PostOrganizationVirtualMachinesBuildFromSpecWithResponse(ctx context.Context, body PostOrganizationVirtualMachinesBuildFromSpecJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOrganizationVirtualMachinesBuildFromSpecResponse, error) { + rsp, err := c.PostOrganizationVirtualMachinesBuildFromSpec(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostOrganizationVirtualMachinesBuildFromSpecResponse(rsp) +} + +// DeleteSecurityGroupWithBodyWithResponse request with arbitrary body returning *DeleteSecurityGroupResponse +func (c *ClientWithResponses) DeleteSecurityGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteSecurityGroupResponse, error) { + rsp, err := c.DeleteSecurityGroupWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSecurityGroupResponse(rsp) +} + +func (c *ClientWithResponses) DeleteSecurityGroupWithResponse(ctx context.Context, body DeleteSecurityGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteSecurityGroupResponse, error) { + rsp, err := c.DeleteSecurityGroup(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSecurityGroupResponse(rsp) +} + +// GetSecurityGroupWithResponse request returning *GetSecurityGroupResponse +func (c *ClientWithResponses) GetSecurityGroupWithResponse(ctx context.Context, params *GetSecurityGroupParams, reqEditors ...RequestEditorFn) (*GetSecurityGroupResponse, error) { + rsp, err := c.GetSecurityGroup(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSecurityGroupResponse(rsp) +} + +// PatchSecurityGroupWithBodyWithResponse request with arbitrary body returning *PatchSecurityGroupResponse +func (c *ClientWithResponses) PatchSecurityGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchSecurityGroupResponse, error) { + rsp, err := c.PatchSecurityGroupWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchSecurityGroupResponse(rsp) +} + +func (c *ClientWithResponses) PatchSecurityGroupWithResponse(ctx context.Context, body PatchSecurityGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchSecurityGroupResponse, error) { + rsp, err := c.PatchSecurityGroup(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchSecurityGroupResponse(rsp) +} + +// GetSecurityGroupRulesWithResponse request returning *GetSecurityGroupRulesResponse +func (c *ClientWithResponses) GetSecurityGroupRulesWithResponse(ctx context.Context, params *GetSecurityGroupRulesParams, reqEditors ...RequestEditorFn) (*GetSecurityGroupRulesResponse, error) { + rsp, err := c.GetSecurityGroupRules(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSecurityGroupRulesResponse(rsp) +} + +// PostSecurityGroupRulesWithBodyWithResponse request with arbitrary body returning *PostSecurityGroupRulesResponse +func (c *ClientWithResponses) PostSecurityGroupRulesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostSecurityGroupRulesResponse, error) { + rsp, err := c.PostSecurityGroupRulesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostSecurityGroupRulesResponse(rsp) +} + +func (c *ClientWithResponses) PostSecurityGroupRulesWithResponse(ctx context.Context, body PostSecurityGroupRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostSecurityGroupRulesResponse, error) { + rsp, err := c.PostSecurityGroupRules(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostSecurityGroupRulesResponse(rsp) +} + +// DeleteSecurityGroupsRulesSecurityGroupRuleWithBodyWithResponse request with arbitrary body returning *DeleteSecurityGroupsRulesSecurityGroupRuleResponse +func (c *ClientWithResponses) DeleteSecurityGroupsRulesSecurityGroupRuleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteSecurityGroupsRulesSecurityGroupRuleResponse, error) { + rsp, err := c.DeleteSecurityGroupsRulesSecurityGroupRuleWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSecurityGroupsRulesSecurityGroupRuleResponse(rsp) +} + +func (c *ClientWithResponses) DeleteSecurityGroupsRulesSecurityGroupRuleWithResponse(ctx context.Context, body DeleteSecurityGroupsRulesSecurityGroupRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteSecurityGroupsRulesSecurityGroupRuleResponse, error) { + rsp, err := c.DeleteSecurityGroupsRulesSecurityGroupRule(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSecurityGroupsRulesSecurityGroupRuleResponse(rsp) +} + +// GetSecurityGroupsRulesSecurityGroupRuleWithResponse request returning *GetSecurityGroupsRulesSecurityGroupRuleResponse +func (c *ClientWithResponses) GetSecurityGroupsRulesSecurityGroupRuleWithResponse(ctx context.Context, params *GetSecurityGroupsRulesSecurityGroupRuleParams, reqEditors ...RequestEditorFn) (*GetSecurityGroupsRulesSecurityGroupRuleResponse, error) { + rsp, err := c.GetSecurityGroupsRulesSecurityGroupRule(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetSecurityGroupsRulesSecurityGroupRuleResponse(rsp) +} + +// PatchSecurityGroupsRulesSecurityGroupRuleWithBodyWithResponse request with arbitrary body returning *PatchSecurityGroupsRulesSecurityGroupRuleResponse +func (c *ClientWithResponses) PatchSecurityGroupsRulesSecurityGroupRuleWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchSecurityGroupsRulesSecurityGroupRuleResponse, error) { + rsp, err := c.PatchSecurityGroupsRulesSecurityGroupRuleWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchSecurityGroupsRulesSecurityGroupRuleResponse(rsp) +} + +func (c *ClientWithResponses) PatchSecurityGroupsRulesSecurityGroupRuleWithResponse(ctx context.Context, body PatchSecurityGroupsRulesSecurityGroupRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchSecurityGroupsRulesSecurityGroupRuleResponse, error) { + rsp, err := c.PatchSecurityGroupsRulesSecurityGroupRule(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchSecurityGroupsRulesSecurityGroupRuleResponse(rsp) +} + +// DeleteSshKeyWithBodyWithResponse request with arbitrary body returning *DeleteSshKeyResponse +func (c *ClientWithResponses) DeleteSshKeyWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteSshKeyResponse, error) { + rsp, err := c.DeleteSshKeyWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSshKeyResponse(rsp) +} + +func (c *ClientWithResponses) DeleteSshKeyWithResponse(ctx context.Context, body DeleteSshKeyJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteSshKeyResponse, error) { + rsp, err := c.DeleteSshKey(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteSshKeyResponse(rsp) +} + +// DeleteTagWithBodyWithResponse request with arbitrary body returning *DeleteTagResponse +func (c *ClientWithResponses) DeleteTagWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteTagResponse, error) { + rsp, err := c.DeleteTagWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteTagResponse(rsp) +} + +func (c *ClientWithResponses) DeleteTagWithResponse(ctx context.Context, body DeleteTagJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteTagResponse, error) { + rsp, err := c.DeleteTag(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteTagResponse(rsp) +} + +// GetTagWithResponse request returning *GetTagResponse +func (c *ClientWithResponses) GetTagWithResponse(ctx context.Context, params *GetTagParams, reqEditors ...RequestEditorFn) (*GetTagResponse, error) { + rsp, err := c.GetTag(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetTagResponse(rsp) +} + +// PatchTagWithBodyWithResponse request with arbitrary body returning *PatchTagResponse +func (c *ClientWithResponses) PatchTagWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchTagResponse, error) { + rsp, err := c.PatchTagWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchTagResponse(rsp) +} + +func (c *ClientWithResponses) PatchTagWithResponse(ctx context.Context, body PatchTagJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchTagResponse, error) { + rsp, err := c.PatchTag(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchTagResponse(rsp) +} + +// GetTaskWithResponse request returning *GetTaskResponse +func (c *ClientWithResponses) GetTaskWithResponse(ctx context.Context, params *GetTaskParams, reqEditors ...RequestEditorFn) (*GetTaskResponse, error) { + rsp, err := c.GetTask(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetTaskResponse(rsp) +} + +// DeleteTrashObjectWithBodyWithResponse request with arbitrary body returning *DeleteTrashObjectResponse +func (c *ClientWithResponses) DeleteTrashObjectWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteTrashObjectResponse, error) { + rsp, err := c.DeleteTrashObjectWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteTrashObjectResponse(rsp) +} + +func (c *ClientWithResponses) DeleteTrashObjectWithResponse(ctx context.Context, body DeleteTrashObjectJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteTrashObjectResponse, error) { + rsp, err := c.DeleteTrashObject(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteTrashObjectResponse(rsp) +} + +// GetTrashObjectWithResponse request returning *GetTrashObjectResponse +func (c *ClientWithResponses) GetTrashObjectWithResponse(ctx context.Context, params *GetTrashObjectParams, reqEditors ...RequestEditorFn) (*GetTrashObjectResponse, error) { + rsp, err := c.GetTrashObject(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetTrashObjectResponse(rsp) +} + +// PostTrashObjectRestoreWithBodyWithResponse request with arbitrary body returning *PostTrashObjectRestoreResponse +func (c *ClientWithResponses) PostTrashObjectRestoreWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostTrashObjectRestoreResponse, error) { + rsp, err := c.PostTrashObjectRestoreWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostTrashObjectRestoreResponse(rsp) +} + +func (c *ClientWithResponses) PostTrashObjectRestoreWithResponse(ctx context.Context, body PostTrashObjectRestoreJSONRequestBody, reqEditors ...RequestEditorFn) (*PostTrashObjectRestoreResponse, error) { + rsp, err := c.PostTrashObjectRestore(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostTrashObjectRestoreResponse(rsp) +} + +// GetUsersCurrentWithResponse request returning *GetUsersCurrentResponse +func (c *ClientWithResponses) GetUsersCurrentWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetUsersCurrentResponse, error) { + rsp, err := c.GetUsersCurrent(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetUsersCurrentResponse(rsp) +} + +// DeleteVirtualMachineGroupWithBodyWithResponse request with arbitrary body returning *DeleteVirtualMachineGroupResponse +func (c *ClientWithResponses) DeleteVirtualMachineGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteVirtualMachineGroupResponse, error) { + rsp, err := c.DeleteVirtualMachineGroupWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteVirtualMachineGroupResponse(rsp) +} + +func (c *ClientWithResponses) DeleteVirtualMachineGroupWithResponse(ctx context.Context, body DeleteVirtualMachineGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteVirtualMachineGroupResponse, error) { + rsp, err := c.DeleteVirtualMachineGroup(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteVirtualMachineGroupResponse(rsp) +} + +// GetVirtualMachineGroupWithResponse request returning *GetVirtualMachineGroupResponse +func (c *ClientWithResponses) GetVirtualMachineGroupWithResponse(ctx context.Context, params *GetVirtualMachineGroupParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineGroupResponse, error) { + rsp, err := c.GetVirtualMachineGroup(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachineGroupResponse(rsp) +} + +// PatchVirtualMachineGroupWithBodyWithResponse request with arbitrary body returning *PatchVirtualMachineGroupResponse +func (c *ClientWithResponses) PatchVirtualMachineGroupWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchVirtualMachineGroupResponse, error) { + rsp, err := c.PatchVirtualMachineGroupWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchVirtualMachineGroupResponse(rsp) +} + +func (c *ClientWithResponses) PatchVirtualMachineGroupWithResponse(ctx context.Context, body PatchVirtualMachineGroupJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchVirtualMachineGroupResponse, error) { + rsp, err := c.PatchVirtualMachineGroup(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchVirtualMachineGroupResponse(rsp) +} + +// GetVMNIVMNIWithResponse request returning *GetVMNIVMNIResponse +func (c *ClientWithResponses) GetVMNIVMNIWithResponse(ctx context.Context, params *GetVMNIVMNIParams, reqEditors ...RequestEditorFn) (*GetVMNIVMNIResponse, error) { + rsp, err := c.GetVMNIVMNI(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVMNIVMNIResponse(rsp) +} + +// PostVirtualMachineNetworkInterfaceAllocateIpWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineNetworkInterfaceAllocateIpResponse +func (c *ClientWithResponses) PostVirtualMachineNetworkInterfaceAllocateIpWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineNetworkInterfaceAllocateIpResponse, error) { + rsp, err := c.PostVirtualMachineNetworkInterfaceAllocateIpWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineNetworkInterfaceAllocateIpResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineNetworkInterfaceAllocateIpWithResponse(ctx context.Context, body PostVirtualMachineNetworkInterfaceAllocateIpJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineNetworkInterfaceAllocateIpResponse, error) { + rsp, err := c.PostVirtualMachineNetworkInterfaceAllocateIp(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineNetworkInterfaceAllocateIpResponse(rsp) +} + +// PostVirtualMachineNetworkInterfaceAllocateNewIpWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineNetworkInterfaceAllocateNewIpResponse +func (c *ClientWithResponses) PostVirtualMachineNetworkInterfaceAllocateNewIpWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineNetworkInterfaceAllocateNewIpResponse, error) { + rsp, err := c.PostVirtualMachineNetworkInterfaceAllocateNewIpWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineNetworkInterfaceAllocateNewIpResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineNetworkInterfaceAllocateNewIpWithResponse(ctx context.Context, body PostVirtualMachineNetworkInterfaceAllocateNewIpJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineNetworkInterfaceAllocateNewIpResponse, error) { + rsp, err := c.PostVirtualMachineNetworkInterfaceAllocateNewIp(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineNetworkInterfaceAllocateNewIpResponse(rsp) +} + +// GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionWithResponse request returning *GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse +func (c *ClientWithResponses) GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionWithResponse(ctx context.Context, params *GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse, error) { + rsp, err := c.GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersion(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse(rsp) +} + +// PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithBodyWithResponse request with arbitrary body returning *PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse +func (c *ClientWithResponses) PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse, error) { + rsp, err := c.PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse(rsp) +} + +func (c *ClientWithResponses) PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithResponse(ctx context.Context, body PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse, error) { + rsp, err := c.PatchVirtualMachineNetworkInterfaceUpdateSpeedProfile(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse(rsp) +} + +// GetVirtualMachinePackagesWithResponse request returning *GetVirtualMachinePackagesResponse +func (c *ClientWithResponses) GetVirtualMachinePackagesWithResponse(ctx context.Context, params *GetVirtualMachinePackagesParams, reqEditors ...RequestEditorFn) (*GetVirtualMachinePackagesResponse, error) { + rsp, err := c.GetVirtualMachinePackages(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachinePackagesResponse(rsp) +} + +// GetVirtualMachinePackageWithResponse request returning *GetVirtualMachinePackageResponse +func (c *ClientWithResponses) GetVirtualMachinePackageWithResponse(ctx context.Context, params *GetVirtualMachinePackageParams, reqEditors ...RequestEditorFn) (*GetVirtualMachinePackageResponse, error) { + rsp, err := c.GetVirtualMachinePackage(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachinePackageResponse(rsp) +} + +// DeleteVirtualMachineWithBodyWithResponse request with arbitrary body returning *DeleteVirtualMachineResponse +func (c *ClientWithResponses) DeleteVirtualMachineWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*DeleteVirtualMachineResponse, error) { + rsp, err := c.DeleteVirtualMachineWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteVirtualMachineResponse(rsp) +} + +func (c *ClientWithResponses) DeleteVirtualMachineWithResponse(ctx context.Context, body DeleteVirtualMachineJSONRequestBody, reqEditors ...RequestEditorFn) (*DeleteVirtualMachineResponse, error) { + rsp, err := c.DeleteVirtualMachine(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParseDeleteVirtualMachineResponse(rsp) +} + +// GetVirtualMachineWithResponse request returning *GetVirtualMachineResponse +func (c *ClientWithResponses) GetVirtualMachineWithResponse(ctx context.Context, params *GetVirtualMachineParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineResponse, error) { + rsp, err := c.GetVirtualMachine(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachineResponse(rsp) +} + +// PatchVirtualMachineWithBodyWithResponse request with arbitrary body returning *PatchVirtualMachineResponse +func (c *ClientWithResponses) PatchVirtualMachineWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PatchVirtualMachineResponse, error) { + rsp, err := c.PatchVirtualMachineWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchVirtualMachineResponse(rsp) +} + +func (c *ClientWithResponses) PatchVirtualMachineWithResponse(ctx context.Context, body PatchVirtualMachineJSONRequestBody, reqEditors ...RequestEditorFn) (*PatchVirtualMachineResponse, error) { + rsp, err := c.PatchVirtualMachine(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePatchVirtualMachineResponse(rsp) +} + +// PostVirtualMachineAllocateIpWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineAllocateIpResponse +func (c *ClientWithResponses) PostVirtualMachineAllocateIpWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineAllocateIpResponse, error) { + rsp, err := c.PostVirtualMachineAllocateIpWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineAllocateIpResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineAllocateIpWithResponse(ctx context.Context, body PostVirtualMachineAllocateIpJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineAllocateIpResponse, error) { + rsp, err := c.PostVirtualMachineAllocateIp(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineAllocateIpResponse(rsp) +} + +// PostVirtualMachineConsoleSessionsWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineConsoleSessionsResponse +func (c *ClientWithResponses) PostVirtualMachineConsoleSessionsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineConsoleSessionsResponse, error) { + rsp, err := c.PostVirtualMachineConsoleSessionsWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineConsoleSessionsResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineConsoleSessionsWithResponse(ctx context.Context, body PostVirtualMachineConsoleSessionsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineConsoleSessionsResponse, error) { + rsp, err := c.PostVirtualMachineConsoleSessions(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineConsoleSessionsResponse(rsp) +} + +// GetVirtualMachineDiskBackupPoliciesWithResponse request returning *GetVirtualMachineDiskBackupPoliciesResponse +func (c *ClientWithResponses) GetVirtualMachineDiskBackupPoliciesWithResponse(ctx context.Context, params *GetVirtualMachineDiskBackupPoliciesParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineDiskBackupPoliciesResponse, error) { + rsp, err := c.GetVirtualMachineDiskBackupPolicies(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachineDiskBackupPoliciesResponse(rsp) +} + +// PostVirtualMachineDiskBackupPoliciesWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineDiskBackupPoliciesResponse +func (c *ClientWithResponses) PostVirtualMachineDiskBackupPoliciesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineDiskBackupPoliciesResponse, error) { + rsp, err := c.PostVirtualMachineDiskBackupPoliciesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineDiskBackupPoliciesResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineDiskBackupPoliciesWithResponse(ctx context.Context, body PostVirtualMachineDiskBackupPoliciesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineDiskBackupPoliciesResponse, error) { + rsp, err := c.PostVirtualMachineDiskBackupPolicies(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineDiskBackupPoliciesResponse(rsp) +} + +// GetVirtualMachineDisksWithResponse request returning *GetVirtualMachineDisksResponse +func (c *ClientWithResponses) GetVirtualMachineDisksWithResponse(ctx context.Context, params *GetVirtualMachineDisksParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineDisksResponse, error) { + rsp, err := c.GetVirtualMachineDisks(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachineDisksResponse(rsp) +} + +// PutVirtualMachineFlexibleResourcesWithBodyWithResponse request with arbitrary body returning *PutVirtualMachineFlexibleResourcesResponse +func (c *ClientWithResponses) PutVirtualMachineFlexibleResourcesWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutVirtualMachineFlexibleResourcesResponse, error) { + rsp, err := c.PutVirtualMachineFlexibleResourcesWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePutVirtualMachineFlexibleResourcesResponse(rsp) +} + +func (c *ClientWithResponses) PutVirtualMachineFlexibleResourcesWithResponse(ctx context.Context, body PutVirtualMachineFlexibleResourcesJSONRequestBody, reqEditors ...RequestEditorFn) (*PutVirtualMachineFlexibleResourcesResponse, error) { + rsp, err := c.PutVirtualMachineFlexibleResources(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePutVirtualMachineFlexibleResourcesResponse(rsp) +} + +// GetVirtualMachineNetworkInterfacesWithResponse request returning *GetVirtualMachineNetworkInterfacesResponse +func (c *ClientWithResponses) GetVirtualMachineNetworkInterfacesWithResponse(ctx context.Context, params *GetVirtualMachineNetworkInterfacesParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineNetworkInterfacesResponse, error) { + rsp, err := c.GetVirtualMachineNetworkInterfaces(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachineNetworkInterfacesResponse(rsp) +} + +// GetVirtualMachineNetworkInterfaceWithResponse request returning *GetVirtualMachineNetworkInterfaceResponse +func (c *ClientWithResponses) GetVirtualMachineNetworkInterfaceWithResponse(ctx context.Context, params *GetVirtualMachineNetworkInterfaceParams, reqEditors ...RequestEditorFn) (*GetVirtualMachineNetworkInterfaceResponse, error) { + rsp, err := c.GetVirtualMachineNetworkInterface(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachineNetworkInterfaceResponse(rsp) +} + +// PutVirtualMachinePackageWithBodyWithResponse request with arbitrary body returning *PutVirtualMachinePackageResponse +func (c *ClientWithResponses) PutVirtualMachinePackageWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutVirtualMachinePackageResponse, error) { + rsp, err := c.PutVirtualMachinePackageWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePutVirtualMachinePackageResponse(rsp) +} + +func (c *ClientWithResponses) PutVirtualMachinePackageWithResponse(ctx context.Context, body PutVirtualMachinePackageJSONRequestBody, reqEditors ...RequestEditorFn) (*PutVirtualMachinePackageResponse, error) { + rsp, err := c.PutVirtualMachinePackage(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePutVirtualMachinePackageResponse(rsp) +} + +// PostVirtualMachineResetWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineResetResponse +func (c *ClientWithResponses) PostVirtualMachineResetWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineResetResponse, error) { + rsp, err := c.PostVirtualMachineResetWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineResetResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineResetWithResponse(ctx context.Context, body PostVirtualMachineResetJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineResetResponse, error) { + rsp, err := c.PostVirtualMachineReset(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineResetResponse(rsp) +} + +// PostVirtualMachineShutdownWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineShutdownResponse +func (c *ClientWithResponses) PostVirtualMachineShutdownWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineShutdownResponse, error) { + rsp, err := c.PostVirtualMachineShutdownWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineShutdownResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineShutdownWithResponse(ctx context.Context, body PostVirtualMachineShutdownJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineShutdownResponse, error) { + rsp, err := c.PostVirtualMachineShutdown(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineShutdownResponse(rsp) +} + +// PostVirtualMachineStartWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineStartResponse +func (c *ClientWithResponses) PostVirtualMachineStartWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineStartResponse, error) { + rsp, err := c.PostVirtualMachineStartWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineStartResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineStartWithResponse(ctx context.Context, body PostVirtualMachineStartJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineStartResponse, error) { + rsp, err := c.PostVirtualMachineStart(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineStartResponse(rsp) +} + +// PostVirtualMachineStopWithBodyWithResponse request with arbitrary body returning *PostVirtualMachineStopResponse +func (c *ClientWithResponses) PostVirtualMachineStopWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostVirtualMachineStopResponse, error) { + rsp, err := c.PostVirtualMachineStopWithBody(ctx, contentType, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineStopResponse(rsp) +} + +func (c *ClientWithResponses) PostVirtualMachineStopWithResponse(ctx context.Context, body PostVirtualMachineStopJSONRequestBody, reqEditors ...RequestEditorFn) (*PostVirtualMachineStopResponse, error) { + rsp, err := c.PostVirtualMachineStop(ctx, body, reqEditors...) + if err != nil { + return nil, err + } + return ParsePostVirtualMachineStopResponse(rsp) +} + +// GetVirtualMachinesBuildsVirtualMachineBuildWithResponse request returning *GetVirtualMachinesBuildsVirtualMachineBuildResponse +func (c *ClientWithResponses) GetVirtualMachinesBuildsVirtualMachineBuildWithResponse(ctx context.Context, params *GetVirtualMachinesBuildsVirtualMachineBuildParams, reqEditors ...RequestEditorFn) (*GetVirtualMachinesBuildsVirtualMachineBuildResponse, error) { + rsp, err := c.GetVirtualMachinesBuildsVirtualMachineBuild(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetVirtualMachinesBuildsVirtualMachineBuildResponse(rsp) +} + +// GetZonesWithResponse request returning *GetZonesResponse +func (c *ClientWithResponses) GetZonesWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetZonesResponse, error) { + rsp, err := c.GetZones(ctx, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetZonesResponse(rsp) +} + +// GetZoneWithResponse request returning *GetZoneResponse +func (c *ClientWithResponses) GetZoneWithResponse(ctx context.Context, params *GetZoneParams, reqEditors ...RequestEditorFn) (*GetZoneResponse, error) { + rsp, err := c.GetZone(ctx, params, reqEditors...) + if err != nil { + return nil, err + } + return ParseGetZoneResponse(rsp) +} + +// ParseGetCertificateResponse parses an HTTP response from a GetCertificateWithResponse call +func ParseGetCertificateResponse(rsp *http.Response) (*GetCertificateResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetCertificateResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Certificate []Certificate `json:"certificate"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest CertificateNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetCountriesResponse parses an HTTP response from a GetCountriesWithResponse call +func ParseGetCountriesResponse(rsp *http.Response) (*GetCountriesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetCountriesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Countries The list of countries + Countries []GetCountries200ResponseCountries `json:"countries"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetCountryResponse parses an HTTP response from a GetCountryWithResponse call +func ParseGetCountryResponse(rsp *http.Response) (*GetCountryResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetCountryResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Country The country details + Country Country `json:"country"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest CountryNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetCountryCountryStatesResponse parses an HTTP response from a GetCountryCountryStatesWithResponse call +func ParseGetCountryCountryStatesResponse(rsp *http.Response) (*GetCountryCountryStatesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetCountryCountryStatesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // CountryStates The list of country states for the given country + CountryStates []GetCountryCountryStates200ResponseCountryStates `json:"country_states"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest CountryNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetCountryStateResponse parses an HTTP response from a GetCountryStateWithResponse call +func ParseGetCountryStateResponse(rsp *http.Response) (*GetCountryStateResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetCountryStateResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // CountryState The country state details + CountryState CountryState `json:"country_state"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest CountryStateNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetCurrenciesResponse parses an HTTP response from a GetCurrenciesWithResponse call +func ParseGetCurrenciesResponse(rsp *http.Response) (*GetCurrenciesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetCurrenciesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Currencies The list of currencies + Currencies []GetCurrencies200ResponseCurrencies `json:"currencies"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetCurrencyResponse parses an HTTP response from a GetCurrencyWithResponse call +func ParseGetCurrencyResponse(rsp *http.Response) (*GetCurrencyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetCurrencyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Currency The currency details + Currency Currency `json:"currency"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest CurrencyNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDataCentersResponse parses an HTTP response from a GetDataCentersWithResponse call +func ParseGetDataCentersResponse(rsp *http.Response) (*GetDataCentersResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDataCentersResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + DataCenters []GetDataCenters200ResponseDataCenters `json:"data_centers"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDataCenterResponse parses an HTTP response from a GetDataCenterWithResponse call +func ParseGetDataCenterResponse(rsp *http.Response) (*GetDataCenterResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDataCenterResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + DataCenter GetDataCenter200ResponseDataCenter `json:"data_center"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DataCenterNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDataCenterDefaultNetworkResponse parses an HTTP response from a GetDataCenterDefaultNetworkWithResponse call +func ParseGetDataCenterDefaultNetworkResponse(rsp *http.Response) (*GetDataCenterDefaultNetworkResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDataCenterDefaultNetworkResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Network The details for the requested network + Network GetDataCenterDefaultNetwork200ResponseNetwork `json:"network"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DataCenterNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDataCenterGpuTypesResponse parses an HTTP response from a GetDataCenterGpuTypesWithResponse call +func ParseGetDataCenterGpuTypesResponse(rsp *http.Response) (*GetDataCenterGpuTypesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDataCenterGpuTypesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + GpuTypes []GetDataCenterGPUTypes200ResponseGPUTypes `json:"gpu_types"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DataCenterNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteDiskBackupPolicyResponse parses an HTTP response from a DeleteDiskBackupPolicyWithResponse call +func ParseDeleteDiskBackupPolicyResponse(rsp *http.Response) (*DeleteDiskBackupPolicyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteDiskBackupPolicyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicy The disk backup policy that has been destroyed + DiskBackupPolicy DeleteDiskBackupPolicy200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskBackupPolicyNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDiskBackupPolicyResponse parses an HTTP response from a GetDiskBackupPolicyWithResponse call +func ParseGetDiskBackupPolicyResponse(rsp *http.Response) (*GetDiskBackupPolicyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDiskBackupPolicyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicy The located disk backup policy + DiskBackupPolicy GetDiskBackupPolicy200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskBackupPolicyNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchDiskBackupPolicyResponse parses an HTTP response from a PatchDiskBackupPolicyWithResponse call +func ParsePatchDiskBackupPolicyResponse(rsp *http.Response) (*PatchDiskBackupPolicyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchDiskBackupPolicyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicy The disk backup policy that has been updated + DiskBackupPolicy PatchDiskBackupPolicy200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskBackupPolicyNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteDiskBackupPolicyScheduleResponse parses an HTTP response from a DeleteDiskBackupPolicyScheduleWithResponse call +func ParseDeleteDiskBackupPolicyScheduleResponse(rsp *http.Response) (*DeleteDiskBackupPolicyScheduleResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteDiskBackupPolicyScheduleResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicy The disk backup policy that has been scheduled for deletion + DiskBackupPolicy DeleteDiskBackupPolicySchedule200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest InvalidTimestamp400Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskBackupPolicyNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDiskTemplateVersionResponse parses an HTTP response from a GetDiskTemplateVersionWithResponse call +func ParseGetDiskTemplateVersionResponse(rsp *http.Response) (*GetDiskTemplateVersionResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDiskTemplateVersionResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskTemplateVersion The disk template version details + DiskTemplateVersion GetDiskTemplateVersion200ResponseDiskTemplateVersion `json:"disk_template_version"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskTemplateVersionNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDiskTemplateVersionSpecResponse parses an HTTP response from a GetDiskTemplateVersionSpecWithResponse call +func ParseGetDiskTemplateVersionSpecResponse(rsp *http.Response) (*GetDiskTemplateVersionSpecResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDiskTemplateVersionSpecResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskTemplateVersion The disk template version details + DiskTemplateVersion GetDiskTemplateVersionSpec200ResponseDiskTemplateVersion `json:"disk_template_version"` + Spec TemplateSpec `json:"spec"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskTemplateVersionNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDiskTemplateResponse parses an HTTP response from a GetDiskTemplateWithResponse call +func ParseGetDiskTemplateResponse(rsp *http.Response) (*GetDiskTemplateResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDiskTemplateResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskTemplate The disk template details + DiskTemplate GetDiskTemplate200ResponseDiskTemplate `json:"disk_template"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskTemplateNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDiskTemplateVersionsResponse parses an HTTP response from a GetDiskTemplateVersionsWithResponse call +func ParseGetDiskTemplateVersionsResponse(rsp *http.Response) (*GetDiskTemplateVersionsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDiskTemplateVersionsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + DiskTemplate GetDiskTemplateVersions200ResponseDiskTemplate `json:"disk_template"` + + // DiskTemplateVersions The disk template versions for the provided template + DiskTemplateVersions []GetDiskTemplateVersions200ResponseDiskTemplateVersions `json:"disk_template_versions"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskTemplateNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDiskResponse parses an HTTP response from a GetDiskWithResponse call +func ParseGetDiskResponse(rsp *http.Response) (*GetDiskResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDiskResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Disk The disk details + Disk GetDisk200ResponseDisk `json:"disk"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDiskDiskBackupPoliciesResponse parses an HTTP response from a GetDiskDiskBackupPoliciesWithResponse call +func ParseGetDiskDiskBackupPoliciesResponse(rsp *http.Response) (*GetDiskDiskBackupPoliciesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDiskDiskBackupPoliciesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicies The disk backup policies for the provided disk + DiskBackupPolicies []GetDiskDiskBackupPolicies200ResponseDiskBackupPolicies `json:"disk_backup_policies"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostDiskDiskBackupPoliciesResponse parses an HTTP response from a PostDiskDiskBackupPoliciesWithResponse call +func ParsePostDiskDiskBackupPoliciesResponse(rsp *http.Response) (*PostDiskDiskBackupPoliciesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostDiskDiskBackupPoliciesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicy The new disk backup policy that has been created + DiskBackupPolicy PostDiskDiskBackupPolicies200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DiskNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteDnsRecordsDnsRecordResponse parses an HTTP response from a DeleteDnsRecordsDnsRecordWithResponse call +func ParseDeleteDnsRecordsDnsRecordResponse(rsp *http.Response) (*DeleteDnsRecordsDnsRecordResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteDnsRecordsDnsRecordResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Success bool `json:"success"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSRecordNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDnsRecordsDnsRecordResponse parses an HTTP response from a GetDnsRecordsDnsRecordWithResponse call +func ParseGetDnsRecordsDnsRecordResponse(rsp *http.Response) (*GetDnsRecordsDnsRecordResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDnsRecordsDnsRecordResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsRecord The DNS record details + DnsRecord GetDNSRecordsDNSRecord200ResponseDNSRecord `json:"dns_record"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSRecordNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchDnsRecordsDnsRecordResponse parses an HTTP response from a PatchDnsRecordsDnsRecordWithResponse call +func ParsePatchDnsRecordsDnsRecordResponse(rsp *http.Response) (*PatchDnsRecordsDnsRecordResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchDnsRecordsDnsRecordResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsRecord The updated DNS record + DnsRecord PatchDNSRecordsDNSRecord200ResponseDNSRecord `json:"dns_record"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSRecordNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteDnsZonesDnsZoneResponse parses an HTTP response from a DeleteDnsZonesDnsZoneWithResponse call +func ParseDeleteDnsZonesDnsZoneResponse(rsp *http.Response) (*DeleteDnsZonesDnsZoneResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteDnsZonesDnsZoneResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZone The DNS zone that has been destroyed + DnsZone DeleteDNSZonesDNSZone200ResponseDNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDnsZonesDnsZoneResponse parses an HTTP response from a GetDnsZonesDnsZoneWithResponse call +func ParseGetDnsZonesDnsZoneResponse(rsp *http.Response) (*GetDnsZonesDnsZoneResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDnsZonesDnsZoneResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZone The DNS zone object + DnsZone DNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDnsZonesDnsZoneRecordsResponse parses an HTTP response from a GetDnsZonesDnsZoneRecordsWithResponse call +func ParseGetDnsZonesDnsZoneRecordsResponse(rsp *http.Response) (*GetDnsZonesDnsZoneRecordsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDnsZonesDnsZoneRecordsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsRecords The DNS records that belong to this DNS zone + DnsRecords []GetDNSZonesDNSZoneRecords200ResponseDNSRecords `json:"dns_records"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostDnsZonesDnsZoneRecordsResponse parses an HTTP response from a PostDnsZonesDnsZoneRecordsWithResponse call +func ParsePostDnsZonesDnsZoneRecordsResponse(rsp *http.Response) (*PostDnsZonesDnsZoneRecordsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostDnsZonesDnsZoneRecordsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsRecord The new DNS record that has been created + DnsRecord PostDNSZonesDNSZoneRecords200ResponseDNSRecord `json:"dns_record"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostDnsZonesDnsZoneUpdateTtlResponse parses an HTTP response from a PostDnsZonesDnsZoneUpdateTtlWithResponse call +func ParsePostDnsZonesDnsZoneUpdateTtlResponse(rsp *http.Response) (*PostDnsZonesDnsZoneUpdateTtlResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostDnsZonesDnsZoneUpdateTtlResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZone The DNS zone with the new TTL value + DnsZone PostDNSZonesDNSZoneUpdateTTL200ResponseDNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest InfrastructureDNSZoneCannotBeEdited403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDnsZonesDnsZoneVerificationDetailsResponse parses an HTTP response from a GetDnsZonesDnsZoneVerificationDetailsWithResponse call +func ParseGetDnsZonesDnsZoneVerificationDetailsResponse(rsp *http.Response) (*GetDnsZonesDnsZoneVerificationDetailsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDnsZonesDnsZoneVerificationDetailsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Details DNSZoneVerificationDetails `json:"details"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest InfrastructureDNSZoneCannotBeEdited403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest DNSZoneAlreadyVerifiedResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostDnsZonesDnsZoneVerifyResponse parses an HTTP response from a PostDnsZonesDnsZoneVerifyWithResponse call +func ParsePostDnsZonesDnsZoneVerifyResponse(rsp *http.Response) (*PostDnsZonesDnsZoneVerifyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostDnsZonesDnsZoneVerifyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZone The DNS zone that has been verified + DnsZone DNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest DNSZoneNotVerifiedResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteDnsRecordResponse parses an HTTP response from a DeleteDnsRecordWithResponse call +func ParseDeleteDnsRecordResponse(rsp *http.Response) (*DeleteDnsRecordResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteDnsRecordResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Deleted bool `json:"deleted"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSRecordNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDnsRecordResponse parses an HTTP response from a GetDnsRecordWithResponse call +func ParseGetDnsRecordResponse(rsp *http.Response) (*GetDnsRecordResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDnsRecordResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsRecord The DNS record for the provided organization + DnsRecord DNSRecord `json:"dns_record"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSRecordNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchDnsRecordResponse parses an HTTP response from a PatchDnsRecordWithResponse call +func ParsePatchDnsRecordResponse(rsp *http.Response) (*PatchDnsRecordResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchDnsRecordResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsRecord The DNS record that has been updated + DnsRecord DNSRecord `json:"dns_record"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSRecordNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteDnsZoneResponse parses an HTTP response from a DeleteDnsZoneWithResponse call +func ParseDeleteDnsZoneResponse(rsp *http.Response) (*DeleteDnsZoneResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteDnsZoneResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Deleted bool `json:"deleted"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDnsZoneResponse parses an HTTP response from a GetDnsZoneWithResponse call +func ParseGetDnsZoneResponse(rsp *http.Response) (*GetDnsZoneResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDnsZoneResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZone The DNS zones for the provided organization + DnsZone DNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchDnsZoneResponse parses an HTTP response from a PatchDnsZoneWithResponse call +func ParsePatchDnsZoneResponse(rsp *http.Response) (*PatchDnsZoneResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchDnsZoneResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZone The DNS zones for the provided organization + DnsZone DNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetDnsZoneRecordsResponse parses an HTTP response from a GetDnsZoneRecordsWithResponse call +func ParseGetDnsZoneRecordsResponse(rsp *http.Response) (*GetDnsZoneRecordsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetDnsZoneRecordsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsRecords The DNS record for the provided zone + DnsRecords []DNSRecord `json:"dns_records"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostDnsZoneRecordsResponse parses an HTTP response from a PostDnsZoneRecordsWithResponse call +func ParsePostDnsZoneRecordsResponse(rsp *http.Response) (*PostDnsZoneRecordsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostDnsZoneRecordsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + DnsRecord DNSRecord `json:"dns_record"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostDnsZoneVerifyResponse parses an HTTP response from a PostDnsZoneVerifyWithResponse call +func ParsePostDnsZoneVerifyResponse(rsp *http.Response) (*PostDnsZoneVerifyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostDnsZoneVerifyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZone The DNS zones for the provided organization + DnsZone DNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DNSZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest DNSZoneNotVerifiedResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteFileStorageVolumeResponse parses an HTTP response from a DeleteFileStorageVolumeWithResponse call +func ParseDeleteFileStorageVolumeResponse(rsp *http.Response) (*DeleteFileStorageVolumeResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteFileStorageVolumeResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // FileStorageVolume The file storage volume that has been destroyed. + FileStorageVolume DeleteFileStorageVolume200ResponseFileStorageVolume `json:"file_storage_volume"` + TrashObject TrashObject `json:"trash_object"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest FileStorageVolumeNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetFileStorageVolumeResponse parses an HTTP response from a GetFileStorageVolumeWithResponse call +func ParseGetFileStorageVolumeResponse(rsp *http.Response) (*GetFileStorageVolumeResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetFileStorageVolumeResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // FileStorageVolume The file storage volume. + FileStorageVolume GetFileStorageVolume200ResponseFileStorageVolume `json:"file_storage_volume"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest FileStorageVolumeNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchFileStorageVolumeResponse parses an HTTP response from a PatchFileStorageVolumeWithResponse call +func ParsePatchFileStorageVolumeResponse(rsp *http.Response) (*PatchFileStorageVolumeResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchFileStorageVolumeResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // FileStorageVolume The file storage volume. + FileStorageVolume PatchFileStorageVolume200ResponseFileStorageVolume `json:"file_storage_volume"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest FileStorageVolumeNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetGpuTypesResponse parses an HTTP response from a GetGpuTypesWithResponse call +func ParseGetGpuTypesResponse(rsp *http.Response) (*GetGpuTypesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetGpuTypesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + GpuTypes []GetGPUTypes200ResponseGPUTypes `json:"gpu_types"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetGpuTypeResponse parses an HTTP response from a GetGpuTypeWithResponse call +func ParseGetGpuTypeResponse(rsp *http.Response) (*GetGpuTypeResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetGpuTypeResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + GpuType GetGPUType200ResponseGPUType `json:"gpu_type"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest GPUTypeNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostInvalidateLinkedWebSessionResponse parses an HTTP response from a PostInvalidateLinkedWebSessionWithResponse call +func ParsePostInvalidateLinkedWebSessionResponse(rsp *http.Response) (*PostInvalidateLinkedWebSessionResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostInvalidateLinkedWebSessionResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Status bool `json:"status"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest IdentityNotLinkedToWebSession400Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteIpAddressResponse parses an HTTP response from a DeleteIpAddressWithResponse call +func ParseDeleteIpAddressResponse(rsp *http.Response) (*DeleteIpAddressResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteIpAddressResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest interface{} + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest IPAddressNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 409: + var dest ResourceDoesNotSupportUnallocationResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON409 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetIpAddressResponse parses an HTTP response from a GetIpAddressWithResponse call +func ParseGetIpAddressResponse(rsp *http.Response) (*GetIpAddressResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetIpAddressResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Allocation The resource this address is allocated to + Allocation *GetIPAddress200ResponseAllocation `json:"allocation"` + + // IpAddress The IP address that has been located + IpAddress IPAddress `json:"ip_address"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest IPAddressNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchIpAddressResponse parses an HTTP response from a PatchIpAddressWithResponse call +func ParsePatchIpAddressResponse(rsp *http.Response) (*PatchIpAddressResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchIpAddressResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // IpAddress The IP address that has been updated + IpAddress IPAddress `json:"ip_address"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest IPAddressNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostIpAddressUnallocateResponse parses an HTTP response from a PostIpAddressUnallocateWithResponse call +func ParsePostIpAddressUnallocateResponse(rsp *http.Response) (*PostIpAddressUnallocateResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostIpAddressUnallocateResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest interface{} + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest IPAddressNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 409: + var dest ResourceDoesNotSupportUnallocationResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON409 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest NoAllocationResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteLoadBalancerResponse parses an HTTP response from a DeleteLoadBalancerWithResponse call +func ParseDeleteLoadBalancerResponse(rsp *http.Response) (*DeleteLoadBalancerResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteLoadBalancerResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancer The load balancer that has been destroyed + LoadBalancer DeleteLoadBalancer200ResponseLoadBalancer `json:"load_balancer"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest LoadBalancerNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetLoadBalancerResponse parses an HTTP response from a GetLoadBalancerWithResponse call +func ParseGetLoadBalancerResponse(rsp *http.Response) (*GetLoadBalancerResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetLoadBalancerResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancer The load balancer + LoadBalancer GetLoadBalancer200ResponseLoadBalancer `json:"load_balancer"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest LoadBalancerNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchLoadBalancerResponse parses an HTTP response from a PatchLoadBalancerWithResponse call +func ParsePatchLoadBalancerResponse(rsp *http.Response) (*PatchLoadBalancerResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchLoadBalancerResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancer The load balancer that has been updated + LoadBalancer PatchLoadBalancer200ResponseLoadBalancer `json:"load_balancer"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest LoadBalancerNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetLoadBalancerRulesResponse parses an HTTP response from a GetLoadBalancerRulesWithResponse call +func ParseGetLoadBalancerRulesResponse(rsp *http.Response) (*GetLoadBalancerRulesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetLoadBalancerRulesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancerRules The load balancer rules for this load balancer + LoadBalancerRules []GetLoadBalancerRules200ResponseLoadBalancerRules `json:"load_balancer_rules"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest LoadBalancerNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostLoadBalancerRulesResponse parses an HTTP response from a PostLoadBalancerRulesWithResponse call +func ParsePostLoadBalancerRulesResponse(rsp *http.Response) (*PostLoadBalancerRulesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostLoadBalancerRulesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancerRule The load balancer rule that has been created + LoadBalancerRule PostLoadBalancerRules200ResponseLoadBalancerRule `json:"load_balancer_rule"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest LoadBalancerNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteLoadBalancersRulesLoadBalancerRuleResponse parses an HTTP response from a DeleteLoadBalancersRulesLoadBalancerRuleWithResponse call +func ParseDeleteLoadBalancersRulesLoadBalancerRuleResponse(rsp *http.Response) (*DeleteLoadBalancersRulesLoadBalancerRuleResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteLoadBalancersRulesLoadBalancerRuleResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancerRule The load balancer rule that has been destroyed + LoadBalancerRule DeleteLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule `json:"load_balancer_rule"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest LoadBalancerRuleNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetLoadBalancersRulesLoadBalancerRuleResponse parses an HTTP response from a GetLoadBalancersRulesLoadBalancerRuleWithResponse call +func ParseGetLoadBalancersRulesLoadBalancerRuleResponse(rsp *http.Response) (*GetLoadBalancersRulesLoadBalancerRuleResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetLoadBalancersRulesLoadBalancerRuleResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancerRule The resolved load balancer rule + LoadBalancerRule GetLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule `json:"load_balancer_rule"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest LoadBalancerRuleNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchLoadBalancersRulesLoadBalancerRuleResponse parses an HTTP response from a PatchLoadBalancersRulesLoadBalancerRuleWithResponse call +func ParsePatchLoadBalancersRulesLoadBalancerRuleResponse(rsp *http.Response) (*PatchLoadBalancersRulesLoadBalancerRuleResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchLoadBalancersRulesLoadBalancerRuleResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancerRule The load balancer that has been updated + LoadBalancerRule PatchLoadBalancersRulesLoadBalancerRule200ResponseLoadBalancerRule `json:"load_balancer_rule"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest LoadBalancerRuleNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetNetworkResponse parses an HTTP response from a GetNetworkWithResponse call +func ParseGetNetworkResponse(rsp *http.Response) (*GetNetworkResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetNetworkResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Network The details for the requested network + Network Network `json:"network"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NetworkNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOperatingSystemsResponse parses an HTTP response from a GetOperatingSystemsWithResponse call +func ParseGetOperatingSystemsResponse(rsp *http.Response) (*GetOperatingSystemsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOperatingSystemsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // OperatingSystems The list of available operating systems + OperatingSystems []GetOperatingSystems200ResponseOperatingSystems `json:"operating_systems"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOperatingSystemResponse parses an HTTP response from a GetOperatingSystemWithResponse call +func ParseGetOperatingSystemResponse(rsp *http.Response) (*GetOperatingSystemResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOperatingSystemResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // OperatingSystem The operating system details + OperatingSystem OperatingSystem `json:"operating_system"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OperatingSystemNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationsResponse parses an HTTP response from a GetOrganizationsWithResponse call +func ParseGetOrganizationsResponse(rsp *http.Response) (*GetOrganizationsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Organizations []GetOrganizations200ResponseOrganizations `json:"organizations"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationResponse parses an HTTP response from a GetOrganizationWithResponse call +func ParseGetOrganizationResponse(rsp *http.Response) (*GetOrganizationResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Organization Organization `json:"organization"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationAvailableNetworksResponse parses an HTTP response from a GetOrganizationAvailableNetworksWithResponse call +func ParseGetOrganizationAvailableNetworksResponse(rsp *http.Response) (*GetOrganizationAvailableNetworksResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationAvailableNetworksResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Networks []GetOrganizationAvailableNetworks200ResponseNetworks `json:"networks"` + VirtualNetworks []GetOrganizationAvailableNetworks200ResponseVirtualNetworks `json:"virtual_networks"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationCertificatesResponse parses an HTTP response from a GetOrganizationCertificatesWithResponse call +func ParseGetOrganizationCertificatesResponse(rsp *http.Response) (*GetOrganizationCertificatesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationCertificatesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Certificates []GetOrganizationCertificates200ResponseCertificates `json:"certificates"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationDiskBackupPoliciesResponse parses an HTTP response from a GetOrganizationDiskBackupPoliciesWithResponse call +func ParseGetOrganizationDiskBackupPoliciesResponse(rsp *http.Response) (*GetOrganizationDiskBackupPoliciesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationDiskBackupPoliciesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicies The disk backup policies for the provided organization + DiskBackupPolicies []GetOrganizationDiskBackupPolicies200ResponseDiskBackupPolicies `json:"disk_backup_policies"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationDiskTemplatesResponse parses an HTTP response from a GetOrganizationDiskTemplatesWithResponse call +func ParseGetOrganizationDiskTemplatesResponse(rsp *http.Response) (*GetOrganizationDiskTemplatesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationDiskTemplatesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskTemplates The list of disk templates + DiskTemplates []GetOrganizationDiskTemplates200ResponseDiskTemplates `json:"disk_templates"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OperatingSystemNotFoundOrganizationNotFound404Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationDisksResponse parses an HTTP response from a GetOrganizationDisksWithResponse call +func ParseGetOrganizationDisksResponse(rsp *http.Response) (*GetOrganizationDisksResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationDisksResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Disk The list of disks + Disk []GetOrganizationDisks200ResponseDisk `json:"disk"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationDnsZonesResponse parses an HTTP response from a GetOrganizationDnsZonesWithResponse call +func ParseGetOrganizationDnsZonesResponse(rsp *http.Response) (*GetOrganizationDnsZonesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationDnsZonesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZones The DNS zones for the provided organization + DnsZones []DNSZone `json:"dns_zones"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationDnsZonesResponse parses an HTTP response from a PostOrganizationDnsZonesWithResponse call +func ParsePostOrganizationDnsZonesResponse(rsp *http.Response) (*PostOrganizationDnsZonesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationDnsZonesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest struct { + // DnsZone The new DNS zone that has been created + DnsZone PostOrganizationDNSZones201ResponseDNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationsOrganizationdnsZonesResponse parses an HTTP response from a GetOrganizationsOrganizationdnsZonesWithResponse call +func ParseGetOrganizationsOrganizationdnsZonesResponse(rsp *http.Response) (*GetOrganizationsOrganizationdnsZonesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationsOrganizationdnsZonesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DnsZones The DNS zones for the provided organization + DnsZones []DNSZone `json:"dns_zones"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationsOrganizationdnsZonesResponse parses an HTTP response from a PostOrganizationsOrganizationdnsZonesWithResponse call +func ParsePostOrganizationsOrganizationdnsZonesResponse(rsp *http.Response) (*PostOrganizationsOrganizationdnsZonesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationsOrganizationdnsZonesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest struct { + // DnsZone The new DNS zone that has been created + DnsZone PostOrganizationsOrganizationDNSZones201ResponseDNSZone `json:"dns_zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationDnsZonesNameserversResponse parses an HTTP response from a GetOrganizationDnsZonesNameserversWithResponse call +func ParseGetOrganizationDnsZonesNameserversResponse(rsp *http.Response) (*GetOrganizationDnsZonesNameserversResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationDnsZonesNameserversResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Nameservers []string `json:"nameservers"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationFileStorageVolumesResponse parses an HTTP response from a GetOrganizationFileStorageVolumesWithResponse call +func ParseGetOrganizationFileStorageVolumesResponse(rsp *http.Response) (*GetOrganizationFileStorageVolumesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationFileStorageVolumesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // FileStorageVolumes A list of all file storage volumes for the given organization. + FileStorageVolumes []GetOrganizationFileStorageVolumes200ResponseFileStorageVolumes `json:"file_storage_volumes"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationFileStorageVolumesResponse parses an HTTP response from a PostOrganizationFileStorageVolumesWithResponse call +func ParsePostOrganizationFileStorageVolumesResponse(rsp *http.Response) (*PostOrganizationFileStorageVolumesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationFileStorageVolumesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest struct { + // FileStorageVolume The file storage volume. + FileStorageVolume PostOrganizationFileStorageVolumes201ResponseFileStorageVolume `json:"file_storage_volume"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationIpAddressesResponse parses an HTTP response from a GetOrganizationIpAddressesWithResponse call +func ParseGetOrganizationIpAddressesResponse(rsp *http.Response) (*GetOrganizationIpAddressesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationIpAddressesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // IpAddresses The IP addresses belonging to this organization + IpAddresses []GetOrganizationIPAddresses200ResponseIPAddresses `json:"ip_addresses"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationIpAddressesResponse parses an HTTP response from a PostOrganizationIpAddressesWithResponse call +func ParsePostOrganizationIpAddressesResponse(rsp *http.Response) (*PostOrganizationIpAddressesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationIpAddressesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // IpAddress The newly allocated IP address + IpAddress IPAddress `json:"ip_address"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NetworkNotFoundOrganizationNotFound404Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest NoAvailableAddressesResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationLoadBalancersResponse parses an HTTP response from a GetOrganizationLoadBalancersWithResponse call +func ParseGetOrganizationLoadBalancersResponse(rsp *http.Response) (*GetOrganizationLoadBalancersResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationLoadBalancersResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancers The load balancers owned by this organization + LoadBalancers []GetOrganizationLoadBalancers200ResponseLoadBalancers `json:"load_balancers"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationLoadBalancersResponse parses an HTTP response from a PostOrganizationLoadBalancersWithResponse call +func ParsePostOrganizationLoadBalancersResponse(rsp *http.Response) (*PostOrganizationLoadBalancersResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationLoadBalancersResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // LoadBalancer The load balancer that has been created + LoadBalancer PostOrganizationLoadBalancers200ResponseLoadBalancer `json:"load_balancer"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationManagedResponse parses an HTTP response from a GetOrganizationManagedWithResponse call +func ParseGetOrganizationManagedResponse(rsp *http.Response) (*GetOrganizationManagedResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationManagedResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Organizations []GetOrganizationManaged200ResponseOrganizations `json:"organizations"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationManagedResponse parses an HTTP response from a PostOrganizationManagedWithResponse call +func ParsePostOrganizationManagedResponse(rsp *http.Response) (*PostOrganizationManagedResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationManagedResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest struct { + Organization PostOrganizationManaged201ResponseOrganization `json:"organization"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest OrganizationLimitReachedValidationError422Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationNetworkSpeedProfilesResponse parses an HTTP response from a GetOrganizationNetworkSpeedProfilesWithResponse call +func ParseGetOrganizationNetworkSpeedProfilesResponse(rsp *http.Response) (*GetOrganizationNetworkSpeedProfilesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationNetworkSpeedProfilesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // NetworkSpeedProfiles The network speed profiles available to this organization + NetworkSpeedProfiles []NetworkSpeedProfile `json:"network_speed_profiles"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationSecurityGroupsResponse parses an HTTP response from a GetOrganizationSecurityGroupsWithResponse call +func ParseGetOrganizationSecurityGroupsResponse(rsp *http.Response) (*GetOrganizationSecurityGroupsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationSecurityGroupsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + + // SecurityGroups The security groups owned by this organization + SecurityGroups []SecurityGroup `json:"security_groups"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationSecurityGroupsResponse parses an HTTP response from a PostOrganizationSecurityGroupsWithResponse call +func ParsePostOrganizationSecurityGroupsResponse(rsp *http.Response) (*PostOrganizationSecurityGroupsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationSecurityGroupsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // SecurityGroup The security group that has been created + SecurityGroup SecurityGroup `json:"security_group"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationSshKeysResponse parses an HTTP response from a GetOrganizationSshKeysWithResponse call +func ParseGetOrganizationSshKeysResponse(rsp *http.Response) (*GetOrganizationSshKeysResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationSshKeysResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + SshKeys []AuthSSHKey `json:"ssh_keys"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationSshKeysResponse parses an HTTP response from a PostOrganizationSshKeysWithResponse call +func ParsePostOrganizationSshKeysResponse(rsp *http.Response) (*PostOrganizationSshKeysResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationSshKeysResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest struct { + SshKey AuthSSHKey `json:"ssh_key"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationTagsResponse parses an HTTP response from a GetOrganizationTagsWithResponse call +func ParseGetOrganizationTagsResponse(rsp *http.Response) (*GetOrganizationTagsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationTagsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + + // Tags The details for the tags on the organization + Tags []GetOrganizationTags200ResponseTags `json:"tags"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationTagsResponse parses an HTTP response from a PostOrganizationTagsWithResponse call +func ParsePostOrganizationTagsResponse(rsp *http.Response) (*PostOrganizationTagsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationTagsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Tag The newly created tag + Tag Tag `json:"tag"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationTrashObjectsResponse parses an HTTP response from a GetOrganizationTrashObjectsWithResponse call +func ParseGetOrganizationTrashObjectsResponse(rsp *http.Response) (*GetOrganizationTrashObjectsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationTrashObjectsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + + // TrashObjects The trash objects that belong to this organization + TrashObjects []TrashObject `json:"trash_objects"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationTrashObjectsPurgeAllResponse parses an HTTP response from a PostOrganizationTrashObjectsPurgeAllWithResponse call +func ParsePostOrganizationTrashObjectsPurgeAllResponse(rsp *http.Response) (*PostOrganizationTrashObjectsPurgeAllResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationTrashObjectsPurgeAllResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task Task `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest TaskQueueingErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationUsersWithAccessResponse parses an HTTP response from a GetOrganizationUsersWithAccessWithResponse call +func ParseGetOrganizationUsersWithAccessResponse(rsp *http.Response) (*GetOrganizationUsersWithAccessResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationUsersWithAccessResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + Users []GetOrganizationUsersWithAccess200ResponseUsers `json:"users"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationVirtualMachineGroupsResponse parses an HTTP response from a GetOrganizationVirtualMachineGroupsWithResponse call +func ParseGetOrganizationVirtualMachineGroupsResponse(rsp *http.Response) (*GetOrganizationVirtualMachineGroupsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationVirtualMachineGroupsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachineGroups The virtual machine groups for the provided organization + VirtualMachineGroups []VirtualMachineGroup `json:"virtual_machine_groups"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationVirtualMachineGroupsResponse parses an HTTP response from a PostOrganizationVirtualMachineGroupsWithResponse call +func ParsePostOrganizationVirtualMachineGroupsResponse(rsp *http.Response) (*PostOrganizationVirtualMachineGroupsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationVirtualMachineGroupsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachineGroup The new virtual machine group details + VirtualMachineGroup VirtualMachineGroup `json:"virtual_machine_group"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetOrganizationVirtualMachinesResponse parses an HTTP response from a GetOrganizationVirtualMachinesWithResponse call +func ParseGetOrganizationVirtualMachinesResponse(rsp *http.Response) (*GetOrganizationVirtualMachinesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetOrganizationVirtualMachinesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + VirtualMachines []GetOrganizationVirtualMachines200ResponseVirtualMachines `json:"virtual_machines"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationVirtualMachinesBuildResponse parses an HTTP response from a PostOrganizationVirtualMachinesBuildWithResponse call +func ParsePostOrganizationVirtualMachinesBuildResponse(rsp *http.Response) (*PostOrganizationVirtualMachinesBuildResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationVirtualMachinesBuildResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest struct { + // Build Deprecated, please use "virtual_machine_build" instead + Build PostOrganizationVirtualMachinesBuild201ResponseBuild `json:"build"` + Hostname string `json:"hostname"` + Task PostOrganizationVirtualMachinesBuild201ResponseTask `json:"task"` + VirtualMachineBuild PostOrganizationVirtualMachinesBuild201ResponseVirtualMachineBuild `json:"virtual_machine_build"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedPermissionDeniedResourceCreationRestricted403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest DataCenterNotFoundVirtualMachinePackageNotFoundZoneNotFound404Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest LocationRequiredValidationError422Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostOrganizationVirtualMachinesBuildFromSpecResponse parses an HTTP response from a PostOrganizationVirtualMachinesBuildFromSpecWithResponse call +func ParsePostOrganizationVirtualMachinesBuildFromSpecResponse(rsp *http.Response) (*PostOrganizationVirtualMachinesBuildFromSpecResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostOrganizationVirtualMachinesBuildFromSpecResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest struct { + // Build Deprecated, please use "virtual_machine_build" instead + Build PostOrganizationVirtualMachinesBuildFromSpec201ResponseBuild `json:"build"` + Hostname string `json:"hostname"` + Task PostOrganizationVirtualMachinesBuildFromSpec201ResponseTask `json:"task"` + VirtualMachineBuild PostOrganizationVirtualMachinesBuildFromSpec201ResponseVirtualMachineBuild `json:"virtual_machine_build"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest InvalidSpecXML400Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspendedPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteSecurityGroupResponse parses an HTTP response from a DeleteSecurityGroupWithResponse call +func ParseDeleteSecurityGroupResponse(rsp *http.Response) (*DeleteSecurityGroupResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteSecurityGroupResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // SecurityGroup The security group that has been destroyed + SecurityGroup DeleteSecurityGroup200ResponseSecurityGroup `json:"security_group"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SecurityGroupNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 409: + var dest DeletionRestrictedResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON409 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetSecurityGroupResponse parses an HTTP response from a GetSecurityGroupWithResponse call +func ParseGetSecurityGroupResponse(rsp *http.Response) (*GetSecurityGroupResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetSecurityGroupResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // SecurityGroup The security group + SecurityGroup SecurityGroup `json:"security_group"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SecurityGroupNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchSecurityGroupResponse parses an HTTP response from a PatchSecurityGroupWithResponse call +func ParsePatchSecurityGroupResponse(rsp *http.Response) (*PatchSecurityGroupResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchSecurityGroupResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // SecurityGroup The security group that has been updated + SecurityGroup SecurityGroup `json:"security_group"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SecurityGroupNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetSecurityGroupRulesResponse parses an HTTP response from a GetSecurityGroupRulesWithResponse call +func ParseGetSecurityGroupRulesResponse(rsp *http.Response) (*GetSecurityGroupRulesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetSecurityGroupRulesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + + // SecurityGroupRules The security group rules for this security group + SecurityGroupRules []GetSecurityGroupRules200ResponseSecurityGroupRules `json:"security_group_rules"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SecurityGroupNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostSecurityGroupRulesResponse parses an HTTP response from a PostSecurityGroupRulesWithResponse call +func ParsePostSecurityGroupRulesResponse(rsp *http.Response) (*PostSecurityGroupRulesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostSecurityGroupRulesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // SecurityGroupRule The security group rule that has been created + SecurityGroupRule PostSecurityGroupRules200ResponseSecurityGroupRule `json:"security_group_rule"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SecurityGroupNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteSecurityGroupsRulesSecurityGroupRuleResponse parses an HTTP response from a DeleteSecurityGroupsRulesSecurityGroupRuleWithResponse call +func ParseDeleteSecurityGroupsRulesSecurityGroupRuleResponse(rsp *http.Response) (*DeleteSecurityGroupsRulesSecurityGroupRuleResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteSecurityGroupsRulesSecurityGroupRuleResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // SecurityGroupRule The security group rule that has been destroyed + SecurityGroupRule DeleteSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule `json:"security_group_rule"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SecurityGroupRuleNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetSecurityGroupsRulesSecurityGroupRuleResponse parses an HTTP response from a GetSecurityGroupsRulesSecurityGroupRuleWithResponse call +func ParseGetSecurityGroupsRulesSecurityGroupRuleResponse(rsp *http.Response) (*GetSecurityGroupsRulesSecurityGroupRuleResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetSecurityGroupsRulesSecurityGroupRuleResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // SecurityGroupRule The resolved security group rule + SecurityGroupRule GetSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule `json:"security_group_rule"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SecurityGroupRuleNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchSecurityGroupsRulesSecurityGroupRuleResponse parses an HTTP response from a PatchSecurityGroupsRulesSecurityGroupRuleWithResponse call +func ParsePatchSecurityGroupsRulesSecurityGroupRuleResponse(rsp *http.Response) (*PatchSecurityGroupsRulesSecurityGroupRuleResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchSecurityGroupsRulesSecurityGroupRuleResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // SecurityGroupRule The security group that has been updated + SecurityGroupRule PatchSecurityGroupsRulesSecurityGroupRule200ResponseSecurityGroupRule `json:"security_group_rule"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SecurityGroupRuleNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteSshKeyResponse parses an HTTP response from a DeleteSshKeyWithResponse call +func ParseDeleteSshKeyResponse(rsp *http.Response) (*DeleteSshKeyResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteSshKeyResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + SshKey AuthSSHKey `json:"ssh_key"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest SSHKeyNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 409: + var dest DeletionRestrictedResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON409 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteTagResponse parses an HTTP response from a DeleteTagWithResponse call +func ParseDeleteTagResponse(rsp *http.Response) (*DeleteTagResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteTagResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Tag The newly deleted tag + Tag Tag `json:"tag"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest TagNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetTagResponse parses an HTTP response from a GetTagWithResponse call +func ParseGetTagResponse(rsp *http.Response) (*GetTagResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetTagResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Tag The details for the requested tag + Tag Tag `json:"tag"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest TagNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchTagResponse parses an HTTP response from a PatchTagWithResponse call +func ParsePatchTagResponse(rsp *http.Response) (*PatchTagResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchTagResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Tag The newly updated tag + Tag Tag `json:"tag"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest TagNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetTaskResponse parses an HTTP response from a GetTaskWithResponse call +func ParseGetTaskResponse(rsp *http.Response) (*GetTaskResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetTaskResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task Task `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest TaskNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteTrashObjectResponse parses an HTTP response from a DeleteTrashObjectWithResponse call +func ParseDeleteTrashObjectResponse(rsp *http.Response) (*DeleteTrashObjectResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteTrashObjectResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task Task `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest TrashObjectNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest TaskQueueingErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetTrashObjectResponse parses an HTTP response from a GetTrashObjectWithResponse call +func ParseGetTrashObjectResponse(rsp *http.Response) (*GetTrashObjectResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetTrashObjectResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // TrashObject The requested trash object + TrashObject TrashObject `json:"trash_object"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest TrashObjectNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostTrashObjectRestoreResponse parses an HTTP response from a PostTrashObjectRestoreWithResponse call +func ParsePostTrashObjectRestoreResponse(rsp *http.Response) (*PostTrashObjectRestoreResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostTrashObjectRestoreResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // TrashObject The requested trash object + TrashObject TrashObject `json:"trash_object"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest TrashObjectNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetUsersCurrentResponse parses an HTTP response from a GetUsersCurrentWithResponse call +func ParseGetUsersCurrentResponse(rsp *http.Response) (*GetUsersCurrentResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetUsersCurrentResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + ApiTokenId string `json:"api_token_id"` + Organizations []GetUsersCurrent200ResponseOrganizations `json:"organizations"` + User User `json:"user"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NoUserAssociatedWithIdentityResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteVirtualMachineGroupResponse parses an HTTP response from a DeleteVirtualMachineGroupWithResponse call +func ParseDeleteVirtualMachineGroupResponse(rsp *http.Response) (*DeleteVirtualMachineGroupResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteVirtualMachineGroupResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachineGroup The details for the deleted virtual machine group + VirtualMachineGroup VirtualMachineGroup `json:"virtual_machine_group"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineGroupNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 409: + var dest DeletionRestrictedResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON409 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachineGroupResponse parses an HTTP response from a GetVirtualMachineGroupWithResponse call +func ParseGetVirtualMachineGroupResponse(rsp *http.Response) (*GetVirtualMachineGroupResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachineGroupResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachineGroup The virtual machine group details + VirtualMachineGroup VirtualMachineGroup `json:"virtual_machine_group"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineGroupNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchVirtualMachineGroupResponse parses an HTTP response from a PatchVirtualMachineGroupWithResponse call +func ParsePatchVirtualMachineGroupResponse(rsp *http.Response) (*PatchVirtualMachineGroupResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchVirtualMachineGroupResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachineGroup The updated virtual machine group details + VirtualMachineGroup VirtualMachineGroup `json:"virtual_machine_group"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineGroupNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVMNIVMNIResponse parses an HTTP response from a GetVMNIVMNIWithResponse call +func ParseGetVMNIVMNIResponse(rsp *http.Response) (*GetVMNIVMNIResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVMNIVMNIResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachineNetworkInterface The network interface details + VirtualMachineNetworkInterface GetVMNIVMNI200ResponseVirtualMachineNetworkInterface `json:"virtual_machine_network_interface"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNetworkInterfaceNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineNetworkInterfaceAllocateIpResponse parses an HTTP response from a PostVirtualMachineNetworkInterfaceAllocateIpWithResponse call +func ParsePostVirtualMachineNetworkInterfaceAllocateIpResponse(rsp *http.Response) (*PostVirtualMachineNetworkInterfaceAllocateIpResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineNetworkInterfaceAllocateIpResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachineNetworkInterface The network interface details + VirtualMachineNetworkInterface PostVirtualMachineNetworkInterfaceAllocateIP200ResponseVirtualMachineNetworkInterface `json:"virtual_machine_network_interface"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest IPAddressNotFoundVirtualMachineNetworkInterfaceNotFound404Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest IPAlreadyAllocatedInvalidIP422Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineNetworkInterfaceAllocateNewIpResponse parses an HTTP response from a PostVirtualMachineNetworkInterfaceAllocateNewIpWithResponse call +func ParsePostVirtualMachineNetworkInterfaceAllocateNewIpResponse(rsp *http.Response) (*PostVirtualMachineNetworkInterfaceAllocateNewIpResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineNetworkInterfaceAllocateNewIpResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // IpAddress The newly allocated IP address + IpAddress IPAddress `json:"ip_address"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNetworkInterfaceNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 503: + var dest NoAvailableAddressesResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON503 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse parses an HTTP response from a GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionWithResponse call +func ParseGetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse(rsp *http.Response) (*GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachineNetworkInterfaceAvailableIpsAddressVersionResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // IpAddresses The IP addresses available for this network interface + IpAddresses []IPAddress `json:"ip_addresses"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNetworkInterfaceNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse parses an HTTP response from a PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileWithResponse call +func ParsePatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse(rsp *http.Response) (*PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchVirtualMachineNetworkInterfaceUpdateSpeedProfileResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Task The task responsible for updating the virtual machine network interface speed profile + Task Task `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest NetworkSpeedProfileNotFoundVirtualMachineNetworkInterfaceNotFound404Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest TaskQueueingErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest SpeedProfileAlreadyAssignedResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachinePackagesResponse parses an HTTP response from a GetVirtualMachinePackagesWithResponse call +func ParseGetVirtualMachinePackagesResponse(rsp *http.Response) (*GetVirtualMachinePackagesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachinePackagesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + VirtualMachinePackages []GetVirtualMachinePackages200ResponseVirtualMachinePackages `json:"virtual_machine_packages"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest OrganizationNotActivatedOrganizationSuspended403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest OrganizationNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachinePackageResponse parses an HTTP response from a GetVirtualMachinePackageWithResponse call +func ParseGetVirtualMachinePackageResponse(rsp *http.Response) (*GetVirtualMachinePackageResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachinePackageResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + VirtualMachinePackage VirtualMachinePackage `json:"virtual_machine_package"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachinePackageNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseDeleteVirtualMachineResponse parses an HTTP response from a DeleteVirtualMachineWithResponse call +func ParseDeleteVirtualMachineResponse(rsp *http.Response) (*DeleteVirtualMachineResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &DeleteVirtualMachineResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + TrashObject TrashObject `json:"trash_object"` + VirtualMachine DeleteVirtualMachine200ResponseVirtualMachine `json:"virtual_machine"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachineResponse parses an HTTP response from a GetVirtualMachineWithResponse call +func ParseGetVirtualMachineResponse(rsp *http.Response) (*GetVirtualMachineResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachineResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + VirtualMachine GetVirtualMachine200ResponseVirtualMachine `json:"virtual_machine"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePatchVirtualMachineResponse parses an HTTP response from a PatchVirtualMachineWithResponse call +func ParsePatchVirtualMachineResponse(rsp *http.Response) (*PatchVirtualMachineResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PatchVirtualMachineResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachine The newly updated virtual machine + VirtualMachine PatchVirtualMachine200ResponseVirtualMachine `json:"virtual_machine"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineAllocateIpResponse parses an HTTP response from a PostVirtualMachineAllocateIpWithResponse call +func ParsePostVirtualMachineAllocateIpResponse(rsp *http.Response) (*PostVirtualMachineAllocateIpResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineAllocateIpResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // IpAddress The newly allocated IP address + IpAddress IPAddress `json:"ip_address"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest IPAddressNotFoundVirtualMachineNotFound404Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest IPAlreadyAllocatedNoInterfaceAvailable422Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineConsoleSessionsResponse parses an HTTP response from a PostVirtualMachineConsoleSessionsWithResponse call +func ParsePostVirtualMachineConsoleSessionsResponse(rsp *http.Response) (*PostVirtualMachineConsoleSessionsResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineConsoleSessionsResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 201: + var dest struct { + ConsoleSession PostVirtualMachineConsoleSessions201ResponseConsoleSession `json:"console_session"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON201 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashVirtualMachineMustBeStarted406Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachineDiskBackupPoliciesResponse parses an HTTP response from a GetVirtualMachineDiskBackupPoliciesWithResponse call +func ParseGetVirtualMachineDiskBackupPoliciesResponse(rsp *http.Response) (*GetVirtualMachineDiskBackupPoliciesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachineDiskBackupPoliciesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicies The disk backup policies for the provided virtual machine + DiskBackupPolicies []GetVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicies `json:"disk_backup_policies"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineDiskBackupPoliciesResponse parses an HTTP response from a PostVirtualMachineDiskBackupPoliciesWithResponse call +func ParsePostVirtualMachineDiskBackupPoliciesResponse(rsp *http.Response) (*PostVirtualMachineDiskBackupPoliciesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineDiskBackupPoliciesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // DiskBackupPolicy The new disk backup policy that has been created + DiskBackupPolicy PostVirtualMachineDiskBackupPolicies200ResponseDiskBackupPolicy `json:"disk_backup_policy"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 422: + var dest ValidationErrorResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON422 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachineDisksResponse parses an HTTP response from a GetVirtualMachineDisksWithResponse call +func ParseGetVirtualMachineDisksResponse(rsp *http.Response) (*GetVirtualMachineDisksResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachineDisksResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Disks The list of disks + Disks []GetVirtualMachineDisks200ResponseDisks `json:"disks"` + Pagination PaginationObject `json:"pagination"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePutVirtualMachineFlexibleResourcesResponse parses an HTTP response from a PutVirtualMachineFlexibleResourcesWithResponse call +func ParsePutVirtualMachineFlexibleResourcesResponse(rsp *http.Response) (*PutVirtualMachineFlexibleResourcesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PutVirtualMachineFlexibleResourcesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task Task `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest FlexibleResourcesUnavailableToOrganizationPermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashTaskQueueingError406Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachineNetworkInterfacesResponse parses an HTTP response from a GetVirtualMachineNetworkInterfacesWithResponse call +func ParseGetVirtualMachineNetworkInterfacesResponse(rsp *http.Response) (*GetVirtualMachineNetworkInterfacesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachineNetworkInterfacesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Pagination PaginationObject `json:"pagination"` + + // VirtualMachineNetworkInterfaces The network interfaces for this virtual machine + VirtualMachineNetworkInterfaces []GetVirtualMachineNetworkInterfaces200ResponseVirtualMachineNetworkInterfaces `json:"virtual_machine_network_interfaces"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachineNetworkInterfaceResponse parses an HTTP response from a GetVirtualMachineNetworkInterfaceWithResponse call +func ParseGetVirtualMachineNetworkInterfaceResponse(rsp *http.Response) (*GetVirtualMachineNetworkInterfaceResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachineNetworkInterfaceResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // VirtualMachineNetworkInterface The network interface details + VirtualMachineNetworkInterface GetVirtualMachineNetworkInterface200ResponseVirtualMachineNetworkInterface `json:"virtual_machine_network_interface"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest InterfaceNotFoundNetworkNotFoundVirtualMachineNotFound404Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePutVirtualMachinePackageResponse parses an HTTP response from a PutVirtualMachinePackageWithResponse call +func ParsePutVirtualMachinePackageResponse(rsp *http.Response) (*PutVirtualMachinePackageResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PutVirtualMachinePackageResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task Task `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundVirtualMachinePackageNotFound404Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashTaskQueueingError406Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineResetResponse parses an HTTP response from a PostVirtualMachineResetWithResponse call +func ParsePostVirtualMachineResetResponse(rsp *http.Response) (*PostVirtualMachineResetResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineResetResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task PostVirtualMachineReset200ResponseTask `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashTaskQueueingError406Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineShutdownResponse parses an HTTP response from a PostVirtualMachineShutdownWithResponse call +func ParsePostVirtualMachineShutdownResponse(rsp *http.Response) (*PostVirtualMachineShutdownResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineShutdownResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task PostVirtualMachineShutdown200ResponseTask `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashTaskQueueingError406Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineStartResponse parses an HTTP response from a PostVirtualMachineStartWithResponse call +func ParsePostVirtualMachineStartResponse(rsp *http.Response) (*PostVirtualMachineStartResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineStartResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task PostVirtualMachineStart200ResponseTask `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashTaskQueueingError406Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParsePostVirtualMachineStopResponse parses an HTTP response from a PostVirtualMachineStopWithResponse call +func ParsePostVirtualMachineStopResponse(rsp *http.Response) (*PostVirtualMachineStopResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &PostVirtualMachineStopResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + Task PostVirtualMachineStop200ResponseTask `json:"task"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest PermissionDenied403Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 406: + var dest ObjectInTrashTaskQueueingError406Res + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON406 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetVirtualMachinesBuildsVirtualMachineBuildResponse parses an HTTP response from a GetVirtualMachinesBuildsVirtualMachineBuildWithResponse call +func ParseGetVirtualMachinesBuildsVirtualMachineBuildResponse(rsp *http.Response) (*GetVirtualMachinesBuildsVirtualMachineBuildResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetVirtualMachinesBuildsVirtualMachineBuildResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + VirtualMachineBuild GetVirtualMachinesBuildsVirtualMachineBuild200ResponseVirtualMachineBuild `json:"virtual_machine_build"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest VirtualMachineBuildNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetZonesResponse parses an HTTP response from a GetZonesWithResponse call +func ParseGetZonesResponse(rsp *http.Response) (*GetZonesResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetZonesResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Zones The zones available to the current identity + Zones []GetZones200ResponseZones `json:"zones"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} + +// ParseGetZoneResponse parses an HTTP response from a GetZoneWithResponse call +func ParseGetZoneResponse(rsp *http.Response) (*GetZoneResponse, error) { + bodyBytes, err := io.ReadAll(rsp.Body) + defer func() { _ = rsp.Body.Close() }() + if err != nil { + return nil, err + } + + response := &GetZoneResponse{ + Body: bodyBytes, + HTTPResponse: rsp, + } + + switch { + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 200: + var dest struct { + // Zone The zone details + Zone Zone `json:"zone"` + } + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON200 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 400: + var dest APIAuthenticator400Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON400 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 403: + var dest APIAuthenticator403Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON403 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 404: + var dest ZoneNotFoundResponse + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON404 = &dest + + case strings.Contains(rsp.Header.Get("Content-Type"), "json") && rsp.StatusCode == 429: + var dest APIAuthenticator429Response + if err := json.Unmarshal(bodyBytes, &dest); err != nil { + return nil, err + } + response.JSON429 = &dest + + } + + return response, nil +} diff --git a/go.mod b/go.mod index 3b6e8f5..a05ca54 100644 --- a/go.mod +++ b/go.mod @@ -3,30 +3,18 @@ module github.com/krystal/go-katapult go 1.18 require ( - github.com/augurysys/timestamp v0.3.2 - github.com/dave/jennifer v1.6.0 - github.com/hashicorp/go-hclog v1.4.0 + github.com/deepmap/oapi-codegen/v2 v2.0.0 github.com/jimeh/go-golden v0.1.0 - github.com/jimeh/rands v0.3.0 github.com/jimeh/undent v1.1.1 - github.com/mitchellh/copystructure v1.2.0 - github.com/stretchr/testify v1.8.2 - golang.org/x/text v0.7.0 + github.com/oapi-codegen/runtime v1.1.1 + github.com/stretchr/testify v1.8.4 gopkg.in/yaml.v3 v3.0.1 - mvdan.cc/gofumpt v0.4.0 ) require ( + github.com/apapsch/go-jsonmerge/v2 v2.0.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect - github.com/fatih/color v1.14.1 // indirect - github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8 // indirect - github.com/google/go-cmp v0.5.9 // indirect - github.com/mattn/go-colorable v0.1.13 // indirect - github.com/mattn/go-isatty v0.0.17 // indirect - github.com/mitchellh/reflectwalk v1.0.2 // indirect + github.com/google/uuid v1.5.0 // indirect + github.com/kr/text v0.2.0 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect - go.mongodb.org/mongo-driver v1.11.2 // indirect - golang.org/x/mod v0.8.0 // indirect - golang.org/x/sys v0.5.0 // indirect - golang.org/x/tools v0.6.0 // indirect ) diff --git a/go.sum b/go.sum index 18ae5f6..0e0989d 100644 --- a/go.sum +++ b/go.sum @@ -1,104 +1,40 @@ -github.com/augurysys/timestamp v0.3.2 h1:XalB++9y/ocSnghyNgJXs9KvTNBGduz9Sm8jBkL3e1M= -github.com/augurysys/timestamp v0.3.2/go.mod h1:YTTgyUjblbfWOBkqUyprzvMEpJmT0Mgt6yGBQDzAyC0= -github.com/dave/jennifer v1.6.0 h1:MQ/6emI2xM7wt0tJzJzyUik2Q3Tcn2eE0vtYgh4GPVI= -github.com/dave/jennifer v1.6.0/go.mod h1:AxTG893FiZKqxy3FP1kL80VMshSMuz2G+EgvszgGRnk= +github.com/RaveNoX/go-jsoncommentstrip v1.0.0/go.mod h1:78ihd09MekBnJnxpICcwzCMzGrKSKYe4AqU6PDYYpjk= +github.com/apapsch/go-jsonmerge/v2 v2.0.0 h1:axGnT1gRIfimI7gJifB699GoE/oq+F2MU7Dml6nw9rQ= +github.com/apapsch/go-jsonmerge/v2 v2.0.0/go.mod h1:lvDnEdqiQrp0O42VQGgmlKpxL1AP2+08jFMw88y4klk= +github.com/bmatcuk/doublestar v1.1.1/go.mod h1:UD6OnuiIn0yFxxA2le/rnRU1G4RaI4UvFv1sNto9p6w= +github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= -github.com/fatih/color v1.14.1 h1:qfhVLaG5s+nCROl1zJsZRxFeYrHLqWroPOQ8BWiNb4w= -github.com/fatih/color v1.14.1/go.mod h1:2oHN61fhTpgcxD3TSWCgKDiH1+x4OiDVVGH8WlgGZGg= -github.com/frankban/quicktest v1.14.3 h1:FJKSZTDHjyhriyC81FLQ0LY93eSai0ZyR/ZIkd3ZUKE= -github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8 h1:DujepqpGd1hyOd7aW59XpK7Qymp8iy83xq74fLr21is= -github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q= -github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= -github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/hashicorp/go-hclog v1.4.0 h1:ctuWFGrhFha8BnnzxqeRGidlEcQkDyL5u8J8t5eA11I= -github.com/hashicorp/go-hclog v1.4.0/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= +github.com/deepmap/oapi-codegen/v2 v2.0.0 h1:3TS7w3r+XnjKFXcbFbc16pTWzfTy0OLPkCsutEHjWDA= +github.com/deepmap/oapi-codegen/v2 v2.0.0/go.mod h1:7zR+ZL3WzLeCkr2k8oWTxEa0v8y/F25ane0l6A5UjLA= +github.com/google/uuid v1.5.0 h1:1p67kYwdtXjb0gL0BPiP1Av9wiZPo5A8z2cWkTZ+eyU= +github.com/google/uuid v1.5.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/jimeh/envctl v0.1.0 h1:KTv3D+pi5M4/PgFVE/W8ssWqiZP3pDJ8Cga50L+1avo= github.com/jimeh/envctl v0.1.0/go.mod h1:aM27ffBbO1yUBKUzgJGCUorS4z+wyh+qhQe1ruxXZZo= github.com/jimeh/go-golden v0.1.0 h1:j8kfajjYhUV2MDodc84eqcszEG/R9EKsE4UHpBJ7oeY= github.com/jimeh/go-golden v0.1.0/go.mod h1:Mu9RS/aNVNzhDOW0+p3R5yx5HvUEF34PcTmRW1jwwZY= -github.com/jimeh/rands v0.3.0 h1:HwN2wcJc0ZvxTGyIcaypRvaZViTgA3z/8BeiLM7n6ro= -github.com/jimeh/rands v0.3.0/go.mod h1:OowfWLB0GN014c0HwxxGMDer0OabCFXT/K2xhEgFyi4= github.com/jimeh/undent v1.1.1 h1:ZAzvd2DDx7gxQvOMGkQjfeRx9gRPIXe2cq+8ZNiGKaM= github.com/jimeh/undent v1.1.1/go.mod h1:oxYCIzdbyQNy8GXnCnjRJ2NS6Uq4p4yWoeawiGFqoHI= -github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= -github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.3.0 h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0= -github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= +github.com/juju/gnuflag v0.0.0-20171113085948-2ce1bb71843d/go.mod h1:2PavIy+JPciBPrBUjwbNvtwB6RQlve+hkpll6QSNmOE= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= -github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= -github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= -github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= -github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= -github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= -github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= -github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= -github.com/mattn/go-isatty v0.0.17 h1:BTarxUcIeDqL27Mc+vyvdWYSL28zpIhv3RoTdsLMPng= -github.com/mattn/go-isatty v0.0.17/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= -github.com/mitchellh/copystructure v1.2.0 h1:vpKXTN4ewci03Vljg/q9QvCGUDttBOGBIa15WveJJGw= -github.com/mitchellh/copystructure v1.2.0/go.mod h1:qLl+cE2AmVv+CoeAwDPye/v+N2HKCj9FbZEVFJRxO9s= -github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zxSIeXaQ= -github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= -github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe/go.mod h1:wL8QJuTMNUDYhXwkmfOly8iTdp5TEcJFWZD2D7SIkUc= -github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= +github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e h1:fD57ERR4JtEqsWbfPhv4DMiApHyliiK5xCTNVSPiaAs= +github.com/oapi-codegen/runtime v1.1.1 h1:EXLHh0DXIJnWhdRPN2w4MXAzFyE4CskzhNLUmtpMYro= +github.com/oapi-codegen/runtime v1.1.1/go.mod h1:SK9X900oXmPWilYR5/WKPzt3Kqxn/uS/+lbpREv+eCg= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/rhysd/go-fakeio v1.0.0 h1:+TjiKCOs32dONY7DaoVz/VPOdvRkPfBkEyUDIpM8FQY= github.com/rhysd/go-fakeio v1.0.0/go.mod h1:joYxF906trVwp2JLrE4jlN7A0z6wrz8O6o1UjarbFzE= -github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= +github.com/spkg/bom v0.0.0-20160624110644-59b7046e48ad/go.mod h1:qLr4V1qq6nMqFKkMo8ZTx3f+BZEkzsRUY10Xsm2mwU0= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= -github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= +github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= -github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= -github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8= -github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/tidwall/pretty v1.0.0 h1:HsD+QiTn7sK6flMKIvNmpqz1qrpP3Ps6jOKIKMooyg4= -github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk= -github.com/xdg-go/pbkdf2 v1.0.0/go.mod h1:jrpuAogTd400dnrH08LKmI/xc1MbPOebTwRqcT5RDeI= -github.com/xdg-go/scram v1.1.1/go.mod h1:RaEWvsqvNKKvBPvcKeFjrG2cJqOkHTiyTpzz23ni57g= -github.com/xdg-go/stringprep v1.0.3/go.mod h1:W3f5j4i+9rC0kuIEJL0ky1VpHXQU3ocBgklLGvcBnW8= -github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d/go.mod h1:rHwXgn7JulP+udvsHwJoVG1YGAP6VLg4y9I5dyZdqmA= -go.mongodb.org/mongo-driver v1.11.2 h1:+1v2rDQUWNcGW7/7E0Jvdz51V38XXxJfhzbV17aNHCw= -go.mongodb.org/mongo-driver v1.11.2/go.mod h1:s7p5vEtfbeR1gYi6pnj3c3/urpbLv2T5Sfd6Rp2HBB8= -golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/mod v0.8.0 h1:LUYupSeNrTNCGzR/hVBk2NHZO4hXcVaW1k4Qx7rjPx8= -golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.5.0 h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU= -golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= -golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.7.0 h1:4BRB4x83lYWy72KwLD/qYDuTu7q9PjSagHvijDw7cLo= -golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.6.0 h1:BOw41kyTf3PuCW1pVQf8+Cyg8pMlkYB1oo9iJ6D/lKM= -golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= +github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 h1:qIbj1fsPNlZgppZ+VLlY7N33q108Sa+fhmuc+sWQYwY= -gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b h1:QRR6H1YWRnHb4Y/HeNFCTJLFVxaq6wH4YuVdsUOr75U= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -mvdan.cc/gofumpt v0.4.0 h1:JVf4NN1mIpHogBj7ABpgOyZc65/UUOkKQFkoURsz4MM= -mvdan.cc/gofumpt v0.4.0/go.mod h1:PljLOHDeZqgS8opHRKLzp2It2VBuSdteAgqUfzMTxlQ=