All URIs are relative to https://api.thousandeyes.com/v7
Method | HTTP request | Description |
---|---|---|
createDnsServerTest | POST /tests/dns-server | Create DNS Server test |
createDnsServerTestWithHttpInfo | POST /tests/dns-server | Create DNS Server test |
deleteDnsServerTest | DELETE /tests/dns-server/{testId} | Delete DNS Server test |
deleteDnsServerTestWithHttpInfo | DELETE /tests/dns-server/{testId} | Delete DNS Server test |
getDnsServerTest | GET /tests/dns-server/{testId} | Get DNS Server test |
getDnsServerTestWithHttpInfo | GET /tests/dns-server/{testId} | Get DNS Server test |
getDnsServerTests | GET /tests/dns-server | List DNS Server tests |
getDnsServerTestsWithHttpInfo | GET /tests/dns-server | List DNS Server tests |
updateDnsServerTest | PUT /tests/dns-server/{testId} | Update DNS Server test |
updateDnsServerTestWithHttpInfo | PUT /tests/dns-server/{testId} | Update DNS Server test |
DnsServerTestResponse createDnsServerTest(dnsServerTestRequest, aid, expand)
Create DNS Server test
Creates a new DNS Server test. This method requires Account Admin permissions.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
DnsServerTestRequest dnsServerTestRequest = new DnsServerTestRequest(); // DnsServerTestRequest |
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
List<ExpandTestOptions> expand = Arrays.asList(); // List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query.
try {
DnsServerTestResponse result = apiInstance.createDnsServerTest(dnsServerTestRequest, aid, expand);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#createDnsServerTest");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
dnsServerTestRequest | DnsServerTestRequest | ||
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
expand | List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query. | [optional] |
- Content-Type: application/json
- Accept: application/hal+json, application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
201 | Created | * Location - |
400 | Bad Request | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
ApiResponse createDnsServerTest createDnsServerTestWithHttpInfo(dnsServerTestRequest, aid, expand)
Create DNS Server test
Creates a new DNS Server test. This method requires Account Admin permissions.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.common.ApiResponse;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
DnsServerTestRequest dnsServerTestRequest = new DnsServerTestRequest(); // DnsServerTestRequest |
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
List<ExpandTestOptions> expand = Arrays.asList(); // List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query.
try {
ApiResponse<DnsServerTestResponse> response = apiInstance.createDnsServerTestWithHttpInfo(dnsServerTestRequest, aid, expand);
System.out.println("Status code: " + response.getStatusCode());
System.out.println("Response headers: " + response.getHeaders());
System.out.println("Response body: " + response.getData());
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#createDnsServerTest");
System.err.println("Status code: " + e.getCode());
System.err.println("Response headers: " + e.getResponseHeaders());
System.err.println("Reason: " + e.getResponseBody());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
dnsServerTestRequest | DnsServerTestRequest | ||
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
expand | List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query. | [optional] |
ApiResponse<DnsServerTestResponse>
- Content-Type: application/json
- Accept: application/hal+json, application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
201 | Created | * Location - |
400 | Bad Request | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
void deleteDnsServerTest(testId, aid)
Delete DNS Server test
Deletes the specified DNS Server test. This method requires Account Admin permissions.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
String testId = "202701"; // String | Test ID
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
try {
apiInstance.deleteDnsServerTest(testId, aid);
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#deleteDnsServerTest");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
testId | String | Test ID | |
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
null (empty response body)
- Content-Type: Not defined
- Accept: application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
204 | No content | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
ApiResponse deleteDnsServerTest deleteDnsServerTestWithHttpInfo(testId, aid)
Delete DNS Server test
Deletes the specified DNS Server test. This method requires Account Admin permissions.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.common.ApiResponse;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
String testId = "202701"; // String | Test ID
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
try {
ApiResponse<Void> response = apiInstance.deleteDnsServerTestWithHttpInfo(testId, aid);
System.out.println("Status code: " + response.getStatusCode());
System.out.println("Response headers: " + response.getHeaders());
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#deleteDnsServerTest");
System.err.println("Status code: " + e.getCode());
System.err.println("Response headers: " + e.getResponseHeaders());
System.err.println("Reason: " + e.getResponseBody());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
testId | String | Test ID | |
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
ApiResponse
- Content-Type: Not defined
- Accept: application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
204 | No content | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
DnsServerTestResponse getDnsServerTest(testId, aid, expand)
Get DNS Server test
Returns details for a DNS Server test, including name, intervals, targets, alert rules and agents.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
String testId = "202701"; // String | Test ID
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
List<ExpandTestOptions> expand = Arrays.asList(); // List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query.
try {
DnsServerTestResponse result = apiInstance.getDnsServerTest(testId, aid, expand);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#getDnsServerTest");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
testId | String | Test ID | |
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
expand | List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query. | [optional] |
- Content-Type: Not defined
- Accept: application/hal+json, application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
ApiResponse getDnsServerTest getDnsServerTestWithHttpInfo(testId, aid, expand)
Get DNS Server test
Returns details for a DNS Server test, including name, intervals, targets, alert rules and agents.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.common.ApiResponse;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
String testId = "202701"; // String | Test ID
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
List<ExpandTestOptions> expand = Arrays.asList(); // List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query.
try {
ApiResponse<DnsServerTestResponse> response = apiInstance.getDnsServerTestWithHttpInfo(testId, aid, expand);
System.out.println("Status code: " + response.getStatusCode());
System.out.println("Response headers: " + response.getHeaders());
System.out.println("Response body: " + response.getData());
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#getDnsServerTest");
System.err.println("Status code: " + e.getCode());
System.err.println("Response headers: " + e.getResponseHeaders());
System.err.println("Reason: " + e.getResponseBody());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
testId | String | Test ID | |
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
expand | List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query. | [optional] |
ApiResponse<DnsServerTestResponse>
- Content-Type: Not defined
- Accept: application/hal+json, application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
DnsServerTests getDnsServerTests(aid)
List DNS Server tests
Returns a list of all DNS Server tests and saved events.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
try {
DnsServerTests result = apiInstance.getDnsServerTests(aid);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#getDnsServerTests");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
- Content-Type: Not defined
- Accept: application/hal+json, application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
ApiResponse getDnsServerTests getDnsServerTestsWithHttpInfo(aid)
List DNS Server tests
Returns a list of all DNS Server tests and saved events.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.common.ApiResponse;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
try {
ApiResponse<DnsServerTests> response = apiInstance.getDnsServerTestsWithHttpInfo(aid);
System.out.println("Status code: " + response.getStatusCode());
System.out.println("Response headers: " + response.getHeaders());
System.out.println("Response body: " + response.getData());
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#getDnsServerTests");
System.err.println("Status code: " + e.getCode());
System.err.println("Response headers: " + e.getResponseHeaders());
System.err.println("Reason: " + e.getResponseBody());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
ApiResponse<DnsServerTests>
- Content-Type: Not defined
- Accept: application/hal+json, application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
DnsServerTestResponse updateDnsServerTest(testId, dnsServerTestRequest, aid, expand)
Update DNS Server test
Updates a DNS Server test. The target test cannot be a live share or saved event. This method requires Account Admin permissions.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
String testId = "202701"; // String | Test ID
DnsServerTestRequest dnsServerTestRequest = new DnsServerTestRequest(); // DnsServerTestRequest |
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
List<ExpandTestOptions> expand = Arrays.asList(); // List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query.
try {
DnsServerTestResponse result = apiInstance.updateDnsServerTest(testId, dnsServerTestRequest, aid, expand);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#updateDnsServerTest");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
testId | String | Test ID | |
dnsServerTestRequest | DnsServerTestRequest | ||
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
expand | List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query. | [optional] |
- Content-Type: application/json
- Accept: application/hal+json, application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
400 | Bad Request | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |
ApiResponse updateDnsServerTest updateDnsServerTestWithHttpInfo(testId, dnsServerTestRequest, aid, expand)
Update DNS Server test
Updates a DNS Server test. The target test cannot be a live share or saved event. This method requires Account Admin permissions.
// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.common.ApiResponse;
import com.thousandeyes.sdk.Configuration;
import com.thousandeyes.sdk.authentication.*;
import com.thousandeyes.sdk.models.*;
import com.thousandeyes.sdk.tests.DnsServerTestsApi;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://api.thousandeyes.com/v7");
// Configure HTTP bearer authorization: BearerAuth
HttpBearerAuth BearerAuth = (HttpBearerAuth) defaultClient.getAuthentication("BearerAuth");
BearerAuth.setBearerToken("BEARER TOKEN");
DnsServerTestsApi apiInstance = new DnsServerTestsApi(defaultClient);
String testId = "202701"; // String | Test ID
DnsServerTestRequest dnsServerTestRequest = new DnsServerTestRequest(); // DnsServerTestRequest |
String aid = "1234"; // String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response.
List<ExpandTestOptions> expand = Arrays.asList(); // List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query.
try {
ApiResponse<DnsServerTestResponse> response = apiInstance.updateDnsServerTestWithHttpInfo(testId, dnsServerTestRequest, aid, expand);
System.out.println("Status code: " + response.getStatusCode());
System.out.println("Response headers: " + response.getHeaders());
System.out.println("Response body: " + response.getData());
} catch (ApiException e) {
System.err.println("Exception when calling DnsServerTestsApi#updateDnsServerTest");
System.err.println("Status code: " + e.getCode());
System.err.println("Response headers: " + e.getResponseHeaders());
System.err.println("Reason: " + e.getResponseBody());
e.printStackTrace();
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
testId | String | Test ID | |
dnsServerTestRequest | DnsServerTestRequest | ||
aid | String | A unique identifier associated with your account group. You can retrieve your `AccountGroupId` from the `/account-groups` endpoint. Note that you must be assigned to the target account group. Specifying this parameter without being assigned to the target account group will result in an error response. | [optional] |
expand | List<ExpandTestOptions> | Optional parameter on whether or not to expand the test sub-resources. By default no expansion is going to take place if the query parameter is not present. If the user wishes to expand the `agents` sub-resource, they need to pass the `?expand=agent` query. | [optional] |
ApiResponse<DnsServerTestResponse>
- Content-Type: application/json
- Accept: application/hal+json, application/json, application/problem+json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
400 | Bad Request | - |
401 | Unauthorized | - |
403 | Insufficient permissions to query endpoint | - |
404 | Not found | - |
429 | Exhausted rate limit for the organization | - |
500 | Internal server error | - |
502 | Bad Gateway | - |
0 | An error occurred | - |