lusid-sdk 2.1.462__py3-none-any.whl → 2.1.537__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (104) hide show
  1. lusid/__init__.py +62 -0
  2. lusid/api/group_reconciliations_api.py +806 -79
  3. lusid/api/instruments_api.py +187 -0
  4. lusid/api/transaction_portfolios_api.py +202 -2
  5. lusid/configuration.py +1 -1
  6. lusid/models/__init__.py +62 -0
  7. lusid/models/accumulation_event.py +3 -3
  8. lusid/models/amortisation_event.py +3 -3
  9. lusid/models/applicable_instrument_event.py +7 -2
  10. lusid/models/asset_leg.py +1 -1
  11. lusid/models/batch_update_user_review_for_comparison_result_request.py +81 -0
  12. lusid/models/batch_update_user_review_for_comparison_result_response.py +146 -0
  13. lusid/models/bond_coupon_event.py +10 -5
  14. lusid/models/bond_default_event.py +3 -3
  15. lusid/models/bond_principal_event.py +10 -5
  16. lusid/models/bonus_issue_event.py +3 -3
  17. lusid/models/call_on_intermediate_securities_event.py +139 -0
  18. lusid/models/capital_distribution_event.py +3 -3
  19. lusid/models/cash_dividend_event.py +3 -3
  20. lusid/models/cash_flow_event.py +3 -3
  21. lusid/models/cds_credit_event.py +3 -3
  22. lusid/models/cdx_credit_event.py +3 -3
  23. lusid/models/close_event.py +3 -3
  24. lusid/models/comparison_attribute_value_pair.py +71 -0
  25. lusid/models/component_transaction.py +10 -3
  26. lusid/models/create_staging_rule_set_request.py +1 -6
  27. lusid/models/credit_premium_cash_flow_event.py +3 -3
  28. lusid/models/custodian_account_request.py +1 -1
  29. lusid/models/delete_instrument_properties_response.py +7 -1
  30. lusid/models/delete_instrument_response.py +7 -1
  31. lusid/models/delete_instruments_response.py +22 -1
  32. lusid/models/deleted_entity_response.py +7 -1
  33. lusid/models/dividend_option_event.py +3 -3
  34. lusid/models/dividend_reinvestment_event.py +9 -4
  35. lusid/models/equity_option.py +19 -4
  36. lusid/models/exchange_traded_option_contract_details.py +1 -1
  37. lusid/models/exercise_event.py +3 -3
  38. lusid/models/expiry_event.py +3 -3
  39. lusid/models/fee.py +10 -3
  40. lusid/models/fee_request.py +13 -6
  41. lusid/models/future_expiry_event.py +3 -3
  42. lusid/models/fx_forward_settlement_event.py +3 -3
  43. lusid/models/group_reconciliation_aggregate_attribute_values.py +86 -0
  44. lusid/models/group_reconciliation_comparison_result.py +148 -0
  45. lusid/models/group_reconciliation_core_attribute_values.py +86 -0
  46. lusid/models/group_reconciliation_date_pair.py +81 -0
  47. lusid/models/group_reconciliation_dates.py +78 -0
  48. lusid/models/group_reconciliation_instance_id.py +71 -0
  49. lusid/models/group_reconciliation_result_statuses.py +89 -0
  50. lusid/models/group_reconciliation_result_types.py +96 -0
  51. lusid/models/group_reconciliation_review_statuses.py +96 -0
  52. lusid/models/group_reconciliation_run_details.py +76 -0
  53. lusid/models/group_reconciliation_run_request.py +75 -0
  54. lusid/models/group_reconciliation_run_response.py +77 -0
  55. lusid/models/group_reconciliation_summary.py +121 -0
  56. lusid/models/group_reconciliation_user_review.py +112 -0
  57. lusid/models/group_reconciliation_user_review_add.py +88 -0
  58. lusid/models/group_reconciliation_user_review_break_code.py +80 -0
  59. lusid/models/group_reconciliation_user_review_comment.py +80 -0
  60. lusid/models/group_reconciliation_user_review_match_key.py +80 -0
  61. lusid/models/group_reconciliation_user_review_remove.py +88 -0
  62. lusid/models/informational_error_event.py +3 -3
  63. lusid/models/informational_event.py +3 -3
  64. lusid/models/instrument_event.py +10 -5
  65. lusid/models/instrument_event_type.py +5 -0
  66. lusid/models/intermediate_securities_distribution_event.py +140 -0
  67. lusid/models/maturity_event.py +3 -3
  68. lusid/models/mbs_coupon_event.py +10 -5
  69. lusid/models/mbs_interest_deferral_event.py +10 -5
  70. lusid/models/mbs_interest_shortfall_event.py +10 -5
  71. lusid/models/mbs_principal_event.py +10 -5
  72. lusid/models/mbs_principal_write_off_event.py +10 -5
  73. lusid/models/merger_event.py +3 -3
  74. lusid/models/new_instrument.py +1 -1
  75. lusid/models/open_event.py +3 -3
  76. lusid/models/option_exercise_cash_event.py +144 -0
  77. lusid/models/option_exercise_election.py +73 -0
  78. lusid/models/option_exercise_physical_event.py +149 -0
  79. lusid/models/paged_resource_list_of_group_reconciliation_comparison_result.py +113 -0
  80. lusid/models/pricing_options.py +8 -2
  81. lusid/models/protection_payout_cash_flow_event.py +102 -0
  82. lusid/models/raw_vendor_event.py +3 -3
  83. lusid/models/reset_event.py +3 -3
  84. lusid/models/resource_list_of_output_transaction.py +113 -0
  85. lusid/models/return_zero_pv_options.py +69 -0
  86. lusid/models/reverse_stock_split_event.py +3 -3
  87. lusid/models/scrip_dividend_event.py +3 -3
  88. lusid/models/spin_off_event.py +3 -3
  89. lusid/models/stock_dividend_event.py +3 -3
  90. lusid/models/stock_split_event.py +3 -3
  91. lusid/models/swap_cash_flow_event.py +3 -3
  92. lusid/models/swap_principal_event.py +3 -3
  93. lusid/models/target_tax_lot.py +23 -2
  94. lusid/models/target_tax_lot_request.py +23 -2
  95. lusid/models/tender_event.py +3 -3
  96. lusid/models/total_return_swap.py +1 -1
  97. lusid/models/transaction_price.py +3 -3
  98. lusid/models/transaction_price_type.py +2 -0
  99. lusid/models/transition_event.py +3 -3
  100. lusid/models/trigger_event.py +3 -3
  101. lusid/models/update_staging_rule_set_request.py +1 -6
  102. {lusid_sdk-2.1.462.dist-info → lusid_sdk-2.1.537.dist-info}/METADATA +40 -3
  103. {lusid_sdk-2.1.462.dist-info → lusid_sdk-2.1.537.dist-info}/RECORD +104 -73
  104. {lusid_sdk-2.1.462.dist-info → lusid_sdk-2.1.537.dist-info}/WHEEL +0 -0
@@ -27,15 +27,15 @@ class OpenEvent(InstrumentEvent):
27
27
  The opening of an instrument. # noqa: E501
28
28
  """
29
29
  anchor_date: Optional[datetime] = Field(None, alias="anchorDate", description="The date on the which the instrument was opened.")
30
- instrument_event_type: StrictStr = Field(..., alias="instrumentEventType", description="The Type of Event. The available values are: TransitionEvent, InformationalEvent, OpenEvent, CloseEvent, StockSplitEvent, BondDefaultEvent, CashDividendEvent, AmortisationEvent, CashFlowEvent, ExerciseEvent, ResetEvent, TriggerEvent, RawVendorEvent, InformationalErrorEvent, BondCouponEvent, DividendReinvestmentEvent, AccumulationEvent, BondPrincipalEvent, DividendOptionEvent, MaturityEvent, FxForwardSettlementEvent, ExpiryEvent, ScripDividendEvent, StockDividendEvent, ReverseStockSplitEvent, CapitalDistributionEvent, SpinOffEvent, MergerEvent, FutureExpiryEvent, SwapCashFlowEvent, SwapPrincipalEvent, CreditPremiumCashFlowEvent, CdsCreditEvent, CdxCreditEvent, MbsCouponEvent, MbsPrincipalEvent, BonusIssueEvent, MbsPrincipalWriteOffEvent, MbsInterestDeferralEvent, MbsInterestShortfallEvent, TenderEvent")
30
+ instrument_event_type: StrictStr = Field(..., alias="instrumentEventType", description="The Type of Event. The available values are: TransitionEvent, InformationalEvent, OpenEvent, CloseEvent, StockSplitEvent, BondDefaultEvent, CashDividendEvent, AmortisationEvent, CashFlowEvent, ExerciseEvent, ResetEvent, TriggerEvent, RawVendorEvent, InformationalErrorEvent, BondCouponEvent, DividendReinvestmentEvent, AccumulationEvent, BondPrincipalEvent, DividendOptionEvent, MaturityEvent, FxForwardSettlementEvent, ExpiryEvent, ScripDividendEvent, StockDividendEvent, ReverseStockSplitEvent, CapitalDistributionEvent, SpinOffEvent, MergerEvent, FutureExpiryEvent, SwapCashFlowEvent, SwapPrincipalEvent, CreditPremiumCashFlowEvent, CdsCreditEvent, CdxCreditEvent, MbsCouponEvent, MbsPrincipalEvent, BonusIssueEvent, MbsPrincipalWriteOffEvent, MbsInterestDeferralEvent, MbsInterestShortfallEvent, TenderEvent, CallOnIntermediateSecuritiesEvent, IntermediateSecuritiesDistributionEvent, OptionExercisePhysicalEvent, OptionExerciseCashEvent, ProtectionPayoutCashFlowEvent")
31
31
  additional_properties: Dict[str, Any] = {}
32
32
  __properties = ["instrumentEventType", "anchorDate"]
33
33
 
34
34
  @validator('instrument_event_type')
35
35
  def instrument_event_type_validate_enum(cls, value):
36
36
  """Validates the enum"""
37
- if value not in ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent', 'BondCouponEvent', 'DividendReinvestmentEvent', 'AccumulationEvent', 'BondPrincipalEvent', 'DividendOptionEvent', 'MaturityEvent', 'FxForwardSettlementEvent', 'ExpiryEvent', 'ScripDividendEvent', 'StockDividendEvent', 'ReverseStockSplitEvent', 'CapitalDistributionEvent', 'SpinOffEvent', 'MergerEvent', 'FutureExpiryEvent', 'SwapCashFlowEvent', 'SwapPrincipalEvent', 'CreditPremiumCashFlowEvent', 'CdsCreditEvent', 'CdxCreditEvent', 'MbsCouponEvent', 'MbsPrincipalEvent', 'BonusIssueEvent', 'MbsPrincipalWriteOffEvent', 'MbsInterestDeferralEvent', 'MbsInterestShortfallEvent', 'TenderEvent'):
38
- raise ValueError("must be one of enum values ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent', 'BondCouponEvent', 'DividendReinvestmentEvent', 'AccumulationEvent', 'BondPrincipalEvent', 'DividendOptionEvent', 'MaturityEvent', 'FxForwardSettlementEvent', 'ExpiryEvent', 'ScripDividendEvent', 'StockDividendEvent', 'ReverseStockSplitEvent', 'CapitalDistributionEvent', 'SpinOffEvent', 'MergerEvent', 'FutureExpiryEvent', 'SwapCashFlowEvent', 'SwapPrincipalEvent', 'CreditPremiumCashFlowEvent', 'CdsCreditEvent', 'CdxCreditEvent', 'MbsCouponEvent', 'MbsPrincipalEvent', 'BonusIssueEvent', 'MbsPrincipalWriteOffEvent', 'MbsInterestDeferralEvent', 'MbsInterestShortfallEvent', 'TenderEvent')")
37
+ if value not in ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent', 'BondCouponEvent', 'DividendReinvestmentEvent', 'AccumulationEvent', 'BondPrincipalEvent', 'DividendOptionEvent', 'MaturityEvent', 'FxForwardSettlementEvent', 'ExpiryEvent', 'ScripDividendEvent', 'StockDividendEvent', 'ReverseStockSplitEvent', 'CapitalDistributionEvent', 'SpinOffEvent', 'MergerEvent', 'FutureExpiryEvent', 'SwapCashFlowEvent', 'SwapPrincipalEvent', 'CreditPremiumCashFlowEvent', 'CdsCreditEvent', 'CdxCreditEvent', 'MbsCouponEvent', 'MbsPrincipalEvent', 'BonusIssueEvent', 'MbsPrincipalWriteOffEvent', 'MbsInterestDeferralEvent', 'MbsInterestShortfallEvent', 'TenderEvent', 'CallOnIntermediateSecuritiesEvent', 'IntermediateSecuritiesDistributionEvent', 'OptionExercisePhysicalEvent', 'OptionExerciseCashEvent', 'ProtectionPayoutCashFlowEvent'):
38
+ raise ValueError("must be one of enum values ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent', 'BondCouponEvent', 'DividendReinvestmentEvent', 'AccumulationEvent', 'BondPrincipalEvent', 'DividendOptionEvent', 'MaturityEvent', 'FxForwardSettlementEvent', 'ExpiryEvent', 'ScripDividendEvent', 'StockDividendEvent', 'ReverseStockSplitEvent', 'CapitalDistributionEvent', 'SpinOffEvent', 'MergerEvent', 'FutureExpiryEvent', 'SwapCashFlowEvent', 'SwapPrincipalEvent', 'CreditPremiumCashFlowEvent', 'CdsCreditEvent', 'CdxCreditEvent', 'MbsCouponEvent', 'MbsPrincipalEvent', 'BonusIssueEvent', 'MbsPrincipalWriteOffEvent', 'MbsInterestDeferralEvent', 'MbsInterestShortfallEvent', 'TenderEvent', 'CallOnIntermediateSecuritiesEvent', 'IntermediateSecuritiesDistributionEvent', 'OptionExercisePhysicalEvent', 'OptionExerciseCashEvent', 'ProtectionPayoutCashFlowEvent')")
39
39
  return value
40
40
 
41
41
  class Config:
@@ -0,0 +1,144 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+ from datetime import datetime
21
+ from typing import Any, Dict, List, Optional, Union
22
+ from pydantic.v1 import Field, StrictFloat, StrictInt, StrictStr, conlist, constr, validator
23
+ from lusid.models.instrument_event import InstrumentEvent
24
+ from lusid.models.option_exercise_election import OptionExerciseElection
25
+
26
+ class OptionExerciseCashEvent(InstrumentEvent):
27
+ """
28
+ Event for cash option exercises. # noqa: E501
29
+ """
30
+ cash_flow_per_unit: Optional[Union[StrictFloat, StrictInt]] = Field(None, alias="cashFlowPerUnit", description="The cashflow per unit")
31
+ exercise_date: Optional[datetime] = Field(None, alias="exerciseDate", description="The exercise date of the option.")
32
+ exercise_type: constr(strict=True, min_length=1) = Field(..., alias="exerciseType", description="The optionality type of the underlying option e.g. American, European. Supported string (enumeration) values are: [European, Bermudan, American].")
33
+ maturity_date: datetime = Field(..., alias="maturityDate", description="The maturity date of the option.")
34
+ moneyness: Optional[StrictStr] = Field(None, description="The moneyness of the option e.g. InTheMoney, OutOfTheMoney. Supported string (enumeration) values are: [InTheMoney, OutOfTheMoney, AtTheMoney].")
35
+ option_exercise_elections: Optional[conlist(OptionExerciseElection)] = Field(None, alias="optionExerciseElections", description="Option exercise election for this OptionExercisePhysicalEvent.")
36
+ option_type: constr(strict=True, min_length=1) = Field(..., alias="optionType", description="Type of optionality that is present e.g. call, put. Supported string (enumeration) values are: [Call, Put].")
37
+ start_date: datetime = Field(..., alias="startDate", description="The start date of the option.")
38
+ strike_currency: StrictStr = Field(..., alias="strikeCurrency", description="The strike currency of the equity option.")
39
+ strike_per_unit: Union[StrictFloat, StrictInt] = Field(..., alias="strikePerUnit", description="The strike of the equity option times the number of shares to exchange if exercised.")
40
+ underlying_value_per_unit: Optional[Union[StrictFloat, StrictInt]] = Field(None, alias="underlyingValuePerUnit", description="The underlying price times the number of shares to exchange if exercised.")
41
+ instrument_event_type: StrictStr = Field(..., alias="instrumentEventType", description="The Type of Event. The available values are: TransitionEvent, InformationalEvent, OpenEvent, CloseEvent, StockSplitEvent, BondDefaultEvent, CashDividendEvent, AmortisationEvent, CashFlowEvent, ExerciseEvent, ResetEvent, TriggerEvent, RawVendorEvent, InformationalErrorEvent, BondCouponEvent, DividendReinvestmentEvent, AccumulationEvent, BondPrincipalEvent, DividendOptionEvent, MaturityEvent, FxForwardSettlementEvent, ExpiryEvent, ScripDividendEvent, StockDividendEvent, ReverseStockSplitEvent, CapitalDistributionEvent, SpinOffEvent, MergerEvent, FutureExpiryEvent, SwapCashFlowEvent, SwapPrincipalEvent, CreditPremiumCashFlowEvent, CdsCreditEvent, CdxCreditEvent, MbsCouponEvent, MbsPrincipalEvent, BonusIssueEvent, MbsPrincipalWriteOffEvent, MbsInterestDeferralEvent, MbsInterestShortfallEvent, TenderEvent, CallOnIntermediateSecuritiesEvent, IntermediateSecuritiesDistributionEvent, OptionExercisePhysicalEvent, OptionExerciseCashEvent, ProtectionPayoutCashFlowEvent")
42
+ additional_properties: Dict[str, Any] = {}
43
+ __properties = ["instrumentEventType", "cashFlowPerUnit", "exerciseDate", "exerciseType", "maturityDate", "moneyness", "optionExerciseElections", "optionType", "startDate", "strikeCurrency", "strikePerUnit", "underlyingValuePerUnit"]
44
+
45
+ @validator('instrument_event_type')
46
+ def instrument_event_type_validate_enum(cls, value):
47
+ """Validates the enum"""
48
+ if value not in ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent', 'BondCouponEvent', 'DividendReinvestmentEvent', 'AccumulationEvent', 'BondPrincipalEvent', 'DividendOptionEvent', 'MaturityEvent', 'FxForwardSettlementEvent', 'ExpiryEvent', 'ScripDividendEvent', 'StockDividendEvent', 'ReverseStockSplitEvent', 'CapitalDistributionEvent', 'SpinOffEvent', 'MergerEvent', 'FutureExpiryEvent', 'SwapCashFlowEvent', 'SwapPrincipalEvent', 'CreditPremiumCashFlowEvent', 'CdsCreditEvent', 'CdxCreditEvent', 'MbsCouponEvent', 'MbsPrincipalEvent', 'BonusIssueEvent', 'MbsPrincipalWriteOffEvent', 'MbsInterestDeferralEvent', 'MbsInterestShortfallEvent', 'TenderEvent', 'CallOnIntermediateSecuritiesEvent', 'IntermediateSecuritiesDistributionEvent', 'OptionExercisePhysicalEvent', 'OptionExerciseCashEvent', 'ProtectionPayoutCashFlowEvent'):
49
+ raise ValueError("must be one of enum values ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent', 'BondCouponEvent', 'DividendReinvestmentEvent', 'AccumulationEvent', 'BondPrincipalEvent', 'DividendOptionEvent', 'MaturityEvent', 'FxForwardSettlementEvent', 'ExpiryEvent', 'ScripDividendEvent', 'StockDividendEvent', 'ReverseStockSplitEvent', 'CapitalDistributionEvent', 'SpinOffEvent', 'MergerEvent', 'FutureExpiryEvent', 'SwapCashFlowEvent', 'SwapPrincipalEvent', 'CreditPremiumCashFlowEvent', 'CdsCreditEvent', 'CdxCreditEvent', 'MbsCouponEvent', 'MbsPrincipalEvent', 'BonusIssueEvent', 'MbsPrincipalWriteOffEvent', 'MbsInterestDeferralEvent', 'MbsInterestShortfallEvent', 'TenderEvent', 'CallOnIntermediateSecuritiesEvent', 'IntermediateSecuritiesDistributionEvent', 'OptionExercisePhysicalEvent', 'OptionExerciseCashEvent', 'ProtectionPayoutCashFlowEvent')")
50
+ return value
51
+
52
+ class Config:
53
+ """Pydantic configuration"""
54
+ allow_population_by_field_name = True
55
+ validate_assignment = True
56
+
57
+ def to_str(self) -> str:
58
+ """Returns the string representation of the model using alias"""
59
+ return pprint.pformat(self.dict(by_alias=True))
60
+
61
+ def to_json(self) -> str:
62
+ """Returns the JSON representation of the model using alias"""
63
+ return json.dumps(self.to_dict())
64
+
65
+ @classmethod
66
+ def from_json(cls, json_str: str) -> OptionExerciseCashEvent:
67
+ """Create an instance of OptionExerciseCashEvent from a JSON string"""
68
+ return cls.from_dict(json.loads(json_str))
69
+
70
+ def to_dict(self):
71
+ """Returns the dictionary representation of the model using alias"""
72
+ _dict = self.dict(by_alias=True,
73
+ exclude={
74
+ "additional_properties"
75
+ },
76
+ exclude_none=True)
77
+ # override the default output from pydantic by calling `to_dict()` of each item in option_exercise_elections (list)
78
+ _items = []
79
+ if self.option_exercise_elections:
80
+ for _item in self.option_exercise_elections:
81
+ if _item:
82
+ _items.append(_item.to_dict())
83
+ _dict['optionExerciseElections'] = _items
84
+ # puts key-value pairs in additional_properties in the top level
85
+ if self.additional_properties is not None:
86
+ for _key, _value in self.additional_properties.items():
87
+ _dict[_key] = _value
88
+
89
+ # set to None if cash_flow_per_unit (nullable) is None
90
+ # and __fields_set__ contains the field
91
+ if self.cash_flow_per_unit is None and "cash_flow_per_unit" in self.__fields_set__:
92
+ _dict['cashFlowPerUnit'] = None
93
+
94
+ # set to None if exercise_date (nullable) is None
95
+ # and __fields_set__ contains the field
96
+ if self.exercise_date is None and "exercise_date" in self.__fields_set__:
97
+ _dict['exerciseDate'] = None
98
+
99
+ # set to None if moneyness (nullable) is None
100
+ # and __fields_set__ contains the field
101
+ if self.moneyness is None and "moneyness" in self.__fields_set__:
102
+ _dict['moneyness'] = None
103
+
104
+ # set to None if option_exercise_elections (nullable) is None
105
+ # and __fields_set__ contains the field
106
+ if self.option_exercise_elections is None and "option_exercise_elections" in self.__fields_set__:
107
+ _dict['optionExerciseElections'] = None
108
+
109
+ # set to None if underlying_value_per_unit (nullable) is None
110
+ # and __fields_set__ contains the field
111
+ if self.underlying_value_per_unit is None and "underlying_value_per_unit" in self.__fields_set__:
112
+ _dict['underlyingValuePerUnit'] = None
113
+
114
+ return _dict
115
+
116
+ @classmethod
117
+ def from_dict(cls, obj: dict) -> OptionExerciseCashEvent:
118
+ """Create an instance of OptionExerciseCashEvent from a dict"""
119
+ if obj is None:
120
+ return None
121
+
122
+ if not isinstance(obj, dict):
123
+ return OptionExerciseCashEvent.parse_obj(obj)
124
+
125
+ _obj = OptionExerciseCashEvent.parse_obj({
126
+ "instrument_event_type": obj.get("instrumentEventType"),
127
+ "cash_flow_per_unit": obj.get("cashFlowPerUnit"),
128
+ "exercise_date": obj.get("exerciseDate"),
129
+ "exercise_type": obj.get("exerciseType"),
130
+ "maturity_date": obj.get("maturityDate"),
131
+ "moneyness": obj.get("moneyness"),
132
+ "option_exercise_elections": [OptionExerciseElection.from_dict(_item) for _item in obj.get("optionExerciseElections")] if obj.get("optionExerciseElections") is not None else None,
133
+ "option_type": obj.get("optionType"),
134
+ "start_date": obj.get("startDate"),
135
+ "strike_currency": obj.get("strikeCurrency"),
136
+ "strike_per_unit": obj.get("strikePerUnit"),
137
+ "underlying_value_per_unit": obj.get("underlyingValuePerUnit")
138
+ })
139
+ # store additional fields in additional_properties
140
+ for _key in obj.keys():
141
+ if _key not in cls.__properties:
142
+ _obj.additional_properties[_key] = obj.get(_key)
143
+
144
+ return _obj
@@ -0,0 +1,73 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+
21
+ from typing import Any, Dict, Optional
22
+ from pydantic.v1 import BaseModel, Field, StrictBool, constr
23
+
24
+ class OptionExerciseElection(BaseModel):
25
+ """
26
+ Option exercise election. # noqa: E501
27
+ """
28
+ election_key: constr(strict=True, min_length=1) = Field(..., alias="electionKey", description="Unique key associated to this election")
29
+ is_default: Optional[StrictBool] = Field(None, alias="isDefault", description="Is this election automatically applied in the absence of an election having been made. May only be true for one election if multiple are provided.")
30
+ is_chosen: Optional[StrictBool] = Field(None, alias="isChosen", description="Is this the election that has been explicitly chosen from multiple options.")
31
+ __properties = ["electionKey", "isDefault", "isChosen"]
32
+
33
+ class Config:
34
+ """Pydantic configuration"""
35
+ allow_population_by_field_name = True
36
+ validate_assignment = True
37
+
38
+ def to_str(self) -> str:
39
+ """Returns the string representation of the model using alias"""
40
+ return pprint.pformat(self.dict(by_alias=True))
41
+
42
+ def to_json(self) -> str:
43
+ """Returns the JSON representation of the model using alias"""
44
+ return json.dumps(self.to_dict())
45
+
46
+ @classmethod
47
+ def from_json(cls, json_str: str) -> OptionExerciseElection:
48
+ """Create an instance of OptionExerciseElection from a JSON string"""
49
+ return cls.from_dict(json.loads(json_str))
50
+
51
+ def to_dict(self):
52
+ """Returns the dictionary representation of the model using alias"""
53
+ _dict = self.dict(by_alias=True,
54
+ exclude={
55
+ },
56
+ exclude_none=True)
57
+ return _dict
58
+
59
+ @classmethod
60
+ def from_dict(cls, obj: dict) -> OptionExerciseElection:
61
+ """Create an instance of OptionExerciseElection from a dict"""
62
+ if obj is None:
63
+ return None
64
+
65
+ if not isinstance(obj, dict):
66
+ return OptionExerciseElection.parse_obj(obj)
67
+
68
+ _obj = OptionExerciseElection.parse_obj({
69
+ "election_key": obj.get("electionKey"),
70
+ "is_default": obj.get("isDefault"),
71
+ "is_chosen": obj.get("isChosen")
72
+ })
73
+ return _obj
@@ -0,0 +1,149 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+ from datetime import datetime
21
+ from typing import Any, Dict, List, Optional, Union
22
+ from pydantic.v1 import Field, StrictFloat, StrictInt, StrictStr, conlist, constr, validator
23
+ from lusid.models.instrument_event import InstrumentEvent
24
+ from lusid.models.new_instrument import NewInstrument
25
+ from lusid.models.option_exercise_election import OptionExerciseElection
26
+ from lusid.models.units_ratio import UnitsRatio
27
+
28
+ class OptionExercisePhysicalEvent(InstrumentEvent):
29
+ """
30
+ Event for physical option exercises. # noqa: E501
31
+ """
32
+ exercise_date: Optional[datetime] = Field(None, alias="exerciseDate", description="The exercise date of the option.")
33
+ exercise_type: constr(strict=True, min_length=1) = Field(..., alias="exerciseType", description="The optionality type of the underlying option e.g. American, European. Supported string (enumeration) values are: [European, Bermudan, American].")
34
+ maturity_date: datetime = Field(..., alias="maturityDate", description="The maturity date of the option.")
35
+ moneyness: Optional[StrictStr] = Field(None, description="The moneyness of the option e.g. InTheMoney, OutOfTheMoney. Supported string (enumeration) values are: [InTheMoney, OutOfTheMoney, AtTheMoney].")
36
+ new_instrument: NewInstrument = Field(..., alias="newInstrument")
37
+ option_exercise_elections: Optional[conlist(OptionExerciseElection)] = Field(None, alias="optionExerciseElections", description="Option exercise election for this OptionExercisePhysicalEvent.")
38
+ option_type: constr(strict=True, min_length=1) = Field(..., alias="optionType", description="Type of optionality that is present e.g. call, put. Supported string (enumeration) values are: [Call, Put].")
39
+ start_date: datetime = Field(..., alias="startDate", description="The trade date of the option.")
40
+ strike_currency: StrictStr = Field(..., alias="strikeCurrency", description="The strike currency of the equity option.")
41
+ strike_per_unit: Union[StrictFloat, StrictInt] = Field(..., alias="strikePerUnit", description="The strike of the equity option times the number of shares to exchange if exercised.")
42
+ underlying_value_per_unit: Optional[Union[StrictFloat, StrictInt]] = Field(None, alias="underlyingValuePerUnit", description="The underlying price times the number of shares to exchange if exercised.")
43
+ units_ratio: UnitsRatio = Field(..., alias="unitsRatio")
44
+ instrument_event_type: StrictStr = Field(..., alias="instrumentEventType", description="The Type of Event. The available values are: TransitionEvent, InformationalEvent, OpenEvent, CloseEvent, StockSplitEvent, BondDefaultEvent, CashDividendEvent, AmortisationEvent, CashFlowEvent, ExerciseEvent, ResetEvent, TriggerEvent, RawVendorEvent, InformationalErrorEvent, BondCouponEvent, DividendReinvestmentEvent, AccumulationEvent, BondPrincipalEvent, DividendOptionEvent, MaturityEvent, FxForwardSettlementEvent, ExpiryEvent, ScripDividendEvent, StockDividendEvent, ReverseStockSplitEvent, CapitalDistributionEvent, SpinOffEvent, MergerEvent, FutureExpiryEvent, SwapCashFlowEvent, SwapPrincipalEvent, CreditPremiumCashFlowEvent, CdsCreditEvent, CdxCreditEvent, MbsCouponEvent, MbsPrincipalEvent, BonusIssueEvent, MbsPrincipalWriteOffEvent, MbsInterestDeferralEvent, MbsInterestShortfallEvent, TenderEvent, CallOnIntermediateSecuritiesEvent, IntermediateSecuritiesDistributionEvent, OptionExercisePhysicalEvent, OptionExerciseCashEvent, ProtectionPayoutCashFlowEvent")
45
+ additional_properties: Dict[str, Any] = {}
46
+ __properties = ["instrumentEventType", "exerciseDate", "exerciseType", "maturityDate", "moneyness", "newInstrument", "optionExerciseElections", "optionType", "startDate", "strikeCurrency", "strikePerUnit", "underlyingValuePerUnit", "unitsRatio"]
47
+
48
+ @validator('instrument_event_type')
49
+ def instrument_event_type_validate_enum(cls, value):
50
+ """Validates the enum"""
51
+ if value not in ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent', 'BondCouponEvent', 'DividendReinvestmentEvent', 'AccumulationEvent', 'BondPrincipalEvent', 'DividendOptionEvent', 'MaturityEvent', 'FxForwardSettlementEvent', 'ExpiryEvent', 'ScripDividendEvent', 'StockDividendEvent', 'ReverseStockSplitEvent', 'CapitalDistributionEvent', 'SpinOffEvent', 'MergerEvent', 'FutureExpiryEvent', 'SwapCashFlowEvent', 'SwapPrincipalEvent', 'CreditPremiumCashFlowEvent', 'CdsCreditEvent', 'CdxCreditEvent', 'MbsCouponEvent', 'MbsPrincipalEvent', 'BonusIssueEvent', 'MbsPrincipalWriteOffEvent', 'MbsInterestDeferralEvent', 'MbsInterestShortfallEvent', 'TenderEvent', 'CallOnIntermediateSecuritiesEvent', 'IntermediateSecuritiesDistributionEvent', 'OptionExercisePhysicalEvent', 'OptionExerciseCashEvent', 'ProtectionPayoutCashFlowEvent'):
52
+ raise ValueError("must be one of enum values ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent', 'BondCouponEvent', 'DividendReinvestmentEvent', 'AccumulationEvent', 'BondPrincipalEvent', 'DividendOptionEvent', 'MaturityEvent', 'FxForwardSettlementEvent', 'ExpiryEvent', 'ScripDividendEvent', 'StockDividendEvent', 'ReverseStockSplitEvent', 'CapitalDistributionEvent', 'SpinOffEvent', 'MergerEvent', 'FutureExpiryEvent', 'SwapCashFlowEvent', 'SwapPrincipalEvent', 'CreditPremiumCashFlowEvent', 'CdsCreditEvent', 'CdxCreditEvent', 'MbsCouponEvent', 'MbsPrincipalEvent', 'BonusIssueEvent', 'MbsPrincipalWriteOffEvent', 'MbsInterestDeferralEvent', 'MbsInterestShortfallEvent', 'TenderEvent', 'CallOnIntermediateSecuritiesEvent', 'IntermediateSecuritiesDistributionEvent', 'OptionExercisePhysicalEvent', 'OptionExerciseCashEvent', 'ProtectionPayoutCashFlowEvent')")
53
+ return value
54
+
55
+ class Config:
56
+ """Pydantic configuration"""
57
+ allow_population_by_field_name = True
58
+ validate_assignment = True
59
+
60
+ def to_str(self) -> str:
61
+ """Returns the string representation of the model using alias"""
62
+ return pprint.pformat(self.dict(by_alias=True))
63
+
64
+ def to_json(self) -> str:
65
+ """Returns the JSON representation of the model using alias"""
66
+ return json.dumps(self.to_dict())
67
+
68
+ @classmethod
69
+ def from_json(cls, json_str: str) -> OptionExercisePhysicalEvent:
70
+ """Create an instance of OptionExercisePhysicalEvent from a JSON string"""
71
+ return cls.from_dict(json.loads(json_str))
72
+
73
+ def to_dict(self):
74
+ """Returns the dictionary representation of the model using alias"""
75
+ _dict = self.dict(by_alias=True,
76
+ exclude={
77
+ "additional_properties"
78
+ },
79
+ exclude_none=True)
80
+ # override the default output from pydantic by calling `to_dict()` of new_instrument
81
+ if self.new_instrument:
82
+ _dict['newInstrument'] = self.new_instrument.to_dict()
83
+ # override the default output from pydantic by calling `to_dict()` of each item in option_exercise_elections (list)
84
+ _items = []
85
+ if self.option_exercise_elections:
86
+ for _item in self.option_exercise_elections:
87
+ if _item:
88
+ _items.append(_item.to_dict())
89
+ _dict['optionExerciseElections'] = _items
90
+ # override the default output from pydantic by calling `to_dict()` of units_ratio
91
+ if self.units_ratio:
92
+ _dict['unitsRatio'] = self.units_ratio.to_dict()
93
+ # puts key-value pairs in additional_properties in the top level
94
+ if self.additional_properties is not None:
95
+ for _key, _value in self.additional_properties.items():
96
+ _dict[_key] = _value
97
+
98
+ # set to None if exercise_date (nullable) is None
99
+ # and __fields_set__ contains the field
100
+ if self.exercise_date is None and "exercise_date" in self.__fields_set__:
101
+ _dict['exerciseDate'] = None
102
+
103
+ # set to None if moneyness (nullable) is None
104
+ # and __fields_set__ contains the field
105
+ if self.moneyness is None and "moneyness" in self.__fields_set__:
106
+ _dict['moneyness'] = None
107
+
108
+ # set to None if option_exercise_elections (nullable) is None
109
+ # and __fields_set__ contains the field
110
+ if self.option_exercise_elections is None and "option_exercise_elections" in self.__fields_set__:
111
+ _dict['optionExerciseElections'] = None
112
+
113
+ # set to None if underlying_value_per_unit (nullable) is None
114
+ # and __fields_set__ contains the field
115
+ if self.underlying_value_per_unit is None and "underlying_value_per_unit" in self.__fields_set__:
116
+ _dict['underlyingValuePerUnit'] = None
117
+
118
+ return _dict
119
+
120
+ @classmethod
121
+ def from_dict(cls, obj: dict) -> OptionExercisePhysicalEvent:
122
+ """Create an instance of OptionExercisePhysicalEvent from a dict"""
123
+ if obj is None:
124
+ return None
125
+
126
+ if not isinstance(obj, dict):
127
+ return OptionExercisePhysicalEvent.parse_obj(obj)
128
+
129
+ _obj = OptionExercisePhysicalEvent.parse_obj({
130
+ "instrument_event_type": obj.get("instrumentEventType"),
131
+ "exercise_date": obj.get("exerciseDate"),
132
+ "exercise_type": obj.get("exerciseType"),
133
+ "maturity_date": obj.get("maturityDate"),
134
+ "moneyness": obj.get("moneyness"),
135
+ "new_instrument": NewInstrument.from_dict(obj.get("newInstrument")) if obj.get("newInstrument") is not None else None,
136
+ "option_exercise_elections": [OptionExerciseElection.from_dict(_item) for _item in obj.get("optionExerciseElections")] if obj.get("optionExerciseElections") is not None else None,
137
+ "option_type": obj.get("optionType"),
138
+ "start_date": obj.get("startDate"),
139
+ "strike_currency": obj.get("strikeCurrency"),
140
+ "strike_per_unit": obj.get("strikePerUnit"),
141
+ "underlying_value_per_unit": obj.get("underlyingValuePerUnit"),
142
+ "units_ratio": UnitsRatio.from_dict(obj.get("unitsRatio")) if obj.get("unitsRatio") is not None else None
143
+ })
144
+ # store additional fields in additional_properties
145
+ for _key in obj.keys():
146
+ if _key not in cls.__properties:
147
+ _obj.additional_properties[_key] = obj.get(_key)
148
+
149
+ return _obj
@@ -0,0 +1,113 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+
21
+ from typing import Any, Dict, List, Optional
22
+ from pydantic.v1 import BaseModel, Field, StrictStr, conlist
23
+ from lusid.models.group_reconciliation_comparison_result import GroupReconciliationComparisonResult
24
+ from lusid.models.link import Link
25
+
26
+ class PagedResourceListOfGroupReconciliationComparisonResult(BaseModel):
27
+ """
28
+ PagedResourceListOfGroupReconciliationComparisonResult
29
+ """
30
+ next_page: Optional[StrictStr] = Field(None, alias="nextPage")
31
+ previous_page: Optional[StrictStr] = Field(None, alias="previousPage")
32
+ values: conlist(GroupReconciliationComparisonResult) = Field(...)
33
+ href: Optional[StrictStr] = None
34
+ links: Optional[conlist(Link)] = None
35
+ __properties = ["nextPage", "previousPage", "values", "href", "links"]
36
+
37
+ class Config:
38
+ """Pydantic configuration"""
39
+ allow_population_by_field_name = True
40
+ validate_assignment = True
41
+
42
+ def to_str(self) -> str:
43
+ """Returns the string representation of the model using alias"""
44
+ return pprint.pformat(self.dict(by_alias=True))
45
+
46
+ def to_json(self) -> str:
47
+ """Returns the JSON representation of the model using alias"""
48
+ return json.dumps(self.to_dict())
49
+
50
+ @classmethod
51
+ def from_json(cls, json_str: str) -> PagedResourceListOfGroupReconciliationComparisonResult:
52
+ """Create an instance of PagedResourceListOfGroupReconciliationComparisonResult from a JSON string"""
53
+ return cls.from_dict(json.loads(json_str))
54
+
55
+ def to_dict(self):
56
+ """Returns the dictionary representation of the model using alias"""
57
+ _dict = self.dict(by_alias=True,
58
+ exclude={
59
+ },
60
+ exclude_none=True)
61
+ # override the default output from pydantic by calling `to_dict()` of each item in values (list)
62
+ _items = []
63
+ if self.values:
64
+ for _item in self.values:
65
+ if _item:
66
+ _items.append(_item.to_dict())
67
+ _dict['values'] = _items
68
+ # override the default output from pydantic by calling `to_dict()` of each item in links (list)
69
+ _items = []
70
+ if self.links:
71
+ for _item in self.links:
72
+ if _item:
73
+ _items.append(_item.to_dict())
74
+ _dict['links'] = _items
75
+ # set to None if next_page (nullable) is None
76
+ # and __fields_set__ contains the field
77
+ if self.next_page is None and "next_page" in self.__fields_set__:
78
+ _dict['nextPage'] = None
79
+
80
+ # set to None if previous_page (nullable) is None
81
+ # and __fields_set__ contains the field
82
+ if self.previous_page is None and "previous_page" in self.__fields_set__:
83
+ _dict['previousPage'] = None
84
+
85
+ # set to None if href (nullable) is None
86
+ # and __fields_set__ contains the field
87
+ if self.href is None and "href" in self.__fields_set__:
88
+ _dict['href'] = None
89
+
90
+ # set to None if links (nullable) is None
91
+ # and __fields_set__ contains the field
92
+ if self.links is None and "links" in self.__fields_set__:
93
+ _dict['links'] = None
94
+
95
+ return _dict
96
+
97
+ @classmethod
98
+ def from_dict(cls, obj: dict) -> PagedResourceListOfGroupReconciliationComparisonResult:
99
+ """Create an instance of PagedResourceListOfGroupReconciliationComparisonResult from a dict"""
100
+ if obj is None:
101
+ return None
102
+
103
+ if not isinstance(obj, dict):
104
+ return PagedResourceListOfGroupReconciliationComparisonResult.parse_obj(obj)
105
+
106
+ _obj = PagedResourceListOfGroupReconciliationComparisonResult.parse_obj({
107
+ "next_page": obj.get("nextPage"),
108
+ "previous_page": obj.get("previousPage"),
109
+ "values": [GroupReconciliationComparisonResult.from_dict(_item) for _item in obj.get("values")] if obj.get("values") is not None else None,
110
+ "href": obj.get("href"),
111
+ "links": [Link.from_dict(_item) for _item in obj.get("links")] if obj.get("links") is not None else None
112
+ })
113
+ return _obj
@@ -21,6 +21,7 @@ import json
21
21
  from typing import Any, Dict, Optional
22
22
  from pydantic.v1 import BaseModel, Field, StrictBool, StrictStr
23
23
  from lusid.models.model_selection import ModelSelection
24
+ from lusid.models.return_zero_pv_options import ReturnZeroPvOptions
24
25
 
25
26
  class PricingOptions(BaseModel):
26
27
  """
@@ -37,7 +38,8 @@ class PricingOptions(BaseModel):
37
38
  use_child_sub_holding_keys_for_portfolio_expansion: Optional[StrictBool] = Field(None, alias="useChildSubHoldingKeysForPortfolioExpansion", description="Should fund constituents inherit subholding keys from the parent subholding keyb")
38
39
  validate_domestic_and_quote_currencies_are_consistent: Optional[StrictBool] = Field(None, alias="validateDomesticAndQuoteCurrenciesAreConsistent", description="Do we validate that the instrument domestic currency matches the quote currency (unless unknown/zzz) when using lookup pricing.")
39
40
  conserved_quantity_for_lookthrough_expansion: Optional[StrictStr] = Field(None, alias="conservedQuantityForLookthroughExpansion", description="When performing lookthrough portfolio expansion with ScalingMethodology set to \"Sum\" or \"AbsoluteSum\", the quantity specified here will be conserved and apportioned to lookthrough constituents. For example, an equal-weighting index with 100 constituents can be modelled as a reference portfolio with 1% weights on each equity. When expanding a $9000 holding of that index into its constituents while conserving PV, we end up with $90 of each equity. The number of units of each equity held is then implied. Note that conservation of one quantity may imply non-conservation of others, especially when some constituents are OTCs. Allowed values are: \"PV\" (default), \"Exposure\".")
40
- __properties = ["modelSelection", "useInstrumentTypeToDeterminePricer", "allowAnyInstrumentsWithSecUidToPriceOffLookup", "allowPartiallySuccessfulEvaluation", "produceSeparateResultForLinearOtcLegs", "enableUseOfCachedUnitResults", "windowValuationOnInstrumentStartEnd", "removeContingentCashflowsInPaymentDiary", "useChildSubHoldingKeysForPortfolioExpansion", "validateDomesticAndQuoteCurrenciesAreConsistent", "conservedQuantityForLookthroughExpansion"]
41
+ return_zero_pv: Optional[ReturnZeroPvOptions] = Field(None, alias="returnZeroPv")
42
+ __properties = ["modelSelection", "useInstrumentTypeToDeterminePricer", "allowAnyInstrumentsWithSecUidToPriceOffLookup", "allowPartiallySuccessfulEvaluation", "produceSeparateResultForLinearOtcLegs", "enableUseOfCachedUnitResults", "windowValuationOnInstrumentStartEnd", "removeContingentCashflowsInPaymentDiary", "useChildSubHoldingKeysForPortfolioExpansion", "validateDomesticAndQuoteCurrenciesAreConsistent", "conservedQuantityForLookthroughExpansion", "returnZeroPv"]
41
43
 
42
44
  class Config:
43
45
  """Pydantic configuration"""
@@ -66,6 +68,9 @@ class PricingOptions(BaseModel):
66
68
  # override the default output from pydantic by calling `to_dict()` of model_selection
67
69
  if self.model_selection:
68
70
  _dict['modelSelection'] = self.model_selection.to_dict()
71
+ # override the default output from pydantic by calling `to_dict()` of return_zero_pv
72
+ if self.return_zero_pv:
73
+ _dict['returnZeroPv'] = self.return_zero_pv.to_dict()
69
74
  # set to None if conserved_quantity_for_lookthrough_expansion (nullable) is None
70
75
  # and __fields_set__ contains the field
71
76
  if self.conserved_quantity_for_lookthrough_expansion is None and "conserved_quantity_for_lookthrough_expansion" in self.__fields_set__:
@@ -93,6 +98,7 @@ class PricingOptions(BaseModel):
93
98
  "remove_contingent_cashflows_in_payment_diary": obj.get("removeContingentCashflowsInPaymentDiary"),
94
99
  "use_child_sub_holding_keys_for_portfolio_expansion": obj.get("useChildSubHoldingKeysForPortfolioExpansion"),
95
100
  "validate_domestic_and_quote_currencies_are_consistent": obj.get("validateDomesticAndQuoteCurrenciesAreConsistent"),
96
- "conserved_quantity_for_lookthrough_expansion": obj.get("conservedQuantityForLookthroughExpansion")
101
+ "conserved_quantity_for_lookthrough_expansion": obj.get("conservedQuantityForLookthroughExpansion"),
102
+ "return_zero_pv": ReturnZeroPvOptions.from_dict(obj.get("returnZeroPv")) if obj.get("returnZeroPv") is not None else None
97
103
  })
98
104
  return _obj