blpapi.Event

class blpapi.Event

A single event resulting from a subscription or a request.

Event objects are created by the API and passed to the application either through a registered eventHandler or EventQueue or returned either from the nextEvent() or tryNextEvent() methods. Event objects contain Message objects which can be accessed using an iteration over Event:

for message in event:
    ...

The Event object is a handle to an event. The event is the basic unit of work provided to applications. Each Event object consists of an eventType attribute and zero or more Message objects.

Event objects are always created by the API, never directly by the application.

The class attributes represent the possible types of event.

ADMIN = 1

Admin event

AUTHORIZATION_STATUS = 11

Status updates for user authorization

PARTIAL_RESPONSE = 6

A partial response to a request

REQUEST = 15

Request event

REQUEST_STATUS = 4

Status updates for a request

RESOLUTION_STATUS = 12

Status updates for a resolution operation

RESPONSE = 5

The final (possibly only) response to a request

SERVICE_STATUS = 9

Status updates for a service

SESSION_STATUS = 2

Status updates for a session

SUBSCRIPTION_DATA = 8

Data updates resulting from a subscription

SUBSCRIPTION_STATUS = 3

Status updates for a subscription

TIMEOUT = 10

An Event returned from nextEvent() if it timed out

TOKEN_STATUS = 14

Status updates for a generate token request

TOPIC_STATUS = 13

Status updates about topics for service providers

UNKNOWN = -1

Unknown event

__iter__()
Returns

Iterator over messages contained in this Event.

destroy()

Destructor

eventType()
Returns

Type of messages contained by this Event.

Return type

int