Skip to main content
Version: Upcoming

Schema: FutureRiskDetailV5 (ID: 4780)

FutureRiskDetail records contain semi-static markup detail for FutureRiskSummary records.

METADATA

AttributeValue
Topic4740-risk-v5
MLink TokenClientRisk
SRSE ProductSRRisk

Note: The symbol = next to a field number indicates that it is a primary key.

BODY

#FieldTypeComment
10=fkeyExpiryKey
11=accntstring(16)
12=tradeDateDateKey
13=clientFirmstring(16)SR assigned client firm
100periodEndTimeDateTimeDTTM of the end of the current trading period
106viewGroup1string(12)Account Group #1 (SR Assigned) used to organize account groups [AccountConfig.viewGroup1]
109viewGroup2string(12)Account Group #2 (SR Assigned) used to organize account groups [AccountConfig.viewGroup2]
112viewGroup3string(12)Account Group #3 (SR Assigned) used to organize account groups [AccountConfig.viewGroup3]
115futStatusenum : FutStatus
118optStatusenum : OptStatus
121riskClassstring(8)Symbol Risk Class Code (user supplied) [SymbolControl.riskClass]
124theoModelstring(16)SR assigned theo model tag (associated with user supplied theo surfaces) [AccountConfig.theoModel]
127theoModel2string(16)SR assigned theo model#2 tag (associated with user supplied theo surfaces) [AccountConfig.theoModel2]
130hedgeDeltaRuleenum : HedgeDeltaRuleHedgeDelta Source (IVol = use SR implied surface (sticky strike), IvS = use SR surface (sticky delta), TVol = use user supplied theo surface (sticky strike), TvS = use user supplied theo surface and atm veSlope (sticky delta)) [AccountConfig.hedgeDelta]
133holdReasonenum : HoldReasonUser supplied description (only informational) [SymbolControl.holdReason]
136binaryDaysfloatFractional days [0 - 5.0] prior to expiration after which hedgeDeltas become binary [-1.0, -0.5, 0, +0.5, +1.0] [SymbolControl.binaryDays]
139ctrlUpdateDateTimelast update dttm of SymbolControl record [SymbolControl.timestamp]
142symbolTypeenum : SymbolTypeSymbolType (Equity, ETF, ShortETF, ADR, CashIndex, FutureComplex)
145namestring(16)Symbol name/description
148betafloatbeta (usually beta to SPX; see AccountConfig.betaSource)
151betaSourceenum : BetaSource
154futVolumefloattrailing 30 day average daily stock volume
157optVolumefloattrailing 30 day average daily option volume
160marginTypeenum : MarginTypemargin slide type: NMS_Equity = +/- 15%, NMS_Index = -8%/+6%, NMS_Medium = +/-10%
163isYieldBasedenum : YesNois the symbol a yield based future;can affect greeks and pricing (eg, eurodollars)
166shortTermVolfloatestimated/implied short term underlier volatility
169pointValuefloatpoint value of this future
172pointCurrencyenum : Currency
175underliersPerCnintunderliers per contract of the futures associated with this symbol (if any) [default = 1]
178underlierTypeenum : UnderlierType
181timestampDateTime

Get Schema API Call

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 = 'FutureRiskDetailV5'

# 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)

Get Msg API Call

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 = 'FutureRiskDetailV5'

# 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 = 'periodEndTime|viewGroup1|viewGroup2|viewGroup3|futStatus|optStatus|riskClass|theoModel|theoModel2|hedgeDeltaRule|holdReason|binaryDays|ctrlUpdate|symbolType|name|beta|betaSource|futVolume|optVolume|marginType|isYieldBased|shortTermVol|pointValue|pointCurrency|underliersPerCn|underlierType|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 = 'accnt:eq:ExampleString'

# 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)

Get Msgs API Call

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 = 'FutureRiskDetailV5'

# Replace with your desired view. A "|" separated list of views can be provided
# If no view is provided, all views will be returned
VIEW = 'periodEndTime|viewGroup1|viewGroup2|viewGroup3|futStatus|optStatus|riskClass|theoModel|theoModel2|hedgeDeltaRule|holdReason|binaryDays|ctrlUpdate|symbolType|name|beta|betaSource|futVolume|optVolume|marginType|isYieldBased|shortTermVol|pointValue|pointCurrency|underliersPerCn|underlierType|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 = 'accnt:eq:ExampleString'

# 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 = 'periodEndTime: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)

Get Aggregate API Call

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 = 'FutureRiskDetailV5'

# Replace with fields you want to see aggregate values for. A "|" separated list of measures should be provided
MEASURE = 'periodEndTime|viewGroup1|viewGroup2|viewGroup3|futStatus|optStatus|riskClass|theoModel|theoModel2|hedgeDeltaRule|holdReason|binaryDays|ctrlUpdate|symbolType|name|beta|betaSource|futVolume|optVolume|marginType|isYieldBased|shortTermVol|pointValue|pointCurrency|underliersPerCn|underlierType|timestamp'

# Replace with fields you want to see aggregated. A "|" separated list of fields should be provided
GROUP = 'futStatus|optStatus|hedgeDeltaRule|holdReason|symbolType|betaSource|marginType|isYieldBased|pointCurrency|underlierType'

# 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 = 'accnt:eq:ExampleString'

# 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)

Get Count API Call

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 = 'FutureRiskDetailV5'

# 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 = 'accnt:eq:ExampleString'

# 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)