Instant Tests API
- API version: 7.0.36
The Instant Tests API operations lets you create and run new instant tests. You will need to be a regular user or have the following permissions:
API Access
View tests
The response does not include the immediate test results. Use the Test Results endpoints to get test results after creating and executing an instant test. You can find the URLs for these endpoints in the _links section of the test definition that is returned when you create the instant test.
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>instant-tests</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:instant-tests:<version>"
At first generate the JAR by executing:
mvn clean package
Then manually install the following JARs:
target/instant-tests-version.jar
target/lib/*.jar
Please follow the installation instruction and execute the following Java code:
import com.thousandeyes.sdk.tests.*;
import com.thousandeyes.sdk.tests.client.*;
import com.thousandeyes.sdk.tests.instant.model.*;
import com.thousandeyes.sdk.tests.instant.AgentToAgentInstantTestsApi;
public class AgentToAgentInstantTestsApiExample {
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();
AgentToAgentInstantTestsApi apiInstance = new AgentToAgentInstantTestsApi(defaultClient);
AgentToAgentInstantTestRequest agentToAgentInstantTestRequest = new AgentToAgentInstantTestRequest(); // AgentToAgentInstantTestRequest |
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<ExpandInstantTestOptions> expand = Arrays.asList(); // List<ExpandInstantTestOptions> | (Optional) Indicates if the test sub-resources should be expanded. Defaults to no expansion. To expand the `agents` sub-resource, use the query `?expand=agent`.
try {
AgentToAgentInstantTestResponse result = apiInstance.createAgentToAgentInstantTest(agentToAgentInstantTestRequest, aid, expand);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling AgentToAgentInstantTestsApi#createAgentToAgentInstantTest");
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 |
---|---|---|---|
AgentToAgentInstantTestsApi | createAgentToAgentInstantTest | POST /tests/agent-to-agent/instant | Create agent-to-agent instant test |
AgentToAgentInstantTestsApi | createAgentToAgentInstantTestWithHttpInfo | POST /tests/agent-to-agent/instant | Create agent-to-agent instant test |
AgentToServerInstantTestsApi | createAgentToServerInstantTest | POST /tests/agent-to-server/instant | Create agent-to-server instant test |
AgentToServerInstantTestsApi | createAgentToServerInstantTestWithHttpInfo | POST /tests/agent-to-server/instant | Create agent-to-server instant test |
ApiInstantTestsApi | createApiInstantTest | POST /tests/api/instant | Create API instant test |
ApiInstantTestsApi | createApiInstantTestWithHttpInfo | POST /tests/api/instant | Create API instant test |
DnsServerInstantTestsApi | createDnsServerInstantTest | POST /tests/dns-server/instant | Create DNS server instant test |
DnsServerInstantTestsApi | createDnsServerInstantTestWithHttpInfo | POST /tests/dns-server/instant | Create DNS server instant test |
DnsTraceInstantTestsApi | createDnsTraceInstantTest | POST /tests/dns-trace/instant | Create DNS trace instant test |
DnsTraceInstantTestsApi | createDnsTraceInstantTestWithHttpInfo | POST /tests/dns-trace/instant | Create DNS trace instant test |
DnssecInstantTestsApi | createDnsSecInstantTest | POST /tests/dnssec/instant | Create DNSSEC instant test |
DnssecInstantTestsApi | createDnsSecInstantTestWithHttpInfo | POST /tests/dnssec/instant | Create DNSSEC instant test |
FtpServerInstantTestsApi | createFtpServerInstantTest | POST /tests/ftp-server/instant | Create FTP server instant test |
FtpServerInstantTestsApi | createFtpServerInstantTestWithHttpInfo | POST /tests/ftp-server/instant | Create FTP server instant test |
HttpPageLoadInstantTestsApi | createPageLoadInstantTest | POST /tests/page-load/instant | Create HTTP page load instant test |
HttpPageLoadInstantTestsApi | createPageLoadInstantTestWithHttpInfo | POST /tests/page-load/instant | Create HTTP page load instant test |
HttpServerInstantTestsApi | createHttpServerInstantTest | POST /tests/http-server/instant | Create HTTP server instant test |
HttpServerInstantTestsApi | createHttpServerInstantTestWithHttpInfo | POST /tests/http-server/instant | Create HTTP server instant test |
InstantTestsApi | runInstantTest | POST /tests/{testId}/run | Run instant test |
InstantTestsApi | runInstantTestWithHttpInfo | POST /tests/{testId}/run | Run instant test |
SipServerInstantTestsApi | createSipServerInstantTest | POST /tests/sip-server/instant | Create SIP server instant test |
SipServerInstantTestsApi | createSipServerInstantTestWithHttpInfo | POST /tests/sip-server/instant | Create SIP server instant test |
VoiceInstantTestsApi | createVoiceInstantTest | POST /tests/voice/instant | Create voice instant test |
VoiceInstantTestsApi | createVoiceInstantTestWithHttpInfo | POST /tests/voice/instant | Create voice instant test |
WebTransactionInstantTestsApi | createWebTransactionInstantTest | POST /tests/web-transactions/instant | Create web transactions instant test |
WebTransactionInstantTestsApi | createWebTransactionInstantTestWithHttpInfo | POST /tests/web-transactions/instant | Create web transactions instant test |
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.