Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
package com.factset.sdk.FactSetFundamentals.api;
import com.factset.sdk.FactSetFundamentals.ApiException;
import com.factset.sdk.FactSetFundamentals.ApiClient;
import com.factset.sdk.FactSetFundamentals.ApiResponse;
import com.factset.sdk.FactSetFundamentals.Configuration;
import com.factset.sdk.FactSetFundamentals.Pair;
import javax.ws.rs.core.GenericType;
import com.factset.sdk.FactSetFundamentals.models.ErrorResponse;
import com.factset.sdk.FactSetFundamentals.models.FundamentalsRequest;
import com.factset.sdk.FactSetFundamentals.models.FundamentalsResponse;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class FactSetFundamentalsApi {
private ApiClient apiClient;
public FactSetFundamentalsApi() {
this(Configuration.getDefaultApiClient());
}
public FactSetFundamentalsApi(ApiClient apiClient) {
this.apiClient = apiClient;
}
/**
* 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;
}
/**
* Returns the Company Fundamental Data.
* Retrieves FactSet Fundamental standardized data for an individual security. Use the /metrics endpoint to retrieve a full list of valid metrics or data items.
* @param ids Security or Entity identifiers. FactSet Identifiers, tickers, CUSIP and SEDOL are accepted as input. <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)
* @param metrics Requested List of Financial Statement Items or Ratios. Use /metrics endpoint for a complete list of available FF_* metric items. <p>*When requesting multiple metrics, you cannot mix metric data types (e.g. strings and floats). Please use /metrics endpoints for context on metric dataType to avoid null data.*</p> <p>***metrics limit** = 1600 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 metrics, 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)
* @param periodicity Periodicity or frequency of the fiscal periods, where * **ANN** = Annual - Original, * **ANN_R** = Annual - Latest - *Includes Restatements*, * **QTR** = Quarterly - Original, * **QTR_R** = Quarterly - Latest - *Includes Restatements*, * **SEMI** = Semi-Annual, * **LTM** = Last Twelve Months, * **LTMSG** = Last Twelve Months Global [OA17959](https://my.apps.factset.com/oa/pages/17959), * **YTD** = Year-to-date. (optional, default to QTR)
* @param fiscalPeriodStart Fiscal period start expressed as YYYY-MM-DD. Calendar date that will fall back to most recent completed period during resolution. (optional)
* @param fiscalPeriodEnd Fiscal period end expressed YYYY-MM-DD. Calendar date that will fall back to most recent completed period during resolution. (optional)
* @param currency Currency code for currency values. For a list of currency ISO codes, visit Online Assistant Page [OA1470](https://my.apps.factset.com/oa/pages/1470). (optional, default to LOCAL)
* @param restated Update Status Flag: * **RP** = Include preliminary data, * **RF** = Only final data (optional, default to RP)
* @return FundamentalsResponse
* @throws ApiException if fails to make API call
* @http.response.details
Status Code
Description
Response Headers
200
Fundamental data items
-
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 FundamentalsResponse getFdsFundamentals(java.util.List ids, java.util.List metrics, String periodicity, String fiscalPeriodStart, String fiscalPeriodEnd, String currency, String restated) throws ApiException {
return getFdsFundamentalsWithHttpInfo(ids, metrics, periodicity, fiscalPeriodStart, fiscalPeriodEnd, currency, restated).getData();
}
/**
* Returns the Company Fundamental Data.
* Retrieves FactSet Fundamental standardized data for an individual security. Use the /metrics endpoint to retrieve a full list of valid metrics or data items.
* @param ids Security or Entity identifiers. FactSet Identifiers, tickers, CUSIP and SEDOL are accepted as input. <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)
* @param metrics Requested List of Financial Statement Items or Ratios. Use /metrics endpoint for a complete list of available FF_* metric items. <p>*When requesting multiple metrics, you cannot mix metric data types (e.g. strings and floats). Please use /metrics endpoints for context on metric dataType to avoid null data.*</p> <p>***metrics limit** = 1600 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 metrics, 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)
* @param periodicity Periodicity or frequency of the fiscal periods, where * **ANN** = Annual - Original, * **ANN_R** = Annual - Latest - *Includes Restatements*, * **QTR** = Quarterly - Original, * **QTR_R** = Quarterly - Latest - *Includes Restatements*, * **SEMI** = Semi-Annual, * **LTM** = Last Twelve Months, * **LTMSG** = Last Twelve Months Global [OA17959](https://my.apps.factset.com/oa/pages/17959), * **YTD** = Year-to-date. (optional, default to QTR)
* @param fiscalPeriodStart Fiscal period start expressed as YYYY-MM-DD. Calendar date that will fall back to most recent completed period during resolution. (optional)
* @param fiscalPeriodEnd Fiscal period end expressed YYYY-MM-DD. Calendar date that will fall back to most recent completed period during resolution. (optional)
* @param currency Currency code for currency values. For a list of currency ISO codes, visit Online Assistant Page [OA1470](https://my.apps.factset.com/oa/pages/1470). (optional, default to LOCAL)
* @param restated Update Status Flag: * **RP** = Include preliminary data, * **RF** = Only final data (optional, default to RP)
* @return ApiResponse<FundamentalsResponse>
* @throws ApiException if fails to make API call
* @http.response.details
Status Code
Description
Response Headers
200
Fundamental data items
-
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 getFdsFundamentalsWithHttpInfo(java.util.List ids, java.util.List metrics, String periodicity, String fiscalPeriodStart, String fiscalPeriodEnd, String currency, String restated) 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 getFdsFundamentals");
}
// verify the required parameter 'metrics' is set
if (metrics == null) {
throw new ApiException(400, "Missing the required parameter 'metrics' when calling getFdsFundamentals");
}
// create path and map variables
String localVarPath = "/factset-fundamentals/v1/fundamentals";
// 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));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "periodicity", periodicity));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "fiscalPeriodStart", fiscalPeriodStart));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "fiscalPeriodEnd", fiscalPeriodEnd));
localVarQueryParams.addAll(apiClient.parameterToPairs("csv", "metrics", metrics));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "currency", currency));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "restated", restated));
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" };
GenericType localVarReturnType = new GenericType() {};
return apiClient.invokeAPI("FactSetFundamentalsApi.getFdsFundamentals", localVarPath, "GET", localVarQueryParams, localVarPostBody,
localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType,
localVarAuthNames, localVarReturnType, false);
}
/**
* Returns the Company Fundamental Data.
* Retrieves FactSet Fundamental standardized data for an individual security. Use the /metrics endpoint to retrieve a full list of valid metrics or data items.
* @param fundamentalsRequest Request object for requesting fundamentals data (required)
* @return FundamentalsResponse
* @throws ApiException if fails to make API call
* @http.response.details
Status Code
Description
Response Headers
200
Fundamental data items
-
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 FundamentalsResponse getFdsFundamentalsForList(FundamentalsRequest fundamentalsRequest) throws ApiException {
return getFdsFundamentalsForListWithHttpInfo(fundamentalsRequest).getData();
}
/**
* Returns the Company Fundamental Data.
* Retrieves FactSet Fundamental standardized data for an individual security. Use the /metrics endpoint to retrieve a full list of valid metrics or data items.
* @param fundamentalsRequest Request object for requesting fundamentals data (required)
* @return ApiResponse<FundamentalsResponse>
* @throws ApiException if fails to make API call
* @http.response.details
Status Code
Description
Response Headers
200
Fundamental data items
-
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 getFdsFundamentalsForListWithHttpInfo(FundamentalsRequest fundamentalsRequest) throws ApiException {
Object localVarPostBody = fundamentalsRequest;
// verify the required parameter 'fundamentalsRequest' is set
if (fundamentalsRequest == null) {
throw new ApiException(400, "Missing the required parameter 'fundamentalsRequest' when calling getFdsFundamentalsForList");
}
// create path and map variables
String localVarPath = "/factset-fundamentals/v1/fundamentals";
// 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" };
GenericType localVarReturnType = new GenericType() {};
return apiClient.invokeAPI("FactSetFundamentalsApi.getFdsFundamentalsForList", localVarPath, "POST", localVarQueryParams, localVarPostBody,
localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType,
localVarAuthNames, localVarReturnType, false);
}
}