GetPrediction - Amazon Fraud Detector


Evaluates an event against a detector version. If a version ID is not provided, the detector’s (ACTIVE) version is used.

Request Syntax

{ "detectorId": "string", "detectorVersionId": "string", "eventAttributes": { "string" : "string" }, "eventId": "string", "externalModelEndpointDataBlobs": { "string" : { "byteBuffer": blob, "contentType": "string" } } }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.


The detector ID.

Type: String

Required: Yes


The detector version ID.

Type: String

Required: No


Names of variables you defined in Amazon Fraud Detector to represent event data elements and their corresponding values for the event you are sending for evaluation.

Type: String to string map

Key Length Constraints: Minimum length of 1. Maximum length of 64.

Value Length Constraints: Minimum length of 1. Maximum length of 256.

Required: No


The unique ID used to identify the event.

Type: String

Required: Yes


The Amazon SageMaker model endpoint input data blobs.

Type: String to ModelEndpointDataBlob object map

Required: No

Response Syntax

{ "modelScores": [ { "modelVersion": { "modelId": "string", "modelType": "string", "modelVersionNumber": "string" }, "scores": { "string" : number } } ], "outcomes": [ "string" ] }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.


The model scores for models used in the detector version.

Type: Array of ModelScores objects


The prediction outcomes.

Type: Array of strings


For information about the errors that are common to all actions, see Common Errors.


An exception indicating an internal server error.

HTTP Status Code: 500


An exception indicating the specified resource was not found.

HTTP Status Code: 400


An exception indicating a throttling error.

HTTP Status Code: 400


An exception indicating a specified value is not allowed.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: