lusid-sdk 2.1.110__py3-none-any.whl → 2.1.131__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 (47) hide show
  1. lusid/__init__.py +40 -0
  2. lusid/api/__init__.py +2 -0
  3. lusid/api/amortisation_rule_sets_api.py +175 -0
  4. lusid/api/compliance_api.py +502 -0
  5. lusid/api/fee_types_api.py +909 -0
  6. lusid/api/instrument_events_api.py +189 -0
  7. lusid/api/portfolio_groups_api.py +16 -8
  8. lusid/api/portfolios_api.py +212 -0
  9. lusid/api/transaction_portfolios_api.py +32 -16
  10. lusid/configuration.py +1 -1
  11. lusid/models/__init__.py +38 -0
  12. lusid/models/amortisation_rule_set.py +7 -11
  13. lusid/models/applicable_instrument_event.py +106 -0
  14. lusid/models/compliance_rule_template.py +153 -0
  15. lusid/models/compliance_step_request.py +76 -0
  16. lusid/models/compliance_step_type_request.py +42 -0
  17. lusid/models/compliance_template_variation_dto.py +112 -0
  18. lusid/models/compliance_template_variation_request.py +112 -0
  19. lusid/models/create_compliance_template_request.py +95 -0
  20. lusid/models/create_derived_property_definition_request.py +3 -3
  21. lusid/models/create_property_definition_request.py +3 -3
  22. lusid/models/diary_entry_request.py +1 -1
  23. lusid/models/fee_accrual.py +83 -0
  24. lusid/models/fee_type.py +115 -0
  25. lusid/models/fee_type_request.py +105 -0
  26. lusid/models/flow_conventions.py +1 -1
  27. lusid/models/operation.py +2 -2
  28. lusid/models/paged_resource_list_of_fee_type.py +113 -0
  29. lusid/models/paged_resource_list_of_instrument_event_instruction.py +113 -0
  30. lusid/models/portfolio_entity_id.py +2 -18
  31. lusid/models/portfolio_holding.py +19 -4
  32. lusid/models/property_definition.py +3 -3
  33. lusid/models/property_definition_search_result.py +3 -3
  34. lusid/models/property_domain.py +1 -0
  35. lusid/models/query_applicable_instrument_events_request.py +89 -0
  36. lusid/models/quote_access_metadata_rule_id.py +1 -1
  37. lusid/models/quote_series_id.py +1 -1
  38. lusid/models/resource_list_of_applicable_instrument_event.py +113 -0
  39. lusid/models/rules_interval.py +83 -0
  40. lusid/models/set_amortisation_rules_request.py +73 -0
  41. lusid/models/settlement_schedule.py +78 -0
  42. lusid/models/update_compliance_template_request.py +95 -0
  43. lusid/models/update_fee_type_request.py +96 -0
  44. lusid/models/valuation_point_data_response.py +15 -2
  45. {lusid_sdk-2.1.110.dist-info → lusid_sdk-2.1.131.dist-info}/METADATA +34 -4
  46. {lusid_sdk-2.1.110.dist-info → lusid_sdk-2.1.131.dist-info}/RECORD +47 -27
  47. {lusid_sdk-2.1.110.dist-info → lusid_sdk-2.1.131.dist-info}/WHEEL +0 -0
@@ -36,7 +36,7 @@ class PropertyDefinition(BaseModel):
36
36
  data_type_id: Optional[ResourceId] = Field(None, alias="dataTypeId")
37
37
  type: Optional[StrictStr] = Field(None, description="The type of the property. The available values are: Label, Metric, Information")
38
38
  unit_schema: Optional[StrictStr] = Field(None, alias="unitSchema", description="The units that can be associated with the property's values. This is defined by the property's data type. The available values are: NoUnits, Basic, Iso4217Currency")
39
- domain: Optional[StrictStr] = Field(None, description="The domain that the property exists in. The available values are: NotDefined, Transaction, Portfolio, Holding, ReferenceHolding, TransactionConfiguration, Instrument, CutLabelDefinition, Analytic, PortfolioGroup, Person, AccessMetadata, Order, UnitResult, MarketData, ConfigurationRecipe, Allocation, Calendar, LegalEntity, Placement, Execution, Block, Participation, Package, OrderInstruction, NextBestAction, CustomEntity, InstrumentEvent, Account, ChartOfAccounts, CustodianAccount, Abor, AborConfiguration, Fund, Reconciliation, PropertyDefinition, Compliance, DiaryEntry, Leg, DerivedValuation")
39
+ domain: Optional[StrictStr] = Field(None, description="The domain that the property exists in. The available values are: NotDefined, Transaction, Portfolio, Holding, ReferenceHolding, TransactionConfiguration, Instrument, CutLabelDefinition, Analytic, PortfolioGroup, Person, AccessMetadata, Order, UnitResult, MarketData, ConfigurationRecipe, Allocation, Calendar, LegalEntity, Placement, Execution, Block, Participation, Package, OrderInstruction, NextBestAction, CustomEntity, InstrumentEvent, Account, ChartOfAccounts, CustodianAccount, Abor, AborConfiguration, Fund, Fee, Reconciliation, PropertyDefinition, Compliance, DiaryEntry, Leg, DerivedValuation")
40
40
  scope: Optional[StrictStr] = Field(None, description="The scope that the property exists in.")
41
41
  code: Optional[StrictStr] = Field(None, description="The code of the property. Together with the domain and scope this uniquely identifies the property.")
42
42
  value_required: Optional[StrictBool] = Field(None, alias="valueRequired", description="This field is not implemented and should be disregarded.")
@@ -87,8 +87,8 @@ class PropertyDefinition(BaseModel):
87
87
  if value is None:
88
88
  return value
89
89
 
90
- if value not in ('NotDefined', 'Transaction', 'Portfolio', 'Holding', 'ReferenceHolding', 'TransactionConfiguration', 'Instrument', 'CutLabelDefinition', 'Analytic', 'PortfolioGroup', 'Person', 'AccessMetadata', 'Order', 'UnitResult', 'MarketData', 'ConfigurationRecipe', 'Allocation', 'Calendar', 'LegalEntity', 'Placement', 'Execution', 'Block', 'Participation', 'Package', 'OrderInstruction', 'NextBestAction', 'CustomEntity', 'InstrumentEvent', 'Account', 'ChartOfAccounts', 'CustodianAccount', 'Abor', 'AborConfiguration', 'Fund', 'Reconciliation', 'PropertyDefinition', 'Compliance', 'DiaryEntry', 'Leg', 'DerivedValuation'):
91
- raise ValueError("must be one of enum values ('NotDefined', 'Transaction', 'Portfolio', 'Holding', 'ReferenceHolding', 'TransactionConfiguration', 'Instrument', 'CutLabelDefinition', 'Analytic', 'PortfolioGroup', 'Person', 'AccessMetadata', 'Order', 'UnitResult', 'MarketData', 'ConfigurationRecipe', 'Allocation', 'Calendar', 'LegalEntity', 'Placement', 'Execution', 'Block', 'Participation', 'Package', 'OrderInstruction', 'NextBestAction', 'CustomEntity', 'InstrumentEvent', 'Account', 'ChartOfAccounts', 'CustodianAccount', 'Abor', 'AborConfiguration', 'Fund', 'Reconciliation', 'PropertyDefinition', 'Compliance', 'DiaryEntry', 'Leg', 'DerivedValuation')")
90
+ if value not in ('NotDefined', 'Transaction', 'Portfolio', 'Holding', 'ReferenceHolding', 'TransactionConfiguration', 'Instrument', 'CutLabelDefinition', 'Analytic', 'PortfolioGroup', 'Person', 'AccessMetadata', 'Order', 'UnitResult', 'MarketData', 'ConfigurationRecipe', 'Allocation', 'Calendar', 'LegalEntity', 'Placement', 'Execution', 'Block', 'Participation', 'Package', 'OrderInstruction', 'NextBestAction', 'CustomEntity', 'InstrumentEvent', 'Account', 'ChartOfAccounts', 'CustodianAccount', 'Abor', 'AborConfiguration', 'Fund', 'Fee', 'Reconciliation', 'PropertyDefinition', 'Compliance', 'DiaryEntry', 'Leg', 'DerivedValuation'):
91
+ raise ValueError("must be one of enum values ('NotDefined', 'Transaction', 'Portfolio', 'Holding', 'ReferenceHolding', 'TransactionConfiguration', 'Instrument', 'CutLabelDefinition', 'Analytic', 'PortfolioGroup', 'Person', 'AccessMetadata', 'Order', 'UnitResult', 'MarketData', 'ConfigurationRecipe', 'Allocation', 'Calendar', 'LegalEntity', 'Placement', 'Execution', 'Block', 'Participation', 'Package', 'OrderInstruction', 'NextBestAction', 'CustomEntity', 'InstrumentEvent', 'Account', 'ChartOfAccounts', 'CustodianAccount', 'Abor', 'AborConfiguration', 'Fund', 'Fee', 'Reconciliation', 'PropertyDefinition', 'Compliance', 'DiaryEntry', 'Leg', 'DerivedValuation')")
92
92
  return value
93
93
 
94
94
  @validator('life_time')
@@ -34,7 +34,7 @@ class PropertyDefinitionSearchResult(BaseModel):
34
34
  data_type_id: Optional[ResourceId] = Field(None, alias="dataTypeId")
35
35
  type: Optional[StrictStr] = Field(None, description="The type of the property. The available values are: Label, Metric, Information")
36
36
  unit_schema: Optional[StrictStr] = Field(None, alias="unitSchema", description="The units that can be associated with the property's values. This is defined by the property's data type. The available values are: NoUnits, Basic, Iso4217Currency")
37
- domain: Optional[StrictStr] = Field(None, description="The domain that the property exists in. The available values are: NotDefined, Transaction, Portfolio, Holding, ReferenceHolding, TransactionConfiguration, Instrument, CutLabelDefinition, Analytic, PortfolioGroup, Person, AccessMetadata, Order, UnitResult, MarketData, ConfigurationRecipe, Allocation, Calendar, LegalEntity, Placement, Execution, Block, Participation, Package, OrderInstruction, NextBestAction, CustomEntity, InstrumentEvent, Account, ChartOfAccounts, CustodianAccount, Abor, AborConfiguration, Fund, Reconciliation, PropertyDefinition, Compliance, DiaryEntry, Leg, DerivedValuation")
37
+ domain: Optional[StrictStr] = Field(None, description="The domain that the property exists in. The available values are: NotDefined, Transaction, Portfolio, Holding, ReferenceHolding, TransactionConfiguration, Instrument, CutLabelDefinition, Analytic, PortfolioGroup, Person, AccessMetadata, Order, UnitResult, MarketData, ConfigurationRecipe, Allocation, Calendar, LegalEntity, Placement, Execution, Block, Participation, Package, OrderInstruction, NextBestAction, CustomEntity, InstrumentEvent, Account, ChartOfAccounts, CustodianAccount, Abor, AborConfiguration, Fund, Fee, Reconciliation, PropertyDefinition, Compliance, DiaryEntry, Leg, DerivedValuation")
38
38
  scope: Optional[StrictStr] = Field(None, description="The scope that the property exists in.")
39
39
  code: Optional[StrictStr] = Field(None, description="The code of the property. Together with the domain and scope this uniquely identifies the property.")
40
40
  value_required: Optional[StrictBool] = Field(None, alias="valueRequired", description="This field is not implemented and should be disregarded.")
@@ -82,8 +82,8 @@ class PropertyDefinitionSearchResult(BaseModel):
82
82
  if value is None:
83
83
  return value
84
84
 
85
- if value not in ('NotDefined', 'Transaction', 'Portfolio', 'Holding', 'ReferenceHolding', 'TransactionConfiguration', 'Instrument', 'CutLabelDefinition', 'Analytic', 'PortfolioGroup', 'Person', 'AccessMetadata', 'Order', 'UnitResult', 'MarketData', 'ConfigurationRecipe', 'Allocation', 'Calendar', 'LegalEntity', 'Placement', 'Execution', 'Block', 'Participation', 'Package', 'OrderInstruction', 'NextBestAction', 'CustomEntity', 'InstrumentEvent', 'Account', 'ChartOfAccounts', 'CustodianAccount', 'Abor', 'AborConfiguration', 'Fund', 'Reconciliation', 'PropertyDefinition', 'Compliance', 'DiaryEntry', 'Leg', 'DerivedValuation'):
86
- raise ValueError("must be one of enum values ('NotDefined', 'Transaction', 'Portfolio', 'Holding', 'ReferenceHolding', 'TransactionConfiguration', 'Instrument', 'CutLabelDefinition', 'Analytic', 'PortfolioGroup', 'Person', 'AccessMetadata', 'Order', 'UnitResult', 'MarketData', 'ConfigurationRecipe', 'Allocation', 'Calendar', 'LegalEntity', 'Placement', 'Execution', 'Block', 'Participation', 'Package', 'OrderInstruction', 'NextBestAction', 'CustomEntity', 'InstrumentEvent', 'Account', 'ChartOfAccounts', 'CustodianAccount', 'Abor', 'AborConfiguration', 'Fund', 'Reconciliation', 'PropertyDefinition', 'Compliance', 'DiaryEntry', 'Leg', 'DerivedValuation')")
85
+ if value not in ('NotDefined', 'Transaction', 'Portfolio', 'Holding', 'ReferenceHolding', 'TransactionConfiguration', 'Instrument', 'CutLabelDefinition', 'Analytic', 'PortfolioGroup', 'Person', 'AccessMetadata', 'Order', 'UnitResult', 'MarketData', 'ConfigurationRecipe', 'Allocation', 'Calendar', 'LegalEntity', 'Placement', 'Execution', 'Block', 'Participation', 'Package', 'OrderInstruction', 'NextBestAction', 'CustomEntity', 'InstrumentEvent', 'Account', 'ChartOfAccounts', 'CustodianAccount', 'Abor', 'AborConfiguration', 'Fund', 'Fee', 'Reconciliation', 'PropertyDefinition', 'Compliance', 'DiaryEntry', 'Leg', 'DerivedValuation'):
86
+ raise ValueError("must be one of enum values ('NotDefined', 'Transaction', 'Portfolio', 'Holding', 'ReferenceHolding', 'TransactionConfiguration', 'Instrument', 'CutLabelDefinition', 'Analytic', 'PortfolioGroup', 'Person', 'AccessMetadata', 'Order', 'UnitResult', 'MarketData', 'ConfigurationRecipe', 'Allocation', 'Calendar', 'LegalEntity', 'Placement', 'Execution', 'Block', 'Participation', 'Package', 'OrderInstruction', 'NextBestAction', 'CustomEntity', 'InstrumentEvent', 'Account', 'ChartOfAccounts', 'CustodianAccount', 'Abor', 'AborConfiguration', 'Fund', 'Fee', 'Reconciliation', 'PropertyDefinition', 'Compliance', 'DiaryEntry', 'Leg', 'DerivedValuation')")
87
87
  return value
88
88
 
89
89
  @validator('life_time')
@@ -63,6 +63,7 @@ class PropertyDomain(str, Enum):
63
63
  ABOR = 'Abor'
64
64
  ABORCONFIGURATION = 'AborConfiguration'
65
65
  FUND = 'Fund'
66
+ FEE = 'Fee'
66
67
  RECONCILIATION = 'Reconciliation'
67
68
  PROPERTYDEFINITION = 'PropertyDefinition'
68
69
  COMPLIANCE = 'Compliance'
@@ -0,0 +1,89 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+ from datetime import datetime
21
+ from typing import Any, Dict, List
22
+ from pydantic.v1 import BaseModel, Field, conlist
23
+ from lusid.models.portfolio_entity_id import PortfolioEntityId
24
+ from lusid.models.resource_id import ResourceId
25
+
26
+ class QueryApplicableInstrumentEventsRequest(BaseModel):
27
+ """
28
+ QueryApplicableInstrumentEventsRequest
29
+ """
30
+ window_start: datetime = Field(..., alias="windowStart", description="The start date of the window.")
31
+ window_end: datetime = Field(..., alias="windowEnd", description="The end date of the window.")
32
+ effective_at: datetime = Field(..., alias="effectiveAt", description="The Effective date that splits query window into two parts: factual period and forecast period")
33
+ portfolio_entity_ids: conlist(PortfolioEntityId) = Field(..., alias="portfolioEntityIds", description="The set of portfolios and portfolio groups to which the instrument events must belong.")
34
+ forecasting_recipe_id: ResourceId = Field(..., alias="forecastingRecipeId")
35
+ __properties = ["windowStart", "windowEnd", "effectiveAt", "portfolioEntityIds", "forecastingRecipeId"]
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) -> QueryApplicableInstrumentEventsRequest:
52
+ """Create an instance of QueryApplicableInstrumentEventsRequest 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 portfolio_entity_ids (list)
62
+ _items = []
63
+ if self.portfolio_entity_ids:
64
+ for _item in self.portfolio_entity_ids:
65
+ if _item:
66
+ _items.append(_item.to_dict())
67
+ _dict['portfolioEntityIds'] = _items
68
+ # override the default output from pydantic by calling `to_dict()` of forecasting_recipe_id
69
+ if self.forecasting_recipe_id:
70
+ _dict['forecastingRecipeId'] = self.forecasting_recipe_id.to_dict()
71
+ return _dict
72
+
73
+ @classmethod
74
+ def from_dict(cls, obj: dict) -> QueryApplicableInstrumentEventsRequest:
75
+ """Create an instance of QueryApplicableInstrumentEventsRequest from a dict"""
76
+ if obj is None:
77
+ return None
78
+
79
+ if not isinstance(obj, dict):
80
+ return QueryApplicableInstrumentEventsRequest.parse_obj(obj)
81
+
82
+ _obj = QueryApplicableInstrumentEventsRequest.parse_obj({
83
+ "window_start": obj.get("windowStart"),
84
+ "window_end": obj.get("windowEnd"),
85
+ "effective_at": obj.get("effectiveAt"),
86
+ "portfolio_entity_ids": [PortfolioEntityId.from_dict(_item) for _item in obj.get("portfolioEntityIds")] if obj.get("portfolioEntityIds") is not None else None,
87
+ "forecasting_recipe_id": ResourceId.from_dict(obj.get("forecastingRecipeId")) if obj.get("forecastingRecipeId") is not None else None
88
+ })
89
+ return _obj
@@ -30,7 +30,7 @@ class QuoteAccessMetadataRuleId(BaseModel):
30
30
  instrument_id: Optional[constr(strict=True, max_length=256, min_length=0)] = Field(None, alias="instrumentId", description="The value of the instrument identifier that uniquely identifies the instrument that the quote is for, e.g. 'BBG00JX0P539'.")
31
31
  instrument_id_type: Optional[constr(strict=True, max_length=50, min_length=0)] = Field(None, alias="instrumentIdType", description="The type of instrument identifier used to uniquely identify the instrument that the quote is for, e.g. 'Figi'.")
32
32
  quote_type: Optional[constr(strict=True, max_length=50, min_length=0)] = Field(None, alias="quoteType", description="The type of the quote. This allows for quotes other than prices e.g. rates or spreads to be used.")
33
- field: Optional[constr(strict=True, max_length=2048, min_length=0)] = Field(None, description="The field of the quote e.g. bid, mid, ask etc. This should be consistent across a time series of quotes. The allowed values depend on the provider according to the following rules: Client : *Any value is accepted*; DataScope : 'bid', 'mid', 'ask'; Lusid : *Any value is accepted*; Edi : 'bid', 'mid', 'ask', 'open', 'close', 'last'; TraderMade : 'bid', 'mid', 'ask', 'open', 'close', 'high', 'low'; FactSet : 'bid', 'mid', 'ask', 'open', 'close'; SIX : 'bid', 'mid', 'ask', 'open', 'close', 'last'; Bloomberg : 'bid', 'mid', 'ask', 'open', 'close', 'last'; Rimes : 'bid', 'mid', 'ask', 'open', 'close', 'last'")
33
+ field: Optional[constr(strict=True, max_length=2048, min_length=0)] = Field(None, description="The field of the quote e.g. bid, mid, ask etc. This should be consistent across a time series of quotes. The allowed values depend on the provider according to the following rules: Client : *Any value is accepted*; DataScope : 'bid', 'mid', 'ask'; Lusid : *Any value is accepted*; Edi : 'bid', 'mid', 'ask', 'open', 'close', 'last'; TraderMade : 'bid', 'mid', 'ask', 'open', 'close', 'high', 'low'; FactSet : 'bid', 'mid', 'ask', 'open', 'close'; SIX : 'bid', 'mid', 'ask', 'open', 'close', 'last', 'referencePrice', 'highPrice', 'lowPrice', 'maxRedemptionPrice', 'maxSubscriptionPrice', 'openPrice', 'bestBidPrice', 'lastBidPrice', 'bestAskPrice', 'lastAskPrice'; Bloomberg : 'bid', 'mid', 'ask', 'open', 'close', 'last'; Rimes : 'bid', 'mid', 'ask', 'open', 'close', 'last'")
34
34
  __properties = ["provider", "priceSource", "instrumentId", "instrumentIdType", "quoteType", "field"]
35
35
 
36
36
  @validator('instrument_id_type')
@@ -30,7 +30,7 @@ class QuoteSeriesId(BaseModel):
30
30
  instrument_id: constr(strict=True, min_length=1) = Field(..., alias="instrumentId", description="The value of the instrument identifier that uniquely identifies the instrument that the quote is for, e.g. 'BBG00JX0P539'.")
31
31
  instrument_id_type: Optional[StrictStr] = Field(..., alias="instrumentIdType", description="The type of instrument identifier used to uniquely identify the instrument that the quote is for, e.g. 'Figi'. The available values are: LusidInstrumentId, Figi, RIC, QuotePermId, Isin, CurrencyPair, ClientInternal, Sedol, Cusip")
32
32
  quote_type: Optional[StrictStr] = Field(..., alias="quoteType", description="The type of the quote. This allows for quotes other than prices e.g. rates or spreads to be used. The available values are: Price, Spread, Rate, LogNormalVol, NormalVol, ParSpread, IsdaSpread, Upfront, Index, Ratio, Delta, PoolFactor, InflationAssumption, DirtyPrice")
33
- field: constr(strict=True, min_length=1) = Field(..., description="The field of the quote e.g. bid, mid, ask etc. This should be consistent across a time series of quotes. The allowed values depend on the provider according to the following rules: Client : *Any value is accepted*; DataScope : 'bid', 'mid', 'ask'; Lusid : *Any value is accepted*; Edi : 'bid', 'mid', 'ask', 'open', 'close', 'last'; TraderMade : 'bid', 'mid', 'ask', 'open', 'close', 'high', 'low'; FactSet : 'bid', 'mid', 'ask', 'open', 'close'; SIX : 'bid', 'mid', 'ask', 'open', 'close', 'last'; Bloomberg : 'bid', 'mid', 'ask', 'open', 'close', 'last'; Rimes : 'bid', 'mid', 'ask', 'open', 'close', 'last'")
33
+ field: constr(strict=True, min_length=1) = Field(..., description="The field of the quote e.g. bid, mid, ask etc. This should be consistent across a time series of quotes. The allowed values depend on the provider according to the following rules: Client : *Any value is accepted*; DataScope : 'bid', 'mid', 'ask'; Lusid : *Any value is accepted*; Edi : 'bid', 'mid', 'ask', 'open', 'close', 'last'; TraderMade : 'bid', 'mid', 'ask', 'open', 'close', 'high', 'low'; FactSet : 'bid', 'mid', 'ask', 'open', 'close'; SIX : 'bid', 'mid', 'ask', 'open', 'close', 'last', 'referencePrice', 'highPrice', 'lowPrice', 'maxRedemptionPrice', 'maxSubscriptionPrice', 'openPrice', 'bestBidPrice', 'lastBidPrice', 'bestAskPrice', 'lastAskPrice'; Bloomberg : 'bid', 'mid', 'ask', 'open', 'close', 'last'; Rimes : 'bid', 'mid', 'ask', 'open', 'close', 'last'")
34
34
  __properties = ["provider", "priceSource", "instrumentId", "instrumentIdType", "quoteType", "field"]
35
35
 
36
36
  @validator('instrument_id_type')
@@ -0,0 +1,113 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+
21
+ from typing import Any, Dict, List, Optional
22
+ from pydantic.v1 import BaseModel, Field, StrictStr, conlist
23
+ from lusid.models.applicable_instrument_event import ApplicableInstrumentEvent
24
+ from lusid.models.link import Link
25
+
26
+ class ResourceListOfApplicableInstrumentEvent(BaseModel):
27
+ """
28
+ ResourceListOfApplicableInstrumentEvent
29
+ """
30
+ values: conlist(ApplicableInstrumentEvent) = Field(...)
31
+ href: Optional[StrictStr] = None
32
+ links: Optional[conlist(Link)] = None
33
+ next_page: Optional[StrictStr] = Field(None, alias="nextPage")
34
+ previous_page: Optional[StrictStr] = Field(None, alias="previousPage")
35
+ __properties = ["values", "href", "links", "nextPage", "previousPage"]
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) -> ResourceListOfApplicableInstrumentEvent:
52
+ """Create an instance of ResourceListOfApplicableInstrumentEvent 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 href (nullable) is None
76
+ # and __fields_set__ contains the field
77
+ if self.href is None and "href" in self.__fields_set__:
78
+ _dict['href'] = None
79
+
80
+ # set to None if links (nullable) is None
81
+ # and __fields_set__ contains the field
82
+ if self.links is None and "links" in self.__fields_set__:
83
+ _dict['links'] = None
84
+
85
+ # set to None if next_page (nullable) is None
86
+ # and __fields_set__ contains the field
87
+ if self.next_page is None and "next_page" in self.__fields_set__:
88
+ _dict['nextPage'] = None
89
+
90
+ # set to None if previous_page (nullable) is None
91
+ # and __fields_set__ contains the field
92
+ if self.previous_page is None and "previous_page" in self.__fields_set__:
93
+ _dict['previousPage'] = None
94
+
95
+ return _dict
96
+
97
+ @classmethod
98
+ def from_dict(cls, obj: dict) -> ResourceListOfApplicableInstrumentEvent:
99
+ """Create an instance of ResourceListOfApplicableInstrumentEvent from a dict"""
100
+ if obj is None:
101
+ return None
102
+
103
+ if not isinstance(obj, dict):
104
+ return ResourceListOfApplicableInstrumentEvent.parse_obj(obj)
105
+
106
+ _obj = ResourceListOfApplicableInstrumentEvent.parse_obj({
107
+ "values": [ApplicableInstrumentEvent.from_dict(_item) for _item in obj.get("values")] if obj.get("values") is not None else None,
108
+ "href": obj.get("href"),
109
+ "links": [Link.from_dict(_item) for _item in obj.get("links")] if obj.get("links") is not None else None,
110
+ "next_page": obj.get("nextPage"),
111
+ "previous_page": obj.get("previousPage")
112
+ })
113
+ return _obj
@@ -0,0 +1,83 @@
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
22
+ from pydantic.v1 import BaseModel, Field, conlist
23
+ from lusid.models.amortisation_rule import AmortisationRule
24
+ from lusid.models.date_range import DateRange
25
+
26
+ class RulesInterval(BaseModel):
27
+ """
28
+ RulesInterval
29
+ """
30
+ effective_range: DateRange = Field(..., alias="effectiveRange")
31
+ rules: conlist(AmortisationRule, max_items=100) = Field(..., description="The rules of this rule set.")
32
+ __properties = ["effectiveRange", "rules"]
33
+
34
+ class Config:
35
+ """Pydantic configuration"""
36
+ allow_population_by_field_name = True
37
+ validate_assignment = True
38
+
39
+ def to_str(self) -> str:
40
+ """Returns the string representation of the model using alias"""
41
+ return pprint.pformat(self.dict(by_alias=True))
42
+
43
+ def to_json(self) -> str:
44
+ """Returns the JSON representation of the model using alias"""
45
+ return json.dumps(self.to_dict())
46
+
47
+ @classmethod
48
+ def from_json(cls, json_str: str) -> RulesInterval:
49
+ """Create an instance of RulesInterval from a JSON string"""
50
+ return cls.from_dict(json.loads(json_str))
51
+
52
+ def to_dict(self):
53
+ """Returns the dictionary representation of the model using alias"""
54
+ _dict = self.dict(by_alias=True,
55
+ exclude={
56
+ },
57
+ exclude_none=True)
58
+ # override the default output from pydantic by calling `to_dict()` of effective_range
59
+ if self.effective_range:
60
+ _dict['effectiveRange'] = self.effective_range.to_dict()
61
+ # override the default output from pydantic by calling `to_dict()` of each item in rules (list)
62
+ _items = []
63
+ if self.rules:
64
+ for _item in self.rules:
65
+ if _item:
66
+ _items.append(_item.to_dict())
67
+ _dict['rules'] = _items
68
+ return _dict
69
+
70
+ @classmethod
71
+ def from_dict(cls, obj: dict) -> RulesInterval:
72
+ """Create an instance of RulesInterval from a dict"""
73
+ if obj is None:
74
+ return None
75
+
76
+ if not isinstance(obj, dict):
77
+ return RulesInterval.parse_obj(obj)
78
+
79
+ _obj = RulesInterval.parse_obj({
80
+ "effective_range": DateRange.from_dict(obj.get("effectiveRange")) if obj.get("effectiveRange") is not None else None,
81
+ "rules": [AmortisationRule.from_dict(_item) for _item in obj.get("rules")] if obj.get("rules") is not None else None
82
+ })
83
+ return _obj
@@ -0,0 +1,73 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+
21
+ from typing import Any, Dict
22
+ from pydantic.v1 import BaseModel, Field
23
+ from lusid.models.rules_interval import RulesInterval
24
+
25
+ class SetAmortisationRulesRequest(BaseModel):
26
+ """
27
+ SetAmortisationRulesRequest
28
+ """
29
+ rules_interval: RulesInterval = Field(..., alias="rulesInterval")
30
+ __properties = ["rulesInterval"]
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) -> SetAmortisationRulesRequest:
47
+ """Create an instance of SetAmortisationRulesRequest 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
+ # override the default output from pydantic by calling `to_dict()` of rules_interval
57
+ if self.rules_interval:
58
+ _dict['rulesInterval'] = self.rules_interval.to_dict()
59
+ return _dict
60
+
61
+ @classmethod
62
+ def from_dict(cls, obj: dict) -> SetAmortisationRulesRequest:
63
+ """Create an instance of SetAmortisationRulesRequest from a dict"""
64
+ if obj is None:
65
+ return None
66
+
67
+ if not isinstance(obj, dict):
68
+ return SetAmortisationRulesRequest.parse_obj(obj)
69
+
70
+ _obj = SetAmortisationRulesRequest.parse_obj({
71
+ "rules_interval": RulesInterval.from_dict(obj.get("rulesInterval")) if obj.get("rulesInterval") is not None else None
72
+ })
73
+ return _obj
@@ -0,0 +1,78 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+ from datetime import datetime
21
+ from typing import Any, Dict, Optional, Union
22
+ from pydantic.v1 import BaseModel, Field, StrictFloat, StrictInt, StrictStr
23
+
24
+ class SettlementSchedule(BaseModel):
25
+ """
26
+ SettlementSchedule
27
+ """
28
+ trade_id: Optional[StrictStr] = Field(None, alias="tradeId")
29
+ settlement_date: Optional[datetime] = Field(None, alias="settlementDate")
30
+ units: Optional[Union[StrictFloat, StrictInt]] = None
31
+ __properties = ["tradeId", "settlementDate", "units"]
32
+
33
+ class Config:
34
+ """Pydantic configuration"""
35
+ allow_population_by_field_name = True
36
+ validate_assignment = True
37
+
38
+ def to_str(self) -> str:
39
+ """Returns the string representation of the model using alias"""
40
+ return pprint.pformat(self.dict(by_alias=True))
41
+
42
+ def to_json(self) -> str:
43
+ """Returns the JSON representation of the model using alias"""
44
+ return json.dumps(self.to_dict())
45
+
46
+ @classmethod
47
+ def from_json(cls, json_str: str) -> SettlementSchedule:
48
+ """Create an instance of SettlementSchedule from a JSON string"""
49
+ return cls.from_dict(json.loads(json_str))
50
+
51
+ def to_dict(self):
52
+ """Returns the dictionary representation of the model using alias"""
53
+ _dict = self.dict(by_alias=True,
54
+ exclude={
55
+ },
56
+ exclude_none=True)
57
+ # set to None if trade_id (nullable) is None
58
+ # and __fields_set__ contains the field
59
+ if self.trade_id is None and "trade_id" in self.__fields_set__:
60
+ _dict['tradeId'] = None
61
+
62
+ return _dict
63
+
64
+ @classmethod
65
+ def from_dict(cls, obj: dict) -> SettlementSchedule:
66
+ """Create an instance of SettlementSchedule from a dict"""
67
+ if obj is None:
68
+ return None
69
+
70
+ if not isinstance(obj, dict):
71
+ return SettlementSchedule.parse_obj(obj)
72
+
73
+ _obj = SettlementSchedule.parse_obj({
74
+ "trade_id": obj.get("tradeId"),
75
+ "settlement_date": obj.get("settlementDate"),
76
+ "units": obj.get("units")
77
+ })
78
+ return _obj
@@ -0,0 +1,95 @@
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
22
+ from pydantic.v1 import BaseModel, Field, conlist, constr, validator
23
+ from lusid.models.compliance_template_variation_request import ComplianceTemplateVariationRequest
24
+
25
+ class UpdateComplianceTemplateRequest(BaseModel):
26
+ """
27
+ UpdateComplianceTemplateRequest
28
+ """
29
+ code: constr(strict=True, max_length=64, min_length=1) = Field(..., description="The code given for the Compliance Template")
30
+ description: constr(strict=True, max_length=1024, min_length=0) = Field(..., description="The description of the Compliance Template")
31
+ variations: conlist(ComplianceTemplateVariationRequest) = Field(..., description="Variation details of a Compliance Template")
32
+ __properties = ["code", "description", "variations"]
33
+
34
+ @validator('code')
35
+ def code_validate_regular_expression(cls, value):
36
+ """Validates the regular expression"""
37
+ if not re.match(r"^[a-zA-Z0-9\-_]+$", value):
38
+ raise ValueError(r"must validate the regular expression /^[a-zA-Z0-9\-_]+$/")
39
+ return value
40
+
41
+ @validator('description')
42
+ def description_validate_regular_expression(cls, value):
43
+ """Validates the regular expression"""
44
+ if not re.match(r"^[\s\S]*$", value):
45
+ raise ValueError(r"must validate the regular expression /^[\s\S]*$/")
46
+ return value
47
+
48
+ class Config:
49
+ """Pydantic configuration"""
50
+ allow_population_by_field_name = True
51
+ validate_assignment = True
52
+
53
+ def to_str(self) -> str:
54
+ """Returns the string representation of the model using alias"""
55
+ return pprint.pformat(self.dict(by_alias=True))
56
+
57
+ def to_json(self) -> str:
58
+ """Returns the JSON representation of the model using alias"""
59
+ return json.dumps(self.to_dict())
60
+
61
+ @classmethod
62
+ def from_json(cls, json_str: str) -> UpdateComplianceTemplateRequest:
63
+ """Create an instance of UpdateComplianceTemplateRequest from a JSON string"""
64
+ return cls.from_dict(json.loads(json_str))
65
+
66
+ def to_dict(self):
67
+ """Returns the dictionary representation of the model using alias"""
68
+ _dict = self.dict(by_alias=True,
69
+ exclude={
70
+ },
71
+ exclude_none=True)
72
+ # override the default output from pydantic by calling `to_dict()` of each item in variations (list)
73
+ _items = []
74
+ if self.variations:
75
+ for _item in self.variations:
76
+ if _item:
77
+ _items.append(_item.to_dict())
78
+ _dict['variations'] = _items
79
+ return _dict
80
+
81
+ @classmethod
82
+ def from_dict(cls, obj: dict) -> UpdateComplianceTemplateRequest:
83
+ """Create an instance of UpdateComplianceTemplateRequest from a dict"""
84
+ if obj is None:
85
+ return None
86
+
87
+ if not isinstance(obj, dict):
88
+ return UpdateComplianceTemplateRequest.parse_obj(obj)
89
+
90
+ _obj = UpdateComplianceTemplateRequest.parse_obj({
91
+ "code": obj.get("code"),
92
+ "description": obj.get("description"),
93
+ "variations": [ComplianceTemplateVariationRequest.from_dict(_item) for _item in obj.get("variations")] if obj.get("variations") is not None else None
94
+ })
95
+ return _obj