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

com.factset.sdk.FactSetFunds.api.HelperApi Maven / Gradle / Ivy

There is a newer version: 2.1.1
Show newest version
package com.factset.sdk.FactSetFunds.api;

import com.factset.sdk.FactSetFunds.ApiException;
import com.factset.sdk.FactSetFunds.ApiClient;
import com.factset.sdk.FactSetFunds.ApiResponse;
import com.factset.sdk.FactSetFunds.Configuration;
import com.factset.sdk.FactSetFunds.Pair;

import javax.ws.rs.core.GenericType;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;

import com.factset.sdk.FactSetFunds.models.ErrorResponse;
import com.factset.sdk.FactSetFunds.models.StatusesRequest;
import com.factset.sdk.FactSetFunds.models.StatusesResponse;

@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class HelperApi {
  private ApiClient apiClient;

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

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

    private static final Map getStatusesResponseTypeMap = new HashMap();
  static {
    getStatusesResponseTypeMap.put(200, new GenericType(){});
    getStatusesResponseTypeMap.put(400, new GenericType(){});
    getStatusesResponseTypeMap.put(401, new GenericType(){});
    getStatusesResponseTypeMap.put(403, new GenericType(){});
    getStatusesResponseTypeMap.put(415, new GenericType(){});
    getStatusesResponseTypeMap.put(500, new GenericType(){});
  }
  private static final Map getStatusesForListResponseTypeMap = new HashMap();
  static {
    getStatusesForListResponseTypeMap.put(200, new GenericType(){});
    getStatusesForListResponseTypeMap.put(400, new GenericType(){});
    getStatusesForListResponseTypeMap.put(401, new GenericType(){});
    getStatusesForListResponseTypeMap.put(403, new GenericType(){});
    getStatusesForListResponseTypeMap.put(415, new GenericType(){});
    getStatusesForListResponseTypeMap.put(500, new GenericType(){});
  }

   


  /**
   * Get the API client
   *
   * @return API client
   */
  public ApiClient getApiClient() {
    return apiClient;
  }

  /**
   * Set the API client
   *
   * @param apiClient an instance of API client
   */
  public void setApiClient(ApiClient apiClient) {
    this.apiClient = apiClient;
  }

  /**
   * Get Fund's current status and database availability
   * Get the funds active status, share class status, and database availability. Most common use is for coverage checks and id resolution checks. 
   * @param ids The requested fund identifier. FactSet Identifiers, tickers, CUSIP, SEDOL, and ISIN are accepted inputs. <p>***ids limit** =  1000 per request*</p> *<p>Make note, GET Method URL request lines are also limited to a total length of 8192 bytes (8KB). In cases where the service allows for thousands of ids, which may lead to exceeding this request line limit of 8KB, its advised for any requests with large request lines to be requested through the respective \"POST\" method.</p>*  (required)
   * @return StatusesResponse
   * @throws ApiException if fails to make API call
   * @http.response.details
     
Status Code Description Response Headers
200 The Statuses response object. -
400 Bad Request. This can occur for several reasons. Please review the \"message\" for more details. -
401 Unauthenticated USERNAME-SERIAL. Ensure you are logged in and have successfully generated an API KEY for the IP range you are connecting from. For more help, select the **Report Issue** in the top right corner of this Developer Portal specification card and choose Connectivity 401 or 403 Responses. -
403 The USERNAME-SERIAL attempted to request the endpoint is not authorized to access. The request was a legal request, but the server is refusing to respond. Please reach out to FactSet Account Team for assistance with authorization. -
415 Unsupported Media Type. This error may be returned when the caller sends a resource in a format that is not accepted by the server. This can be fixed by ensuring that Content-Type header is set to the correct value. In this instance, \"application/json\" would be the appropriate value. -
500 Internal Server Error. -
*/ public StatusesResponse getStatuses(java.util.List ids) throws ApiException { return getStatusesWithHttpInfo(ids).getData(); } /** * Get Fund's current status and database availability * Get the funds active status, share class status, and database availability. Most common use is for coverage checks and id resolution checks. * @param ids The requested fund identifier. FactSet Identifiers, tickers, CUSIP, SEDOL, and ISIN are accepted inputs. <p>***ids limit** = 1000 per request*</p> *<p>Make note, GET Method URL request lines are also limited to a total length of 8192 bytes (8KB). In cases where the service allows for thousands of ids, which may lead to exceeding this request line limit of 8KB, its advised for any requests with large request lines to be requested through the respective \"POST\" method.</p>* (required) * @return ApiResponse<StatusesResponse> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 The Statuses response object. -
400 Bad Request. This can occur for several reasons. Please review the \"message\" for more details. -
401 Unauthenticated USERNAME-SERIAL. Ensure you are logged in and have successfully generated an API KEY for the IP range you are connecting from. For more help, select the **Report Issue** in the top right corner of this Developer Portal specification card and choose Connectivity 401 or 403 Responses. -
403 The USERNAME-SERIAL attempted to request the endpoint is not authorized to access. The request was a legal request, but the server is refusing to respond. Please reach out to FactSet Account Team for assistance with authorization. -
415 Unsupported Media Type. This error may be returned when the caller sends a resource in a format that is not accepted by the server. This can be fixed by ensuring that Content-Type header is set to the correct value. In this instance, \"application/json\" would be the appropriate value. -
500 Internal Server Error. -
*/ public ApiResponse getStatusesWithHttpInfo(java.util.List ids) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'ids' is set if (ids == null) { throw new ApiException(400, "Missing the required parameter 'ids' when calling getStatuses"); } // create path and map variables String localVarPath = "/factset-funds/v1/status"; // query params java.util.List localVarQueryParams = new java.util.ArrayList(); java.util.Map localVarHeaderParams = new java.util.HashMap(); java.util.Map localVarCookieParams = new java.util.HashMap(); java.util.Map localVarFormParams = new java.util.HashMap(); localVarQueryParams.addAll(apiClient.parameterToPairs("csv", "ids", ids)); final String[] localVarAccepts = { "application/json" }; final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); final String[] localVarContentTypes = { }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< StatusesResponse > apiResponse = apiClient.invokeAPI("HelperApi.getStatuses", localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, getStatusesResponseTypeMap, false); return apiResponse; } /** * Get Fund's current status and database availability for large list of ids. * Get the funds active status, share class status, and database availability. Most common use is for coverage checks and id resolution checks. * @param statusesRequest The Statuses request body, allowing the user to specify a list of ids. (required) * @return StatusesResponse * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 The Statuses response object. -
400 Bad Request. This can occur for several reasons. Please review the \"message\" for more details. -
401 Unauthenticated USERNAME-SERIAL. Ensure you are logged in and have successfully generated an API KEY for the IP range you are connecting from. For more help, select the **Report Issue** in the top right corner of this Developer Portal specification card and choose Connectivity 401 or 403 Responses. -
403 The USERNAME-SERIAL attempted to request the endpoint is not authorized to access. The request was a legal request, but the server is refusing to respond. Please reach out to FactSet Account Team for assistance with authorization. -
415 Unsupported Media Type. This error may be returned when the caller sends a resource in a format that is not accepted by the server. This can be fixed by ensuring that Content-Type header is set to the correct value. In this instance, \"application/json\" would be the appropriate value. -
500 Internal Server Error. -
*/ public StatusesResponse getStatusesForList(StatusesRequest statusesRequest) throws ApiException { return getStatusesForListWithHttpInfo(statusesRequest).getData(); } /** * Get Fund's current status and database availability for large list of ids. * Get the funds active status, share class status, and database availability. Most common use is for coverage checks and id resolution checks. * @param statusesRequest The Statuses request body, allowing the user to specify a list of ids. (required) * @return ApiResponse<StatusesResponse> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 The Statuses response object. -
400 Bad Request. This can occur for several reasons. Please review the \"message\" for more details. -
401 Unauthenticated USERNAME-SERIAL. Ensure you are logged in and have successfully generated an API KEY for the IP range you are connecting from. For more help, select the **Report Issue** in the top right corner of this Developer Portal specification card and choose Connectivity 401 or 403 Responses. -
403 The USERNAME-SERIAL attempted to request the endpoint is not authorized to access. The request was a legal request, but the server is refusing to respond. Please reach out to FactSet Account Team for assistance with authorization. -
415 Unsupported Media Type. This error may be returned when the caller sends a resource in a format that is not accepted by the server. This can be fixed by ensuring that Content-Type header is set to the correct value. In this instance, \"application/json\" would be the appropriate value. -
500 Internal Server Error. -
*/ public ApiResponse getStatusesForListWithHttpInfo(StatusesRequest statusesRequest) throws ApiException { Object localVarPostBody = statusesRequest; // verify the required parameter 'statusesRequest' is set if (statusesRequest == null) { throw new ApiException(400, "Missing the required parameter 'statusesRequest' when calling getStatusesForList"); } // create path and map variables String localVarPath = "/factset-funds/v1/status"; // query params java.util.List localVarQueryParams = new java.util.ArrayList(); java.util.Map localVarHeaderParams = new java.util.HashMap(); java.util.Map localVarCookieParams = new java.util.HashMap(); java.util.Map localVarFormParams = new java.util.HashMap(); 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[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< StatusesResponse > apiResponse = apiClient.invokeAPI("HelperApi.getStatusesForList", localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, getStatusesForListResponseTypeMap, false); return apiResponse; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy