Authentication We use bearerAuth with JSON Web Tokens for Authentication. You must send this token in the Authorization header when making requests to protected resources: Authorization: Bearer <JWTtoken>
You can find more information here # Pagination We use github style pagination with WebLinking. Maximum 100 results per page. # Rate limits 2000 requests per account per hour. You can see your limits in the following response headers * X-RateLimit-Limit
for a total limit * X-RateLimit-Remaining
for remaining limit * X-RateLimit-Reset
for timestamp when the oldest request will expire
This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.
- API version: 1.0.0
- Package version: 1.0.0
- Build package: org.openapitools.codegen.languages.GoClientCodegen
Install the following dependencies:
go get github.com/stretchr/testify/assert
go get golang.org/x/oauth2
go get golang.org/x/net/context
go get github.com/antihax/optional
Put the package under your project folder and add the following in import:
import "./client"
All URIs are relative to http://localhost
Class | Method | HTTP request | Description |
---|---|---|---|
BandwidthOptionApi | ListAllBandwidthForUplink | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/uplink_models/{uplink_model_id}/bandwidth | List all bandwidth for uplink |
BandwidthOptionApi | RetrieveAnExistingBandwidth | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/uplink_models/{uplink_model_id}/bandwidth/{bandwidth_id} | Retrieve an existing bandwidth |
CloudCredentialsApi | ShowCloudCredentialsToOpenstack | Get /v1/cloud_computing/regions/{region_id}/credentials | Show cloud credentials to OpenStack |
CloudFlavorApi | ListCloudFlavors | Get /v1/cloud_computing/regions/{region_id}/flavors | List cloud flavors |
CloudImageApi | ListCloudImages | Get /v1/cloud_computing/regions/{region_id}/images | List cloud images |
CloudInstanceApi | ApproveInstanceUpgrade | Post /v1/cloud_computing/instances/{instance_id}/approve_upgrade | Approve instance upgrade |
CloudInstanceApi | CreateANewCloudInstance | Post /v1/cloud_computing/instances | Create a new cloud instance |
CloudInstanceApi | CreatePtrForInstance | Post /v1/cloud_computing/instances/{instance_id}/ptr_records | Create PTR for instance |
CloudInstanceApi | DeleteInstance | Delete /v1/cloud_computing/instances/{instance_id} | Delete instance |
CloudInstanceApi | DetetePtrForInstance | Delete /v1/cloud_computing/instances/{instance_id}/ptr_records/{record_id} | Detete PTR for instance |
CloudInstanceApi | ExitFromRescueState | Post /v1/cloud_computing/instances/{instance_id}/unrescue | Exit from rescue state |
CloudInstanceApi | ListCloudInstances | Get /v1/cloud_computing/instances | List cloud instances |
CloudInstanceApi | MoveInstanceToRescueState | Post /v1/cloud_computing/instances/{instance_id}/rescue | Move instance to rescue state |
CloudInstanceApi | ReinstallInstanceWithImage | Post /v1/cloud_computing/instances/{instance_id}/reinstall | Reinstall instance with image |
CloudInstanceApi | ReturnsInstancePtrRecords | Get /v1/cloud_computing/instances/{instance_id}/ptr_records | Returns instance PTR records |
CloudInstanceApi | RevertInstanceUpgrade | Post /v1/cloud_computing/instances/{instance_id}/revert_upgrade | Revert instance upgrade |
CloudInstanceApi | ShowCloudInstance | Get /v1/cloud_computing/instances/{instance_id} | Show cloud instance |
CloudInstanceApi | SwitchPowerOff | Post /v1/cloud_computing/instances/{instance_id}/switch_off | Switch power off |
CloudInstanceApi | SwitchPowerOn | Post /v1/cloud_computing/instances/{instance_id}/switch_on | Switch power on |
CloudInstanceApi | UpdateCloudInstance | Put /v1/cloud_computing/instances/{instance_id} | Update cloud instance |
CloudInstanceApi | UpgradeInstance | Post /v1/cloud_computing/instances/{instance_id}/upgrade | Upgrade instance |
CloudRegionApi | ListCloudRegions | Get /v1/cloud_computing/regions | List cloud regions |
CloudSnapshotsApi | CreateInstanceSnapshots | Post /v1/cloud_computing/regions/{region_id}/snapshots | Create instance snapshots |
CloudSnapshotsApi | DeleteSnapshot | Delete /v1/cloud_computing/regions/{region_id}/snapshots/{snapshot_id} | Delete snapshot |
CloudSnapshotsApi | ListCloudSnapshots | Get /v1/cloud_computing/regions/{region_id}/snapshots | List cloud snapshots |
DedicatedServerApi | AbortReleaseForAnExistingDedicatedServer | Post /v1/hosts/dedicated_servers/{server_id}/abort_release | Abort release for an existing dedicated server |
DedicatedServerApi | CreateANewDedicatedServer | Post /v1/hosts/dedicated_servers | Create a new dedicated server |
DedicatedServerApi | CreatePtrRecordForServerNetworks | Post /v1/hosts/dedicated_servers/{server_id}/ptr_records | Create PTR record for server networks |
DedicatedServerApi | DeleteAnExistingPtrRecord | Delete /v1/hosts/dedicated_servers/{server_id}/ptr_records/{record_id} | Delete an existing PTR record |
DedicatedServerApi | ListAllConnectionsForAnExistingDedicatedServer | Get /v1/hosts/dedicated_servers/{lease_id}/connections | List all connections for an existing dedicated server |
DedicatedServerApi | ListAllNetworksForAnExistingDedicatedServer | Get /v1/hosts/dedicated_servers/{server_id}/networks | List all networks for an existing dedicated server |
DedicatedServerApi | ListAllPowerFeedsForAnExistingDedicatedServer | Get /v1/hosts/dedicated_servers/{server_id}/power_feeds | List all power feeds for an existing dedicated server |
DedicatedServerApi | ListAllPtrRecordsForServerNetworks | Get /v1/hosts/dedicated_servers/{server_id}/ptr_records | List all PTR records for server networks |
DedicatedServerApi | RetrieveAnExistingDedicatedServer | Get /v1/hosts/dedicated_servers/{server_id} | Retrieve an existing dedicated server |
DedicatedServerApi | ScheduleReleaseForAnExistingDedicatedServer | Post /v1/hosts/dedicated_servers/{server_id}/schedule_release | Schedule release for an existing dedicated server |
DriveModelOptionApi | ListAllDriveModelsOptionsForServerModel | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/drive_models | List all drive models options for server model |
DriveModelOptionApi | RetrieveAnExistingDriveModelOption | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/drive_models/{drive_model_id} | Retrieve an existing drive model option |
HostsApi | ListAllHosts | Get /v1/hosts | List all hosts |
KubernetesBaremetalNodeApi | ListAllNetworksForAnExistingKubernetesBaremetalNode | Get /v1/hosts/kubernetes_baremetal_nodes/{server_id}/networks | List all networks for an existing kubernetes baremetal node |
KubernetesBaremetalNodeApi | ListAllPowerFeedsForAnExistingKubernetesBaremetalNode | Get /v1/hosts/kubernetes_baremetal_nodes/{server_id}/power_feeds | List all power feeds for an existing kubernetes baremetal node |
KubernetesBaremetalNodeApi | RetrieveAnExistingKubernetesBaremetalNode | Get /v1/hosts/kubernetes_baremetal_nodes/{server_id} | Retrieve an existing kubernetes baremetal node |
L2SegmentApi | CreateANewL2Segment | Post /v1/l2_segments | Create a new L2 segment |
L2SegmentApi | DeleteAnExistingL2Segment | Delete /v1/l2_segments/{l2_segment_id} | Delete an existing L2 segment |
L2SegmentApi | ListAllL2SegmentMembers | Get /v1/l2_segments/{l2_segment_id}/members | List all L2 segment members |
L2SegmentApi | ListAllL2SegmentNetworks | Get /v1/l2_segments/{l2_segment_id}/networks | List all l2 segment networks |
L2SegmentApi | ListAllL2Segments | Get /v1/l2_segments | List all L2 segments |
L2SegmentApi | ListAllLocationGroups | Get /v1/l2_segments/location_groups | List all Location groups |
L2SegmentApi | RetrieveAnExistingL2Segment | Get /v1/l2_segments/{l2_segment_id} | Retrieve an existing L2 segment |
L2SegmentApi | UpdateAnExistingL2Segment | Put /v1/l2_segments/{l2_segment_id} | Update an existing L2 segment |
L2SegmentApi | UpdateAnExistingL2SegmentNetworks | Put /v1/l2_segments/{l2_segment_id}/networks | Update an existing L2 segment networks |
LocationApi | Locations | Get /v1/locations | Locations |
LocationApi | RetrieveAnExisitingLocation | Get /v1/locations/{location_id} | Retrieve an exisiting location |
OperatingSystemOptionApi | ListAllOperatingSystemsForServerModel | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/operating_systems | List all operating systems for server model |
OperatingSystemOptionApi | RetrieveAnExstingOperatingSystem | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/operating_systems/{operating_system_id} | Retrieve an exsting operating system |
RamOptionApi | ListAllAvailableRamOptionsForServerModel | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/ram | List all available ram options for server model |
SSHKeyApi | AddNewSshKey | Post /v1/ssh_keys | Add new ssh key |
SSHKeyApi | DeleteSshKey | Delete /v1/ssh_keys/{fingerprint} | Delete ssh key |
SSHKeyApi | ListAllSshKeys | Get /v1/ssh_keys | List all ssh keys |
SSHKeyApi | ShowSshKey | Get /v1/ssh_keys/{fingerprint} | Show ssh key |
SSHKeyApi | UpdateTheNameOfSshKey | Put /v1/ssh_keys/{fingerprint} | Update the name of ssh key |
SSLCertificateApi | CreateANewCustomSslCertificate | Post /v1/ssl_certificates/custom | Create a new custom SSL certificate |
SSLCertificateApi | RetrieveAnExistingCustomSslCertificate | Get /v1/ssl_certificates/custom/{id} | Retrieve an existing custom ssl certificate |
SSLCertificateApi | SSLCertificates | Get /v1/ssl_certificates | SSL Certificates |
ServerModelOptionApi | ListAllServerModelsForLocation | Get /v1/locations/{location_id}/order_options/server_models | List all server models for location |
ServerModelOptionApi | RetrieveAnExistingServerModel | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id} | Retrieve an existing server model |
UplinkModelOptionApi | ListAllUplinksForServerModel | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/uplink_models | List all uplinks for server model |
UplinkModelOptionApi | RetrieveAnExistingUplink | Get /v1/locations/{location_id}/order_options/server_models/{server_model_id}/uplink_models/{uplink_model_id} | Retrieve an existing uplink |
- Connection
- DriveSlot
- InlineObject
- InlineObject1
- InlineObject2
- InlineObject3
- InlineObject4
- InlineObject5
- InlineResponse200
- InlineResponse404
- Network
- PowerFeed
- TheDedicatedServerEntitySchema
- TheItemsSchema
- TheItemsSchema1
- TheItemsSchema10
- TheItemsSchema2
- TheItemsSchema3
- TheItemsSchema4
- TheItemsSchema5
- TheItemsSchema6
- TheItemsSchema7
- TheItemsSchema8
- TheItemsSchema9
- TheKubernetesBaremetalNodeEntitySchema
- TheRootSchema
- TheRootSchema1
- TheSshKeySchema
- V1HostsDedicatedServersDrives
- V1HostsDedicatedServersDrivesLayout
- V1HostsDedicatedServersDrivesPartitions
- V1HostsDedicatedServersDrivesSlots
- V1HostsDedicatedServersEntity
- V1HostsDedicatedServersHosts
- V1HostsDedicatedServersShortEntity
- V1HostsDedicatedServersUplinkModels
- V1HostsDedicatedServersUplinkModelsPrivate
- V1HostsDedicatedServersUplinkModelsPublic
- V1HostsKubernetesBaremetalNodeEntity
- V1L2SegmentsL2LocationGroup
- V1L2SegmentsL2Member
- V1L2SegmentsL2Network
- V1L2SegmentsL2Segment
- V1L2SegmentsL2SegmentDetailed
- V1L2SegmentsL2SegmentIdNetworksCreate
- V1L2SegmentsMembers
- V1OrderOptionsBandwidthBase
- V1OrderOptionsDriveModelsBase
- V1OrderOptionsOperatingSystemsBase
- V1OrderOptionsUplinkModelsBase
- Type: HTTP basic authentication
Example
auth := context.WithValue(context.Background(), sw.ContextBasicAuth, sw.BasicAuth{
UserName: "username",
Password: "password",
})
r, err := client.Service.Operation(auth, args)