2023/02/15 - Amazon Fraud Detector - 5 new api methods
Changes This release introduces Lists feature which allows customers to reference a set of values in Fraud Detector's rules. With Lists, customers can dynamically manage these attributes in real time. Lists can be created/deleted and its contents can be modified using the Fraud Detector API.
Creates a list.
List is a set of input data for a variable in your event dataset. You use the input data in a rule that's associated with your detector. For more information, see Lists .
See also: AWS API Documentation
Request Syntax
client.create_list( name='string', elements=[ 'string', ], variableType='string', description='string', tags=[ { 'key': 'string', 'value': 'string' }, ] )
string
[REQUIRED]
The name of the list.
list
The names of the elements, if providing. You can also create an empty list and add elements later using the UpdateList API.
(string) --
string
The variable type of the list. You can only assign the variable type with String data type. For more information, see Variable types .
string
The description of the list.
list
A collection of the 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.
dict
Response Syntax
{}
Response Structure
(dict) --
Deletes the list, provided it is not used in a rule.
When you delete a list, Amazon Fraud Detector permanently deletes that list and the elements in the list.
See also: AWS API Documentation
Request Syntax
client.delete_list( name='string' )
string
[REQUIRED]
The name of the list to delete.
dict
Response Syntax
{}
Response Structure
(dict) --
Gets the metadata of either all the lists under the account or the specified list.
See also: AWS API Documentation
Request Syntax
client.get_lists_metadata( name='string', nextToken='string', maxResults=123 )
string
The name of the list.
string
The next token for the subsequent request.
integer
The maximum number of objects to return for the request.
dict
Response Syntax
{ 'lists': [ { 'name': 'string', 'description': 'string', 'variableType': 'string', 'createdTime': 'string', 'updatedTime': 'string', 'arn': 'string' }, ], 'nextToken': 'string' }
Response Structure
(dict) --
lists (list) --
The metadata of the specified list or all lists under the account.
(dict) --
The metadata of a list.
name (string) --
The name of the list.
description (string) --
The description of the list.
variableType (string) --
The variable type of the list.
createdTime (string) --
The time the list was created.
updatedTime (string) --
The time the list was last updated.
arn (string) --
The ARN of the list.
nextToken (string) --
The next page token.
Updates a list.
See also: AWS API Documentation
Request Syntax
client.update_list( name='string', elements=[ 'string', ], description='string', updateMode='REPLACE'|'APPEND'|'REMOVE', variableType='string' )
string
[REQUIRED]
The name of the list to update.
list
One or more list elements to add or replace. If you are providing the elements, make sure to specify the updateMode to use.
If you are deleting all elements from the list, use REPLACE for the updateMode and provide an empty list (0 elements).
(string) --
string
The new description.
string
The update mode (type).
Use APPEND if you are adding elements to the list.
Use REPLACE if you replacing existing elements in the list.
Use REMOVE if you are removing elements from the list.
string
The variable type you want to assign to the list.
Note
You cannot update a variable type of a list that already has a variable type assigned to it. You can assign a variable type to a list only if the list does not already have a variable type.
dict
Response Syntax
{}
Response Structure
(dict) --
Gets all the elements in the specified list.
See also: AWS API Documentation
Request Syntax
client.get_list_elements( name='string', nextToken='string', maxResults=123 )
string
[REQUIRED]
The name of the list.
string
The next token for the subsequent request.
integer
The maximum number of objects to return for the request.
dict
Response Syntax
{ 'elements': [ 'string', ], 'nextToken': 'string' }
Response Structure
(dict) --
elements (list) --
The list elements.
(string) --
nextToken (string) --
The next page token.