Live Option Basket Calculator via MLink
The SpiderRock Option Basket Calculator (Listed and FLEX) allows clients to send a collection of option definitions (FLEX/Listed) OptionItemDef to the server, grouped into a basket identified by a unique basket number. Clients can then request the server to recalculate the options in the basket on demand using a GetOptionBasket request. The MLink Servers will respond with the recalculated option details in the form of OptionItemCalc objects.
Note: The Live Option Basket Calculator will work for a basket of listed options only, a basket of FLEX options only, and a basket of both Listed and FLEX options.
Basket Calculator messages are available to SpiderRock Connect clients (hereafter "Subscribers") via SpiderRock Connect's MLink/WebSocket API and MLink/REST API. Clients have the possibility to override option default values when they define their basket. Overrideable values include volatility, underlying price, rate, model type etc... To gain access, clients must secure an MLink API Key, connect to an MLink/WebSocket server, and define their basket sending OptionItemDef messages.
This page focuses on the messages relevant to the Basket Calculator users. Interested users should also review SpiderRock Connect's more general MLink/Websocket API documentation for information on connecting, subscribing, sending, and receiving messages.
Live Option Basket Calculator
Message | Source | Description |
---|---|---|
OptionItemDef | Subscriber | This is the primary message used to define the Option Basket that an that a user is interested in. Option can be LISTED or FLEX |
GetOptionBasket | Subscriber | Trigger Option Basket Calculator |
OptionItemCalc | SR | Live option basket pricing item calculation returned by the Basket Calc trigger |
Workflow
-
Client Sends OptionItemDef Objects
The client sends multiple OptionItemDef objects to the MLink server, each representing an option the client is interested in. These objects include key details about the option, such as option key, volatility, underlying price, rate, and other relevant information.
Each OptionItemDef object includes a basketNumber field that groups multiple options into a single basket.
-
Client Requests Recalculation with GetBasketCalc
The client sends a GetBasketCalc object to the server, specifying the basketNumber of the basket they want recalculated. This object serves as a request for the server to perform calculations on all the options within the specified basket.
-
Server Processes the Request
Upon receiving the GetBasketCalc request, the server processes the request by recalculating the details of each option in the basket. This involves performing various computations based on the parameters provided in the OptionItemDef objects.
-
Server Sends OptionItemCalc Objects
The server responds to the client's GetBasketCalc request by sending back multiple OptionItemCalc JSON objects. Each object contains the recalculated details of an option in the basket, including values such as delta, gamma, theta, and other Greeks, along with the option price and any error messages.
For further information on how volatility for FLEX options is calculated, please read our article on FLEX Volatility Interpolation.