AWS.PersonalizeRuntime — 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.

Overview

Constructs a service interface object. Each API operation is exposed as a function on service.

Service Description

Sending a Request Using PersonalizeRuntime

var personalizeruntime = new AWS.PersonalizeRuntime();
personalizeruntime.getActionRecommendations(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 PersonalizeRuntime object uses this specific API, you can construct the object by passing the apiVersion option to the constructor:

var personalizeruntime = new AWS.PersonalizeRuntime({apiVersion: '2018-05-22'});

You can also set the API version globally in AWS.config.apiVersions using the personalizeruntime service identifier:

AWS.config.apiVersions = {
  personalizeruntime: '2018-05-22',
  // other service API versions
};

var personalizeruntime = new AWS.PersonalizeRuntime();

Constructor Summarycollapse

Property Summarycollapse

Properties inherited from AWS.Service

apiVersions

Method Summarycollapse

Methods inherited from AWS.Service

makeRequest, makeUnauthenticatedRequest, waitFor, setupRequestListeners, defineService

Constructor Details

new AWS.PersonalizeRuntime(options = {}) ⇒ Object

Constructs a service object. This object has one method for each API operation.

Property Details

endpointAWS.Endpoint

Returns an Endpoint object representing the endpoint URL for service requests.

Method Details

getActionRecommendations(params = {}, callback) ⇒ AWS.Request

Returns a list of recommended actions in sorted in descending order by prediction score. Use the GetActionRecommendations API if you have a custom campaign that deploys a solution version trained with a PERSONALIZED_ACTIONS recipe.

For more information about PERSONALIZED_ACTIONS recipes, see PERSONALIZED_ACTIONS recipes. For more information about getting action recommendations, see Getting action recommendations.

getPersonalizedRanking(params = {}, callback) ⇒ AWS.Request

Re-ranks a list of recommended items for the given user. The first item in the list is deemed the most likely item to be of interest to the user.

Note: The solution backing the campaign must have been created using a recipe of type PERSONALIZED_RANKING.

getRecommendations(params = {}, callback) ⇒ AWS.Request

Returns a list of recommended items. For campaigns, the campaign's Amazon Resource Name (ARN) is required and the required user and item input depends on the recipe type used to create the solution backing the campaign as follows:

Note: Campaigns that are backed by a solution created using a recipe of type PERSONALIZED_RANKING use the API.

For recommenders, the recommender's ARN is required and the required item and user input depends on the use case (domain-based recipe) backing the recommender. For information on use case requirements see Choosing recommender use cases.