lusid-sdk 2.1.254__py3-none-any.whl → 2.1.286__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.

Potentially problematic release.


This version of lusid-sdk might be problematic. Click here for more details.

Files changed (82) hide show
  1. lusid/__init__.py +44 -0
  2. lusid/api/__init__.py +2 -0
  3. lusid/api/fund_configurations_api.py +944 -0
  4. lusid/api/funds_api.py +1 -1
  5. lusid/api/order_management_api.py +161 -2
  6. lusid/configuration.py +1 -1
  7. lusid/models/__init__.py +42 -0
  8. lusid/models/accounting_method.py +3 -0
  9. lusid/models/accumulation_event.py +3 -3
  10. lusid/models/amortisation_event.py +3 -3
  11. lusid/models/bond_coupon_event.py +3 -3
  12. lusid/models/bond_default_event.py +3 -3
  13. lusid/models/bond_principal_event.py +3 -3
  14. lusid/models/cancel_placements_response.py +153 -0
  15. lusid/models/cancelled_placement_result.py +83 -0
  16. lusid/models/capital_distribution_event.py +3 -3
  17. lusid/models/cash.py +93 -0
  18. lusid/models/cash_dividend_event.py +3 -3
  19. lusid/models/cash_flow_event.py +3 -3
  20. lusid/models/close_event.py +3 -3
  21. lusid/models/component_filter.py +85 -0
  22. lusid/models/component_rule.py +77 -0
  23. lusid/models/contract_for_difference.py +4 -2
  24. lusid/models/create_derived_transaction_portfolio_request.py +3 -3
  25. lusid/models/create_transaction_portfolio_request.py +3 -3
  26. lusid/models/dividend_option_event.py +3 -3
  27. lusid/models/dividend_reinvestment_event.py +3 -3
  28. lusid/models/exercise_event.py +3 -3
  29. lusid/models/expiry_event.py +3 -3
  30. lusid/models/fund.py +6 -1
  31. lusid/models/fund_amount.py +69 -0
  32. lusid/models/fund_configuration.py +151 -0
  33. lusid/models/fund_configuration_properties.py +115 -0
  34. lusid/models/fund_configuration_request.py +136 -0
  35. lusid/models/fund_previous_nav.py +69 -0
  36. lusid/models/fund_request.py +6 -1
  37. lusid/models/fund_valuation_point_data.py +160 -0
  38. lusid/models/future_expiry_event.py +100 -0
  39. lusid/models/futures_contract_details.py +9 -2
  40. lusid/models/fx_forward_settlement_event.py +3 -3
  41. lusid/models/informational_error_event.py +3 -3
  42. lusid/models/informational_event.py +3 -3
  43. lusid/models/instrument_event.py +6 -5
  44. lusid/models/instrument_event_type.py +1 -0
  45. lusid/models/lusid_instrument.py +3 -2
  46. lusid/models/market_data_key_rule.py +3 -3
  47. lusid/models/market_data_specific_rule.py +3 -3
  48. lusid/models/market_quote.py +3 -3
  49. lusid/models/maturity_event.py +3 -3
  50. lusid/models/merger_event.py +3 -3
  51. lusid/models/model_selection.py +3 -3
  52. lusid/models/open_event.py +3 -3
  53. lusid/models/paged_resource_list_of_fund_configuration.py +113 -0
  54. lusid/models/portfolio.py +3 -3
  55. lusid/models/portfolio_details.py +3 -3
  56. lusid/models/portfolio_without_href.py +3 -3
  57. lusid/models/previous_fund_valuation_point_data.py +79 -0
  58. lusid/models/previous_nav.py +73 -0
  59. lusid/models/previous_share_class_breakdown.py +81 -0
  60. lusid/models/pricing_model.py +1 -0
  61. lusid/models/property_definition.py +7 -1
  62. lusid/models/quote_series_id.py +4 -20
  63. lusid/models/quote_type.py +3 -0
  64. lusid/models/raw_vendor_event.py +3 -3
  65. lusid/models/reset_event.py +3 -3
  66. lusid/models/reverse_stock_split_event.py +3 -3
  67. lusid/models/scrip_dividend_event.py +3 -3
  68. lusid/models/share_class_amount.py +73 -0
  69. lusid/models/share_class_breakdown.py +171 -0
  70. lusid/models/share_class_data.py +79 -0
  71. lusid/models/share_class_details.py +108 -0
  72. lusid/models/spin_off_event.py +3 -3
  73. lusid/models/stock_dividend_event.py +3 -3
  74. lusid/models/stock_split_event.py +3 -3
  75. lusid/models/transaction_field_map.py +8 -3
  76. lusid/models/transition_event.py +3 -3
  77. lusid/models/trigger_event.py +3 -3
  78. lusid/models/unitisation_data.py +73 -0
  79. lusid/models/valuation_point_data_response.py +30 -9
  80. {lusid_sdk-2.1.254.dist-info → lusid_sdk-2.1.286.dist-info}/METADATA +31 -4
  81. {lusid_sdk-2.1.254.dist-info → lusid_sdk-2.1.286.dist-info}/RECORD +82 -60
  82. {lusid_sdk-2.1.254.dist-info → lusid_sdk-2.1.286.dist-info}/WHEEL +0 -0
@@ -32,7 +32,7 @@ class CreateDerivedTransactionPortfolioRequest(BaseModel):
32
32
  parent_portfolio_id: ResourceId = Field(..., alias="parentPortfolioId")
33
33
  created: Optional[datetime] = Field(None, description="This will be auto-populated to be the parent portfolio creation date.")
34
34
  corporate_action_source_id: Optional[ResourceId] = Field(None, alias="corporateActionSourceId")
35
- accounting_method: Optional[StrictStr] = Field(None, alias="accountingMethod", description=". The available values are: Default, AverageCost, FirstInFirstOut, LastInFirstOut, HighestCostFirst, LowestCostFirst")
35
+ accounting_method: Optional[StrictStr] = Field(None, alias="accountingMethod", description=". The available values are: Default, AverageCost, FirstInFirstOut, LastInFirstOut, HighestCostFirst, LowestCostFirst, ProRateByUnits, ProRateByCost, ProRateByCostPortfolioCurrency")
36
36
  sub_holding_keys: Optional[conlist(StrictStr)] = Field(None, alias="subHoldingKeys", description="A set of unique transaction properties to group the derived transaction portfolio's holdings by, perhaps for strategy tagging. Each property must be from the 'Transaction' domain and identified by a key in the format {domain}/{scope}/{code}, for example 'Transaction/strategies/quantsignal'. See https://support.lusid.com/knowledgebase/article/KA-01879/en-us for more information.")
37
37
  instrument_scopes: Optional[conlist(StrictStr, max_items=1)] = Field(None, alias="instrumentScopes", description="The resolution strategy used to resolve instruments of transactions/holdings upserted to this derived portfolio.")
38
38
  amortisation_method: Optional[StrictStr] = Field(None, alias="amortisationMethod", description="The amortisation method used by the portfolio for the calculation. The available values are: NoAmortisation, StraightLine, EffectiveYield, StraightLineSettlementDate, EffectiveYieldSettlementDate")
@@ -71,8 +71,8 @@ class CreateDerivedTransactionPortfolioRequest(BaseModel):
71
71
  if value is None:
72
72
  return value
73
73
 
74
- if value not in ('Default', 'AverageCost', 'FirstInFirstOut', 'LastInFirstOut', 'HighestCostFirst', 'LowestCostFirst'):
75
- raise ValueError("must be one of enum values ('Default', 'AverageCost', 'FirstInFirstOut', 'LastInFirstOut', 'HighestCostFirst', 'LowestCostFirst')")
74
+ if value not in ('Default', 'AverageCost', 'FirstInFirstOut', 'LastInFirstOut', 'HighestCostFirst', 'LowestCostFirst', 'ProRateByUnits', 'ProRateByCost', 'ProRateByCostPortfolioCurrency'):
75
+ raise ValueError("must be one of enum values ('Default', 'AverageCost', 'FirstInFirstOut', 'LastInFirstOut', 'HighestCostFirst', 'LowestCostFirst', 'ProRateByUnits', 'ProRateByCost', 'ProRateByCostPortfolioCurrency')")
76
76
  return value
77
77
 
78
78
  @validator('transaction_type_scope')
@@ -34,7 +34,7 @@ class CreateTransactionPortfolioRequest(BaseModel):
34
34
  created: Optional[datetime] = Field(None, description="The effective datetime at which to create the transaction portfolio. No transactions can be added to the transaction portfolio before this date. Defaults to the current LUSID system datetime if not specified.")
35
35
  base_currency: StrictStr = Field(..., alias="baseCurrency", description="The base currency of the transaction portfolio in ISO 4217 currency code format.")
36
36
  corporate_action_source_id: Optional[ResourceId] = Field(None, alias="corporateActionSourceId")
37
- accounting_method: Optional[StrictStr] = Field(None, alias="accountingMethod", description=". The available values are: Default, AverageCost, FirstInFirstOut, LastInFirstOut, HighestCostFirst, LowestCostFirst")
37
+ accounting_method: Optional[StrictStr] = Field(None, alias="accountingMethod", description=". The available values are: Default, AverageCost, FirstInFirstOut, LastInFirstOut, HighestCostFirst, LowestCostFirst, ProRateByUnits, ProRateByCost, ProRateByCostPortfolioCurrency")
38
38
  sub_holding_keys: Optional[conlist(StrictStr, max_items=100)] = Field(None, alias="subHoldingKeys", description="A set of unique transaction properties to group the transaction portfolio's holdings by, perhaps for strategy tagging. Each property must be from the 'Transaction' domain and identified by a key in the format {domain}/{scope}/{code}, for example 'Transaction/strategies/quantsignal'. See https://support.lusid.com/knowledgebase/article/KA-01879/en-us for more information.")
39
39
  properties: Optional[Dict[str, ModelProperty]] = Field(None, description="A set of unique portfolio properties to add custom data to the transaction portfolio. Each property must be from the 'Portfolio' domain and identified by a key in the format {domain}/{scope}/{code}, for example 'Portfolio/Manager/Id'. Note these properties must be pre-defined.")
40
40
  instrument_scopes: Optional[conlist(StrictStr, max_items=1)] = Field(None, alias="instrumentScopes", description="The resolution strategy used to resolve instruments of transactions/holdings upserted to this portfolio.")
@@ -51,8 +51,8 @@ class CreateTransactionPortfolioRequest(BaseModel):
51
51
  if value is None:
52
52
  return value
53
53
 
54
- if value not in ('Default', 'AverageCost', 'FirstInFirstOut', 'LastInFirstOut', 'HighestCostFirst', 'LowestCostFirst'):
55
- raise ValueError("must be one of enum values ('Default', 'AverageCost', 'FirstInFirstOut', 'LastInFirstOut', 'HighestCostFirst', 'LowestCostFirst')")
54
+ if value not in ('Default', 'AverageCost', 'FirstInFirstOut', 'LastInFirstOut', 'HighestCostFirst', 'LowestCostFirst', 'ProRateByUnits', 'ProRateByCost', 'ProRateByCostPortfolioCurrency'):
55
+ raise ValueError("must be one of enum values ('Default', 'AverageCost', 'FirstInFirstOut', 'LastInFirstOut', 'HighestCostFirst', 'LowestCostFirst', 'ProRateByUnits', 'ProRateByCost', 'ProRateByCostPortfolioCurrency')")
56
56
  return value
57
57
 
58
58
  @validator('transaction_type_scope')
@@ -35,15 +35,15 @@ class DividendOptionEvent(InstrumentEvent):
35
35
  record_date: Optional[datetime] = Field(None, alias="recordDate", description="Date you have to be the holder of record in order to participate in the tender.")
36
36
  security_elections: conlist(SecurityElection) = Field(..., alias="securityElections", description="SecurityElection for this DividendReinvestmentEvent")
37
37
  security_settlement_date: Optional[datetime] = Field(None, alias="securitySettlementDate", description="The settlement date of the additional units. Equal to the PaymentDate if not provided.")
38
- 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")
38
+ 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")
39
39
  additional_properties: Dict[str, Any] = {}
40
40
  __properties = ["instrumentEventType", "announcementDate", "cashElections", "exDate", "paymentDate", "recordDate", "securityElections", "securitySettlementDate"]
41
41
 
42
42
  @validator('instrument_event_type')
43
43
  def instrument_event_type_validate_enum(cls, value):
44
44
  """Validates the enum"""
45
- 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'):
46
- 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')")
45
+ 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'):
46
+ 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')")
47
47
  return value
48
48
 
49
49
  class Config:
@@ -35,15 +35,15 @@ class DividendReinvestmentEvent(InstrumentEvent):
35
35
  record_date: datetime = Field(..., alias="recordDate", description="Date you have to be the holder of record in order to participate in the tender.")
36
36
  security_elections: conlist(SecurityElection) = Field(..., alias="securityElections", description="SecurityElection for this DividendReinvestmentEvent")
37
37
  security_settlement_date: Optional[datetime] = Field(None, alias="securitySettlementDate", description="The settlement date of the additional units. Equal to the PaymentDate if not provided.")
38
- 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")
38
+ 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")
39
39
  additional_properties: Dict[str, Any] = {}
40
40
  __properties = ["instrumentEventType", "announcementDate", "cashElections", "exDate", "paymentDate", "recordDate", "securityElections", "securitySettlementDate"]
41
41
 
42
42
  @validator('instrument_event_type')
43
43
  def instrument_event_type_validate_enum(cls, value):
44
44
  """Validates the enum"""
45
- 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'):
46
- 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')")
45
+ 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'):
46
+ 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')")
47
47
  return value
48
48
 
49
49
  class Config:
@@ -30,15 +30,15 @@ class ExerciseEvent(InstrumentEvent):
30
30
  instrument: LusidInstrument = Field(...)
31
31
  anchor_date: datetime = Field(..., alias="anchorDate", description="The date the exercise window starts, or point it takes effect on.")
32
32
  event_window_end: Optional[datetime] = Field(None, alias="eventWindowEnd", description="The date the exercise window ends, or point it takes effect on.")
33
- 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")
33
+ 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")
34
34
  additional_properties: Dict[str, Any] = {}
35
35
  __properties = ["instrumentEventType", "instrument", "anchorDate", "eventWindowEnd"]
36
36
 
37
37
  @validator('instrument_event_type')
38
38
  def instrument_event_type_validate_enum(cls, value):
39
39
  """Validates the enum"""
40
- 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'):
41
- 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')")
40
+ 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'):
41
+ 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')")
42
42
  return value
43
43
 
44
44
  class Config:
@@ -27,15 +27,15 @@ class ExpiryEvent(InstrumentEvent):
27
27
  Definition of an Expiry Event This is an event that describes the expiry of the instrument. # noqa: E501
28
28
  """
29
29
  expiry_date: datetime = Field(..., alias="expiryDate", description="Expiry date of the instrument")
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")
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")
31
31
  additional_properties: Dict[str, Any] = {}
32
32
  __properties = ["instrumentEventType", "expiryDate"]
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'):
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')")
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'):
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')")
39
39
  return value
40
40
 
41
41
  class Config:
lusid/models/fund.py CHANGED
@@ -35,6 +35,7 @@ class Fund(BaseModel):
35
35
  id: ResourceId = Field(...)
36
36
  display_name: Optional[constr(strict=True, max_length=256, min_length=1)] = Field(None, alias="displayName", description="The name of the Fund.")
37
37
  description: Optional[constr(strict=True, max_length=1024, min_length=0)] = Field(None, description="A description for the Fund.")
38
+ fund_configuration_id: Optional[ResourceId] = Field(None, alias="fundConfigurationId")
38
39
  abor_id: ResourceId = Field(..., alias="aborId")
39
40
  share_class_instruments: Optional[conlist(InstrumentResolutionDetail)] = Field(None, alias="shareClassInstruments", description="Details the user-provided instrument identifiers and the instrument resolved from them.")
40
41
  type: constr(strict=True, min_length=1) = Field(..., description="The type of fund; 'Standalone', 'Master' or 'Feeder'")
@@ -44,7 +45,7 @@ class Fund(BaseModel):
44
45
  properties: Optional[Dict[str, ModelProperty]] = Field(None, description="A set of properties for the Fund.")
45
46
  version: Optional[Version] = None
46
47
  links: Optional[conlist(Link)] = None
47
- __properties = ["href", "id", "displayName", "description", "aborId", "shareClassInstruments", "type", "inceptionDate", "decimalPlaces", "yearEndDate", "properties", "version", "links"]
48
+ __properties = ["href", "id", "displayName", "description", "fundConfigurationId", "aborId", "shareClassInstruments", "type", "inceptionDate", "decimalPlaces", "yearEndDate", "properties", "version", "links"]
48
49
 
49
50
  @validator('description')
50
51
  def description_validate_regular_expression(cls, value):
@@ -83,6 +84,9 @@ class Fund(BaseModel):
83
84
  # override the default output from pydantic by calling `to_dict()` of id
84
85
  if self.id:
85
86
  _dict['id'] = self.id.to_dict()
87
+ # override the default output from pydantic by calling `to_dict()` of fund_configuration_id
88
+ if self.fund_configuration_id:
89
+ _dict['fundConfigurationId'] = self.fund_configuration_id.to_dict()
86
90
  # override the default output from pydantic by calling `to_dict()` of abor_id
87
91
  if self.abor_id:
88
92
  _dict['aborId'] = self.abor_id.to_dict()
@@ -164,6 +168,7 @@ class Fund(BaseModel):
164
168
  "id": ResourceId.from_dict(obj.get("id")) if obj.get("id") is not None else None,
165
169
  "display_name": obj.get("displayName"),
166
170
  "description": obj.get("description"),
171
+ "fund_configuration_id": ResourceId.from_dict(obj.get("fundConfigurationId")) if obj.get("fundConfigurationId") is not None else None,
167
172
  "abor_id": ResourceId.from_dict(obj.get("aborId")) if obj.get("aborId") is not None else None,
168
173
  "share_class_instruments": [InstrumentResolutionDetail.from_dict(_item) for _item in obj.get("shareClassInstruments")] if obj.get("shareClassInstruments") is not None else None,
169
174
  "type": obj.get("type"),
@@ -0,0 +1,69 @@
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, Union
22
+ from pydantic.v1 import BaseModel, Field, StrictFloat, StrictInt
23
+
24
+ class FundAmount(BaseModel):
25
+ """
26
+ FundAmount
27
+ """
28
+ value: Optional[Union[StrictFloat, StrictInt]] = Field(None, description="The value of the amount.")
29
+ __properties = ["value"]
30
+
31
+ class Config:
32
+ """Pydantic configuration"""
33
+ allow_population_by_field_name = True
34
+ validate_assignment = True
35
+
36
+ def to_str(self) -> str:
37
+ """Returns the string representation of the model using alias"""
38
+ return pprint.pformat(self.dict(by_alias=True))
39
+
40
+ def to_json(self) -> str:
41
+ """Returns the JSON representation of the model using alias"""
42
+ return json.dumps(self.to_dict())
43
+
44
+ @classmethod
45
+ def from_json(cls, json_str: str) -> FundAmount:
46
+ """Create an instance of FundAmount from a JSON string"""
47
+ return cls.from_dict(json.loads(json_str))
48
+
49
+ def to_dict(self):
50
+ """Returns the dictionary representation of the model using alias"""
51
+ _dict = self.dict(by_alias=True,
52
+ exclude={
53
+ },
54
+ exclude_none=True)
55
+ return _dict
56
+
57
+ @classmethod
58
+ def from_dict(cls, obj: dict) -> FundAmount:
59
+ """Create an instance of FundAmount from a dict"""
60
+ if obj is None:
61
+ return None
62
+
63
+ if not isinstance(obj, dict):
64
+ return FundAmount.parse_obj(obj)
65
+
66
+ _obj = FundAmount.parse_obj({
67
+ "value": obj.get("value")
68
+ })
69
+ return _obj
@@ -0,0 +1,151 @@
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.component_rule import ComponentRule
24
+ from lusid.models.link import Link
25
+ from lusid.models.model_property import ModelProperty
26
+ from lusid.models.resource_id import ResourceId
27
+ from lusid.models.version import Version
28
+
29
+ class FundConfiguration(BaseModel):
30
+ """
31
+ FundConfiguration
32
+ """
33
+ href: Optional[StrictStr] = Field(None, description="The specific Uniform Resource Identifier (URI) for this resource at the requested effective and asAt datetime.")
34
+ id: ResourceId = Field(...)
35
+ display_name: Optional[StrictStr] = Field(None, alias="displayName", description="The name of the FundConfiguration.")
36
+ description: Optional[StrictStr] = Field(None, description="A description for the FundConfiguration.")
37
+ dealing_rule: Optional[ComponentRule] = Field(None, alias="dealingRule")
38
+ fund_pnl_exclusion_rule: Optional[ComponentRule] = Field(None, alias="fundPnlExclusionRule")
39
+ back_out_rule: Optional[ComponentRule] = Field(None, alias="backOutRule")
40
+ properties: Optional[Dict[str, ModelProperty]] = Field(None, description="A set of properties for the Fund Configuration.")
41
+ version: Optional[Version] = None
42
+ links: Optional[conlist(Link)] = None
43
+ __properties = ["href", "id", "displayName", "description", "dealingRule", "fundPnlExclusionRule", "backOutRule", "properties", "version", "links"]
44
+
45
+ class Config:
46
+ """Pydantic configuration"""
47
+ allow_population_by_field_name = True
48
+ validate_assignment = True
49
+
50
+ def to_str(self) -> str:
51
+ """Returns the string representation of the model using alias"""
52
+ return pprint.pformat(self.dict(by_alias=True))
53
+
54
+ def to_json(self) -> str:
55
+ """Returns the JSON representation of the model using alias"""
56
+ return json.dumps(self.to_dict())
57
+
58
+ @classmethod
59
+ def from_json(cls, json_str: str) -> FundConfiguration:
60
+ """Create an instance of FundConfiguration from a JSON string"""
61
+ return cls.from_dict(json.loads(json_str))
62
+
63
+ def to_dict(self):
64
+ """Returns the dictionary representation of the model using alias"""
65
+ _dict = self.dict(by_alias=True,
66
+ exclude={
67
+ },
68
+ exclude_none=True)
69
+ # override the default output from pydantic by calling `to_dict()` of id
70
+ if self.id:
71
+ _dict['id'] = self.id.to_dict()
72
+ # override the default output from pydantic by calling `to_dict()` of dealing_rule
73
+ if self.dealing_rule:
74
+ _dict['dealingRule'] = self.dealing_rule.to_dict()
75
+ # override the default output from pydantic by calling `to_dict()` of fund_pnl_exclusion_rule
76
+ if self.fund_pnl_exclusion_rule:
77
+ _dict['fundPnlExclusionRule'] = self.fund_pnl_exclusion_rule.to_dict()
78
+ # override the default output from pydantic by calling `to_dict()` of back_out_rule
79
+ if self.back_out_rule:
80
+ _dict['backOutRule'] = self.back_out_rule.to_dict()
81
+ # override the default output from pydantic by calling `to_dict()` of each value in properties (dict)
82
+ _field_dict = {}
83
+ if self.properties:
84
+ for _key in self.properties:
85
+ if self.properties[_key]:
86
+ _field_dict[_key] = self.properties[_key].to_dict()
87
+ _dict['properties'] = _field_dict
88
+ # override the default output from pydantic by calling `to_dict()` of version
89
+ if self.version:
90
+ _dict['version'] = self.version.to_dict()
91
+ # override the default output from pydantic by calling `to_dict()` of each item in links (list)
92
+ _items = []
93
+ if self.links:
94
+ for _item in self.links:
95
+ if _item:
96
+ _items.append(_item.to_dict())
97
+ _dict['links'] = _items
98
+ # set to None if href (nullable) is None
99
+ # and __fields_set__ contains the field
100
+ if self.href is None and "href" in self.__fields_set__:
101
+ _dict['href'] = None
102
+
103
+ # set to None if display_name (nullable) is None
104
+ # and __fields_set__ contains the field
105
+ if self.display_name is None and "display_name" in self.__fields_set__:
106
+ _dict['displayName'] = None
107
+
108
+ # set to None if description (nullable) is None
109
+ # and __fields_set__ contains the field
110
+ if self.description is None and "description" in self.__fields_set__:
111
+ _dict['description'] = None
112
+
113
+ # set to None if properties (nullable) is None
114
+ # and __fields_set__ contains the field
115
+ if self.properties is None and "properties" in self.__fields_set__:
116
+ _dict['properties'] = None
117
+
118
+ # set to None if links (nullable) is None
119
+ # and __fields_set__ contains the field
120
+ if self.links is None and "links" in self.__fields_set__:
121
+ _dict['links'] = None
122
+
123
+ return _dict
124
+
125
+ @classmethod
126
+ def from_dict(cls, obj: dict) -> FundConfiguration:
127
+ """Create an instance of FundConfiguration from a dict"""
128
+ if obj is None:
129
+ return None
130
+
131
+ if not isinstance(obj, dict):
132
+ return FundConfiguration.parse_obj(obj)
133
+
134
+ _obj = FundConfiguration.parse_obj({
135
+ "href": obj.get("href"),
136
+ "id": ResourceId.from_dict(obj.get("id")) if obj.get("id") is not None else None,
137
+ "display_name": obj.get("displayName"),
138
+ "description": obj.get("description"),
139
+ "dealing_rule": ComponentRule.from_dict(obj.get("dealingRule")) if obj.get("dealingRule") is not None else None,
140
+ "fund_pnl_exclusion_rule": ComponentRule.from_dict(obj.get("fundPnlExclusionRule")) if obj.get("fundPnlExclusionRule") is not None else None,
141
+ "back_out_rule": ComponentRule.from_dict(obj.get("backOutRule")) if obj.get("backOutRule") is not None else None,
142
+ "properties": dict(
143
+ (_k, ModelProperty.from_dict(_v))
144
+ for _k, _v in obj.get("properties").items()
145
+ )
146
+ if obj.get("properties") is not None
147
+ else None,
148
+ "version": Version.from_dict(obj.get("version")) if obj.get("version") is not None else None,
149
+ "links": [Link.from_dict(_item) for _item in obj.get("links")] if obj.get("links") is not None else None
150
+ })
151
+ return _obj
@@ -0,0 +1,115 @@
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.link import Link
24
+ from lusid.models.model_property import ModelProperty
25
+ from lusid.models.version import Version
26
+
27
+ class FundConfigurationProperties(BaseModel):
28
+ """
29
+ FundConfigurationProperties
30
+ """
31
+ href: Optional[StrictStr] = Field(None, description="The specific Uniform Resource Identifier (URI) for this resource at the requested effective and asAt datetime.")
32
+ properties: Optional[Dict[str, ModelProperty]] = Field(None, description="The Fund Configuration properties. These will be from the 'FundConfiguration' domain.")
33
+ version: Optional[Version] = None
34
+ links: Optional[conlist(Link)] = None
35
+ __properties = ["href", "properties", "version", "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) -> FundConfigurationProperties:
52
+ """Create an instance of FundConfigurationProperties 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 value in properties (dict)
62
+ _field_dict = {}
63
+ if self.properties:
64
+ for _key in self.properties:
65
+ if self.properties[_key]:
66
+ _field_dict[_key] = self.properties[_key].to_dict()
67
+ _dict['properties'] = _field_dict
68
+ # override the default output from pydantic by calling `to_dict()` of version
69
+ if self.version:
70
+ _dict['version'] = self.version.to_dict()
71
+ # override the default output from pydantic by calling `to_dict()` of each item in links (list)
72
+ _items = []
73
+ if self.links:
74
+ for _item in self.links:
75
+ if _item:
76
+ _items.append(_item.to_dict())
77
+ _dict['links'] = _items
78
+ # set to None if href (nullable) is None
79
+ # and __fields_set__ contains the field
80
+ if self.href is None and "href" in self.__fields_set__:
81
+ _dict['href'] = None
82
+
83
+ # set to None if properties (nullable) is None
84
+ # and __fields_set__ contains the field
85
+ if self.properties is None and "properties" in self.__fields_set__:
86
+ _dict['properties'] = None
87
+
88
+ # set to None if links (nullable) is None
89
+ # and __fields_set__ contains the field
90
+ if self.links is None and "links" in self.__fields_set__:
91
+ _dict['links'] = None
92
+
93
+ return _dict
94
+
95
+ @classmethod
96
+ def from_dict(cls, obj: dict) -> FundConfigurationProperties:
97
+ """Create an instance of FundConfigurationProperties from a dict"""
98
+ if obj is None:
99
+ return None
100
+
101
+ if not isinstance(obj, dict):
102
+ return FundConfigurationProperties.parse_obj(obj)
103
+
104
+ _obj = FundConfigurationProperties.parse_obj({
105
+ "href": obj.get("href"),
106
+ "properties": dict(
107
+ (_k, ModelProperty.from_dict(_v))
108
+ for _k, _v in obj.get("properties").items()
109
+ )
110
+ if obj.get("properties") is not None
111
+ else None,
112
+ "version": Version.from_dict(obj.get("version")) if obj.get("version") is not None else None,
113
+ "links": [Link.from_dict(_item) for _item in obj.get("links")] if obj.get("links") is not None else None
114
+ })
115
+ return _obj