Models

LabelApi

LabelApi

All URIs are relative to https://api.ionos.com/cloudapi/v5

Method

HTTP request

Description

datacentersLabelsDelete

DELETE /datacenters/{datacenterId}/labels/{key}

Delete a Label from Data Center

datacentersLabelsFindByKey

GET /datacenters/{datacenterId}/labels/{key}

Retrieve a Label of Data Center

datacentersLabelsGet

GET /datacenters/{datacenterId}/labels

List all Data Center Labels

datacentersLabelsPost

POST /datacenters/{datacenterId}/labels

Add a Label to Data Center

datacentersLabelsPut

PUT /datacenters/{datacenterId}/labels/{key}

Modify a Label of Data Center

datacentersServersLabelsDelete

DELETE /datacenters/{datacenterId}/servers/{serverId}/labels/{key}

Delete a Label from Server

datacentersServersLabelsFindByKey

GET /datacenters/{datacenterId}/servers/{serverId}/labels/{key}

Retrieve a Label of Server

datacentersServersLabelsGet

GET /datacenters/{datacenterId}/servers/{serverId}/labels

List all Server Labels

datacentersServersLabelsPost

POST /datacenters/{datacenterId}/servers/{serverId}/labels

Add a Label to Server

datacentersServersLabelsPut

PUT /datacenters/{datacenterId}/servers/{serverId}/labels/{key}

Modify a Label of Server

datacentersVolumesLabelsDelete

DELETE /datacenters/{datacenterId}/volumes/{volumeId}/labels/{key}

Delete a Label from Volume

datacentersVolumesLabelsFindByKey

GET /datacenters/{datacenterId}/volumes/{volumeId}/labels/{key}

Retrieve a Label of Volume

datacentersVolumesLabelsGet

GET /datacenters/{datacenterId}/volumes/{volumeId}/labels

List all Volume Labels

datacentersVolumesLabelsPost

POST /datacenters/{datacenterId}/volumes/{volumeId}/labels

Add a Label to Volume

datacentersVolumesLabelsPut

PUT /datacenters/{datacenterId}/volumes/{volumeId}/labels/{key}

Modify a Label of Volume

ipblocksLabelsDelete

DELETE /ipblocks/{ipblockId}/labels/{key}

Delete a Label from IP Block

ipblocksLabelsFindByKey

GET /ipblocks/{ipblockId}/labels/{key}

Retrieve a Label of IP Block

ipblocksLabelsGet

GET /ipblocks/{ipblockId}/labels

List all Ip Block Labels

ipblocksLabelsPost

POST /ipblocks/{ipblockId}/labels

Add a Label to IP Block

ipblocksLabelsPut

PUT /ipblocks/{ipblockId}/labels/{key}

Modify a Label of IP Block

labelsFindByUrn

GET /labels/{labelurn}

Returns the label by its URN.

labelsGet

GET /labels

List Labels

snapshotsLabelsDelete

DELETE /snapshots/{snapshotId}/labels/{key}

Delete a Label from Snapshot

snapshotsLabelsFindByKey

GET /snapshots/{snapshotId}/labels/{key}

Retrieve a Label of Snapshot

snapshotsLabelsGet

GET /snapshots/{snapshotId}/labels

List all Snapshot Labels

snapshotsLabelsPost

POST /snapshots/{snapshotId}/labels

Add a Label to Snapshot

snapshotsLabelsPut

PUT /snapshots/{snapshotId}/labels/{key}

Modify a Label of Snapshot

datacentersLabelsDelete

Object datacentersLabelsDelete(datacenterId, key, pretty, depth, xContractNumber)

Delete a Label from Data Center

This will remove a label from the data center.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Data Center
String key = "key_example"; // String | The key of the Label
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
Object result = apiInstance.datacentersLabelsDelete(datacenterId, key, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersLabelsDelete");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Data Center

key

String

The key of the Label

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

Object

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersLabelsFindByKey

LabelResource datacentersLabelsFindByKey(datacenterId, key, pretty, depth, xContractNumber)

Retrieve a Label of Data Center

This will retrieve the properties of a associated label to a data center.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Data Center
String key = "key_example"; // String | The key of the Label
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
LabelResource result = apiInstance.datacentersLabelsFindByKey(datacenterId, key, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersLabelsFindByKey");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Data Center

key

String

The key of the Label

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

LabelResource

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersLabelsGet

LabelResources datacentersLabelsGet(datacenterId, pretty, depth, xContractNumber, offset, limit)

List all Data Center Labels

You can retrieve a list of all labels associated with a data center

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Data Center
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
Integer offset = 0; // Integer | the first element (of the total list of elements) to include in the response (use together with <code>limit</code> for pagination)
Integer limit = 1000; // Integer | the maximum number of elements to return (use together with <code>offset</code> for pagination)
try {
LabelResources result = apiInstance.datacentersLabelsGet(datacenterId, pretty, depth, xContractNumber, offset, limit);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersLabelsGet");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Data Center

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

offset

Integer

the first element (of the total list of elements) to include in the response (use together with <code>limit</code> for pagination)

[optional] [default to 0]

limit

Integer

the maximum number of elements to return (use together with <code>offset</code> for pagination)

[optional] [default to 1000]

Return type

LabelResources

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersLabelsPost

LabelResource datacentersLabelsPost(datacenterId, label, pretty, depth, xContractNumber)

Add a Label to Data Center

This will add a label to the data center.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Data Center
LabelResource label = new LabelResource(); // LabelResource | Label to be added
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
LabelResource result = apiInstance.datacentersLabelsPost(datacenterId, label, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersLabelsPost");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Data Center

label

LabelResource

Label to be added

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

LabelResource

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

datacentersLabelsPut

LabelResource datacentersLabelsPut(datacenterId, key, label, pretty, depth, xContractNumber)

Modify a Label of Data Center

This will modify the value of the label on a data center.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Data Center
String key = "key_example"; // String | The key of the Label
LabelResource label = new LabelResource(); // LabelResource | Modified Label
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
LabelResource result = apiInstance.datacentersLabelsPut(datacenterId, key, label, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersLabelsPut");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Data Center

key

String

The key of the Label

label

LabelResource

Modified Label

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

LabelResource

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

datacentersServersLabelsDelete

Object datacentersServersLabelsDelete(datacenterId, serverId, key, pretty, depth, xContractNumber)

Delete a Label from Server

This will remove a label from the server.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Datacenter
String serverId = "serverId_example"; // String | The unique ID of the Server
String key = "key_example"; // String | The key of the Label
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
Object result = apiInstance.datacentersServersLabelsDelete(datacenterId, serverId, key, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersServersLabelsDelete");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Datacenter

serverId

String

The unique ID of the Server

key

String

The key of the Label

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

Object

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersServersLabelsFindByKey

LabelResource datacentersServersLabelsFindByKey(datacenterId, serverId, key, pretty, depth, xContractNumber)

Retrieve a Label of Server

This will retrieve the properties of a associated label to a server.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Datacenter
String serverId = "serverId_example"; // String | The unique ID of the Server
String key = "key_example"; // String | The key of the Label
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
LabelResource result = apiInstance.datacentersServersLabelsFindByKey(datacenterId, serverId, key, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersServersLabelsFindByKey");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Datacenter

serverId

String

The unique ID of the Server

key

String

The key of the Label

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

LabelResource

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersServersLabelsGet

LabelResources datacentersServersLabelsGet(datacenterId, serverId, pretty, depth, xContractNumber, offset, limit)

List all Server Labels

You can retrieve a list of all labels associated with a server

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Datacenter
String serverId = "serverId_example"; // String | The unique ID of the Server
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
Integer offset = 0; // Integer | the first element (of the total list of elements) to include in the response (use together with <code>limit</code> for pagination)
Integer limit = 1000; // Integer | the maximum number of elements to return (use together with <code>offset</code> for pagination)
try {
LabelResources result = apiInstance.datacentersServersLabelsGet(datacenterId, serverId, pretty, depth, xContractNumber, offset, limit);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersServersLabelsGet");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Datacenter

serverId

String

The unique ID of the Server

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

offset

Integer

the first element (of the total list of elements) to include in the response (use together with <code>limit</code> for pagination)

[optional] [default to 0]

limit

Integer

the maximum number of elements to return (use together with <code>offset</code> for pagination)

[optional] [default to 1000]

Return type

LabelResources

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersServersLabelsPost

LabelResource datacentersServersLabelsPost(datacenterId, serverId, label, pretty, depth, xContractNumber)

Add a Label to Server

This will add a label to the server.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Datacenter
String serverId = "serverId_example"; // String | The unique ID of the Server
LabelResource label = new LabelResource(); // LabelResource | Label to be added
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
LabelResource result = apiInstance.datacentersServersLabelsPost(datacenterId, serverId, label, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersServersLabelsPost");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Datacenter

serverId

String

The unique ID of the Server

label

LabelResource

Label to be added

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

LabelResource

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

datacentersServersLabelsPut

LabelResource datacentersServersLabelsPut(datacenterId, serverId, key, label, pretty, depth, xContractNumber)

Modify a Label of Server

This will modify the value of the label on a server.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Datacenter
String serverId = "serverId_example"; // String | The unique ID of the Server
String key = "key_example"; // String | The key of the Label
LabelResource label = new LabelResource(); // LabelResource | Modified Label
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
LabelResource result = apiInstance.datacentersServersLabelsPut(datacenterId, serverId, key, label, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersServersLabelsPut");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Datacenter

serverId

String

The unique ID of the Server

key

String

The key of the Label

label

LabelResource

Modified Label

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

LabelResource

HTTP request headers

  • Content-Type: application/json

  • Accept: application/json

datacentersVolumesLabelsDelete

Object datacentersVolumesLabelsDelete(datacenterId, volumeId, key, pretty, depth, xContractNumber)

Delete a Label from Volume

This will remove a label from the volume.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Datacenter
String volumeId = "volumeId_example"; // String | The unique ID of the Volume
String key = "key_example"; // String | The key of the Label
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
Object result = apiInstance.datacentersVolumesLabelsDelete(datacenterId, volumeId, key, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersVolumesLabelsDelete");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Datacenter

volumeId

String

The unique ID of the Volume

key

String

The key of the Label

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

Object

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersVolumesLabelsFindByKey

LabelResource datacentersVolumesLabelsFindByKey(datacenterId, volumeId, key, pretty, depth, xContractNumber)

Retrieve a Label of Volume

This will retrieve the properties of a associated label to a volume.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Datacenter
String volumeId = "volumeId_example"; // String | The unique ID of the Volume
String key = "key_example"; // String | The key of the Label
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
try {
LabelResource result = apiInstance.datacentersVolumesLabelsFindByKey(datacenterId, volumeId, key, pretty, depth, xContractNumber);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersVolumesLabelsFindByKey");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Datacenter

volumeId

String

The unique ID of the Volume

key

String

The key of the Label

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

Return type

LabelResource

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersVolumesLabelsGet

LabelResources datacentersVolumesLabelsGet(datacenterId, volumeId, pretty, depth, xContractNumber, offset, limit)

List all Volume Labels

You can retrieve a list of all labels associated with a volume

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: Basic Authentication
HttpBasicAuth basicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("Basic Authentication");
basicAuthentication.setUsername("YOUR USERNAME");
basicAuthentication.setPassword("YOUR PASSWORD");
LabelApi apiInstance = new LabelApi(defaultClient);
String datacenterId = "datacenterId_example"; // String | The unique ID of the Datacenter
String volumeId = "volumeId_example"; // String | The unique ID of the Volume
Boolean pretty = true; // Boolean | Controls whether response is pretty-printed (with indentation and new lines)
Integer depth = 0; // Integer | Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on
Integer xContractNumber = 56; // Integer | Users having more than 1 contract need to provide contract number, against which all API requests should be executed
Integer offset = 0; // Integer | the first element (of the total list of elements) to include in the response (use together with <code>limit</code> for pagination)
Integer limit = 1000; // Integer | the maximum number of elements to return (use together with <code>offset</code> for pagination)
try {
LabelResources result = apiInstance.datacentersVolumesLabelsGet(datacenterId, volumeId, pretty, depth, xContractNumber, offset, limit);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling LabelApi#datacentersVolumesLabelsGet");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}

Parameters

Name

Type

Description

Notes

datacenterId

String

The unique ID of the Datacenter

volumeId

String

The unique ID of the Volume

pretty

Boolean

Controls whether response is pretty-printed (with indentation and new lines)

[optional] [default to true]

depth

Integer

Controls the details depth of response objects. Eg. GET /datacenters/[ID] - depth=0: only direct properties are included. Children (servers etc.) are not included - depth=1: direct properties and children references are included - depth=2: direct properties and children properties are included - depth=3: direct properties and children properties and children's children are included - depth=... and so on

[optional] [default to 0]

xContractNumber

Integer

Users having more than 1 contract need to provide contract number, against which all API requests should be executed

[optional]

offset

Integer

the first element (of the total list of elements) to include in the response (use together with <code>limit</code> for pagination)

[optional] [default to 0]

limit

Integer

the maximum number of elements to return (use together with <code>offset</code> for pagination)

[optional] [default to 1000]

Return type

LabelResources

HTTP request headers

  • Content-Type: Not defined

  • Accept: application/json

datacentersVolumesLabelsPost

LabelResource datacentersVolumesLabelsPost(datacenterId, volumeId, label, pretty, depth, xContractNumber)

Add a Label to Volume

This will add a label to the volume.

Example

// Import classes:
import com.ionoscloud.ApiClient;
import com.ionoscloud.ApiException;
import com.ionoscloud.Configuration;
import com.ionoscloud.auth.*;
import com.ionoscloud.model.*;
import com.ionoscloud.api.LabelApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();