Endpoint Agents API
- API version: 7.0.34
Manage ThousandEyes Endpoint Agents using this API.
For more information about Endpoint Agents, see Endpoint Agents.
Automatically generated by the OpenAPI Generator
Building the API client library requires:
- Java 11+
- Maven/Gradle
To install the API client library to your local Maven repository, simply execute:
mvn clean install
To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
mvn clean deploy
Refer to the OSSRH Guide for more information.
Add this dependency to your project's POM:
<dependencies>
<dependency>
<groupId>com.thousandeyes.sdk</groupId>
<artifactId>endpoint-agents</artifactId>
<version>version</version>
</dependency>
<dependency>
<groupId>com.thousandeyes.sdk</groupId>
<artifactId>client</artifactId>
<version>version</version>
</dependency>
<!-- Example only, you can use your own client implementation -->
<dependency>
<groupId>com.thousandeyes.sdk</groupId>
<artifactId>client-native</artifactId>
<version>version</version>
</dependency>
</dependencies>
Add this dependency to your project's build file:
implementation "com.thousandeyes.sdk:client:<version>"
implementation "com.thousandeyes.sdk:client-native:<version>" #Example only, you can use your own client implementation
implementation "com.thousandeyes.sdk:endpoint-agents:<version>"
At first generate the JAR by executing:
mvn clean package
Then manually install the following JARs:
target/endpoint-agents-version.jar
target/lib/*.jar
Please follow the installation instruction and execute the following Java code:
import com.thousandeyes.sdk.endpoint.*;
import com.thousandeyes.sdk.endpoint.client.*;
import com.thousandeyes.sdk.endpoint.agents.model.*;
import com.thousandeyes.sdk.endpoint.agents.EndpointAgentsApi;
public class EndpointAgentsApiExample {
public static void main(String[] args) {
// Configure clients using the `defaultClient` object, such as
// overriding the host and port, timeout, etc. In this example we are using the NativeApiClient
// but you can use your own client implementation
ApiClient defaultClient = NativeApiClient
.builder()
.baseUri("https://api.thousandeyes.com/v7")
.bearerToken("<bearer-token>")
.build();
EndpointAgentsApi apiInstance = new EndpointAgentsApi(defaultClient);
UUID agentId = UUID.randomUUID(); // UUID | The identifier of the agent to operate on.
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<ExpandEndpointAgentOptions> expand = Arrays.asList(); // List<ExpandEndpointAgentOptions> | This optional parameter allows you to control the expansion of test resources associated with the agent. By default, no expansion occurs when this query parameter is omitted. To expand the \"clients\" resource, include the query parameter `?expand=clients`. For multiple expansions, you have two options: * Separate the values with commas. For example, `?expandAgent=clients,tasks`. * Specify the parameter multiple times. For example, `?expandAgent=clients&expandAgent=tasks`. This parameter offers flexibility for users to customize the expansion of specific resources related to the agent.
try {
apiInstance.deleteEndpointAgent(agentId, aid, expand);
} catch (ApiException e) {
System.err.println("Exception when calling EndpointAgentsApi#deleteEndpointAgent");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
All URIs are relative to https://api.thousandeyes.com/v7
Class | Method | HTTP request | Description |
---|---|---|---|
EndpointAgentsApi | deleteEndpointAgent | DELETE /endpoint/agents/{agentId} | Delete endpoint agent |
EndpointAgentsApi | deleteEndpointAgentWithHttpInfo | DELETE /endpoint/agents/{agentId} | Delete endpoint agent |
EndpointAgentsApi | disableEndpointAgent | POST /endpoint/agents/{agentId}/disable | Disable endpoint agent |
EndpointAgentsApi | disableEndpointAgentWithHttpInfo | POST /endpoint/agents/{agentId}/disable | Disable endpoint agent |
EndpointAgentsApi | enableEndpointAgent | POST /endpoint/agents/{agentId}/enable | Enable endpoint agent |
EndpointAgentsApi | enableEndpointAgentWithHttpInfo | POST /endpoint/agents/{agentId}/enable | Enable endpoint agent |
EndpointAgentsApi | filterEndpointAgents | POST /endpoint/agents/filter | Filter endpoint agents |
EndpointAgentsApi | filterEndpointAgentsWithHttpInfo | POST /endpoint/agents/filter | Filter endpoint agents |
EndpointAgentsApi | getEndpointAgent | GET /endpoint/agents/{agentId} | Retrieve endpoint agent |
EndpointAgentsApi | getEndpointAgentWithHttpInfo | GET /endpoint/agents/{agentId} | Retrieve endpoint agent |
EndpointAgentsApi | getEndpointAgents | GET /endpoint/agents | List endpoint agents |
EndpointAgentsApi | getEndpointAgentsWithHttpInfo | GET /endpoint/agents | List endpoint agents |
EndpointAgentsApi | getEndpointAgentsConnectionString | GET /endpoint/agents/connection-string | Get agent connection string |
EndpointAgentsApi | getEndpointAgentsConnectionStringWithHttpInfo | GET /endpoint/agents/connection-string | Get agent connection string |
EndpointAgentsApi | updateEndpointAgent | PATCH /endpoint/agents/{agentId} | Update endpoint agent |
EndpointAgentsApi | updateEndpointAgentWithHttpInfo | PATCH /endpoint/agents/{agentId} | Update endpoint agent |
EndpointAgentsTransferApi | transferEndpointAgent | POST /endpoint/agents/{agentId}/transfer | Transfer endpoint agent |
EndpointAgentsTransferApi | transferEndpointAgentWithHttpInfo | POST /endpoint/agents/{agentId}/transfer | Transfer endpoint agent |
EndpointAgentsTransferApi | transferEndpointAgents | POST /endpoint/agents/transfer/bulk | Bulk transfer agents |
EndpointAgentsTransferApi | transferEndpointAgentsWithHttpInfo | POST /endpoint/agents/transfer/bulk | Bulk transfer agents |
Authentication schemes defined for the API:
- Type: HTTP Bearer Token authentication
It's recommended to create an instance of ApiClient
per thread in a multithreaded environment to avoid any potential issues.
However, the instances of the api clients created from the ApiClient
are thread-safe and can be re-used.