LSEG Data Library for TypeScript

Delivery.OMMStream.Definition object

Creates a definition that can be used to get the OMMStream that can be used to subscribe to streaming items of any Domain Model (e.g. MarkePrice, MarketByPrice...) exposed by the underlying WebSocket protocol of the Delivery Platform (formerly Refinitiv Data Platform).

Syntax

Delivery.OMMStream.Definition(params: Delivery.OMMStreamRequestParams)

Parameters

Value Description Data type Optional Default value
params An object literal of type Delivery.OMMStreamRequestParams. object No -

Delivery.OMMStreamRequestParams properties:

Value Description Data type Optional Default value
name The item name of interest. string No -
service Offers the ability to use a specific service to manage the realtime streaming data. string Yes -
domain The domain for the specific data of interest. For example, MarketPrice, MarketByPrice, MarketByOrder, etc. string Yes 'MarketPrice'
streaming Specifies whether the stream will deliver the initial image followed by updates. boolean Yes true
fields The specific fields to be delivered when messages arrive. string[] Yes /all fields/
filter A filter specification used to request which filter entries will be present in a Filter List payload. number Yes -
api Connection name to be used for a particular Item Stream. All the configurations from this connection will be applied unless another connection name is specified. string Yes 'streaming/pricing/main'
extendedParams Additional parameters to apply to the request. object Yes -

Returned value

OMMStreamDefinition object.

Usage

The following example demonstrates how to create an OMM stream definition:

import { Delivery } from '@lsegroup/data';

const definition = Delivery.OMMStream.Definition({
    name: 'EUR=',
    fields: ['DSPLY_NAME', 'PRCTCK_1', 'TRDPRC_1', 'PCTCHNG', 'HIGH_1', 'LOW_1']
})
`
222 words (1:10 mins)