All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.camunda.community.rest.client.api.TelemetryApi Maven / Gradle / Ivy

The newest version!
/*
 * Camunda Platform REST API
 * OpenApi Spec for Camunda Platform REST API.
 *
 * The version of the OpenAPI document: 7.21.0
 * 
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */

package org.camunda.community.rest.client.api;

import com.fasterxml.jackson.core.type.TypeReference;

import org.camunda.community.rest.client.invoker.ApiException;
import org.camunda.community.rest.client.invoker.ApiClient;
import org.camunda.community.rest.client.invoker.Configuration;
import org.camunda.community.rest.client.invoker.Pair;

import org.camunda.community.rest.client.dto.ExceptionDto;
import org.camunda.community.rest.client.dto.TelemetryConfigurationDto;
import org.camunda.community.rest.client.dto.TelemetryDataDto;


import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.StringJoiner;

@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2024-06-27T13:50:23.655629899Z[Etc/UTC]")
public class TelemetryApi {


  private ApiClient apiClient;

  public TelemetryApi() {
    this(Configuration.getDefaultApiClient());
  }

  public TelemetryApi(ApiClient apiClient) {
    this.apiClient = apiClient;
  }

  public ApiClient getApiClient() {
    return apiClient;
  }

  public void setApiClient(ApiClient apiClient) {
    this.apiClient = apiClient;
  }

  /**
   * Configure Telemetry
   * Configures whether Camunda receives data collection of the process engine setup and usage.
   * @param telemetryConfigurationDto  (optional)
   * @throws ApiException if fails to make API call
   */
  public void configureTelemetry(TelemetryConfigurationDto telemetryConfigurationDto) throws ApiException {
    this.configureTelemetry(telemetryConfigurationDto, Collections.emptyMap());
  }


  /**
   * Configure Telemetry
   * Configures whether Camunda receives data collection of the process engine setup and usage.
   * @param telemetryConfigurationDto  (optional)
   * @param additionalHeaders additionalHeaders for this call
   * @throws ApiException if fails to make API call
   */
  public void configureTelemetry(TelemetryConfigurationDto telemetryConfigurationDto, Map additionalHeaders) throws ApiException {
    Object localVarPostBody = telemetryConfigurationDto;
    
    // create path and map variables
    String localVarPath = "/telemetry/configuration";

    StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
    String localVarQueryParameterBaseName;
    List localVarQueryParams = new ArrayList();
    List localVarCollectionQueryParams = new ArrayList();
    Map localVarHeaderParams = new HashMap();
    Map localVarCookieParams = new HashMap();
    Map localVarFormParams = new HashMap();

    
    localVarHeaderParams.putAll(additionalHeaders);

    
    
    final String[] localVarAccepts = {
      "application/json"
    };
    final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);

    final String[] localVarContentTypes = {
      "application/json"
    };
    final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);

    String[] localVarAuthNames = new String[] { "basicAuth" };

    apiClient.invokeAPI(
        localVarPath,
        "POST",
        localVarQueryParams,
        localVarCollectionQueryParams,
        localVarQueryStringJoiner.toString(),
        localVarPostBody,
        localVarHeaderParams,
        localVarCookieParams,
        localVarFormParams,
        localVarAccept,
        localVarContentType,
        localVarAuthNames,
        null
    );
  }

  /**
   * Fetch Telemetry Configuration
   * Fetches Telemetry Configuration.
   * @return TelemetryConfigurationDto
   * @throws ApiException if fails to make API call
   */
  public TelemetryConfigurationDto getTelemetryConfiguration() throws ApiException {
    return this.getTelemetryConfiguration(Collections.emptyMap());
  }


  /**
   * Fetch Telemetry Configuration
   * Fetches Telemetry Configuration.
   * @param additionalHeaders additionalHeaders for this call
   * @return TelemetryConfigurationDto
   * @throws ApiException if fails to make API call
   */
  public TelemetryConfigurationDto getTelemetryConfiguration(Map additionalHeaders) throws ApiException {
    Object localVarPostBody = null;
    
    // create path and map variables
    String localVarPath = "/telemetry/configuration";

    StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
    String localVarQueryParameterBaseName;
    List localVarQueryParams = new ArrayList();
    List localVarCollectionQueryParams = new ArrayList();
    Map localVarHeaderParams = new HashMap();
    Map localVarCookieParams = new HashMap();
    Map localVarFormParams = new HashMap();

    
    localVarHeaderParams.putAll(additionalHeaders);

    
    
    final String[] localVarAccepts = {
      "application/json"
    };
    final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);

    final String[] localVarContentTypes = {
      
    };
    final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);

    String[] localVarAuthNames = new String[] { "basicAuth" };

    TypeReference localVarReturnType = new TypeReference() {};
    return apiClient.invokeAPI(
        localVarPath,
        "GET",
        localVarQueryParams,
        localVarCollectionQueryParams,
        localVarQueryStringJoiner.toString(),
        localVarPostBody,
        localVarHeaderParams,
        localVarCookieParams,
        localVarFormParams,
        localVarAccept,
        localVarContentType,
        localVarAuthNames,
        localVarReturnType
    );
  }

  /**
   * Fetch Telemetry Data
   * Fetches Telemetry Data.
   * @return TelemetryDataDto
   * @throws ApiException if fails to make API call
   */
  public TelemetryDataDto getTelemetryData() throws ApiException {
    return this.getTelemetryData(Collections.emptyMap());
  }


  /**
   * Fetch Telemetry Data
   * Fetches Telemetry Data.
   * @param additionalHeaders additionalHeaders for this call
   * @return TelemetryDataDto
   * @throws ApiException if fails to make API call
   */
  public TelemetryDataDto getTelemetryData(Map additionalHeaders) throws ApiException {
    Object localVarPostBody = null;
    
    // create path and map variables
    String localVarPath = "/telemetry/data";

    StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
    String localVarQueryParameterBaseName;
    List localVarQueryParams = new ArrayList();
    List localVarCollectionQueryParams = new ArrayList();
    Map localVarHeaderParams = new HashMap();
    Map localVarCookieParams = new HashMap();
    Map localVarFormParams = new HashMap();

    
    localVarHeaderParams.putAll(additionalHeaders);

    
    
    final String[] localVarAccepts = {
      "application/json"
    };
    final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);

    final String[] localVarContentTypes = {
      
    };
    final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);

    String[] localVarAuthNames = new String[] { "basicAuth" };

    TypeReference localVarReturnType = new TypeReference() {};
    return apiClient.invokeAPI(
        localVarPath,
        "GET",
        localVarQueryParams,
        localVarCollectionQueryParams,
        localVarQueryStringJoiner.toString(),
        localVarPostBody,
        localVarHeaderParams,
        localVarCookieParams,
        localVarFormParams,
        localVarAccept,
        localVarContentType,
        localVarAuthNames,
        localVarReturnType
    );
  }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy