Schema: LiveSurfaceDetail (ID: 1130)
LiveSurfaceDetail (surfaceType = 'Live') records are computed and publish continuously during trading hours and represent a current best implied volatility market fit details.
SurfaceType = 'PriorDay' records contain the `closing surface record from the prior trading period (usually from just before the last main session close).
METADATA
Attribute | Value |
---|---|
Topic | 1000-analytics |
MLink Token | SystemData |
SRSE Product | SRAnalytics |
Note: The symbol
=
next to a field number indicates that it is a primary key.
BODY
# | Field | Type | Comment |
---|---|---|---|
10= | ekey | ExpiryKey | |
11= | surfaceType | enum : SurfaceCurveType | |
100 | ticker | TickerKey | underlying stock key that this option expiration attaches to |
101 | fkey | ExpiryKey | underlying future key (if any) |
102 | uPrcDriverKey | ExpiryKey | underlier driver key |
103 | uPrcDriverType | enum : SpdrKeyType | underlier driver key type (stock or future) |
104 | ddiv | float | (expected) cumulative discrete dividend $ amounts prior to expiration |
105 | ddivPv | float | (expected) cumulative npv of discrete dividend $ amounts prior to expiration (SR global rate curve) |
106 | ddivSource | enum : DDivSource | Forecast if any of the dividends prior to expiry are forecast rather than announced |
107 | symbolRatio | float | underlier price ratio (usually 1.0 or a multi-hedge option price ratio; if one exists) |
108 | exType | enum : ExerciseType | exercise type (American or European) |
109 | modelType | enum : CalcModelType | option pricing model used for price calcs (Normal, LogNormal, etc.) |
110 | priceType | enum : CalcPriceType | Equity has independent sdiv and rate, Future has sdiv = rate |
111 | earnCnt | float | number of qualifying earnings events prior to expiration [can be fractional] (from StockEarningsCalendar) |
112 | earnCntAdj | float | number of qualifying earnings events prior to expiration [adjusted] (from StockEarningsCalendar + LiveSurfaceTerm) |
113 | moneynessType | enum : MoneynessType | moneyness (xAxis) convention |
114 | priceQuoteType | enum : PriceQuoteType | Price or Vol |
115 | atmVolHist | float | historical realized volatility (includes eMoveHist x earnCntAdj adjustment). Note that this is the default atmVol if no implied markets existed previous day. |
116 | atmCenHist | float | censored (earnings events removed) historical realized volatility. Trailing periods is 2x forward time to expiration. From HistoricalVolatility(windowType=hlCen).mv_nnn |
117 | uBetaHist | float | beta (this underlier vs basis underlier; T + 1 week) |
118 | eMove | float | implied earnings move (from LiveSurfaceTerm) |
119 | eMoveHist | float | historical earnings move (avg of trailing 8 moves). From StockEarningsCalendar.eMoveHist |
120 | minXAxis | float | minimum xAxis value; left most point with a valid supporting strike |
121 | maxXAxis | float | maximum xAxis value; right most point with a valid supporting strike |
122 | atmPhi | float | surface phi @ xAxis = 0 |
123 | atmRho | float | surface rho @ xAxis = 0 |
124 | atmVega | float | surface vega @ xAxis = 0 |
125 | uPrcRatio | double | uPrcAdj = uPrc * uPrcRatioFit |
126 | pwidth | float | minimum mkt premium width |
127 | vwidth | float | minimum mkt volatility width |
128 | cCnt | ushort | num call strikes in base fit |
129 | pCnt | ushort | num put strikes in base fit |
130 | hasBracketMin | enum : YesNo | |
131 | surfaceSkewType | enum : SurfaceSkewType | |
132 | cBidMiss | byte | number of call bid violations (surface outside the market) |
133 | cAskMiss | byte | number of call ask violations (surface outside the market) |
134 | pBidMiss | byte | number of put bid violations |
135 | pAskMiss | byte | number of put ask violations |
136 | fitScoreT0 | float | |
137 | fitScoreT1 | float | |
138 | cumFitScoreT0 | float | |
139 | cumFitScoreT1 | float | |
140 | fitCounter | int | number of fit/count passes (current trade date / market open) |
141 | timestamp | DateTime |
Get Schema API Call
- Python
- cUrl
import requests
# Replace with your desired MLINK URL
MLINK_PROD_URL = 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json'
# Replace with your MLINK API Key
API_KEY = 'XXXX-XXXX-XXXX-XXXX'
# Replace with your desired MsgType.
MSG_TYPE = 'LiveSurfaceDetail'
# Request Parameters for Get Schema Of The MsgType
params = {
#Required Parameters
"apiKey": API_KEY,
"cmd": 'getschema',
"msgType": MSG_TYPE,
}
response = requests.get(MLINK_PROD_URL, params=params)
curl -G 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json' \
--data-urlencode 'apiKey=XXXX-XXXX-XXXX-XXXX' \
--data-urlencode 'cmd=getschema' \
--data-urlencode 'msgType=LiveSurfaceDetail'
Get Msg API Call
- Python
- cUrl
import requests
# Replace with your desired MLINK URL
MLINK_PROD_URL = 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json'
# Replace with your MLINK API Key
API_KEY = 'XXXX-XXXX-XXXX-XXXX'
# Replace with your desired MsgType.
MSG_TYPE = 'LiveSurfaceDetail'
# Replace with your pkey value for getting the specific message desired
PKEY = 'ReplaceThisValueForTheQueryToWork'
# Replace with your desired view. A "|" separated list of views can be provided
# If no view is provided, all views will be returned.
VIEW = 'ticker|fkey|uPrcDriverKey|uPrcDriverType|ddiv|ddivPv|ddivSource|symbolRatio|exType|modelType|priceType|earnCnt|earnCntAdj|moneynessType|priceQuoteType|atmVolHist|atmCenHist|uBetaHist|eMove|eMoveHist|minXAxis|maxXAxis|atmPhi|atmRho|atmVega|uPrcRatio|pwidth|vwidth|cCnt|pCnt|hasBracketMin|surfaceSkewType|cBidMiss|cAskMiss|pBidMiss|pAskMiss|fitScoreT0|fitScoreT1|cumFitScoreT0|cumFitScoreT1|fitCounter|timestamp'
# Replace with your desired where clause.
# a string in the form "field1:eq:valuse" or "(field1:ne:value1 & field1:ne:value2)
# "WHERE" clauses can contain the following comparison symbols:
# :gt: is greater than
# :ge: is greater than or equal to
# :lt: is less than
# :le: is less than or equal to
# :eq: is equal
# :ne: is not equal
# %26 is an AND statement
# | is an OR statement
# :sw: is starts with
# :ew: is ends with
# :cv: is contains values
# :nv: is does not contain value
# :cb: is contained between (two dates for instance) separated by '$'
WHERE = ''
# Request Parameters for getmsg Of The MsgType
params = {
# Required Parameters
"apiKey": API_KEY,
"cmd": 'getmsg',
"pkey": PKEY,
"msgType": MSG_TYPE,
# Optional Parameters
"view": VIEW,
"where": WHERE
}
response = requests.get(MLINK_PROD_URL, params=params)
curl -G 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json' \
--data-urlencode 'apiKey=XXXX-XXXX-XXXX-XXXX' \
--data-urlencode 'cmd=getmsg' \
--data-urlencode 'pkey=ReplaceThisValueForTheQueryToWork' \
--data-urlencode 'msgType=LiveSurfaceDetail' \
--data-urlencode 'view=ticker|fkey|uPrcDriverKey|uPrcDriverType|ddiv|ddivPv|ddivSource|symbolRatio|exType|modelType|priceType|earnCnt|earnCntAdj|moneynessType|priceQuoteType|atmVolHist|atmCenHist|uBetaHist|eMove|eMoveHist|minXAxis|maxXAxis|atmPhi|atmRho|atmVega|uPrcRatio|pwidth|vwidth|cCnt|pCnt|hasBracketMin|surfaceSkewType|cBidMiss|cAskMiss|pBidMiss|pAskMiss|fitScoreT0|fitScoreT1|cumFitScoreT0|cumFitScoreT1|fitCounter|timestamp' \
--data-urlencode 'where='
Get Msgs API Call
- Python
- cUrl
import requests
# Replace with your desired MLINK URL
MLINK_PROD_URL = 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json'
# Replace with your MLINK API Key
API_KEY = 'XXXX-XXXX-XXXX-XXXX'
# Replace with your desired MsgType.
MSG_TYPE = 'LiveSurfaceDetail'
# Replace with your desired view. A "|" separated list of views can be provided
# If no view is provided, all views will be returned
VIEW = 'ticker|fkey|uPrcDriverKey|uPrcDriverType|ddiv|ddivPv|ddivSource|symbolRatio|exType|modelType|priceType|earnCnt|earnCntAdj|moneynessType|priceQuoteType|atmVolHist|atmCenHist|uBetaHist|eMove|eMoveHist|minXAxis|maxXAxis|atmPhi|atmRho|atmVega|uPrcRatio|pwidth|vwidth|cCnt|pCnt|hasBracketMin|surfaceSkewType|cBidMiss|cAskMiss|pBidMiss|pAskMiss|fitScoreT0|fitScoreT1|cumFitScoreT0|cumFitScoreT1|fitCounter|timestamp'
# Replace with your desired where clause.
# a string in the form "field1:eq:value" or "(field1:ne:value1 & field1:ne:value2)
# "WHERE" clauses can contain the following comparison symbols:
# :gt: is greater than
# :ge: is greater than or equal to
# :lt: is less than
# :le: is less than or equal to
# :eq: is equal
# :ne: is not equal
# %26 is an AND statement
# | is an OR statement
# :sw: is starts with
# :ew: is ends with
# :cv: is contains values
# :nv: is does not contain value
# :cb: is contained between (two dates for instance) separated by '$'
WHERE = ''
# Replace with your desired limit of how many messages you receive. The default limit is 500
LIMIT = 500
# Order clause eg. "(field1:DESC | field1:ASC | field2:DESC:ABS | field2:ASC:ABS" (default is unordered; default is faster)
ORDER = 'ticker:ASC'
# Request Parameters for getmsgs Of The MsgType
params = {
# Required Parameters
"apiKey": API_KEY,
"cmd": 'getmsgs',
"msgType": MSG_TYPE,
# Optional Parameters
"view": VIEW,
"where": WHERE,
"limit": LIMIT,
"order": ORDER
}
response = requests.get(MLINK_PROD_URL, params=params)
curl -G 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json' \
--data-urlencode 'apiKey=XXXX-XXXX-XXXX-XXXX' \
--data-urlencode 'cmd=getmsgs' \
--data-urlencode 'msgType=LiveSurfaceDetail' \
--data-urlencode 'view=ticker|fkey|uPrcDriverKey|uPrcDriverType|ddiv|ddivPv|ddivSource|symbolRatio|exType|modelType|priceType|earnCnt|earnCntAdj|moneynessType|priceQuoteType|atmVolHist|atmCenHist|uBetaHist|eMove|eMoveHist|minXAxis|maxXAxis|atmPhi|atmRho|atmVega|uPrcRatio|pwidth|vwidth|cCnt|pCnt|hasBracketMin|surfaceSkewType|cBidMiss|cAskMiss|pBidMiss|pAskMiss|fitScoreT0|fitScoreT1|cumFitScoreT0|cumFitScoreT1|fitCounter|timestamp' \
--data-urlencode 'where=' \
--data-urlencode 'limit=500' \
--data-urlencode 'order=ticker:ASC'
Get Aggregate API Call
- Python
- cUrl
import requests
# Replace with your desired MLINK URL
MLINK_PROD_URL = 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json'
# Replace with your MLINK API Key
API_KEY = 'XXXX-XXXX-XXXX-XXXX'
# Replace with your desired MsgType.
MSG_TYPE = 'LiveSurfaceDetail'
# Replace with fields you want to see aggregate values for. A "|" separated list of measures should be provided
MEASURE = 'ticker|fkey|uPrcDriverKey|uPrcDriverType|ddiv|ddivPv|ddivSource|symbolRatio|exType|modelType|priceType|earnCnt|earnCntAdj|moneynessType|priceQuoteType|atmVolHist|atmCenHist|uBetaHist|eMove|eMoveHist|minXAxis|maxXAxis|atmPhi|atmRho|atmVega|uPrcRatio|pwidth|vwidth|cCnt|pCnt|hasBracketMin|surfaceSkewType|cBidMiss|cAskMiss|pBidMiss|pAskMiss|fitScoreT0|fitScoreT1|cumFitScoreT0|cumFitScoreT1|fitCounter|timestamp'
# Replace with fields you want to see aggregated. A "|" separated list of fields should be provided
GROUP = 'uPrcDriverType|ddivSource|exType|modelType|priceType|moneynessType|priceQuoteType|hasBracketMin|surfaceSkewType'
# Replace with your desired where clause.
# a string in the form "field1:eq:value" or "(field1:ne:value1 & field1:ne:value2)
# "WHERE" clauses can contain the following comparison symbols:
# :gt: is greater than
# :ge: is greater than or equal to
# :lt: is less than
# :le: is less than or equal to
# :eq: is equal
# :ne: is not equal
# %26 is an AND statement
# | is an OR statement
# :sw: is starts with
# :ew: is ends with
# :cv: is contains values
# :nv: is does not contain value
# :cb: is contained between (two dates for instance) separated by '$'
WHERE = ''
# Request Parameters for getaggregate Of The MsgType
params = {
# Required Parameters
"apiKey": API_KEY,
"cmd": 'getaggregate',
"msgType": MSG_TYPE,
"measure": MEASURE,
"group": GROUP,
# Optional Parameters
"where": WHERE,
}
response = requests.get(MLINK_PROD_URL, params=params)
curl -G 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json' \
--data-urlencode 'apiKey=XXXX-XXXX-XXXX-XXXX' \
--data-urlencode 'cmd=getaggregate' \
--data-urlencode 'msgType=LiveSurfaceDetail' \
--data-urlencode 'measure=ticker|fkey|uPrcDriverKey|uPrcDriverType|ddiv|ddivPv|ddivSource|symbolRatio|exType|modelType|priceType|earnCnt|earnCntAdj|moneynessType|priceQuoteType|atmVolHist|atmCenHist|uBetaHist|eMove|eMoveHist|minXAxis|maxXAxis|atmPhi|atmRho|atmVega|uPrcRatio|pwidth|vwidth|cCnt|pCnt|hasBracketMin|surfaceSkewType|cBidMiss|cAskMiss|pBidMiss|pAskMiss|fitScoreT0|fitScoreT1|cumFitScoreT0|cumFitScoreT1|fitCounter|timestamp' \
--data-urlencode 'group=uPrcDriverType|ddivSource|exType|modelType|priceType|moneynessType|priceQuoteType|hasBracketMin|surfaceSkewType' \
--data-urlencode 'where='
Get Count API Call
- Python
- cUrl
import requests
# Replace with your desired MLINK URL
MLINK_PROD_URL = 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json'
# Replace with your MLINK API Key
API_KEY = 'XXXX-XXXX-XXXX-XXXX'
# Replace with your desired MsgType.
MSG_TYPE = 'LiveSurfaceDetail'
# Replace with your desired where clause.
# a string in the form "field1:eq:value" or "(field1:ne:value1 & field1:ne:value2)
# "WHERE" clauses can contain the following comparison symbols:
# :gt: is greater than
# :ge: is greater than or equal to
# :lt: is less than
# :le: is less than or equal to
# :eq: is equal
# :ne: is not equal
# %26 is an AND statement
# | is an OR statement
# :sw: is starts with
# :ew: is ends with
# :cv: is contains values
# :nv: is does not contain value
# :cb: is contained between (two dates for instance) separated by '$'
WHERE = ''
# Request Parameters for getCount Of The MsgType
params = {
# Required Parameters
"apiKey": API_KEY,
"cmd": 'getcount',
"msgType": MSG_TYPE,
# Optional Parameters
"where": WHERE,
}
response = requests.get(MLINK_PROD_URL, params=params)
curl -G 'https://mlink-live.nms.saturn.spiderrockconnect.com/rest/json' \
--data-urlencode 'apiKey=XXXX-XXXX-XXXX-XXXX' \
--data-urlencode 'cmd=getcount' \
--data-urlencode 'msgType=LiveSurfaceDetail' \
--data-urlencode 'where='