LSEG Data Library for .NET

About the Financial Contracts Option FX

Financial Contracts provide 2 main definition for retrieving options data:

OptionFxDefinition

OptionEtiDefinition


Alternatively, option data can also be retrieved using **FinancialContractsDefinition** with a specific request object.

OptionFxDefinition - options methods

InstrumentTag(string tag)

A user-defined string to identify the instrument.

FxCrossCode(string code)

The currency pair. Should contain the two currencies, ex EURUSD.

PricingParams(OptionFx.IFxPricingDefinition pricing)

Properties used to control the Fx pricing calculations.

Fields(params string[] fields)

The collection of fields included within the response. Default: all available on the server.

Fields(IEnumerable fields)

The collection of fields included within the response. Default: all available on the server.

Outputs(params FinancialContracts.Output[] outputs)

Defines the sections that will be returned within the response.

Outputs(IEnumerable<FinancialContracts.Output> outputs)

Defines the sections that will be returned within the response.

Strike(double strike)

Option strike price. Required only if pricing an OTC Option.

BuySell(FinancialContracts.BuySell buySell)

The side of the deal. Optional. Default: Buy.

CallPut(FinancialContracts.CallPut callPut)

Defines the type of an option. Optional. Default: Call.

ExcerciseStyle(OptionFx.ExerciseStyle style)

Defines the exercise style of the option. Optional. Default: Euro.

EndDate(DateTime date)

The Option expiry date expressed in ISO 8601 format. Required only when pricing an OTC Option.

EndDate(string date)

The Option expiry date expressed in ISO 8601 format. Required only when pricing an OTC Option.

AsianDefinition(OptionFx.IFxAsianDefinition asian)

An Asian option is an option type where the payoff depends on the average price of the underlying asset over a certain period of time.

BarrierDefinition(OptionFx.IFxBarrierDefinition barrier)

Details of a barrier option. Required only when defining a barrier option.

DoubleBarriersDefinition(OptionFx.IFxDoubleBarrierDefinition barrier)

Details of an FX double barrier option. Required only when defining a barrier option.

BinaryDefinition(OptionFx.IFxBinaryDefinition binary)

Details of an Fx binary option. Required only when defining a binary option.

DoubleBinaryDefinition(OptionFx.IFxDoubleBinaryDefinition binary)

Details of double binary option. Required only when defining a double binary option.

ForwardStartDefinition(OptionFx.IFxForwardStartDefinition forward)

Details of a forward start option.

Tenor(string tenor)

The tenor of the option (if expiry is not defined).

DeliveryDate(DateTime date)

The delivery date of the option.

DeliveryDate(string date)

The delivery date of the option.

NotionalAmount(double amount)

The unsigned amount of traded currency actually bought or sold.

NotionalCcy(string ccy)

The ISO code of the traded currency. If the option is a EURGBP Call option, the deal currency can be in EUR or GBP.

SettlementType(OptionFx.SettlementType settlementType)

Specifies the delivery type of the binary option. Optional. Required if payoutCcy is not specified.

FxDualCurrencyDefinition(DateTime depositeStartDate, double marginPct = 0)

Details for dual currency option.

FxDualCurrencyDefinition(string depositeStartDate, double marginPct = 0)

Details for dual currency option.

Closure(object closure)

Optionally, include a user-defined Closure to match specific requests and responses.

ExtendedParams(JObject extendedParams)

Apply any properties that are not available within this request interface.
The extended params acts as a fallback measure in case properties are unavailable.
It is also an alternative for users that prefer to define the request using native json definitions.

Usage

  1. An example of an OptionFx pricing definition with multiple properties specified
    var pricing = OptionFx.PricingDefinition().CutoffTimeZone(OptionFx.CutoffTimeZone.GMT)
                                           .FxSpotObject(OptionFx.BidAskMidDefinition().Mid(2.5))
                                           .CutoffTime("1500PM")
                                           .PricingModelType(OptionFx.PricingModelType.VannaVolga);

  2. An example of an OptionFx binary definition with multiple properties specified
var binaryDefinition = OptionFx
    .BinaryDefinition(OptionFx.BinaryType.OneTouchDeferred, 1.2001)
    .PayoutAmount(1000000);

  1. An example of an OptionFx definition with multiple properties specified
    var data = OptionFx.Definition().Fields("FxCrossCode", "EndDate", "ForeignCcy", "FxSwap", "ErrorMessage")
                                 .FxCrossCode("EURUSD")
                                 .SettlementType(OptionFx.SettlementType.Cash)
                                 .Tenor("1M")
                                 .BinaryDefinition(binary)
                                 .PricingParams(pricing)
                                 .GetData();

  1. An example of requesting an OptionFx data using the Financial Contracts definition with a specific request object
    ```csharp
    // FX Option (include some pricing and binary properties)
    var fx = new JObject()
    {
    ["fields"] = new JArray("FxCrossCode", "EndDate", "ForeignCcy", "FxSwap", "ErrorMessage"),
    ["universe"] = new JArray(new JObject()
    {
     ["instrumentType"] = "Option",
     ["instrumentDefinition"] = new JObject()
     {
         ["underlyingType"] = "Fx",
         ["UnderlyingDefinition"] = new JObject() { ["fxCrossCode"] = "EURUSD" },
         ["binaryDefinition"] = new JObject()
         {
             ["binaryType"] = "OneTouchDeferred",
             ["trigger"] = 1.2001,
             ["payoutAmount"] = 1000000
         },
         ["settlementType"] = "Cash",
         ["tenor"] = "1M"
     }
    }),
    ["pricingParameters"] = new JObject()
    {
     ["pricingModelType"] = "VannaVolga",
     ["fxSpotObject"] = new JObject() { ["mid"] = 2.5 },
     ["cutoffTimeZone"] = "GMT",
     ["CutoffTime"] = "1500PM"
    }
    };

var data = FinancialContracts.Definition(fx).GetData();
```