Skip to content

Latest commit

 

History

History
178 lines (133 loc) · 8.83 KB

SipServerInstantTestsApi.md

File metadata and controls

178 lines (133 loc) · 8.83 KB

SipServerInstantTestsApi

All URIs are relative to https://api.thousandeyes.com/v7

Method HTTP request Description
createSipServerInstantTest POST /tests/sip-server/instant Create SIP server instant test
createSipServerInstantTestWithHttpInfo POST /tests/sip-server/instant Create SIP server instant test

createSipServerInstantTest

SipServerInstantTestResponse createSipServerInstantTest(sipServerInstantTestRequest, aid, expand)

Create SIP server instant test

Creates and runs a new SIP server instant test.

Example

// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.tests.Configuration;
import com.thousandeyes.sdk.tests.authentication.*;
import com.thousandeyes.sdk.tests.models.*;
import com.thousandeyes.sdk.tests.instant.SipServerInstantTestsApi;

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");

        SipServerInstantTestsApi apiInstance = new SipServerInstantTestsApi(defaultClient);
        SipServerInstantTestRequest sipServerInstantTestRequest = new SipServerInstantTestRequest(); // SipServerInstantTestRequest | 
        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 {
            SipServerInstantTestResponse result = apiInstance.createSipServerInstantTest(sipServerInstantTestRequest, aid, expand);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling SipServerInstantTestsApi#createSipServerInstantTest");
            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
sipServerInstantTestRequest SipServerInstantTestRequest
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<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`. [optional]

Return type

SipServerInstantTestResponse

Authorization

BearerAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/hal+json, application/json, application/problem+json

HTTP response details

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 -

createSipServerInstantTestWithHttpInfo

ApiResponse createSipServerInstantTest createSipServerInstantTestWithHttpInfo(sipServerInstantTestRequest, aid, expand)

Create SIP server instant test

Creates and runs a new SIP server instant test.

Example

// Import classes:
import com.thousandeyes.sdk.client.ApiClient;
import com.thousandeyes.sdk.common.ApiException;
import com.thousandeyes.sdk.common.ApiResponse;
import com.thousandeyes.sdk.tests.Configuration;
import com.thousandeyes.sdk.tests.authentication.*;
import com.thousandeyes.sdk.tests.models.*;
import com.thousandeyes.sdk.tests.instant.SipServerInstantTestsApi;

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");

        SipServerInstantTestsApi apiInstance = new SipServerInstantTestsApi(defaultClient);
        SipServerInstantTestRequest sipServerInstantTestRequest = new SipServerInstantTestRequest(); // SipServerInstantTestRequest | 
        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 {
            ApiResponse<SipServerInstantTestResponse> response = apiInstance.createSipServerInstantTestWithHttpInfo(sipServerInstantTestRequest, 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 SipServerInstantTestsApi#createSipServerInstantTest");
            System.err.println("Status code: " + e.getCode());
            System.err.println("Response headers: " + e.getResponseHeaders());
            System.err.println("Reason: " + e.getResponseBody());
            e.printStackTrace();
        }
    }
}

Parameters

Name Type Description Notes
sipServerInstantTestRequest SipServerInstantTestRequest
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<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`. [optional]

Return type

ApiResponse<SipServerInstantTestResponse>

Authorization

BearerAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/hal+json, application/json, application/problem+json

HTTP response details

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 -