lusid-sdk 2.1.264__py3-none-any.whl → 2.1.280__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 +26 -0
- lusid/configuration.py +1 -1
- lusid/models/__init__.py +26 -0
- lusid/models/cash.py +93 -0
- lusid/models/component_filter.py +85 -0
- lusid/models/component_rule.py +12 -9
- lusid/models/contract_for_difference.py +4 -2
- lusid/models/fund.py +6 -1
- lusid/models/fund_amount.py +69 -0
- lusid/models/fund_previous_nav.py +69 -0
- lusid/models/fund_request.py +6 -1
- lusid/models/fund_valuation_point_data.py +160 -0
- lusid/models/futures_contract_details.py +9 -2
- lusid/models/lusid_instrument.py +3 -2
- lusid/models/market_data_key_rule.py +3 -3
- lusid/models/market_data_specific_rule.py +3 -3
- lusid/models/market_quote.py +3 -3
- lusid/models/previous_fund_valuation_point_data.py +79 -0
- lusid/models/previous_nav.py +73 -0
- lusid/models/previous_share_class_breakdown.py +81 -0
- lusid/models/quote_series_id.py +4 -20
- lusid/models/quote_type.py +3 -0
- lusid/models/share_class_amount.py +73 -0
- lusid/models/share_class_breakdown.py +171 -0
- lusid/models/share_class_data.py +79 -0
- lusid/models/share_class_details.py +108 -0
- lusid/models/unitisation_data.py +73 -0
- lusid/models/valuation_point_data_response.py +30 -9
- {lusid_sdk-2.1.264.dist-info → lusid_sdk-2.1.280.dist-info}/METADATA +16 -3
- {lusid_sdk-2.1.264.dist-info → lusid_sdk-2.1.280.dist-info}/RECORD +31 -18
- {lusid_sdk-2.1.264.dist-info → lusid_sdk-2.1.280.dist-info}/WHEEL +0 -0
lusid/__init__.py
CHANGED
|
@@ -189,6 +189,7 @@ from lusid.models.cancel_placements_response import CancelPlacementsResponse
|
|
|
189
189
|
from lusid.models.cancelled_placement_result import CancelledPlacementResult
|
|
190
190
|
from lusid.models.cap_floor import CapFloor
|
|
191
191
|
from lusid.models.capital_distribution_event import CapitalDistributionEvent
|
|
192
|
+
from lusid.models.cash import Cash
|
|
192
193
|
from lusid.models.cash_and_security_offer_election import CashAndSecurityOfferElection
|
|
193
194
|
from lusid.models.cash_dependency import CashDependency
|
|
194
195
|
from lusid.models.cash_dividend_event import CashDividendEvent
|
|
@@ -253,6 +254,7 @@ from lusid.models.compliance_template_parameter import ComplianceTemplateParamet
|
|
|
253
254
|
from lusid.models.compliance_template_variation import ComplianceTemplateVariation
|
|
254
255
|
from lusid.models.compliance_template_variation_dto import ComplianceTemplateVariationDto
|
|
255
256
|
from lusid.models.compliance_template_variation_request import ComplianceTemplateVariationRequest
|
|
257
|
+
from lusid.models.component_filter import ComponentFilter
|
|
256
258
|
from lusid.models.component_rule import ComponentRule
|
|
257
259
|
from lusid.models.component_transaction import ComponentTransaction
|
|
258
260
|
from lusid.models.composite_breakdown import CompositeBreakdown
|
|
@@ -420,12 +422,15 @@ from lusid.models.flow_conventions import FlowConventions
|
|
|
420
422
|
from lusid.models.forward_rate_agreement import ForwardRateAgreement
|
|
421
423
|
from lusid.models.from_recipe import FromRecipe
|
|
422
424
|
from lusid.models.fund import Fund
|
|
425
|
+
from lusid.models.fund_amount import FundAmount
|
|
423
426
|
from lusid.models.fund_configuration import FundConfiguration
|
|
424
427
|
from lusid.models.fund_configuration_properties import FundConfigurationProperties
|
|
425
428
|
from lusid.models.fund_configuration_request import FundConfigurationRequest
|
|
429
|
+
from lusid.models.fund_previous_nav import FundPreviousNAV
|
|
426
430
|
from lusid.models.fund_properties import FundProperties
|
|
427
431
|
from lusid.models.fund_request import FundRequest
|
|
428
432
|
from lusid.models.fund_share_class import FundShareClass
|
|
433
|
+
from lusid.models.fund_valuation_point_data import FundValuationPointData
|
|
429
434
|
from lusid.models.funding_leg import FundingLeg
|
|
430
435
|
from lusid.models.funding_leg_options import FundingLegOptions
|
|
431
436
|
from lusid.models.future import Future
|
|
@@ -734,6 +739,9 @@ from lusid.models.posting_module_response import PostingModuleResponse
|
|
|
734
739
|
from lusid.models.posting_module_rule import PostingModuleRule
|
|
735
740
|
from lusid.models.posting_module_rules_updated_response import PostingModuleRulesUpdatedResponse
|
|
736
741
|
from lusid.models.premium import Premium
|
|
742
|
+
from lusid.models.previous_fund_valuation_point_data import PreviousFundValuationPointData
|
|
743
|
+
from lusid.models.previous_nav import PreviousNAV
|
|
744
|
+
from lusid.models.previous_share_class_breakdown import PreviousShareClassBreakdown
|
|
737
745
|
from lusid.models.pricing_context import PricingContext
|
|
738
746
|
from lusid.models.pricing_model import PricingModel
|
|
739
747
|
from lusid.models.pricing_options import PricingOptions
|
|
@@ -914,6 +922,10 @@ from lusid.models.set_share_class_instruments_request import SetShareClassInstru
|
|
|
914
922
|
from lusid.models.set_transaction_configuration_alias import SetTransactionConfigurationAlias
|
|
915
923
|
from lusid.models.set_transaction_configuration_source_request import SetTransactionConfigurationSourceRequest
|
|
916
924
|
from lusid.models.settlement_schedule import SettlementSchedule
|
|
925
|
+
from lusid.models.share_class_amount import ShareClassAmount
|
|
926
|
+
from lusid.models.share_class_breakdown import ShareClassBreakdown
|
|
927
|
+
from lusid.models.share_class_data import ShareClassData
|
|
928
|
+
from lusid.models.share_class_details import ShareClassDetails
|
|
917
929
|
from lusid.models.side_configuration_data import SideConfigurationData
|
|
918
930
|
from lusid.models.side_configuration_data_request import SideConfigurationDataRequest
|
|
919
931
|
from lusid.models.side_definition import SideDefinition
|
|
@@ -1007,6 +1019,7 @@ from lusid.models.trial_balance_query_parameters import TrialBalanceQueryParamet
|
|
|
1007
1019
|
from lusid.models.trigger_event import TriggerEvent
|
|
1008
1020
|
from lusid.models.typed_resource_id import TypedResourceId
|
|
1009
1021
|
from lusid.models.unit_schema import UnitSchema
|
|
1022
|
+
from lusid.models.unitisation_data import UnitisationData
|
|
1010
1023
|
from lusid.models.units_ratio import UnitsRatio
|
|
1011
1024
|
from lusid.models.unmatched_holding_method import UnmatchedHoldingMethod
|
|
1012
1025
|
from lusid.models.update_amortisation_rule_set_details_request import UpdateAmortisationRuleSetDetailsRequest
|
|
@@ -1279,6 +1292,7 @@ __all__ = [
|
|
|
1279
1292
|
"CancelledPlacementResult",
|
|
1280
1293
|
"CapFloor",
|
|
1281
1294
|
"CapitalDistributionEvent",
|
|
1295
|
+
"Cash",
|
|
1282
1296
|
"CashAndSecurityOfferElection",
|
|
1283
1297
|
"CashDependency",
|
|
1284
1298
|
"CashDividendEvent",
|
|
@@ -1343,6 +1357,7 @@ __all__ = [
|
|
|
1343
1357
|
"ComplianceTemplateVariation",
|
|
1344
1358
|
"ComplianceTemplateVariationDto",
|
|
1345
1359
|
"ComplianceTemplateVariationRequest",
|
|
1360
|
+
"ComponentFilter",
|
|
1346
1361
|
"ComponentRule",
|
|
1347
1362
|
"ComponentTransaction",
|
|
1348
1363
|
"CompositeBreakdown",
|
|
@@ -1510,12 +1525,15 @@ __all__ = [
|
|
|
1510
1525
|
"ForwardRateAgreement",
|
|
1511
1526
|
"FromRecipe",
|
|
1512
1527
|
"Fund",
|
|
1528
|
+
"FundAmount",
|
|
1513
1529
|
"FundConfiguration",
|
|
1514
1530
|
"FundConfigurationProperties",
|
|
1515
1531
|
"FundConfigurationRequest",
|
|
1532
|
+
"FundPreviousNAV",
|
|
1516
1533
|
"FundProperties",
|
|
1517
1534
|
"FundRequest",
|
|
1518
1535
|
"FundShareClass",
|
|
1536
|
+
"FundValuationPointData",
|
|
1519
1537
|
"FundingLeg",
|
|
1520
1538
|
"FundingLegOptions",
|
|
1521
1539
|
"Future",
|
|
@@ -1824,6 +1842,9 @@ __all__ = [
|
|
|
1824
1842
|
"PostingModuleRule",
|
|
1825
1843
|
"PostingModuleRulesUpdatedResponse",
|
|
1826
1844
|
"Premium",
|
|
1845
|
+
"PreviousFundValuationPointData",
|
|
1846
|
+
"PreviousNAV",
|
|
1847
|
+
"PreviousShareClassBreakdown",
|
|
1827
1848
|
"PricingContext",
|
|
1828
1849
|
"PricingModel",
|
|
1829
1850
|
"PricingOptions",
|
|
@@ -2004,6 +2025,10 @@ __all__ = [
|
|
|
2004
2025
|
"SetTransactionConfigurationAlias",
|
|
2005
2026
|
"SetTransactionConfigurationSourceRequest",
|
|
2006
2027
|
"SettlementSchedule",
|
|
2028
|
+
"ShareClassAmount",
|
|
2029
|
+
"ShareClassBreakdown",
|
|
2030
|
+
"ShareClassData",
|
|
2031
|
+
"ShareClassDetails",
|
|
2007
2032
|
"SideConfigurationData",
|
|
2008
2033
|
"SideConfigurationDataRequest",
|
|
2009
2034
|
"SideDefinition",
|
|
@@ -2097,6 +2122,7 @@ __all__ = [
|
|
|
2097
2122
|
"TriggerEvent",
|
|
2098
2123
|
"TypedResourceId",
|
|
2099
2124
|
"UnitSchema",
|
|
2125
|
+
"UnitisationData",
|
|
2100
2126
|
"UnitsRatio",
|
|
2101
2127
|
"UnmatchedHoldingMethod",
|
|
2102
2128
|
"UpdateAmortisationRuleSetDetailsRequest",
|
lusid/configuration.py
CHANGED
|
@@ -373,7 +373,7 @@ class Configuration:
|
|
|
373
373
|
return "Python SDK Debug Report:\n"\
|
|
374
374
|
"OS: {env}\n"\
|
|
375
375
|
"Python Version: {pyversion}\n"\
|
|
376
|
-
"Version of the API: 0.11.
|
|
376
|
+
"Version of the API: 0.11.6713\n"\
|
|
377
377
|
"SDK Package Version: {package_version}".\
|
|
378
378
|
format(env=sys.platform, pyversion=sys.version, package_version=package_version)
|
|
379
379
|
|
lusid/models/__init__.py
CHANGED
|
@@ -110,6 +110,7 @@ from lusid.models.cancel_placements_response import CancelPlacementsResponse
|
|
|
110
110
|
from lusid.models.cancelled_placement_result import CancelledPlacementResult
|
|
111
111
|
from lusid.models.cap_floor import CapFloor
|
|
112
112
|
from lusid.models.capital_distribution_event import CapitalDistributionEvent
|
|
113
|
+
from lusid.models.cash import Cash
|
|
113
114
|
from lusid.models.cash_and_security_offer_election import CashAndSecurityOfferElection
|
|
114
115
|
from lusid.models.cash_dependency import CashDependency
|
|
115
116
|
from lusid.models.cash_dividend_event import CashDividendEvent
|
|
@@ -174,6 +175,7 @@ from lusid.models.compliance_template_parameter import ComplianceTemplateParamet
|
|
|
174
175
|
from lusid.models.compliance_template_variation import ComplianceTemplateVariation
|
|
175
176
|
from lusid.models.compliance_template_variation_dto import ComplianceTemplateVariationDto
|
|
176
177
|
from lusid.models.compliance_template_variation_request import ComplianceTemplateVariationRequest
|
|
178
|
+
from lusid.models.component_filter import ComponentFilter
|
|
177
179
|
from lusid.models.component_rule import ComponentRule
|
|
178
180
|
from lusid.models.component_transaction import ComponentTransaction
|
|
179
181
|
from lusid.models.composite_breakdown import CompositeBreakdown
|
|
@@ -341,12 +343,15 @@ from lusid.models.flow_conventions import FlowConventions
|
|
|
341
343
|
from lusid.models.forward_rate_agreement import ForwardRateAgreement
|
|
342
344
|
from lusid.models.from_recipe import FromRecipe
|
|
343
345
|
from lusid.models.fund import Fund
|
|
346
|
+
from lusid.models.fund_amount import FundAmount
|
|
344
347
|
from lusid.models.fund_configuration import FundConfiguration
|
|
345
348
|
from lusid.models.fund_configuration_properties import FundConfigurationProperties
|
|
346
349
|
from lusid.models.fund_configuration_request import FundConfigurationRequest
|
|
350
|
+
from lusid.models.fund_previous_nav import FundPreviousNAV
|
|
347
351
|
from lusid.models.fund_properties import FundProperties
|
|
348
352
|
from lusid.models.fund_request import FundRequest
|
|
349
353
|
from lusid.models.fund_share_class import FundShareClass
|
|
354
|
+
from lusid.models.fund_valuation_point_data import FundValuationPointData
|
|
350
355
|
from lusid.models.funding_leg import FundingLeg
|
|
351
356
|
from lusid.models.funding_leg_options import FundingLegOptions
|
|
352
357
|
from lusid.models.future import Future
|
|
@@ -655,6 +660,9 @@ from lusid.models.posting_module_response import PostingModuleResponse
|
|
|
655
660
|
from lusid.models.posting_module_rule import PostingModuleRule
|
|
656
661
|
from lusid.models.posting_module_rules_updated_response import PostingModuleRulesUpdatedResponse
|
|
657
662
|
from lusid.models.premium import Premium
|
|
663
|
+
from lusid.models.previous_fund_valuation_point_data import PreviousFundValuationPointData
|
|
664
|
+
from lusid.models.previous_nav import PreviousNAV
|
|
665
|
+
from lusid.models.previous_share_class_breakdown import PreviousShareClassBreakdown
|
|
658
666
|
from lusid.models.pricing_context import PricingContext
|
|
659
667
|
from lusid.models.pricing_model import PricingModel
|
|
660
668
|
from lusid.models.pricing_options import PricingOptions
|
|
@@ -835,6 +843,10 @@ from lusid.models.set_share_class_instruments_request import SetShareClassInstru
|
|
|
835
843
|
from lusid.models.set_transaction_configuration_alias import SetTransactionConfigurationAlias
|
|
836
844
|
from lusid.models.set_transaction_configuration_source_request import SetTransactionConfigurationSourceRequest
|
|
837
845
|
from lusid.models.settlement_schedule import SettlementSchedule
|
|
846
|
+
from lusid.models.share_class_amount import ShareClassAmount
|
|
847
|
+
from lusid.models.share_class_breakdown import ShareClassBreakdown
|
|
848
|
+
from lusid.models.share_class_data import ShareClassData
|
|
849
|
+
from lusid.models.share_class_details import ShareClassDetails
|
|
838
850
|
from lusid.models.side_configuration_data import SideConfigurationData
|
|
839
851
|
from lusid.models.side_configuration_data_request import SideConfigurationDataRequest
|
|
840
852
|
from lusid.models.side_definition import SideDefinition
|
|
@@ -928,6 +940,7 @@ from lusid.models.trial_balance_query_parameters import TrialBalanceQueryParamet
|
|
|
928
940
|
from lusid.models.trigger_event import TriggerEvent
|
|
929
941
|
from lusid.models.typed_resource_id import TypedResourceId
|
|
930
942
|
from lusid.models.unit_schema import UnitSchema
|
|
943
|
+
from lusid.models.unitisation_data import UnitisationData
|
|
931
944
|
from lusid.models.units_ratio import UnitsRatio
|
|
932
945
|
from lusid.models.unmatched_holding_method import UnmatchedHoldingMethod
|
|
933
946
|
from lusid.models.update_amortisation_rule_set_details_request import UpdateAmortisationRuleSetDetailsRequest
|
|
@@ -1122,6 +1135,7 @@ __all__ = [
|
|
|
1122
1135
|
"CancelledPlacementResult",
|
|
1123
1136
|
"CapFloor",
|
|
1124
1137
|
"CapitalDistributionEvent",
|
|
1138
|
+
"Cash",
|
|
1125
1139
|
"CashAndSecurityOfferElection",
|
|
1126
1140
|
"CashDependency",
|
|
1127
1141
|
"CashDividendEvent",
|
|
@@ -1186,6 +1200,7 @@ __all__ = [
|
|
|
1186
1200
|
"ComplianceTemplateVariation",
|
|
1187
1201
|
"ComplianceTemplateVariationDto",
|
|
1188
1202
|
"ComplianceTemplateVariationRequest",
|
|
1203
|
+
"ComponentFilter",
|
|
1189
1204
|
"ComponentRule",
|
|
1190
1205
|
"ComponentTransaction",
|
|
1191
1206
|
"CompositeBreakdown",
|
|
@@ -1353,12 +1368,15 @@ __all__ = [
|
|
|
1353
1368
|
"ForwardRateAgreement",
|
|
1354
1369
|
"FromRecipe",
|
|
1355
1370
|
"Fund",
|
|
1371
|
+
"FundAmount",
|
|
1356
1372
|
"FundConfiguration",
|
|
1357
1373
|
"FundConfigurationProperties",
|
|
1358
1374
|
"FundConfigurationRequest",
|
|
1375
|
+
"FundPreviousNAV",
|
|
1359
1376
|
"FundProperties",
|
|
1360
1377
|
"FundRequest",
|
|
1361
1378
|
"FundShareClass",
|
|
1379
|
+
"FundValuationPointData",
|
|
1362
1380
|
"FundingLeg",
|
|
1363
1381
|
"FundingLegOptions",
|
|
1364
1382
|
"Future",
|
|
@@ -1667,6 +1685,9 @@ __all__ = [
|
|
|
1667
1685
|
"PostingModuleRule",
|
|
1668
1686
|
"PostingModuleRulesUpdatedResponse",
|
|
1669
1687
|
"Premium",
|
|
1688
|
+
"PreviousFundValuationPointData",
|
|
1689
|
+
"PreviousNAV",
|
|
1690
|
+
"PreviousShareClassBreakdown",
|
|
1670
1691
|
"PricingContext",
|
|
1671
1692
|
"PricingModel",
|
|
1672
1693
|
"PricingOptions",
|
|
@@ -1847,6 +1868,10 @@ __all__ = [
|
|
|
1847
1868
|
"SetTransactionConfigurationAlias",
|
|
1848
1869
|
"SetTransactionConfigurationSourceRequest",
|
|
1849
1870
|
"SettlementSchedule",
|
|
1871
|
+
"ShareClassAmount",
|
|
1872
|
+
"ShareClassBreakdown",
|
|
1873
|
+
"ShareClassData",
|
|
1874
|
+
"ShareClassDetails",
|
|
1850
1875
|
"SideConfigurationData",
|
|
1851
1876
|
"SideConfigurationDataRequest",
|
|
1852
1877
|
"SideDefinition",
|
|
@@ -1940,6 +1965,7 @@ __all__ = [
|
|
|
1940
1965
|
"TriggerEvent",
|
|
1941
1966
|
"TypedResourceId",
|
|
1942
1967
|
"UnitSchema",
|
|
1968
|
+
"UnitisationData",
|
|
1943
1969
|
"UnitsRatio",
|
|
1944
1970
|
"UnmatchedHoldingMethod",
|
|
1945
1971
|
"UpdateAmortisationRuleSetDetailsRequest",
|
lusid/models/cash.py
ADDED
|
@@ -0,0 +1,93 @@
|
|
|
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.v1 import Field, StrictFloat, StrictInt, StrictStr, validator
|
|
23
|
+
from lusid.models.lusid_instrument import LusidInstrument
|
|
24
|
+
|
|
25
|
+
class Cash(LusidInstrument):
|
|
26
|
+
"""
|
|
27
|
+
LUSID representation of Cash which is the sum of one or more cashflows from the past. # noqa: E501
|
|
28
|
+
"""
|
|
29
|
+
dom_ccy: StrictStr = Field(..., alias="domCcy", description="The domestic currency of the instrument.")
|
|
30
|
+
amount: Union[StrictFloat, StrictInt] = Field(..., description="Cash amount.")
|
|
31
|
+
instrument_type: StrictStr = Field(..., alias="instrumentType", description="The available values are: QuotedSecurity, InterestRateSwap, FxForward, Future, ExoticInstrument, FxOption, CreditDefaultSwap, InterestRateSwaption, Bond, EquityOption, FixedLeg, FloatingLeg, BespokeCashFlowsLeg, Unknown, TermDeposit, ContractForDifference, EquitySwap, CashPerpetual, CapFloor, CashSettled, CdsIndex, Basket, FundingLeg, FxSwap, ForwardRateAgreement, SimpleInstrument, Repo, Equity, ExchangeTradedOption, ReferenceInstrument, ComplexBond, InflationLinkedBond, InflationSwap, SimpleCashFlowLoan, TotalReturnSwap, InflationLeg, FundShareClass, FlexibleLoan, UnsettledCash, Cash")
|
|
32
|
+
additional_properties: Dict[str, Any] = {}
|
|
33
|
+
__properties = ["instrumentType", "domCcy", "amount"]
|
|
34
|
+
|
|
35
|
+
@validator('instrument_type')
|
|
36
|
+
def instrument_type_validate_enum(cls, value):
|
|
37
|
+
"""Validates the enum"""
|
|
38
|
+
if value not in ('QuotedSecurity', 'InterestRateSwap', 'FxForward', 'Future', 'ExoticInstrument', 'FxOption', 'CreditDefaultSwap', 'InterestRateSwaption', 'Bond', 'EquityOption', 'FixedLeg', 'FloatingLeg', 'BespokeCashFlowsLeg', 'Unknown', 'TermDeposit', 'ContractForDifference', 'EquitySwap', 'CashPerpetual', 'CapFloor', 'CashSettled', 'CdsIndex', 'Basket', 'FundingLeg', 'FxSwap', 'ForwardRateAgreement', 'SimpleInstrument', 'Repo', 'Equity', 'ExchangeTradedOption', 'ReferenceInstrument', 'ComplexBond', 'InflationLinkedBond', 'InflationSwap', 'SimpleCashFlowLoan', 'TotalReturnSwap', 'InflationLeg', 'FundShareClass', 'FlexibleLoan', 'UnsettledCash', 'Cash'):
|
|
39
|
+
raise ValueError("must be one of enum values ('QuotedSecurity', 'InterestRateSwap', 'FxForward', 'Future', 'ExoticInstrument', 'FxOption', 'CreditDefaultSwap', 'InterestRateSwaption', 'Bond', 'EquityOption', 'FixedLeg', 'FloatingLeg', 'BespokeCashFlowsLeg', 'Unknown', 'TermDeposit', 'ContractForDifference', 'EquitySwap', 'CashPerpetual', 'CapFloor', 'CashSettled', 'CdsIndex', 'Basket', 'FundingLeg', 'FxSwap', 'ForwardRateAgreement', 'SimpleInstrument', 'Repo', 'Equity', 'ExchangeTradedOption', 'ReferenceInstrument', 'ComplexBond', 'InflationLinkedBond', 'InflationSwap', 'SimpleCashFlowLoan', 'TotalReturnSwap', 'InflationLeg', 'FundShareClass', 'FlexibleLoan', 'UnsettledCash', 'Cash')")
|
|
40
|
+
return value
|
|
41
|
+
|
|
42
|
+
class Config:
|
|
43
|
+
"""Pydantic configuration"""
|
|
44
|
+
allow_population_by_field_name = True
|
|
45
|
+
validate_assignment = True
|
|
46
|
+
|
|
47
|
+
def to_str(self) -> str:
|
|
48
|
+
"""Returns the string representation of the model using alias"""
|
|
49
|
+
return pprint.pformat(self.dict(by_alias=True))
|
|
50
|
+
|
|
51
|
+
def to_json(self) -> str:
|
|
52
|
+
"""Returns the JSON representation of the model using alias"""
|
|
53
|
+
return json.dumps(self.to_dict())
|
|
54
|
+
|
|
55
|
+
@classmethod
|
|
56
|
+
def from_json(cls, json_str: str) -> Cash:
|
|
57
|
+
"""Create an instance of Cash from a JSON string"""
|
|
58
|
+
return cls.from_dict(json.loads(json_str))
|
|
59
|
+
|
|
60
|
+
def to_dict(self):
|
|
61
|
+
"""Returns the dictionary representation of the model using alias"""
|
|
62
|
+
_dict = self.dict(by_alias=True,
|
|
63
|
+
exclude={
|
|
64
|
+
"additional_properties"
|
|
65
|
+
},
|
|
66
|
+
exclude_none=True)
|
|
67
|
+
# puts key-value pairs in additional_properties in the top level
|
|
68
|
+
if self.additional_properties is not None:
|
|
69
|
+
for _key, _value in self.additional_properties.items():
|
|
70
|
+
_dict[_key] = _value
|
|
71
|
+
|
|
72
|
+
return _dict
|
|
73
|
+
|
|
74
|
+
@classmethod
|
|
75
|
+
def from_dict(cls, obj: dict) -> Cash:
|
|
76
|
+
"""Create an instance of Cash from a dict"""
|
|
77
|
+
if obj is None:
|
|
78
|
+
return None
|
|
79
|
+
|
|
80
|
+
if not isinstance(obj, dict):
|
|
81
|
+
return Cash.parse_obj(obj)
|
|
82
|
+
|
|
83
|
+
_obj = Cash.parse_obj({
|
|
84
|
+
"instrument_type": obj.get("instrumentType"),
|
|
85
|
+
"dom_ccy": obj.get("domCcy"),
|
|
86
|
+
"amount": obj.get("amount")
|
|
87
|
+
})
|
|
88
|
+
# store additional fields in additional_properties
|
|
89
|
+
for _key in obj.keys():
|
|
90
|
+
if _key not in cls.__properties:
|
|
91
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
92
|
+
|
|
93
|
+
return _obj
|
|
@@ -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
|
|
22
|
+
from pydantic.v1 import BaseModel, Field, constr, validator
|
|
23
|
+
|
|
24
|
+
class ComponentFilter(BaseModel):
|
|
25
|
+
"""
|
|
26
|
+
ComponentFilter
|
|
27
|
+
"""
|
|
28
|
+
filter_id: constr(strict=True, max_length=16384, min_length=1) = Field(..., alias="filterId")
|
|
29
|
+
filter: constr(strict=True, max_length=16384, min_length=1) = Field(...)
|
|
30
|
+
__properties = ["filterId", "filter"]
|
|
31
|
+
|
|
32
|
+
@validator('filter_id')
|
|
33
|
+
def filter_id_validate_regular_expression(cls, value):
|
|
34
|
+
"""Validates the regular expression"""
|
|
35
|
+
if not re.match(r"^[\s\S]*$", value):
|
|
36
|
+
raise ValueError(r"must validate the regular expression /^[\s\S]*$/")
|
|
37
|
+
return value
|
|
38
|
+
|
|
39
|
+
@validator('filter')
|
|
40
|
+
def filter_validate_regular_expression(cls, value):
|
|
41
|
+
"""Validates the regular expression"""
|
|
42
|
+
if not re.match(r"^[\s\S]*$", value):
|
|
43
|
+
raise ValueError(r"must validate the regular expression /^[\s\S]*$/")
|
|
44
|
+
return value
|
|
45
|
+
|
|
46
|
+
class Config:
|
|
47
|
+
"""Pydantic configuration"""
|
|
48
|
+
allow_population_by_field_name = True
|
|
49
|
+
validate_assignment = True
|
|
50
|
+
|
|
51
|
+
def to_str(self) -> str:
|
|
52
|
+
"""Returns the string representation of the model using alias"""
|
|
53
|
+
return pprint.pformat(self.dict(by_alias=True))
|
|
54
|
+
|
|
55
|
+
def to_json(self) -> str:
|
|
56
|
+
"""Returns the JSON representation of the model using alias"""
|
|
57
|
+
return json.dumps(self.to_dict())
|
|
58
|
+
|
|
59
|
+
@classmethod
|
|
60
|
+
def from_json(cls, json_str: str) -> ComponentFilter:
|
|
61
|
+
"""Create an instance of ComponentFilter from a JSON string"""
|
|
62
|
+
return cls.from_dict(json.loads(json_str))
|
|
63
|
+
|
|
64
|
+
def to_dict(self):
|
|
65
|
+
"""Returns the dictionary representation of the model using alias"""
|
|
66
|
+
_dict = self.dict(by_alias=True,
|
|
67
|
+
exclude={
|
|
68
|
+
},
|
|
69
|
+
exclude_none=True)
|
|
70
|
+
return _dict
|
|
71
|
+
|
|
72
|
+
@classmethod
|
|
73
|
+
def from_dict(cls, obj: dict) -> ComponentFilter:
|
|
74
|
+
"""Create an instance of ComponentFilter from a dict"""
|
|
75
|
+
if obj is None:
|
|
76
|
+
return None
|
|
77
|
+
|
|
78
|
+
if not isinstance(obj, dict):
|
|
79
|
+
return ComponentFilter.parse_obj(obj)
|
|
80
|
+
|
|
81
|
+
_obj = ComponentFilter.parse_obj({
|
|
82
|
+
"filter_id": obj.get("filterId"),
|
|
83
|
+
"filter": obj.get("filter")
|
|
84
|
+
})
|
|
85
|
+
return _obj
|
lusid/models/component_rule.py
CHANGED
|
@@ -18,15 +18,16 @@ import re # noqa: F401
|
|
|
18
18
|
import json
|
|
19
19
|
|
|
20
20
|
|
|
21
|
-
from typing import Any, Dict, Optional
|
|
22
|
-
from pydantic.v1 import BaseModel, Field,
|
|
21
|
+
from typing import Any, Dict, List, Optional
|
|
22
|
+
from pydantic.v1 import BaseModel, Field, conlist, constr, validator
|
|
23
|
+
from lusid.models.component_filter import ComponentFilter
|
|
23
24
|
|
|
24
25
|
class ComponentRule(BaseModel):
|
|
25
26
|
"""
|
|
26
27
|
ComponentRule
|
|
27
28
|
"""
|
|
28
29
|
match_criteria: constr(strict=True, max_length=16384, min_length=1) = Field(..., alias="matchCriteria")
|
|
29
|
-
components: Optional[
|
|
30
|
+
components: Optional[conlist(ComponentFilter)] = None
|
|
30
31
|
__properties = ["matchCriteria", "components"]
|
|
31
32
|
|
|
32
33
|
@validator('match_criteria')
|
|
@@ -60,11 +61,13 @@ class ComponentRule(BaseModel):
|
|
|
60
61
|
exclude={
|
|
61
62
|
},
|
|
62
63
|
exclude_none=True)
|
|
63
|
-
#
|
|
64
|
-
|
|
65
|
-
if self.components
|
|
66
|
-
|
|
67
|
-
|
|
64
|
+
# override the default output from pydantic by calling `to_dict()` of each item in components (list)
|
|
65
|
+
_items = []
|
|
66
|
+
if self.components:
|
|
67
|
+
for _item in self.components:
|
|
68
|
+
if _item:
|
|
69
|
+
_items.append(_item.to_dict())
|
|
70
|
+
_dict['components'] = _items
|
|
68
71
|
return _dict
|
|
69
72
|
|
|
70
73
|
@classmethod
|
|
@@ -78,6 +81,6 @@ class ComponentRule(BaseModel):
|
|
|
78
81
|
|
|
79
82
|
_obj = ComponentRule.parse_obj({
|
|
80
83
|
"match_criteria": obj.get("matchCriteria"),
|
|
81
|
-
"components": obj.get("components")
|
|
84
|
+
"components": [ComponentFilter.from_dict(_item) for _item in obj.get("components")] if obj.get("components") is not None else None
|
|
82
85
|
})
|
|
83
86
|
return _obj
|
|
@@ -35,9 +35,10 @@ class ContractForDifference(LusidInstrument):
|
|
|
35
35
|
type: constr(strict=True, min_length=1) = Field(..., description="The type of CFD. Supported string (enumeration) values are: [Cash, Futures].")
|
|
36
36
|
underlying_ccy: StrictStr = Field(..., alias="underlyingCcy", description="The currency of the underlying")
|
|
37
37
|
underlying_identifier: constr(strict=True, min_length=1) = Field(..., alias="underlyingIdentifier", description="External market codes and identifiers for the CFD, e.g. RIC. Supported string (enumeration) values are: [LusidInstrumentId, Isin, Sedol, Cusip, ClientInternal, Figi, RIC, QuotePermId, REDCode, BBGId, ICECode].")
|
|
38
|
+
lot_size: Optional[StrictInt] = Field(None, alias="lotSize", description="CFD LotSize, the minimum number of shares that can be bought or sold at once. Optional, if set must be non-negative, if not set defaults to 1.")
|
|
38
39
|
instrument_type: StrictStr = Field(..., alias="instrumentType", description="The available values are: QuotedSecurity, InterestRateSwap, FxForward, Future, ExoticInstrument, FxOption, CreditDefaultSwap, InterestRateSwaption, Bond, EquityOption, FixedLeg, FloatingLeg, BespokeCashFlowsLeg, Unknown, TermDeposit, ContractForDifference, EquitySwap, CashPerpetual, CapFloor, CashSettled, CdsIndex, Basket, FundingLeg, FxSwap, ForwardRateAgreement, SimpleInstrument, Repo, Equity, ExchangeTradedOption, ReferenceInstrument, ComplexBond, InflationLinkedBond, InflationSwap, SimpleCashFlowLoan, TotalReturnSwap, InflationLeg, FundShareClass, FlexibleLoan, UnsettledCash, Cash")
|
|
39
40
|
additional_properties: Dict[str, Any] = {}
|
|
40
|
-
__properties = ["instrumentType", "startDate", "maturityDate", "code", "contractSize", "payCcy", "referenceRate", "type", "underlyingCcy", "underlyingIdentifier"]
|
|
41
|
+
__properties = ["instrumentType", "startDate", "maturityDate", "code", "contractSize", "payCcy", "referenceRate", "type", "underlyingCcy", "underlyingIdentifier", "lotSize"]
|
|
41
42
|
|
|
42
43
|
@validator('instrument_type')
|
|
43
44
|
def instrument_type_validate_enum(cls, value):
|
|
@@ -97,7 +98,8 @@ class ContractForDifference(LusidInstrument):
|
|
|
97
98
|
"reference_rate": obj.get("referenceRate"),
|
|
98
99
|
"type": obj.get("type"),
|
|
99
100
|
"underlying_ccy": obj.get("underlyingCcy"),
|
|
100
|
-
"underlying_identifier": obj.get("underlyingIdentifier")
|
|
101
|
+
"underlying_identifier": obj.get("underlyingIdentifier"),
|
|
102
|
+
"lot_size": obj.get("lotSize")
|
|
101
103
|
})
|
|
102
104
|
# store additional fields in additional_properties
|
|
103
105
|
for _key in obj.keys():
|
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
|