AWS.ForecastQueryService — AWS SDK for JavaScript (original) (raw)
We recommend that you migrate to AWS SDK for JavaScript v3. For dates, additional details, and information on how to migrate, please refer to the linked announcement.
Inherits:
- Object
- AWS.Service
- AWS.ForecastQueryService show all
Identifier:
forecastqueryservice
API Version:
2018-06-26
Defined in:
(unknown)
Overview
Constructs a service interface object. Each API operation is exposed as a function on service.
Service Description
Provides APIs for creating and managing Amazon Forecast resources.
Sending a Request Using ForecastQueryService
var forecastqueryservice = new AWS.ForecastQueryService();
forecastqueryservice.queryForecast(params, function (err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Locking the API Version
In order to ensure that the ForecastQueryService object uses this specific API, you can construct the object by passing the apiVersion
option to the constructor:
var forecastqueryservice = new AWS.ForecastQueryService({apiVersion: '2018-06-26'});
You can also set the API version globally in AWS.config.apiVersions
using the forecastqueryservice service identifier:
AWS.config.apiVersions = {
forecastqueryservice: '2018-06-26',
// other service API versions
};
var forecastqueryservice = new AWS.ForecastQueryService();
Constructor Summarycollapse
- new AWS.ForecastQueryService(options = {}) ⇒ Object constructor
Constructs a service object.
Property Summarycollapse
- endpoint ⇒ AWS.Endpoint readwrite
An Endpoint object representing the endpoint URL for service requests.
Properties inherited from AWS.Service
Method Summarycollapse
- queryForecast(params = {}, callback) ⇒ AWS.Request
Retrieves a forecast for a single item, filtered by the supplied criteria.
The criteria is a key-value pair. - queryWhatIfForecast(params = {}, callback) ⇒ AWS.Request
Retrieves a what-if forecast.
.
Methods inherited from AWS.Service
makeRequest, makeUnauthenticatedRequest, waitFor, setupRequestListeners, defineService
Constructor Details
new AWS.ForecastQueryService(options = {}) ⇒ Object
Constructs a service object. This object has one method for each API operation.
Property Details
endpoint ⇒ AWS.Endpoint
Returns an Endpoint object representing the endpoint URL for service requests.
Method Details
queryForecast(params = {}, callback) ⇒ AWS.Request
Retrieves a forecast for a single item, filtered by the supplied criteria.
The criteria is a key-value pair. The key is either item_id
(or the equivalent non-timestamp, non-target field) from the TARGET_TIME_SERIES
dataset, or one of the forecast dimensions specified as part of the FeaturizationConfig
object.
By default, QueryForecast
returns the complete date range for the filtered forecast. You can request a specific date range.
To get the full forecast, use the CreateForecastExportJob operation.
Note: The forecasts generated by Amazon Forecast are in the same timezone as the dataset that was used to create the predictor.
queryWhatIfForecast(params = {}, callback) ⇒ AWS.Request
Retrieves a what-if forecast.