All URIs are relative to https://api.factset.com
| Method | HTTP request | Description |
|---|---|---|
| CancelCalculationById | DELETE /analytics/engines/v2/calculations/{id} | Cancel calculation by id |
| GetCalculationStatusById | GET /analytics/engines/v2/calculations/{id} | Get calculation status by id |
| GetCalculationStatusSummaries | GET /analytics/engines/v2/calculations | Get all calculation statuses |
| RunCalculation | POST /analytics/engines/v2/calculations | Run calculation |
void CancelCalculationById (string id)
Cancel calculation by id
This is the endpoint to cancel a previously submitted calculation request. Instead of doing a GET on the getCalculationById URL, cancel the calculation by doing a DELETE. All individual calculation units within the calculation will be canceled if they have not already finished.
using System.Collections.Generic;
using System.Diagnostics;
using FactSet.AnalyticsAPI.Engines.Api;
using FactSet.AnalyticsAPI.Engines.Client;
using FactSet.AnalyticsAPI.Engines.Model;
namespace Example
{
public class CancelCalculationByIdExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.factset.com";
// Configure HTTP basic authorization: Basic
config.Username = "YOUR_USERNAME";
config.Password = "YOUR_PASSWORD";
var apiInstance = new CalculationsApi(config);
var id = id_example; // string | From url, provided from the location header in the Run Multiple Calculations endpoint.
try
{
// Cancel calculation by id
apiInstance.CancelCalculationById(id);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CalculationsApi.CancelCalculationById: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| id | string | From url, provided from the location header in the Run Multiple Calculations endpoint. |
void (empty response body)
- Content-Type: Not defined
- Accept: Not defined
| Status code | Description | Response headers |
|---|---|---|
| 204 | Expected response, request was cancelled successfully. | * 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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 404 | There was no request for the identifier provided, or the request was already canceled for the provided identifier. | * 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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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]
CalculationStatus GetCalculationStatusById (string id)
Get calculation status by id
This is the endpoint to check on the progress of a previous calculation request. Response body contains status information of the entire request and each individual calculation unit.
using System.Collections.Generic;
using System.Diagnostics;
using FactSet.AnalyticsAPI.Engines.Api;
using FactSet.AnalyticsAPI.Engines.Client;
using FactSet.AnalyticsAPI.Engines.Model;
namespace Example
{
public class GetCalculationStatusByIdExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.factset.com";
// Configure HTTP basic authorization: Basic
config.Username = "YOUR_USERNAME";
config.Password = "YOUR_PASSWORD";
var apiInstance = new CalculationsApi(config);
var id = id_example; // string | From url, provided from the location header in the Run Multiple Calculations endpoint.
try
{
// Get calculation status by id
CalculationStatus result = apiInstance.GetCalculationStatusById(id);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CalculationsApi.GetCalculationStatusById: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| id | string | From url, provided from the location header in the Run Multiple Calculations endpoint. |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | Expected response, returns status information of the entire calculation and each individual calculation unit. | * 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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 400 | Invalid identifier provided. | * 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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 401 | Missing or invalid authentication. | * 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. |
| 403 | User is forbidden with current credentials. | * 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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 404 | Provided identifier was not a request, or the request was cancelled. | * 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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 406 | Unsupported Accept header. Header needs to be set to application/json. | * 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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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. | * 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. * 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. | * 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. |
| 503 | Request timed out. Retry the request in sometime. | * 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. |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Dictionary<string, CalculationStatusSummary> GetCalculationStatusSummaries ()
Get all calculation statuses
This endpoints returns all active calculation requests.
using System.Collections.Generic;
using System.Diagnostics;
using FactSet.AnalyticsAPI.Engines.Api;
using FactSet.AnalyticsAPI.Engines.Client;
using FactSet.AnalyticsAPI.Engines.Model;
namespace Example
{
public class GetCalculationStatusSummariesExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.factset.com";
// Configure HTTP basic authorization: Basic
config.Username = "YOUR_USERNAME";
config.Password = "YOUR_PASSWORD";
var apiInstance = new CalculationsApi(config);
try
{
// Get all calculation statuses
Dictionary<string, CalculationStatusSummary> result = apiInstance.GetCalculationStatusSummaries();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CalculationsApi.GetCalculationStatusSummaries: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}This endpoint does not need any parameter.
Dictionary<string, CalculationStatusSummary>
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | List of active 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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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]
void RunCalculation (Calculation calculation = null)
Run calculation
This endpoint creates a new calculation and runs the set of calculation units specified in the POST body. 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: * Maximum 500 units allowed across all simultaneous calculations. (Refer API documentation for more information) * Any settings in POST body will act as a one-time override over the settings saved in the PA/SPAR/Vault template.
using System.Collections.Generic;
using System.Diagnostics;
using FactSet.AnalyticsAPI.Engines.Api;
using FactSet.AnalyticsAPI.Engines.Client;
using FactSet.AnalyticsAPI.Engines.Model;
namespace Example
{
public class RunCalculationExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.factset.com";
// Configure HTTP basic authorization: Basic
config.Username = "YOUR_USERNAME";
config.Password = "YOUR_PASSWORD";
var apiInstance = new CalculationsApi(config);
var calculation = new Calculation(); // Calculation | (optional)
try
{
// Run calculation
apiInstance.RunCalculation(calculation);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CalculationsApi.RunCalculation: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| calculation | Calculation | [optional] |
void (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-Points-Limit - Maximum points limit across all batches. * X-FactSet-Api-Points-Remaining - Number of points remaining till points limit reached. * X-FactSet-Api-Units-Limit - Maximum units limit across all batches. * X-FactSet-Api-Units-Remaining - Number of units remaining till units limit reached. * X-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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-Points-Limit - Maximum points limit across all batches. * X-FactSet-Api-Points-Remaining - Number of points remaining till points limit reached. * X-FactSet-Api-Units-Limit - Maximum units limit across all batches. * X-FactSet-Api-Units-Remaining - Number of units remaining till units limit reached. * X-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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-Points-Limit - Maximum points limit across all batches. * X-FactSet-Api-Points-Remaining - Number of points remaining till points limit reached. * X-FactSet-Api-Units-Limit - Maximum units limit across all batches. * X-FactSet-Api-Units-Remaining - Number of units remaining till units 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-Points-Limit - Maximum points limit across all batches. * X-FactSet-Api-Points-Remaining - Number of points remaining till points limit reached. * X-FactSet-Api-Units-Limit - Maximum units limit across all batches. * X-FactSet-Api-Units-Remaining - Number of units remaining till units limit reached. * X-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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-Points-Limit - Maximum points limit across all batches. * X-FactSet-Api-Points-Remaining - Number of points remaining till points limit reached. * X-FactSet-Api-Units-Limit - Maximum units limit across all batches. * X-FactSet-Api-Units-Remaining - Number of units remaining till units limit reached. * X-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-RateLimit-Reset - Number of seconds remaining till rate limit resets. |
| 429 | Rate limit reached. Cancel older requests using Cancel 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-Points-Limit - Maximum points limit across all batches. * X-FactSet-Api-Points-Remaining - Number of points remaining till points limit reached. * X-FactSet-Api-Units-Limit - Maximum units limit across all batches. * X-FactSet-Api-Units-Remaining - Number of units remaining till units limit reached. * X-RateLimit-Limit - Number of allowed requests for the time window. * X-RateLimit-Remaining - Number of requests left for the time window. * X-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-Points-Limit - Maximum points limit across all batches. * X-FactSet-Api-Points-Remaining - Number of points remaining till points limit reached. * X-FactSet-Api-Units-Limit - Maximum units limit across all batches. * X-FactSet-Api-Units-Remaining - Number of units remaining till units 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-Points-Limit - Maximum points limit across all batches. * X-FactSet-Api-Points-Remaining - Number of points remaining till points limit reached. * X-FactSet-Api-Units-Limit - Maximum units limit across all batches. * X-FactSet-Api-Units-Remaining - Number of units remaining till units limit reached. |
[Back to top] [Back to API list] [Back to Model list] [Back to README]