Amazon Fraud Detector

2023/05/31 - Amazon Fraud Detector - 2 updated api methods

Changes  This release enables publishing event predictions from Amazon Fraud Detector (AFD) to Amazon EventBridge. For example, after getting predictions from AFD, Amazon EventBridge rules can be configured to trigger notification through an SNS topic, send a message with SES, or trigger Lambda workflows.

GetEventTypes (updated) Link ¶
Changes (response)
{'eventTypes': {'eventOrchestration': {'eventBridgeEnabled': 'boolean'}}}

Gets all event types or a specific event type if name is provided. This is a paginated API. If you provide a null maxResults , this action retrieves a maximum of 10 records per page. If you provide a maxResults , the value must be between 5 and 10. To get the next page results, provide the pagination token from the GetEventTypesResponse as part of your request. A null pagination token fetches the records from the beginning.

See also: AWS API Documentation

Request Syntax

client.get_event_types(
    name='string',
    nextToken='string',
    maxResults=123
)
type name

string

param name

The name.

type nextToken

string

param nextToken

The next token for the subsequent request.

type maxResults

integer

param maxResults

The maximum number of objects to return for the request.

rtype

dict

returns

Response Syntax

{
    'eventTypes': [
        {
            'name': 'string',
            'description': 'string',
            'eventVariables': [
                'string',
            ],
            'labels': [
                'string',
            ],
            'entityTypes': [
                'string',
            ],
            'eventIngestion': 'ENABLED'|'DISABLED',
            'ingestedEventStatistics': {
                'numberOfEvents': 123,
                'eventDataSizeInBytes': 123,
                'leastRecentEvent': 'string',
                'mostRecentEvent': 'string',
                'lastUpdatedTime': 'string'
            },
            'lastUpdatedTime': 'string',
            'createdTime': 'string',
            'arn': 'string',
            'eventOrchestration': {
                'eventBridgeEnabled': True|False
            }
        },
    ],
    'nextToken': 'string'
}

Response Structure

  • (dict) --

    • eventTypes (list) --

      An array of event types.

      • (dict) --

        The event type details.

        • name (string) --

          The event type name.

        • description (string) --

          The event type description.

        • eventVariables (list) --

          The event type event variables.

          • (string) --

        • labels (list) --

          The event type labels.

          • (string) --

        • entityTypes (list) --

          The event type entity types.

          • (string) --

        • eventIngestion (string) --

          If Enabled , Amazon Fraud Detector stores event data when you generate a prediction and uses that data to update calculated variables in near real-time. Amazon Fraud Detector uses this data, known as INGESTED_EVENTS , to train your model and improve fraud predictions.

        • ingestedEventStatistics (dict) --

          Data about the stored events.

          • numberOfEvents (integer) --

            The number of stored events.

          • eventDataSizeInBytes (integer) --

            The total size of the stored events.

          • leastRecentEvent (string) --

            The oldest stored event.

          • mostRecentEvent (string) --

            The newest stored event.

          • lastUpdatedTime (string) --

            Timestamp of when the stored event was last updated.

        • lastUpdatedTime (string) --

          Timestamp of when the event type was last updated.

        • createdTime (string) --

          Timestamp of when the event type was created.

        • arn (string) --

          The entity type ARN.

        • eventOrchestration (dict) --

          The event orchestration status.

          • eventBridgeEnabled (boolean) --

            Specifies if event orchestration is enabled through Amazon EventBridge.

    • nextToken (string) --

      The next page token.

PutEventType (updated) Link ¶
Changes (request)
{'eventOrchestration': {'eventBridgeEnabled': 'boolean'}}

Creates or updates an event type. An event is a business activity that is evaluated for fraud risk. With Amazon Fraud Detector, you generate fraud predictions for events. An event type defines the structure for an event sent to Amazon Fraud Detector. This includes the variables sent as part of the event, the entity performing the event (such as a customer), and the labels that classify the event. Example event types include online payment transactions, account registrations, and authentications.

See also: AWS API Documentation

Request Syntax

client.put_event_type(
    name='string',
    description='string',
    eventVariables=[
        'string',
    ],
    labels=[
        'string',
    ],
    entityTypes=[
        'string',
    ],
    eventIngestion='ENABLED'|'DISABLED',
    tags=[
        {
            'key': 'string',
            'value': 'string'
        },
    ],
    eventOrchestration={
        'eventBridgeEnabled': True|False
    }
)
type name

string

param name

[REQUIRED]

The name.

type description

string

param description

The description of the event type.

type eventVariables

list

param eventVariables

[REQUIRED]

The event type variables.

  • (string) --

type labels

list

param labels

The event type labels.

  • (string) --

type entityTypes

list

param entityTypes

[REQUIRED]

The entity type for the event type. Example entity types: customer, merchant, account.

  • (string) --

type eventIngestion

string

param eventIngestion

Specifies if ingestion is enabled or disabled.

type tags

list

param tags

A collection of key and value pairs.

  • (dict) --

    A key and value pair.

    • key (string) -- [REQUIRED]

      A tag key.

    • value (string) -- [REQUIRED]

      A value assigned to a tag key.

type eventOrchestration

dict

param eventOrchestration

Enables or disables event orchestration. If enabled, you can send event predictions to select AWS services for downstream processing of the events.

  • eventBridgeEnabled (boolean) -- [REQUIRED]

    Specifies if event orchestration is enabled through Amazon EventBridge.

rtype

dict

returns

Response Syntax

{}

Response Structure

  • (dict) --