lusid-sdk 2.0.50b0__py3-none-any.whl → 2.0.470__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.
- lusid/__init__.py +1117 -14
- lusid/api/__init__.py +69 -0
- lusid/api/abor_api.py +513 -179
- lusid/api/abor_configuration_api.py +25 -24
- lusid/api/allocations_api.py +12 -20
- lusid/api/blocks_api.py +6 -6
- lusid/api/calendars_api.py +16 -24
- lusid/api/chart_of_accounts_api.py +1745 -441
- lusid/api/compliance_api.py +71 -62
- lusid/api/configuration_recipe_api.py +1198 -56
- lusid/api/corporate_action_sources_api.py +8 -8
- lusid/api/custom_entities_api.py +6 -6
- lusid/api/cut_label_definitions_api.py +9 -17
- lusid/api/data_types_api.py +16 -32
- lusid/api/executions_api.py +6 -6
- lusid/api/funds_api.py +1119 -0
- lusid/api/instrument_event_types_api.py +1287 -0
- lusid/api/instruments_api.py +12 -20
- lusid/api/legacy_compliance_api.py +12 -12
- lusid/api/legal_entities_api.py +12 -12
- lusid/api/order_graph_api.py +12 -12
- lusid/api/order_instructions_api.py +6 -6
- lusid/api/order_management_api.py +495 -14
- lusid/api/orders_api.py +16 -24
- lusid/api/packages_api.py +6 -6
- lusid/api/persons_api.py +16 -24
- lusid/api/placements_api.py +12 -12
- lusid/api/portfolio_groups_api.py +6 -6
- lusid/api/portfolios_api.py +23 -39
- lusid/api/property_definitions_api.py +205 -0
- lusid/api/queryable_keys_api.py +211 -0
- lusid/api/quotes_api.py +20 -36
- lusid/api/reconciliations_api.py +410 -1978
- lusid/api/schemas_api.py +7 -15
- lusid/api/scopes_api.py +151 -0
- lusid/api/scripted_translation_api.py +30 -28
- lusid/api/staging_rule_set_api.py +885 -0
- lusid/api/transaction_configuration_api.py +22 -22
- lusid/api/transaction_portfolios_api.py +282 -577
- lusid/api_client.py +5 -3
- lusid/configuration.py +1 -1
- lusid/extensions/__init__.py +10 -7
- lusid/extensions/api_client.py +3 -1
- lusid/extensions/api_client_factory.py +156 -45
- lusid/extensions/api_configuration.py +124 -15
- lusid/extensions/configuration_loaders.py +2 -4
- lusid/extensions/proxy_config.py +8 -5
- lusid/extensions/socket_keep_alive.py +14 -15
- lusid/extensions/tcp_keep_alive_connector.py +93 -46
- lusid/models/__init__.py +1028 -13
- lusid/models/abor.py +9 -2
- lusid/models/abor_configuration.py +8 -8
- lusid/models/abor_configuration_request.py +9 -9
- lusid/models/abor_request.py +1 -1
- lusid/models/account.py +6 -1
- lusid/models/accumulation_event.py +104 -0
- lusid/models/address_key_compliance_parameter.py +5 -12
- lusid/models/address_key_list_compliance_parameter.py +3 -3
- lusid/models/address_key_option_definition.py +3 -1
- lusid/models/amortisation_event.py +4 -6
- lusid/models/{underlying_leg.py → asset_leg.py} +15 -15
- lusid/models/basket.py +3 -3
- lusid/models/block_and_order_id_request.py +78 -0
- lusid/models/block_and_orders.py +83 -0
- lusid/models/block_and_orders_create_request.py +77 -0
- lusid/models/block_and_orders_request.py +134 -0
- lusid/models/blocked_order_request.py +130 -0
- lusid/models/bond.py +13 -6
- lusid/models/bond_coupon_event.py +97 -0
- lusid/models/bond_default_event.py +8 -18
- lusid/models/bond_principal_event.py +97 -0
- lusid/models/book_transactions_request.py +97 -0
- lusid/models/bool_compliance_parameter.py +3 -3
- lusid/models/bool_list_compliance_parameter.py +3 -3
- lusid/models/branch_step.py +101 -0
- lusid/models/cap_floor.py +3 -3
- lusid/models/cash_dividend_event.py +32 -10
- lusid/models/cash_election.py +91 -0
- lusid/models/cash_flow_event.py +5 -7
- lusid/models/cash_perpetual.py +3 -3
- lusid/models/cds_flow_conventions.py +1 -1
- lusid/models/cds_index.py +4 -4
- lusid/models/check_step.py +110 -0
- lusid/models/cleardown_module_details.py +95 -0
- lusid/models/cleardown_module_request.py +117 -0
- lusid/models/cleardown_module_response.py +139 -0
- lusid/models/cleardown_module_rule.py +94 -0
- lusid/models/{reconciliation_run_break.py → cleardown_module_rules_updated_response.py} +30 -36
- lusid/models/close_event.py +3 -3
- lusid/models/close_period_diary_entry_request.py +149 -0
- lusid/models/complete_portfolio.py +8 -1
- lusid/models/complex_bond.py +4 -4
- lusid/models/complex_market_data.py +6 -5
- lusid/models/compliance_parameter.py +8 -5
- lusid/models/compliance_parameter_type.py +3 -0
- lusid/models/compliance_rule_breakdown.py +16 -8
- lusid/models/compliance_rule_breakdown_request.py +12 -4
- lusid/models/compliance_rule_result_v2.py +85 -0
- lusid/models/compliance_step.py +99 -0
- lusid/models/compliance_step_type.py +42 -0
- lusid/models/compliance_summary_rule_result.py +12 -15
- lusid/models/compliance_summary_rule_result_request.py +12 -15
- lusid/models/compliance_template_variation.py +12 -2
- lusid/models/component_transaction.py +92 -0
- lusid/models/composite_dispersion.py +30 -5
- lusid/models/compounding.py +4 -4
- lusid/models/configuration_recipe.py +10 -19
- lusid/models/constant_volatility_surface.py +102 -0
- lusid/models/contract_for_difference.py +3 -3
- lusid/models/create_derived_property_definition_request.py +3 -3
- lusid/models/create_derived_transaction_portfolio_request.py +10 -3
- lusid/models/create_property_definition_request.py +12 -5
- lusid/models/create_staging_rule_set_request.py +91 -0
- lusid/models/create_trade_tickets_response.py +87 -0
- lusid/models/create_transaction_portfolio_request.py +16 -3
- lusid/models/credit_default_swap.py +4 -4
- lusid/models/credit_spread_curve_data.py +4 -4
- lusid/models/custom_entity_definition.py +8 -2
- lusid/models/custom_entity_type.py +8 -2
- lusid/models/cut_label_definition.py +7 -1
- lusid/models/data_type.py +7 -1
- lusid/models/data_type_summary.py +8 -2
- lusid/models/date_time_compliance_parameter.py +3 -3
- lusid/models/date_time_list_compliance_parameter.py +3 -3
- lusid/models/{upsert_reconciliation_run_request.py → day_month.py} +15 -15
- lusid/models/decimal_compliance_parameter.py +3 -3
- lusid/models/decimal_list_compliance_parameter.py +3 -3
- lusid/models/dialect.py +9 -3
- lusid/models/diary_entry.py +1 -1
- lusid/models/diary_entry_request.py +1 -1
- lusid/models/discount_factor_curve_data.py +3 -3
- lusid/models/dividend_option_event.py +129 -0
- lusid/models/dividend_reinvestment_event.py +124 -0
- lusid/models/election_specification.py +73 -0
- lusid/models/eligibility_calculation.py +71 -0
- lusid/models/empty_model_options.py +3 -3
- lusid/models/equity.py +8 -6
- lusid/models/equity_curve_by_prices_data.py +3 -3
- lusid/models/equity_model_options.py +3 -3
- lusid/models/equity_option.py +3 -3
- lusid/models/equity_swap.py +4 -4
- lusid/models/equity_vol_surface_data.py +3 -3
- lusid/models/exchange_traded_option.py +3 -3
- lusid/models/exercise_event.py +5 -7
- lusid/models/exotic_instrument.py +3 -3
- lusid/models/expiry_event.py +91 -0
- lusid/models/filter_predicate_compliance_parameter.py +91 -0
- lusid/models/filter_step.py +101 -0
- lusid/models/fixed_leg.py +3 -3
- lusid/models/fixed_schedule.py +4 -9
- lusid/models/flexible_loan.py +105 -0
- lusid/models/float_schedule.py +20 -12
- lusid/models/floating_leg.py +3 -3
- lusid/models/flow_convention_name.py +1 -1
- lusid/models/flow_conventions.py +1 -1
- lusid/models/forward_rate_agreement.py +3 -3
- lusid/models/from_recipe.py +81 -0
- lusid/models/fund.py +182 -0
- lusid/models/fund_properties.py +115 -0
- lusid/models/fund_request.py +165 -0
- lusid/models/fund_share_class.py +99 -0
- lusid/models/funding_leg.py +3 -3
- lusid/models/funding_leg_options.py +3 -3
- lusid/models/future.py +3 -3
- lusid/models/fx_conventions.py +73 -0
- lusid/models/fx_forward.py +8 -6
- lusid/models/fx_forward_curve_by_quote_reference.py +4 -4
- lusid/models/fx_forward_curve_data.py +3 -3
- lusid/models/fx_forward_model_options.py +3 -3
- lusid/models/fx_forward_pips_curve_data.py +3 -3
- lusid/models/fx_forward_settlement_event.py +136 -0
- lusid/models/fx_forward_tenor_curve_data.py +4 -4
- lusid/models/fx_forward_tenor_pips_curve_data.py +4 -4
- lusid/models/fx_linked_notional_schedule.py +108 -0
- lusid/models/fx_option.py +3 -3
- lusid/models/fx_rate_schedule.py +3 -3
- lusid/models/fx_swap.py +4 -4
- lusid/models/fx_vol_surface_data.py +3 -3
- lusid/models/{reconciliation_run.py → get_recipe_composer_response.py} +15 -15
- lusid/models/group_by_selector_compliance_parameter.py +91 -0
- lusid/models/group_by_step.py +101 -0
- lusid/models/group_filter_predicate_compliance_parameter.py +91 -0
- lusid/models/group_filter_step.py +110 -0
- lusid/models/group_of_market_data_key_rules.py +79 -0
- lusid/models/index_convention.py +1 -1
- lusid/models/index_model_options.py +3 -3
- lusid/models/inflation_index_conventions.py +2 -2
- lusid/models/inflation_leg.py +3 -3
- lusid/models/inflation_linked_bond.py +3 -3
- lusid/models/inflation_swap.py +4 -4
- lusid/models/informational_error_event.py +3 -3
- lusid/models/informational_event.py +4 -6
- lusid/models/instrument_event.py +13 -5
- lusid/models/instrument_event_configuration.py +74 -0
- lusid/models/instrument_event_holder.py +12 -3
- lusid/models/instrument_event_type.py +8 -0
- lusid/models/instrument_leg.py +3 -3
- lusid/models/instrument_list_compliance_parameter.py +3 -3
- lusid/models/instrument_payment_diary_leg.py +5 -3
- lusid/models/instrument_resolution_detail.py +105 -0
- lusid/models/instrument_type.py +2 -0
- lusid/models/interest_rate_swap.py +4 -4
- lusid/models/interest_rate_swaption.py +3 -3
- lusid/models/intermediate_compliance_step.py +110 -0
- lusid/models/ir_vol_cube_data.py +3 -3
- lusid/models/journal_entry_line.py +34 -3
- lusid/models/journal_entry_lines_query_parameters.py +1 -1
- lusid/models/label_value_set.py +1 -1
- lusid/models/leg_definition.py +16 -3
- lusid/models/lineage_member.py +87 -0
- lusid/models/lock_period_diary_entry_request.py +91 -0
- lusid/models/lusid_instrument.py +7 -5
- lusid/models/lusid_trade_ticket.py +8 -1
- lusid/models/market_context.py +17 -2
- lusid/models/market_data_type.py +1 -0
- lusid/models/maturity_event.py +91 -0
- lusid/models/model_options.py +5 -6
- lusid/models/model_options_type.py +0 -1
- lusid/models/model_selection.py +3 -3
- lusid/models/move_orders_to_different_blocks_request.py +77 -0
- lusid/models/moved_order_to_different_block_response.py +85 -0
- lusid/models/movement_type.py +2 -0
- lusid/models/multi_currency_amounts.py +71 -0
- lusid/models/opaque_market_data.py +3 -3
- lusid/models/opaque_model_options.py +3 -3
- lusid/models/open_event.py +3 -3
- lusid/models/optionality_schedule.py +3 -3
- lusid/models/order_graph_block.py +4 -2
- lusid/models/order_graph_block_order_detail.py +16 -2
- lusid/models/output_transaction.py +9 -2
- lusid/models/paged_resource_list_of_cleardown_module_response.py +113 -0
- lusid/models/{paged_resource_list_of_reconciliation_run_break.py → paged_resource_list_of_cleardown_module_rule.py} +11 -11
- lusid/models/{paged_resource_list_of_reconciliation_run.py → paged_resource_list_of_fund.py} +11 -11
- lusid/models/paged_resource_list_of_property_definition.py +113 -0
- lusid/models/paged_resource_list_of_staging_rule_set.py +113 -0
- lusid/models/paged_resource_list_of_transaction_template.py +113 -0
- lusid/models/paged_resource_list_of_transaction_template_specification.py +113 -0
- lusid/models/participation_request.py +3 -9
- lusid/models/performance_returns_metric.py +1 -1
- lusid/models/period_diary_entries_reopened_response.py +104 -0
- lusid/models/place_blocks_request.py +77 -0
- lusid/models/portfolio.py +15 -2
- lusid/models/portfolio_details.py +15 -2
- lusid/models/portfolio_group_id_compliance_parameter.py +3 -3
- lusid/models/portfolio_group_id_list_compliance_parameter.py +3 -3
- lusid/models/portfolio_holding.py +27 -2
- lusid/models/portfolio_id_compliance_parameter.py +3 -3
- lusid/models/portfolio_id_list_compliance_parameter.py +3 -3
- lusid/models/posting_module_rule.py +29 -4
- lusid/models/pricing_model.py +2 -1
- lusid/models/property_definition.py +17 -4
- lusid/models/property_definition_search_result.py +3 -3
- lusid/models/property_domain.py +3 -0
- lusid/models/property_key_compliance_parameter.py +3 -3
- lusid/models/property_key_list_compliance_parameter.py +3 -3
- lusid/models/queryable_key.py +124 -0
- lusid/models/raw_vendor_event.py +5 -7
- lusid/models/re_open_period_diary_entry_request.py +84 -0
- lusid/models/recipe_block.py +87 -0
- lusid/models/recipe_composer.py +100 -0
- lusid/models/{reconciliation_break_id.py → recipe_value.py} +22 -23
- lusid/models/recombine_step.py +101 -0
- lusid/models/reference_instrument.py +3 -3
- lusid/models/relative_date_offset.py +71 -0
- lusid/models/repo.py +3 -3
- lusid/models/reset_event.py +4 -6
- lusid/models/resource_list_of_block_and_orders.py +113 -0
- lusid/models/resource_list_of_get_recipe_composer_response.py +113 -0
- lusid/models/resource_list_of_moved_order_to_different_block_response.py +113 -0
- lusid/models/resource_list_of_queryable_key.py +113 -0
- lusid/models/schedule.py +6 -5
- lusid/models/schedule_type.py +1 -0
- lusid/models/script_map_reference.py +94 -0
- lusid/models/security_election.py +86 -0
- lusid/models/set_share_class_instruments_request.py +79 -0
- lusid/models/side_definition.py +1 -8
- lusid/models/sides_definition_request.py +1 -8
- lusid/models/simple_cash_flow_loan.py +3 -3
- lusid/models/simple_instrument.py +3 -3
- lusid/models/staging_rule.py +90 -0
- lusid/models/staging_rule_approval_criteria.py +81 -0
- lusid/models/staging_rule_match_criteria.py +95 -0
- lusid/models/staging_rule_set.py +103 -0
- lusid/models/step_schedule.py +3 -3
- lusid/models/stock_split_event.py +3 -3
- lusid/models/string_compliance_parameter.py +3 -3
- lusid/models/string_list_compliance_parameter.py +3 -3
- lusid/models/template_field.py +77 -0
- lusid/models/term_deposit.py +3 -3
- lusid/models/total_return_swap.py +16 -16
- lusid/models/transaction_configuration_movement_data.py +3 -3
- lusid/models/transaction_configuration_movement_data_request.py +3 -3
- lusid/models/transaction_currency_and_amount.py +81 -0
- lusid/models/transaction_field_map.py +97 -0
- lusid/models/transaction_price.py +3 -3
- lusid/models/transaction_price_and_type.py +81 -0
- lusid/models/transaction_price_type.py +1 -0
- lusid/models/transaction_property_map.py +80 -0
- lusid/models/transaction_template.py +100 -0
- lusid/models/transaction_template_request.py +79 -0
- lusid/models/transaction_template_specification.py +99 -0
- lusid/models/transaction_type_alias.py +0 -7
- lusid/models/transaction_type_calculation.py +1 -1
- lusid/models/transition_event.py +3 -3
- lusid/models/translation_context.py +75 -0
- lusid/models/translation_script.py +9 -3
- lusid/models/trial_balance.py +46 -11
- lusid/models/trial_balance_query_parameters.py +15 -6
- lusid/models/trigger_event.py +3 -3
- lusid/models/units_ratio.py +71 -0
- lusid/models/update_staging_rule_set_request.py +91 -0
- lusid/models/{compliance_run_summary.py → upsert_compliance_run_summary_result.py} +8 -8
- lusid/models/upsert_dialect_request.py +79 -0
- lusid/models/upsert_instrument_event_request.py +12 -3
- lusid/models/upsert_quote_request.py +1 -1
- lusid/models/upsert_recipe_composer_request.py +73 -0
- lusid/models/upsert_recipe_request.py +3 -9
- lusid/models/upsert_translation_script_request.py +75 -0
- lusid/models/valuation_schedule.py +10 -3
- lusid/models/weighted_instrument.py +13 -2
- lusid/models/weighted_instrument_in_line_lookup_identifiers.py +89 -0
- lusid/models/yield_curve_data.py +3 -3
- lusid/rest.py +1 -1
- {lusid_sdk-2.0.50b0.dist-info → lusid_sdk-2.0.470.dist-info}/METADATA +245 -48
- {lusid_sdk-2.0.50b0.dist-info → lusid_sdk-2.0.470.dist-info}/RECORD +326 -235
- {lusid_sdk-2.0.50b0.dist-info → lusid_sdk-2.0.470.dist-info}/WHEEL +1 -1
- lusid/extensions/api_client_builder.py +0 -138
- lusid/models/configuration_recipe_snippet.py +0 -139
- lusid/models/je_lines_query_parameters.py +0 -105
- lusid/models/look_up_pricing_model_options.py +0 -93
- lusid/models/reconciliation_run_id.py +0 -85
- lusid/models/upsert_reconciliation_break_request.py +0 -98
|
@@ -0,0 +1,85 @@
|
|
|
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 import BaseModel, Field
|
|
23
|
+
from lusid.models.block import Block
|
|
24
|
+
from lusid.models.order import Order
|
|
25
|
+
from lusid.models.resource_id import ResourceId
|
|
26
|
+
|
|
27
|
+
class MovedOrderToDifferentBlockResponse(BaseModel):
|
|
28
|
+
"""
|
|
29
|
+
MovedOrderToDifferentBlockResponse
|
|
30
|
+
"""
|
|
31
|
+
destination_block: Optional[Block] = Field(None, alias="destinationBlock")
|
|
32
|
+
order: Optional[Order] = None
|
|
33
|
+
source_block_id: Optional[ResourceId] = Field(None, alias="sourceBlockId")
|
|
34
|
+
__properties = ["destinationBlock", "order", "sourceBlockId"]
|
|
35
|
+
|
|
36
|
+
class Config:
|
|
37
|
+
"""Pydantic configuration"""
|
|
38
|
+
allow_population_by_field_name = True
|
|
39
|
+
validate_assignment = True
|
|
40
|
+
|
|
41
|
+
def to_str(self) -> str:
|
|
42
|
+
"""Returns the string representation of the model using alias"""
|
|
43
|
+
return pprint.pformat(self.dict(by_alias=True))
|
|
44
|
+
|
|
45
|
+
def to_json(self) -> str:
|
|
46
|
+
"""Returns the JSON representation of the model using alias"""
|
|
47
|
+
return json.dumps(self.to_dict())
|
|
48
|
+
|
|
49
|
+
@classmethod
|
|
50
|
+
def from_json(cls, json_str: str) -> MovedOrderToDifferentBlockResponse:
|
|
51
|
+
"""Create an instance of MovedOrderToDifferentBlockResponse from a JSON string"""
|
|
52
|
+
return cls.from_dict(json.loads(json_str))
|
|
53
|
+
|
|
54
|
+
def to_dict(self):
|
|
55
|
+
"""Returns the dictionary representation of the model using alias"""
|
|
56
|
+
_dict = self.dict(by_alias=True,
|
|
57
|
+
exclude={
|
|
58
|
+
},
|
|
59
|
+
exclude_none=True)
|
|
60
|
+
# override the default output from pydantic by calling `to_dict()` of destination_block
|
|
61
|
+
if self.destination_block:
|
|
62
|
+
_dict['destinationBlock'] = self.destination_block.to_dict()
|
|
63
|
+
# override the default output from pydantic by calling `to_dict()` of order
|
|
64
|
+
if self.order:
|
|
65
|
+
_dict['order'] = self.order.to_dict()
|
|
66
|
+
# override the default output from pydantic by calling `to_dict()` of source_block_id
|
|
67
|
+
if self.source_block_id:
|
|
68
|
+
_dict['sourceBlockId'] = self.source_block_id.to_dict()
|
|
69
|
+
return _dict
|
|
70
|
+
|
|
71
|
+
@classmethod
|
|
72
|
+
def from_dict(cls, obj: dict) -> MovedOrderToDifferentBlockResponse:
|
|
73
|
+
"""Create an instance of MovedOrderToDifferentBlockResponse from a dict"""
|
|
74
|
+
if obj is None:
|
|
75
|
+
return None
|
|
76
|
+
|
|
77
|
+
if not isinstance(obj, dict):
|
|
78
|
+
return MovedOrderToDifferentBlockResponse.parse_obj(obj)
|
|
79
|
+
|
|
80
|
+
_obj = MovedOrderToDifferentBlockResponse.parse_obj({
|
|
81
|
+
"destination_block": Block.from_dict(obj.get("destinationBlock")) if obj.get("destinationBlock") is not None else None,
|
|
82
|
+
"order": Order.from_dict(obj.get("order")) if obj.get("order") is not None else None,
|
|
83
|
+
"source_block_id": ResourceId.from_dict(obj.get("sourceBlockId")) if obj.get("sourceBlockId") is not None else None
|
|
84
|
+
})
|
|
85
|
+
return _obj
|
lusid/models/movement_type.py
CHANGED
|
@@ -0,0 +1,71 @@
|
|
|
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, Union
|
|
22
|
+
from pydantic import BaseModel, Field, StrictFloat, StrictInt
|
|
23
|
+
|
|
24
|
+
class MultiCurrencyAmounts(BaseModel):
|
|
25
|
+
"""
|
|
26
|
+
MultiCurrencyAmounts
|
|
27
|
+
"""
|
|
28
|
+
local_amount: Union[StrictFloat, StrictInt] = Field(..., alias="localAmount")
|
|
29
|
+
base_amount: Union[StrictFloat, StrictInt] = Field(..., alias="baseAmount")
|
|
30
|
+
__properties = ["localAmount", "baseAmount"]
|
|
31
|
+
|
|
32
|
+
class Config:
|
|
33
|
+
"""Pydantic configuration"""
|
|
34
|
+
allow_population_by_field_name = True
|
|
35
|
+
validate_assignment = True
|
|
36
|
+
|
|
37
|
+
def to_str(self) -> str:
|
|
38
|
+
"""Returns the string representation of the model using alias"""
|
|
39
|
+
return pprint.pformat(self.dict(by_alias=True))
|
|
40
|
+
|
|
41
|
+
def to_json(self) -> str:
|
|
42
|
+
"""Returns the JSON representation of the model using alias"""
|
|
43
|
+
return json.dumps(self.to_dict())
|
|
44
|
+
|
|
45
|
+
@classmethod
|
|
46
|
+
def from_json(cls, json_str: str) -> MultiCurrencyAmounts:
|
|
47
|
+
"""Create an instance of MultiCurrencyAmounts from a JSON string"""
|
|
48
|
+
return cls.from_dict(json.loads(json_str))
|
|
49
|
+
|
|
50
|
+
def to_dict(self):
|
|
51
|
+
"""Returns the dictionary representation of the model using alias"""
|
|
52
|
+
_dict = self.dict(by_alias=True,
|
|
53
|
+
exclude={
|
|
54
|
+
},
|
|
55
|
+
exclude_none=True)
|
|
56
|
+
return _dict
|
|
57
|
+
|
|
58
|
+
@classmethod
|
|
59
|
+
def from_dict(cls, obj: dict) -> MultiCurrencyAmounts:
|
|
60
|
+
"""Create an instance of MultiCurrencyAmounts from a dict"""
|
|
61
|
+
if obj is None:
|
|
62
|
+
return None
|
|
63
|
+
|
|
64
|
+
if not isinstance(obj, dict):
|
|
65
|
+
return MultiCurrencyAmounts.parse_obj(obj)
|
|
66
|
+
|
|
67
|
+
_obj = MultiCurrencyAmounts.parse_obj({
|
|
68
|
+
"local_amount": obj.get("localAmount"),
|
|
69
|
+
"base_amount": obj.get("baseAmount")
|
|
70
|
+
})
|
|
71
|
+
return _obj
|
|
@@ -30,15 +30,15 @@ class OpaqueMarketData(ComplexMarketData):
|
|
|
30
30
|
format: constr(strict=True, min_length=1) = Field(..., description="What format is the document stored in, e.g. Xml. Supported string (enumeration) values are: [Unknown, Xml, Json, Csv].")
|
|
31
31
|
name: constr(strict=True, min_length=1) = Field(..., description="Internal name of document. This is not used for search, it is simply a designator that helps identify the document and could be anything (filename, ftp address or similar)")
|
|
32
32
|
lineage: Optional[constr(strict=True, max_length=1024, min_length=0)] = Field(None, description="Description of the complex market data's lineage e.g. 'FundAccountant_GreenQuality'.")
|
|
33
|
-
market_data_type: StrictStr = Field(..., alias="marketDataType", description="The available values are: DiscountFactorCurveData, EquityVolSurfaceData, FxVolSurfaceData, IrVolCubeData, OpaqueMarketData, YieldCurveData, FxForwardCurveData, FxForwardPipsCurveData, FxForwardTenorCurveData, FxForwardTenorPipsCurveData, FxForwardCurveByQuoteReference, CreditSpreadCurveData, EquityCurveByPricesData")
|
|
33
|
+
market_data_type: StrictStr = Field(..., alias="marketDataType", description="The available values are: DiscountFactorCurveData, EquityVolSurfaceData, FxVolSurfaceData, IrVolCubeData, OpaqueMarketData, YieldCurveData, FxForwardCurveData, FxForwardPipsCurveData, FxForwardTenorCurveData, FxForwardTenorPipsCurveData, FxForwardCurveByQuoteReference, CreditSpreadCurveData, EquityCurveByPricesData, ConstantVolatilitySurface")
|
|
34
34
|
additional_properties: Dict[str, Any] = {}
|
|
35
35
|
__properties = ["marketDataType", "document", "format", "name", "lineage"]
|
|
36
36
|
|
|
37
37
|
@validator('market_data_type')
|
|
38
38
|
def market_data_type_validate_enum(cls, value):
|
|
39
39
|
"""Validates the enum"""
|
|
40
|
-
if value not in ('DiscountFactorCurveData', 'EquityVolSurfaceData', 'FxVolSurfaceData', 'IrVolCubeData', 'OpaqueMarketData', 'YieldCurveData', 'FxForwardCurveData', 'FxForwardPipsCurveData', 'FxForwardTenorCurveData', 'FxForwardTenorPipsCurveData', 'FxForwardCurveByQuoteReference', 'CreditSpreadCurveData', 'EquityCurveByPricesData'):
|
|
41
|
-
raise ValueError("must be one of enum values ('DiscountFactorCurveData', 'EquityVolSurfaceData', 'FxVolSurfaceData', 'IrVolCubeData', 'OpaqueMarketData', 'YieldCurveData', 'FxForwardCurveData', 'FxForwardPipsCurveData', 'FxForwardTenorCurveData', 'FxForwardTenorPipsCurveData', 'FxForwardCurveByQuoteReference', 'CreditSpreadCurveData', 'EquityCurveByPricesData')")
|
|
40
|
+
if value not in ('DiscountFactorCurveData', 'EquityVolSurfaceData', 'FxVolSurfaceData', 'IrVolCubeData', 'OpaqueMarketData', 'YieldCurveData', 'FxForwardCurveData', 'FxForwardPipsCurveData', 'FxForwardTenorCurveData', 'FxForwardTenorPipsCurveData', 'FxForwardCurveByQuoteReference', 'CreditSpreadCurveData', 'EquityCurveByPricesData', 'ConstantVolatilitySurface'):
|
|
41
|
+
raise ValueError("must be one of enum values ('DiscountFactorCurveData', 'EquityVolSurfaceData', 'FxVolSurfaceData', 'IrVolCubeData', 'OpaqueMarketData', 'YieldCurveData', 'FxForwardCurveData', 'FxForwardPipsCurveData', 'FxForwardTenorCurveData', 'FxForwardTenorPipsCurveData', 'FxForwardCurveByQuoteReference', 'CreditSpreadCurveData', 'EquityCurveByPricesData', 'ConstantVolatilitySurface')")
|
|
42
42
|
return value
|
|
43
43
|
|
|
44
44
|
class Config:
|
|
@@ -27,15 +27,15 @@ class OpaqueModelOptions(ModelOptions):
|
|
|
27
27
|
OpaqueModelOptions
|
|
28
28
|
"""
|
|
29
29
|
data: Dict[str, Dict[str, Any]] = Field(...)
|
|
30
|
-
model_options_type: StrictStr = Field(..., alias="modelOptionsType", description="The available values are: Invalid, OpaqueModelOptions, EmptyModelOptions, IndexModelOptions, FxForwardModelOptions, FundingLegModelOptions, EquityModelOptions
|
|
30
|
+
model_options_type: StrictStr = Field(..., alias="modelOptionsType", description="The available values are: Invalid, OpaqueModelOptions, EmptyModelOptions, IndexModelOptions, FxForwardModelOptions, FundingLegModelOptions, EquityModelOptions")
|
|
31
31
|
additional_properties: Dict[str, Any] = {}
|
|
32
32
|
__properties = ["modelOptionsType", "data"]
|
|
33
33
|
|
|
34
34
|
@validator('model_options_type')
|
|
35
35
|
def model_options_type_validate_enum(cls, value):
|
|
36
36
|
"""Validates the enum"""
|
|
37
|
-
if value not in ('Invalid', 'OpaqueModelOptions', 'EmptyModelOptions', 'IndexModelOptions', 'FxForwardModelOptions', 'FundingLegModelOptions', 'EquityModelOptions'
|
|
38
|
-
raise ValueError("must be one of enum values ('Invalid', 'OpaqueModelOptions', 'EmptyModelOptions', 'IndexModelOptions', 'FxForwardModelOptions', 'FundingLegModelOptions', 'EquityModelOptions'
|
|
37
|
+
if value not in ('Invalid', 'OpaqueModelOptions', 'EmptyModelOptions', 'IndexModelOptions', 'FxForwardModelOptions', 'FundingLegModelOptions', 'EquityModelOptions'):
|
|
38
|
+
raise ValueError("must be one of enum values ('Invalid', 'OpaqueModelOptions', 'EmptyModelOptions', 'IndexModelOptions', 'FxForwardModelOptions', 'FundingLegModelOptions', 'EquityModelOptions')")
|
|
39
39
|
return value
|
|
40
40
|
|
|
41
41
|
class Config:
|
lusid/models/open_event.py
CHANGED
|
@@ -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")
|
|
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")
|
|
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'):
|
|
38
|
-
raise ValueError("must be one of enum values ('TransitionEvent', 'InformationalEvent', 'OpenEvent', 'CloseEvent', 'StockSplitEvent', 'BondDefaultEvent', 'CashDividendEvent', 'AmortisationEvent', 'CashFlowEvent', 'ExerciseEvent', 'ResetEvent', 'TriggerEvent', 'RawVendorEvent', 'InformationalErrorEvent')")
|
|
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'):
|
|
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')")
|
|
39
39
|
return value
|
|
40
40
|
|
|
41
41
|
class Config:
|
|
@@ -30,15 +30,15 @@ class OptionalitySchedule(Schedule):
|
|
|
30
30
|
exercise_type: Optional[StrictStr] = Field(None, alias="exerciseType", description="The exercise type of the optionality schedule (American or European). For American type, the bond is perpetually callable from a given exercise date until it matures, or the next date in the schedule. For European type, the bond is only callable on a given exercise date. Supported string (enumeration) values are: [European, American].")
|
|
31
31
|
option_entries: Optional[conlist(OptionEntry)] = Field(None, alias="optionEntries", description="The dates at which the bond call/put may be actioned, and associated strikes.")
|
|
32
32
|
option_type: Optional[StrictStr] = Field(None, alias="optionType", description="Type of optionality for the schedule. Supported string (enumeration) values are: [Call, Put].")
|
|
33
|
-
schedule_type: StrictStr = Field(..., alias="scheduleType", description="The available values are: FixedSchedule, FloatSchedule, OptionalitySchedule, StepSchedule, Exercise, FxRateSchedule, Invalid")
|
|
33
|
+
schedule_type: StrictStr = Field(..., alias="scheduleType", description="The available values are: FixedSchedule, FloatSchedule, OptionalitySchedule, StepSchedule, Exercise, FxRateSchedule, FxLinkedNotionalSchedule, Invalid")
|
|
34
34
|
additional_properties: Dict[str, Any] = {}
|
|
35
35
|
__properties = ["scheduleType", "exerciseType", "optionEntries", "optionType"]
|
|
36
36
|
|
|
37
37
|
@validator('schedule_type')
|
|
38
38
|
def schedule_type_validate_enum(cls, value):
|
|
39
39
|
"""Validates the enum"""
|
|
40
|
-
if value not in ('FixedSchedule', 'FloatSchedule', 'OptionalitySchedule', 'StepSchedule', 'Exercise', 'FxRateSchedule', 'Invalid'):
|
|
41
|
-
raise ValueError("must be one of enum values ('FixedSchedule', 'FloatSchedule', 'OptionalitySchedule', 'StepSchedule', 'Exercise', 'FxRateSchedule', 'Invalid')")
|
|
40
|
+
if value not in ('FixedSchedule', 'FloatSchedule', 'OptionalitySchedule', 'StepSchedule', 'Exercise', 'FxRateSchedule', 'FxLinkedNotionalSchedule', 'Invalid'):
|
|
41
|
+
raise ValueError("must be one of enum values ('FixedSchedule', 'FloatSchedule', 'OptionalitySchedule', 'StepSchedule', 'Exercise', 'FxRateSchedule', 'FxLinkedNotionalSchedule', 'Invalid')")
|
|
42
42
|
return value
|
|
43
43
|
|
|
44
44
|
class Config:
|
|
@@ -37,7 +37,8 @@ class OrderGraphBlock(BaseModel):
|
|
|
37
37
|
allocated: OrderGraphBlockAllocationSynopsis = Field(...)
|
|
38
38
|
derived_state: constr(strict=True, min_length=1) = Field(..., alias="derivedState", description="A simple description of the overall state of a block.")
|
|
39
39
|
derived_compliance_state: constr(strict=True, min_length=1) = Field(..., alias="derivedComplianceState", description="The overall compliance state of a block, derived from the block's orders. Possible values are 'Pending', 'Failed', 'Manually approved' and 'Passed'.")
|
|
40
|
-
|
|
40
|
+
derived_approval_state: constr(strict=True, min_length=1) = Field(..., alias="derivedApprovalState", description="The overall approval state of a block, derived from approval of the block's orders. Possible values are 'Pending', 'Approved' and 'Rejected'.")
|
|
41
|
+
__properties = ["block", "ordered", "placed", "executed", "allocated", "derivedState", "derivedComplianceState", "derivedApprovalState"]
|
|
41
42
|
|
|
42
43
|
class Config:
|
|
43
44
|
"""Pydantic configuration"""
|
|
@@ -96,6 +97,7 @@ class OrderGraphBlock(BaseModel):
|
|
|
96
97
|
"executed": OrderGraphBlockExecutionSynopsis.from_dict(obj.get("executed")) if obj.get("executed") is not None else None,
|
|
97
98
|
"allocated": OrderGraphBlockAllocationSynopsis.from_dict(obj.get("allocated")) if obj.get("allocated") is not None else None,
|
|
98
99
|
"derived_state": obj.get("derivedState"),
|
|
99
|
-
"derived_compliance_state": obj.get("derivedComplianceState")
|
|
100
|
+
"derived_compliance_state": obj.get("derivedComplianceState"),
|
|
101
|
+
"derived_approval_state": obj.get("derivedApprovalState")
|
|
100
102
|
})
|
|
101
103
|
return _obj
|
|
@@ -28,9 +28,12 @@ class OrderGraphBlockOrderDetail(BaseModel):
|
|
|
28
28
|
"""
|
|
29
29
|
id: ResourceId = Field(...)
|
|
30
30
|
compliance_state: constr(strict=True, min_length=1) = Field(..., alias="complianceState", description="The compliance state of this order. Possible values are 'Pending', 'Failed', 'Manually approved' and 'Passed'.")
|
|
31
|
+
approval_state: constr(strict=True, min_length=1) = Field(..., alias="approvalState", description="The approval state of this order. Possible values are 'Pending', 'Rejected' and 'Approved'.")
|
|
31
32
|
portfolio_id: Optional[ResourceId] = Field(None, alias="portfolioId")
|
|
32
33
|
portfolio_name: Optional[StrictStr] = Field(None, alias="portfolioName", description="The name of the order's referenced Portfolio.")
|
|
33
|
-
|
|
34
|
+
order_approval_task_id: Optional[StrictStr] = Field(None, alias="orderApprovalTaskId", description="The task id associated with the approval state of the order.")
|
|
35
|
+
order_approval_task_definition_id: Optional[ResourceId] = Field(None, alias="orderApprovalTaskDefinitionId")
|
|
36
|
+
__properties = ["id", "complianceState", "approvalState", "portfolioId", "portfolioName", "orderApprovalTaskId", "orderApprovalTaskDefinitionId"]
|
|
34
37
|
|
|
35
38
|
class Config:
|
|
36
39
|
"""Pydantic configuration"""
|
|
@@ -62,11 +65,19 @@ class OrderGraphBlockOrderDetail(BaseModel):
|
|
|
62
65
|
# override the default output from pydantic by calling `to_dict()` of portfolio_id
|
|
63
66
|
if self.portfolio_id:
|
|
64
67
|
_dict['portfolioId'] = self.portfolio_id.to_dict()
|
|
68
|
+
# override the default output from pydantic by calling `to_dict()` of order_approval_task_definition_id
|
|
69
|
+
if self.order_approval_task_definition_id:
|
|
70
|
+
_dict['orderApprovalTaskDefinitionId'] = self.order_approval_task_definition_id.to_dict()
|
|
65
71
|
# set to None if portfolio_name (nullable) is None
|
|
66
72
|
# and __fields_set__ contains the field
|
|
67
73
|
if self.portfolio_name is None and "portfolio_name" in self.__fields_set__:
|
|
68
74
|
_dict['portfolioName'] = None
|
|
69
75
|
|
|
76
|
+
# set to None if order_approval_task_id (nullable) is None
|
|
77
|
+
# and __fields_set__ contains the field
|
|
78
|
+
if self.order_approval_task_id is None and "order_approval_task_id" in self.__fields_set__:
|
|
79
|
+
_dict['orderApprovalTaskId'] = None
|
|
80
|
+
|
|
70
81
|
return _dict
|
|
71
82
|
|
|
72
83
|
@classmethod
|
|
@@ -81,7 +92,10 @@ class OrderGraphBlockOrderDetail(BaseModel):
|
|
|
81
92
|
_obj = OrderGraphBlockOrderDetail.parse_obj({
|
|
82
93
|
"id": ResourceId.from_dict(obj.get("id")) if obj.get("id") is not None else None,
|
|
83
94
|
"compliance_state": obj.get("complianceState"),
|
|
95
|
+
"approval_state": obj.get("approvalState"),
|
|
84
96
|
"portfolio_id": ResourceId.from_dict(obj.get("portfolioId")) if obj.get("portfolioId") is not None else None,
|
|
85
|
-
"portfolio_name": obj.get("portfolioName")
|
|
97
|
+
"portfolio_name": obj.get("portfolioName"),
|
|
98
|
+
"order_approval_task_id": obj.get("orderApprovalTaskId"),
|
|
99
|
+
"order_approval_task_definition_id": ResourceId.from_dict(obj.get("orderApprovalTaskDefinitionId")) if obj.get("orderApprovalTaskDefinitionId") is not None else None
|
|
86
100
|
})
|
|
87
101
|
return _obj
|
|
@@ -52,7 +52,8 @@ class OutputTransaction(BaseModel):
|
|
|
52
52
|
cancel_date_time: Optional[datetime] = Field(None, alias="cancelDateTime", description="If the transaction has been cancelled, the asAt datetime that the transaction was cancelled.")
|
|
53
53
|
realised_gain_loss: Optional[conlist(RealisedGainLoss)] = Field(None, alias="realisedGainLoss", description="The collection of realised gains or losses resulting from relevant transactions e.g. a sale transaction. The cost used in calculating the realised gain or loss is determined by the accounting method defined when the transaction portfolio is created.")
|
|
54
54
|
holding_ids: Optional[conlist(StrictInt)] = Field(None, alias="holdingIds", description="The collection of single identifiers for the holding within the portfolio. The holdingId is constructed from the LusidInstrumentId, sub-holding keys and currrency and is unique within the portfolio.")
|
|
55
|
-
|
|
55
|
+
source_type: Optional[StrictStr] = Field(None, alias="sourceType", description="The type of source that the transaction originated from, eg: InputTransaction, InstrumentEvent, HoldingAdjustment")
|
|
56
|
+
__properties = ["transactionId", "type", "description", "instrumentIdentifiers", "instrumentScope", "instrumentUid", "transactionDate", "settlementDate", "units", "transactionAmount", "transactionPrice", "totalConsideration", "exchangeRate", "transactionToPortfolioRate", "transactionCurrency", "properties", "counterpartyId", "source", "transactionStatus", "entryDateTime", "cancelDateTime", "realisedGainLoss", "holdingIds", "sourceType"]
|
|
56
57
|
|
|
57
58
|
@validator('transaction_status')
|
|
58
59
|
def transaction_status_validate_enum(cls, value):
|
|
@@ -163,6 +164,11 @@ class OutputTransaction(BaseModel):
|
|
|
163
164
|
if self.holding_ids is None and "holding_ids" in self.__fields_set__:
|
|
164
165
|
_dict['holdingIds'] = None
|
|
165
166
|
|
|
167
|
+
# set to None if source_type (nullable) is None
|
|
168
|
+
# and __fields_set__ contains the field
|
|
169
|
+
if self.source_type is None and "source_type" in self.__fields_set__:
|
|
170
|
+
_dict['sourceType'] = None
|
|
171
|
+
|
|
166
172
|
return _dict
|
|
167
173
|
|
|
168
174
|
@classmethod
|
|
@@ -202,6 +208,7 @@ class OutputTransaction(BaseModel):
|
|
|
202
208
|
"entry_date_time": obj.get("entryDateTime"),
|
|
203
209
|
"cancel_date_time": obj.get("cancelDateTime"),
|
|
204
210
|
"realised_gain_loss": [RealisedGainLoss.from_dict(_item) for _item in obj.get("realisedGainLoss")] if obj.get("realisedGainLoss") is not None else None,
|
|
205
|
-
"holding_ids": obj.get("holdingIds")
|
|
211
|
+
"holding_ids": obj.get("holdingIds"),
|
|
212
|
+
"source_type": obj.get("sourceType")
|
|
206
213
|
})
|
|
207
214
|
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 import BaseModel, Field, StrictStr, conlist
|
|
23
|
+
from lusid.models.cleardown_module_response import CleardownModuleResponse
|
|
24
|
+
from lusid.models.link import Link
|
|
25
|
+
|
|
26
|
+
class PagedResourceListOfCleardownModuleResponse(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
PagedResourceListOfCleardownModuleResponse
|
|
29
|
+
"""
|
|
30
|
+
next_page: Optional[StrictStr] = Field(None, alias="nextPage")
|
|
31
|
+
previous_page: Optional[StrictStr] = Field(None, alias="previousPage")
|
|
32
|
+
values: conlist(CleardownModuleResponse) = 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) -> PagedResourceListOfCleardownModuleResponse:
|
|
52
|
+
"""Create an instance of PagedResourceListOfCleardownModuleResponse 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) -> PagedResourceListOfCleardownModuleResponse:
|
|
99
|
+
"""Create an instance of PagedResourceListOfCleardownModuleResponse from a dict"""
|
|
100
|
+
if obj is None:
|
|
101
|
+
return None
|
|
102
|
+
|
|
103
|
+
if not isinstance(obj, dict):
|
|
104
|
+
return PagedResourceListOfCleardownModuleResponse.parse_obj(obj)
|
|
105
|
+
|
|
106
|
+
_obj = PagedResourceListOfCleardownModuleResponse.parse_obj({
|
|
107
|
+
"next_page": obj.get("nextPage"),
|
|
108
|
+
"previous_page": obj.get("previousPage"),
|
|
109
|
+
"values": [CleardownModuleResponse.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
|
|
@@ -20,16 +20,16 @@ import json
|
|
|
20
20
|
|
|
21
21
|
from typing import Any, Dict, List, Optional
|
|
22
22
|
from pydantic import BaseModel, Field, StrictStr, conlist
|
|
23
|
+
from lusid.models.cleardown_module_rule import CleardownModuleRule
|
|
23
24
|
from lusid.models.link import Link
|
|
24
|
-
from lusid.models.reconciliation_run_break import ReconciliationRunBreak
|
|
25
25
|
|
|
26
|
-
class
|
|
26
|
+
class PagedResourceListOfCleardownModuleRule(BaseModel):
|
|
27
27
|
"""
|
|
28
|
-
|
|
28
|
+
PagedResourceListOfCleardownModuleRule
|
|
29
29
|
"""
|
|
30
30
|
next_page: Optional[StrictStr] = Field(None, alias="nextPage")
|
|
31
31
|
previous_page: Optional[StrictStr] = Field(None, alias="previousPage")
|
|
32
|
-
values: conlist(
|
|
32
|
+
values: conlist(CleardownModuleRule) = Field(...)
|
|
33
33
|
href: Optional[StrictStr] = None
|
|
34
34
|
links: Optional[conlist(Link)] = None
|
|
35
35
|
__properties = ["nextPage", "previousPage", "values", "href", "links"]
|
|
@@ -48,8 +48,8 @@ class PagedResourceListOfReconciliationRunBreak(BaseModel):
|
|
|
48
48
|
return json.dumps(self.to_dict())
|
|
49
49
|
|
|
50
50
|
@classmethod
|
|
51
|
-
def from_json(cls, json_str: str) ->
|
|
52
|
-
"""Create an instance of
|
|
51
|
+
def from_json(cls, json_str: str) -> PagedResourceListOfCleardownModuleRule:
|
|
52
|
+
"""Create an instance of PagedResourceListOfCleardownModuleRule from a JSON string"""
|
|
53
53
|
return cls.from_dict(json.loads(json_str))
|
|
54
54
|
|
|
55
55
|
def to_dict(self):
|
|
@@ -95,18 +95,18 @@ class PagedResourceListOfReconciliationRunBreak(BaseModel):
|
|
|
95
95
|
return _dict
|
|
96
96
|
|
|
97
97
|
@classmethod
|
|
98
|
-
def from_dict(cls, obj: dict) ->
|
|
99
|
-
"""Create an instance of
|
|
98
|
+
def from_dict(cls, obj: dict) -> PagedResourceListOfCleardownModuleRule:
|
|
99
|
+
"""Create an instance of PagedResourceListOfCleardownModuleRule from a dict"""
|
|
100
100
|
if obj is None:
|
|
101
101
|
return None
|
|
102
102
|
|
|
103
103
|
if not isinstance(obj, dict):
|
|
104
|
-
return
|
|
104
|
+
return PagedResourceListOfCleardownModuleRule.parse_obj(obj)
|
|
105
105
|
|
|
106
|
-
_obj =
|
|
106
|
+
_obj = PagedResourceListOfCleardownModuleRule.parse_obj({
|
|
107
107
|
"next_page": obj.get("nextPage"),
|
|
108
108
|
"previous_page": obj.get("previousPage"),
|
|
109
|
-
"values": [
|
|
109
|
+
"values": [CleardownModuleRule.from_dict(_item) for _item in obj.get("values")] if obj.get("values") is not None else None,
|
|
110
110
|
"href": obj.get("href"),
|
|
111
111
|
"links": [Link.from_dict(_item) for _item in obj.get("links")] if obj.get("links") is not None else None
|
|
112
112
|
})
|
lusid/models/{paged_resource_list_of_reconciliation_run.py → paged_resource_list_of_fund.py}
RENAMED
|
@@ -20,16 +20,16 @@ import json
|
|
|
20
20
|
|
|
21
21
|
from typing import Any, Dict, List, Optional
|
|
22
22
|
from pydantic import BaseModel, Field, StrictStr, conlist
|
|
23
|
+
from lusid.models.fund import Fund
|
|
23
24
|
from lusid.models.link import Link
|
|
24
|
-
from lusid.models.reconciliation_run import ReconciliationRun
|
|
25
25
|
|
|
26
|
-
class
|
|
26
|
+
class PagedResourceListOfFund(BaseModel):
|
|
27
27
|
"""
|
|
28
|
-
|
|
28
|
+
PagedResourceListOfFund
|
|
29
29
|
"""
|
|
30
30
|
next_page: Optional[StrictStr] = Field(None, alias="nextPage")
|
|
31
31
|
previous_page: Optional[StrictStr] = Field(None, alias="previousPage")
|
|
32
|
-
values: conlist(
|
|
32
|
+
values: conlist(Fund) = Field(...)
|
|
33
33
|
href: Optional[StrictStr] = None
|
|
34
34
|
links: Optional[conlist(Link)] = None
|
|
35
35
|
__properties = ["nextPage", "previousPage", "values", "href", "links"]
|
|
@@ -48,8 +48,8 @@ class PagedResourceListOfReconciliationRun(BaseModel):
|
|
|
48
48
|
return json.dumps(self.to_dict())
|
|
49
49
|
|
|
50
50
|
@classmethod
|
|
51
|
-
def from_json(cls, json_str: str) ->
|
|
52
|
-
"""Create an instance of
|
|
51
|
+
def from_json(cls, json_str: str) -> PagedResourceListOfFund:
|
|
52
|
+
"""Create an instance of PagedResourceListOfFund from a JSON string"""
|
|
53
53
|
return cls.from_dict(json.loads(json_str))
|
|
54
54
|
|
|
55
55
|
def to_dict(self):
|
|
@@ -95,18 +95,18 @@ class PagedResourceListOfReconciliationRun(BaseModel):
|
|
|
95
95
|
return _dict
|
|
96
96
|
|
|
97
97
|
@classmethod
|
|
98
|
-
def from_dict(cls, obj: dict) ->
|
|
99
|
-
"""Create an instance of
|
|
98
|
+
def from_dict(cls, obj: dict) -> PagedResourceListOfFund:
|
|
99
|
+
"""Create an instance of PagedResourceListOfFund from a dict"""
|
|
100
100
|
if obj is None:
|
|
101
101
|
return None
|
|
102
102
|
|
|
103
103
|
if not isinstance(obj, dict):
|
|
104
|
-
return
|
|
104
|
+
return PagedResourceListOfFund.parse_obj(obj)
|
|
105
105
|
|
|
106
|
-
_obj =
|
|
106
|
+
_obj = PagedResourceListOfFund.parse_obj({
|
|
107
107
|
"next_page": obj.get("nextPage"),
|
|
108
108
|
"previous_page": obj.get("previousPage"),
|
|
109
|
-
"values": [
|
|
109
|
+
"values": [Fund.from_dict(_item) for _item in obj.get("values")] if obj.get("values") is not None else None,
|
|
110
110
|
"href": obj.get("href"),
|
|
111
111
|
"links": [Link.from_dict(_item) for _item in obj.get("links")] if obj.get("links") is not None else None
|
|
112
112
|
})
|