EventsOperations Class

EventsOperations operations.

Inheritance
builtins.object
EventsOperations

Constructor

EventsOperations(client, config, serializer, deserializer)

Parameters

client
Required

Client for service requests.

config
Required

Configuration of service client.

serializer
Required

An object model serializer.

deserializer
Required

An object model deserializer.

Methods

activate

Report that the specified event was actually displayed to the user and a reward should be expected for it.

reward

Report reward to allocate to the top ranked action for the specified event.

activate

Report that the specified event was actually displayed to the user and a reward should be expected for it.

activate(event_id, custom_headers=None, raw=False, **operation_config)

Parameters

event_id
str
Required

The event ID this activation applies to.

custom_headers
dict
default value: None

headers that will be added to the request

raw
bool
default value: False

returns the direct response alongside the deserialized response

operation_config
Required

Operation configuration overrides.

Returns

None or ClientRawResponse if raw=true

Return type

None,

Exceptions

reward

Report reward to allocate to the top ranked action for the specified event.

reward(event_id, value, custom_headers=None, raw=False, **operation_config)

Parameters

event_id
str
Required

The event id this reward applies to.

value
float
Required

Reward to be assigned to an action. Value should be between -1 and 1 inclusive.

custom_headers
dict
default value: None

headers that will be added to the request

raw
bool
default value: False

returns the direct response alongside the deserialized response

operation_config
Required

Operation configuration overrides.

Returns

None or ClientRawResponse if raw=true

Return type

None,

Exceptions

Attributes

models

models = <module 'azure.cognitiveservices.personalizer.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.9.12\\x64\\lib\\site-packages\\azure\\cognitiveservices\\personalizer\\models\\__init__.py'>