Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This section provides messaging examples for CME Market Data Over Websocket WebSocket API.

Table of Contents
maxLevel2

Example 1 - Login Authenticated

...

In this example,  a client system is using market data subscription filters to filter by month/year (periodCodes ) and message type (spreadReportTypes).

Code Block
languagejs
{
    "header":
    {
        "messageType": "SUBSCRIBE",
        "sentTime": "2022-12-13T15:25:56.600000000Z",
        "version": "1.0",
        "requestId": 1477
    },
    "payload":
    {
        "subscriptionMessageTypes":
        [
            "TOB","TRD","STAT"
        ],
        "subscriptions":
        [
            {
                "productType": "OOF",
                "productCode": "E1C",
                "periodCodes": ["202409", "202409w1"]
                "spreadReportTypes":
                [
                    "OUTRIGHT"
                ]
            }
        ]
    }
}

Example 4 - Multiple Top of Book and Trade Subscriptions

In this example, a client system successfully subscribes to multiple products.

...