View on GitHub

analyticsapi-engines-dotnet-sdk

FactSet.AnalyticsAPI.Engines.Api.BPMOptimizerApi

All URIs are relative to https://api.factset.com

Method HTTP request Description
CancelOptimizationById DELETE /analytics/engines/bpm/v3/optimizations/{id} Cancel BPM optimization by id
GetOptimizationParameters GET /analytics/engines/bpm/v3/optimizations/{id} Get BPM optimization parameters by id
GetOptimizationResult GET /analytics/engines/bpm/v3/optimizations/{id}/result Get BPM optimization result by id
GetOptimizationStatusById GET /analytics/engines/bpm/v3/optimizations/{id}/status Get BPM optimization status by id
PostAndOptimize POST /analytics/engines/bpm/v3/optimizations Create and Run BPM optimization
PutAndOptimize PUT /analytics/engines/bpm/v3/optimizations/{id} Create or Update BPM optimization and run it.

CancelOptimizationById

void CancelOptimizationById (string id)

Cancel BPM optimization by id

This is the endpoint to cancel a previously submitted optimization.

Example

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 CancelOptimizationByIdExample
    {
        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";
            // Configure Bearer token for authorization: Bearer
            config.AccessToken = "YOUR_BEARER_TOKEN";

            var apiInstance = new BPMOptimizerApi(config);
            var id = id_example;  // string | from url, provided from the location header in the Create and Run BPM optimization endpoint

            try
            {
                // Cancel BPM optimization by id
                apiInstance.CancelOptimizationById(id);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling BPMOptimizerApi.CancelOptimizationById: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
id string from url, provided from the location header in the Create and Run BPM optimization endpoint  

Return type

void (empty response body)

Authorization

Basic, Bearer

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 204 | Expected response, optimization was canceled 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-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.
| | 404 | There was no request for the optimization 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-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.
| | 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]

GetOptimizationParameters

BPMOptimizationParametersRoot GetOptimizationParameters (string id)

Get BPM optimization parameters by id

This is the endpoint that returns the optimization parameters passed for an optimization.

Example

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 GetOptimizationParametersExample
    {
        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";
            // Configure Bearer token for authorization: Bearer
            config.AccessToken = "YOUR_BEARER_TOKEN";

            var apiInstance = new BPMOptimizerApi(config);
            var id = id_example;  // string | from url, provided from the location header in the Create and Run BPM optimization endpoint

            try
            {
                // Get BPM optimization parameters by id
                BPMOptimizationParametersRoot result = apiInstance.GetOptimizationParameters(id);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling BPMOptimizerApi.GetOptimizationParameters: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
id string from url, provided from the location header in the Create and Run BPM optimization endpoint  

Return type

BPMOptimizationParametersRoot

Authorization

Basic, Bearer

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 200 | Expected response, returns the BPM optimization parameters. | * 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.
| | 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.
| | 404 | Optimization id not found | * 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.
| | 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]

GetOptimizationResult

ObjectRoot GetOptimizationResult (string id)

Get BPM optimization result by id

This is the endpoint to get the result of a previously requested optimization.

Example

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 GetOptimizationResultExample
    {
        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";
            // Configure Bearer token for authorization: Bearer
            config.AccessToken = "YOUR_BEARER_TOKEN";

            var apiInstance = new BPMOptimizerApi(config);
            var id = id_example;  // string | from url, provided from the location header in the Get BPM optimization status by id endpoint

            try
            {
                // Get BPM optimization result by id
                ObjectRoot result = apiInstance.GetOptimizationResult(id);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling BPMOptimizerApi.GetOptimizationResult: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
id string from url, provided from the location header in the Get BPM optimization status by id endpoint  

Return type

ObjectRoot

Authorization

Basic, Bearer

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 200 | Expected response once optimization is completed, returns JSON. | * 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.
| | 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.
| | 404 | Optimization result was already returned, provided id was not a requested optimization, or the optimization 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.
| | 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.
| | 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]

GetOptimizationStatusById

ObjectRoot GetOptimizationStatusById (string id)

Get BPM optimization status by id

This is the endpoint to check on the progress of a previously requested optimization. If the optimization has finished computing, the body of the response will contain result in JSON. Otherwise, the optimization is still running and the X-FactSet-Api-PickUp-Progress header will contain a progress percentage.

Example

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 GetOptimizationStatusByIdExample
    {
        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";
            // Configure Bearer token for authorization: Bearer
            config.AccessToken = "YOUR_BEARER_TOKEN";

            var apiInstance = new BPMOptimizerApi(config);
            var id = id_example;  // string | from url, provided from the location header in the Create and Run BPM optimization endpoint

            try
            {
                // Get BPM optimization status by id
                ObjectRoot result = apiInstance.GetOptimizationStatusById(id);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling BPMOptimizerApi.GetOptimizationStatusById: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
id string from url, provided from the location header in the Create and Run BPM optimization endpoint  

Return type

ObjectRoot

Authorization

Basic, Bearer

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 201 | Expected response once optimization is completed, returns 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.
| | 202 | Expected response returned if the optimization is not yet completed, should contain X-FactSet-Api-PickUp-Progress header. | * X-FactSet-Api-PickUp-Progress - FactSet's progress header.
* 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.
| | 404 | Optimization result was already returned, provided id was not a requested optimization, or the optimization 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.
| | 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.
| | 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]

PostAndOptimize

ObjectRoot PostAndOptimize (int? xFactSetApiLongRunningDeadline = null, string cacheControl = null, BPMOptimizationParametersRoot bPMOptimizationParametersRoot = null)

Create and Run BPM optimization

This endpoint creates and runs BPM optimization specified in the POST body parameters. Remarks: * Any settings in POST body will act as a one-time override over the settings saved in the strategy document.

Example

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 PostAndOptimizeExample
    {
        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";
            // Configure Bearer token for authorization: Bearer
            config.AccessToken = "YOUR_BEARER_TOKEN";

            var apiInstance = new BPMOptimizerApi(config);
            var xFactSetApiLongRunningDeadline = 10;  // int? | Long running deadline in seconds. Example value is set to 10s. Please update it as per requirement before triggering a calculation. (optional) 
            var cacheControl = cacheControl_example;  // string | Standard HTTP header.  Accepts max-stale. (optional) 
            var bPMOptimizationParametersRoot = new BPMOptimizationParametersRoot(); // BPMOptimizationParametersRoot | Optimization Parameters (optional) 

            try
            {
                // Create and Run BPM optimization
                ObjectRoot result = apiInstance.PostAndOptimize(xFactSetApiLongRunningDeadline, cacheControl, bPMOptimizationParametersRoot);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling BPMOptimizerApi.PostAndOptimize: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
xFactSetApiLongRunningDeadline int? Long running deadline in seconds. Example value is set to 10s. Please update it as per requirement before triggering a calculation. [optional]
cacheControl string Standard HTTP header. Accepts max-stale. [optional]
bPMOptimizationParametersRoot BPMOptimizationParametersRoot Optimization Parameters [optional]

Return type

ObjectRoot

Authorization

Basic, Bearer

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 202 | Expected response, contains the poll URL in the Location header. | * Location - URL to poll for the resulting optimization
* 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.
| | 201 | Expected response, returns json if optimization is completed in a short span. | * 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 optimization parameters. | * 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 | One or more optimization settings were unavailable. | * 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.
| | 415 | Missing/Invalid Content-Type 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. Cancel older requests using Cancel optimization endpoint or wait for older requests to finish/expire. | * 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.
* 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]

PutAndOptimize

ObjectRoot PutAndOptimize (string id, int? xFactSetApiLongRunningDeadline = null, string cacheControl = null, BPMOptimizationParametersRoot bPMOptimizationParametersRoot = null)

Create or Update BPM optimization and run it.

This endpoint updates and run the BPM optimization specified in the PUT body parameters. It also allows the creation of new BPM optimization with custom id.

Example

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 PutAndOptimizeExample
    {
        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";
            // Configure Bearer token for authorization: Bearer
            config.AccessToken = "YOUR_BEARER_TOKEN";

            var apiInstance = new BPMOptimizerApi(config);
            var id = id_example;  // string | from url, provided from the location header in the Create and Run BPM optimization endpoint
            var xFactSetApiLongRunningDeadline = 10;  // int? | Long running deadline in seconds. Example value is set to 10s. Please update it as per requirement before triggering a calculation. (optional) 
            var cacheControl = cacheControl_example;  // string | Standard HTTP header.  Accepts max-stale. (optional) 
            var bPMOptimizationParametersRoot = new BPMOptimizationParametersRoot(); // BPMOptimizationParametersRoot | Optimization Parameters (optional) 

            try
            {
                // Create or Update BPM optimization and run it.
                ObjectRoot result = apiInstance.PutAndOptimize(id, xFactSetApiLongRunningDeadline, cacheControl, bPMOptimizationParametersRoot);
                Debug.WriteLine(result);
            }
            catch (ApiException  e)
            {
                Debug.Print("Exception when calling BPMOptimizerApi.PutAndOptimize: " + e.Message );
                Debug.Print("Status Code: "+ e.ErrorCode);
                Debug.Print(e.StackTrace);
            }
        }
    }
}

Parameters

Name Type Description Notes
id string from url, provided from the location header in the Create and Run BPM optimization endpoint  
xFactSetApiLongRunningDeadline int? Long running deadline in seconds. Example value is set to 10s. Please update it as per requirement before triggering a calculation. [optional]
cacheControl string Standard HTTP header. Accepts max-stale. [optional]
bPMOptimizationParametersRoot BPMOptimizationParametersRoot Optimization Parameters [optional]

Return type

ObjectRoot

Authorization

Basic, Bearer

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| | 202 | Expected response, contains the poll URL in the Location header. | * Location - URL to poll for the resulting optimization
* 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.
| | 201 | Expected response, returns json if optimization is completed in a short span. | * 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 Optimization Parameters. | * 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 | One or more optimization settings were unavailable. | * 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.
| | 409 | Duplicate optimization exists with same parameters. | * 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.
| | 415 | Missing/Invalid Content-Type 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. Cancel older requests using Cancel optimization endpoint or wait for older requests to finish/expire. | * 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.
* 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]