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

com.factset.sdk.IRNConfiguration.api.ContactsCustomFieldsApi Maven / Gradle / Ivy

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

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

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

import com.factset.sdk.IRNConfiguration.models.ContactCustomFieldDto;
import com.factset.sdk.IRNConfiguration.models.ContactCustomFieldSaveDto;
import com.factset.sdk.IRNConfiguration.models.NewItemDto;
import com.factset.sdk.IRNConfiguration.models.Operation;
import com.factset.sdk.IRNConfiguration.models.ProblemDetails;

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

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

  public ContactsCustomFieldsApi(ApiClient apiClient) {
    this.apiClient = apiClient;
  }
  
  private static final Map createContactCustomFieldResponseTypeMap = new HashMap();
  static {
    createContactCustomFieldResponseTypeMap.put(201, new GenericType(){});
    createContactCustomFieldResponseTypeMap.put(400, new GenericType(){});
    createContactCustomFieldResponseTypeMap.put(0, new GenericType(){});
  }

  private static final Map deleteContactCustomFieldResponseTypeMap = new HashMap();

  private static final Map getContactCustomFieldResponseTypeMap = new HashMap();
  static {
    getContactCustomFieldResponseTypeMap.put(200, new GenericType(){});
    getContactCustomFieldResponseTypeMap.put(404, new GenericType(){});
    getContactCustomFieldResponseTypeMap.put(0, new GenericType(){});
  }

  private static final Map getContactCustomFieldsResponseTypeMap = new HashMap();
  static {
    getContactCustomFieldsResponseTypeMap.put(200, new GenericType>(){});
  }

  private static final Map patchContactCustomFieldResponseTypeMap = new HashMap();

  


  /**
   * 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;
  }

  /**
   * Create a contact custom field
   * 
   * @param contactCustomFieldSaveDto ContactCustomFieldSaveDto object to save (optional)
   * @return NewItemDto
   * @throws ApiException if fails to make API call
   * @http.response.details
     
Status Code Description Response Headers
201 Created -
400 Bad Request -
0 Error -
*/ public NewItemDto createContactCustomField(ContactCustomFieldSaveDto contactCustomFieldSaveDto) throws ApiException { return createContactCustomFieldWithHttpInfo(contactCustomFieldSaveDto).getData(); } /** * Create a contact custom field * * @param contactCustomFieldSaveDto ContactCustomFieldSaveDto object to save (optional) * @return ApiResponse<NewItemDto> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
201 Created -
400 Bad Request -
0 Error -
*/ public ApiResponse createContactCustomFieldWithHttpInfo(ContactCustomFieldSaveDto contactCustomFieldSaveDto) throws ApiException { Object localVarPostBody = contactCustomFieldSaveDto; // create path and map variables String localVarPath = "/v1/contact-custom-fields"; // 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-patch+json", "application/json", "text/json", "application/_*+json" }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< NewItemDto > apiResponse = apiClient.invokeAPI("ContactsCustomFieldsApi.createContactCustomField", localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, createContactCustomFieldResponseTypeMap, false); return apiResponse; } /** * Delete a contact custom field * * @param contactCustomFieldId contactCustomFieldId to delete associated record (required) * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
400 Bad Request -
404 Not Found -
0 Error -
*/ public void deleteContactCustomField(java.util.UUID contactCustomFieldId) throws ApiException { deleteContactCustomFieldWithHttpInfo(contactCustomFieldId); } /** * Delete a contact custom field * * @param contactCustomFieldId contactCustomFieldId to delete associated record (required) * @return ApiResponse<Void> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
400 Bad Request -
404 Not Found -
0 Error -
*/ public ApiResponse deleteContactCustomFieldWithHttpInfo(java.util.UUID contactCustomFieldId) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'contactCustomFieldId' is set if (contactCustomFieldId == null) { throw new ApiException(400, "Missing the required parameter 'contactCustomFieldId' when calling deleteContactCustomField"); } // create path and map variables String localVarPath = "/v1/contact-custom-fields/{contactCustomFieldId}" .replaceAll("\\{" + "contactCustomFieldId" + "\\}", apiClient.escapeString(contactCustomFieldId.toString())); // 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 = { }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< Void > apiResponse = apiClient.invokeAPI("ContactsCustomFieldsApi.deleteContactCustomField", localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, deleteContactCustomFieldResponseTypeMap, false); return apiResponse; } /** * Get a specific Contact custom field's details * * @param contactCustomFieldId contactCustomFieldId to get associated record (required) * @return ContactCustomFieldDto * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
404 Not Found -
0 Error -
*/ public ContactCustomFieldDto getContactCustomField(java.util.UUID contactCustomFieldId) throws ApiException { return getContactCustomFieldWithHttpInfo(contactCustomFieldId).getData(); } /** * Get a specific Contact custom field's details * * @param contactCustomFieldId contactCustomFieldId to get associated record (required) * @return ApiResponse<ContactCustomFieldDto> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
404 Not Found -
0 Error -
*/ public ApiResponse getContactCustomFieldWithHttpInfo(java.util.UUID contactCustomFieldId) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'contactCustomFieldId' is set if (contactCustomFieldId == null) { throw new ApiException(400, "Missing the required parameter 'contactCustomFieldId' when calling getContactCustomField"); } // create path and map variables String localVarPath = "/v1/contact-custom-fields/{contactCustomFieldId}" .replaceAll("\\{" + "contactCustomFieldId" + "\\}", apiClient.escapeString(contactCustomFieldId.toString())); // 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 = { }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< ContactCustomFieldDto > apiResponse = apiClient.invokeAPI("ContactsCustomFieldsApi.getContactCustomField", localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, getContactCustomFieldResponseTypeMap, false); return apiResponse; } /** * Get all the contact custom fields * * @return java.util.List * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
*/ public java.util.List getContactCustomFields() throws ApiException { return getContactCustomFieldsWithHttpInfo().getData(); } /** * Get all the contact custom fields * * @return ApiResponse<java.util.List> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
*/ public ApiResponse> getContactCustomFieldsWithHttpInfo() throws ApiException { Object localVarPostBody = null; // create path and map variables String localVarPath = "/v1/contact-custom-fields"; // 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 = { }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< java.util.List > apiResponse = apiClient.invokeAPI("ContactsCustomFieldsApi.getContactCustomFields", localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, getContactCustomFieldsResponseTypeMap, false); return apiResponse; } /** * Edit a contact custom field * * @param contactCustomFieldId contactCustomFieldId to update associated record (required) * @param operation contactCustomFieldUpdateDto object to update (optional) * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
400 Bad Request -
404 Not Found -
0 Error -
*/ public void patchContactCustomField(java.util.UUID contactCustomFieldId, java.util.List operation) throws ApiException { patchContactCustomFieldWithHttpInfo(contactCustomFieldId, operation); } /** * Edit a contact custom field * * @param contactCustomFieldId contactCustomFieldId to update associated record (required) * @param operation contactCustomFieldUpdateDto object to update (optional) * @return ApiResponse<Void> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
400 Bad Request -
404 Not Found -
0 Error -
*/ public ApiResponse patchContactCustomFieldWithHttpInfo(java.util.UUID contactCustomFieldId, java.util.List operation) throws ApiException { Object localVarPostBody = operation; // verify the required parameter 'contactCustomFieldId' is set if (contactCustomFieldId == null) { throw new ApiException(400, "Missing the required parameter 'contactCustomFieldId' when calling patchContactCustomField"); } // create path and map variables String localVarPath = "/v1/contact-custom-fields/{contactCustomFieldId}" .replaceAll("\\{" + "contactCustomFieldId" + "\\}", apiClient.escapeString(contactCustomFieldId.toString())); // 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-patch+json", "application/json", "text/json", "application/_*+json" }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< Void > apiResponse = apiClient.invokeAPI("ContactsCustomFieldsApi.patchContactCustomField", localVarPath, "PATCH", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, patchContactCustomFieldResponseTypeMap, false); return apiResponse; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy