All URIs are relative to https://api.factset.com
| Method | HTTP request | Description |
|---|---|---|
| get_calculation_by_id | GET /analytics/engines/fiab/v1/calculations/{id} | Get FIAB calculation by id |
| get_calculation_status_summaries | GET /analytics/engines/fiab/v1/calculations | Get all FIAB calculation summaries |
| run_calculation | POST /analytics/engines/fiab/v1/calculations | Run FIAB calculation |
FIABCalculationStatus get_calculation_by_id(id)
Get FIAB calculation by id
This is the endpoint to check on the progress of a previously requested calculation.
- Basic Authentication (Basic):
- Bearer Authentication (Bearer):
import time
import fds.analyticsapi.engines
from fds.analyticsapi.engines.api import fiab_calculations_api
from fds.analyticsapi.engines.model.fiab_calculation_status import FIABCalculationStatus
from pprint import pprint
# Defining the host is optional and defaults to https://api.factset.com
# See configuration.py for a list of all supported configuration parameters.
configuration = fds.analyticsapi.engines.Configuration(
host = "https://api.factset.com"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure HTTP basic authorization: Basic
configuration = fds.analyticsapi.engines.Configuration(
username = 'YOUR_USERNAME',
password = 'YOUR_PASSWORD'
)
# Configure Bearer authorization: Bearer
configuration = fds.analyticsapi.engines.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with fds.analyticsapi.engines.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = fiab_calculations_api.FIABCalculationsApi(api_client)
id = "id_example" # str | from url, provided from the location header in the Run FIAB Calculation endpoint
# example passing only required values which don't have defaults set
try:
# Get FIAB calculation by id
api_response = api_instance.get_calculation_by_id(id)
pprint(api_response)
except fds.analyticsapi.engines.ApiException as e:
print("Exception when calling FIABCalculationsApi->get_calculation_by_id: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| id | str | from url, provided from the location header in the Run FIAB Calculation endpoint |
- A tuple with response data, HTTP status code and response headers.
- Response datatype: FIABCalculationStatus
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | Expected response, returns status information of the entire calculation if it is complete. | * Content-Encoding - Standard HTTP header. Header value based on Accept-Encoding Request header. * Content-Type - Standard HTTP header. * Transfer-Encoding - Standard HTTP header. Header value will be set to Chunked if Accept-Encoding header is specified. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 202 | Expected response, returns status information of the entire calculation if it is not complete. | * Cache-Control - Standard HTTP header. Header will specify max-age in seconds. Polling can be adjusted based on the max-age value. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 400 | Invalid identifier provided. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 401 | Missing or invalid authentication. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. |
| 403 | User is forbidden with current credentials | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 404 | Calculation was already returned, provided id was not a requested calculation, or the calculation was cancelled | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 500 | Server error. Log the X-DataDirect-Request-Key header to assist in troubleshooting | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. |
| 503 | Request timed out. Retry the request in sometime. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
{str: (FIABCalculationStatusSummary,)} get_calculation_status_summaries()
Get all FIAB calculation summaries
This endpoints returns all FIAB calculation requests.
- Basic Authentication (Basic):
- Bearer Authentication (Bearer):
import time
import fds.analyticsapi.engines
from fds.analyticsapi.engines.api import fiab_calculations_api
from fds.analyticsapi.engines.model.fiab_calculation_status_summary import FIABCalculationStatusSummary
from pprint import pprint
# Defining the host is optional and defaults to https://api.factset.com
# See configuration.py for a list of all supported configuration parameters.
configuration = fds.analyticsapi.engines.Configuration(
host = "https://api.factset.com"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure HTTP basic authorization: Basic
configuration = fds.analyticsapi.engines.Configuration(
username = 'YOUR_USERNAME',
password = 'YOUR_PASSWORD'
)
# Configure Bearer authorization: Bearer
configuration = fds.analyticsapi.engines.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with fds.analyticsapi.engines.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = fiab_calculations_api.FIABCalculationsApi(api_client)
# example, this endpoint has no required or optional parameters
try:
# Get all FIAB calculation summaries
api_response = api_instance.get_calculation_status_summaries()
pprint(api_response)
except fds.analyticsapi.engines.ApiException as e:
print("Exception when calling FIABCalculationsApi->get_calculation_status_summaries: %s\n" % e)This endpoint does not need any parameter.
- A tuple with response data, HTTP status code and response headers.
- Response datatype: [{str: (FIABCalculationStatusSummary,)}]({str: (FIABCalculationStatusSummary,)}.md)
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | List of active FIAB calculation requests. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 401 | Missing or invalid authentication. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. |
| 403 | User is forbidden with current credentials. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 406 | Unsupported Accept header. Header needs to be set to application/json. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 429 | Rate limit reached. Wait till the time specified in Retry-After header value to make further requests. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * Retry-After - Time to wait in seconds before making a new request as the rate limit has reached. |
| 500 | Server error. Log the X-DataDirect-Request-Key header to assist in troubleshooting. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. |
| 503 | Request timed out. Retry the request in sometime. | * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
run_calculation()
Run FIAB calculation
This endpoint creates a new FIAB calculation. This must be used first before get status or cancelling endpoints with a calculation id. A successful response will contain the URL to check the status of the calculation request. Remarks: * Any settings in POST body will act as a one-time override over the settings saved in the FIAB template.
- Basic Authentication (Basic):
- Bearer Authentication (Bearer):
import time
import fds.analyticsapi.engines
from fds.analyticsapi.engines.api import fiab_calculations_api
from fds.analyticsapi.engines.model.fiab_calculation_parameters import FIABCalculationParameters
from pprint import pprint
# Defining the host is optional and defaults to https://api.factset.com
# See configuration.py for a list of all supported configuration parameters.
configuration = fds.analyticsapi.engines.Configuration(
host = "https://api.factset.com"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure HTTP basic authorization: Basic
configuration = fds.analyticsapi.engines.Configuration(
username = 'YOUR_USERNAME',
password = 'YOUR_PASSWORD'
)
# Configure Bearer authorization: Bearer
configuration = fds.analyticsapi.engines.Configuration(
access_token = 'YOUR_BEARER_TOKEN'
)
# Enter a context with an instance of the API client
with fds.analyticsapi.engines.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = fiab_calculations_api.FIABCalculationsApi(api_client)
fiab_calculation_parameters = FIABCalculationParameters(
fiabdocument="fiabdocument_example",
account=FIABIdentifier(
id="id_example",
),
dates=FIABDateParameters(
startdate="startdate_example",
enddate="enddate_example",
),
msl="msl_example",
fisettingsdocument="fisettingsdocument_example",
) # FIABCalculationParameters | (optional)
# example passing only required values which don't have defaults set
# and optional values
try:
# Run FIAB calculation
api_instance.run_calculation(fiab_calculation_parameters=fiab_calculation_parameters)
except fds.analyticsapi.engines.ApiException as e:
print("Exception when calling FIABCalculationsApi->run_calculation: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| fiab_calculation_parameters | FIABCalculationParameters | [optional] |
- A tuple with response data, HTTP status code and response headers.
- Response datatype: None (empty response body)
- Content-Type: application/json
- Accept: Not defined
| Status code | Description | Response headers |
|---|---|---|
| 202 | Expected response, contains the URL in the Location header to check the status of the calculation. | * Location - URL to check status of the request. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-Calculations-Limit - Maximum FIAB request limit. * X-FactSet-Api-Calculations-Remaining - Number of FIAB requests remaining till request limit reached. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 400 | Invalid POST body. | * Location - URL to check status of the request. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-Calculations-Limit - Maximum FIAB request limit. * X-FactSet-Api-Calculations-Remaining - Number of FIAB requests remaining till request limit reached. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 401 | Missing or invalid authentication. | * Location - URL to check status of the request. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-Calculations-Limit - Maximum FIAB request limit. * X-FactSet-Api-Calculations-Remaining - Number of FIAB requests remaining till request limit reached. |
| 403 | User is forbidden with current credentials. | * Location - URL to check status of the request. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-Calculations-Limit - Maximum FIAB request limit. * X-FactSet-Api-Calculations-Remaining - Number of FIAB requests remaining till request limit reached. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 415 | Missing/Invalid Content-Type header. Header needs to be set to application/json. | * Location - URL to check status of the request. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-Calculations-Limit - Maximum FIAB request limit. * X-FactSet-Api-Calculations-Remaining - Number of FIAB requests remaining till request limit reached. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 429 | Rate limit reached. Cancel older requests using Cancel FIAB Calculation endpoint or wait for older requests to finish / expire. | * Location - URL to check status of the request. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-Calculations-Limit - Maximum FIAB request limit. * X-FactSet-Api-Calculations-Remaining - Number of FIAB requests remaining till request limit reached. * X-FactSet-Api-RateLimit-Limit - Number of allowed requests for the time window. * X-FactSet-Api-RateLimit-Remaining - Number of requests left for the time window. * X-FactSet-Api-RateLimit-Reset - Number of seconds remaining till rate limit resets. * Retry-After - Time to wait in seconds before making a new request as the rate limit has reached. |
| 500 | Server error. Log the X-DataDirect-Request-Key header to assist in troubleshooting. | * Location - URL to check status of the request. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-Calculations-Limit - Maximum FIAB request limit. * X-FactSet-Api-Calculations-Remaining - Number of FIAB requests remaining till request limit reached. |
| 503 | Request timed out. Retry the request in sometime. | * Location - URL to check status of the request. * X-DataDirect-Request-Key - FactSet's request key header. * X-FactSet-Api-Request-Key - Key to uniquely identify an Analytics API request. Only available after successful authentication. * X-FactSet-Api-Calculations-Limit - Maximum FIAB request limit. * X-FactSet-Api-Calculations-Remaining - Number of FIAB requests remaining till request limit reached. |
[Back to top] [Back to API list] [Back to Model list] [Back to README]