lusid-sdk 2.1.590__py3-none-any.whl → 2.1.637__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (154) hide show
  1. lusid/__init__.py +42 -0
  2. lusid/api/__init__.py +2 -0
  3. lusid/api/chart_of_accounts_api.py +6 -6
  4. lusid/api/corporate_action_sources_api.py +6 -6
  5. lusid/api/entities_api.py +24 -24
  6. lusid/api/funds_api.py +438 -1
  7. lusid/api/order_management_api.py +16 -8
  8. lusid/api/staged_modifications_api.py +12 -12
  9. lusid/api/timelines_api.py +1094 -0
  10. lusid/api/transaction_portfolios_api.py +189 -6
  11. lusid/api/workspace_api.py +96 -48
  12. lusid/configuration.py +1 -1
  13. lusid/models/__init__.py +40 -0
  14. lusid/models/accounted_transaction.py +88 -0
  15. lusid/models/accumulation_event.py +3 -3
  16. lusid/models/adjust_global_commitment_event.py +93 -0
  17. lusid/models/amortisation_event.py +3 -3
  18. lusid/models/basket.py +3 -3
  19. lusid/models/bond.py +11 -5
  20. lusid/models/bond_coupon_event.py +3 -3
  21. lusid/models/bond_default_event.py +3 -3
  22. lusid/models/bond_principal_event.py +3 -3
  23. lusid/models/bonus_issue_event.py +3 -3
  24. lusid/models/call_on_intermediate_securities_event.py +3 -3
  25. lusid/models/cancel_single_holding_adjustment_request.py +96 -0
  26. lusid/models/cap_floor.py +22 -7
  27. lusid/models/capital_distribution_event.py +3 -3
  28. lusid/models/cash.py +3 -3
  29. lusid/models/cash_dividend_event.py +3 -3
  30. lusid/models/cash_flow_event.py +3 -3
  31. lusid/models/cash_perpetual.py +3 -3
  32. lusid/models/cds_credit_event.py +3 -3
  33. lusid/models/cds_index.py +3 -3
  34. lusid/models/cdx_credit_event.py +3 -3
  35. lusid/models/close_event.py +3 -3
  36. lusid/models/closed_period.py +128 -0
  37. lusid/models/complete_portfolio.py +3 -3
  38. lusid/models/complex_bond.py +20 -7
  39. lusid/models/contract_details.py +101 -0
  40. lusid/models/contract_for_difference.py +3 -3
  41. lusid/models/contract_initialisation_event.py +99 -0
  42. lusid/models/create_closed_period_request.py +96 -0
  43. lusid/models/create_derived_property_definition_request.py +8 -6
  44. lusid/models/create_derived_transaction_portfolio_request.py +8 -2
  45. lusid/models/create_property_definition_request.py +3 -3
  46. lusid/models/create_timeline_request.py +102 -0
  47. lusid/models/credit_default_swap.py +3 -3
  48. lusid/models/credit_premium_cash_flow_event.py +3 -3
  49. lusid/models/dependency_source_filter.py +19 -4
  50. lusid/models/dividend_option_event.py +3 -3
  51. lusid/models/dividend_reinvestment_event.py +3 -3
  52. lusid/models/drawdown_event.py +99 -0
  53. lusid/models/early_redemption_event.py +3 -3
  54. lusid/models/eligibility_calculation.py +6 -4
  55. lusid/models/equity.py +3 -3
  56. lusid/models/equity_option.py +29 -8
  57. lusid/models/equity_swap.py +3 -3
  58. lusid/models/exchange_traded_option.py +12 -6
  59. lusid/models/exercise_event.py +3 -3
  60. lusid/models/exotic_instrument.py +3 -3
  61. lusid/models/expiry_event.py +3 -3
  62. lusid/models/fee_accrual.py +3 -1
  63. lusid/models/fixed_leg.py +3 -3
  64. lusid/models/flexible_deposit.py +105 -0
  65. lusid/models/flexible_loan.py +3 -3
  66. lusid/models/floating_leg.py +3 -3
  67. lusid/models/forward_rate_agreement.py +3 -3
  68. lusid/models/fund_share_class.py +3 -3
  69. lusid/models/funding_leg.py +3 -3
  70. lusid/models/future.py +19 -7
  71. lusid/models/future_expiry_event.py +3 -3
  72. lusid/models/future_mark_to_market_event.py +100 -0
  73. lusid/models/fx_forward.py +3 -3
  74. lusid/models/fx_forward_settlement_event.py +3 -3
  75. lusid/models/fx_option.py +3 -3
  76. lusid/models/fx_swap.py +3 -3
  77. lusid/models/group_reconciliation_summary.py +2 -2
  78. lusid/models/inflation_leg.py +3 -3
  79. lusid/models/inflation_linked_bond.py +11 -5
  80. lusid/models/inflation_swap.py +3 -3
  81. lusid/models/informational_error_event.py +3 -3
  82. lusid/models/informational_event.py +3 -3
  83. lusid/models/instrument_event.py +10 -5
  84. lusid/models/instrument_event_instruction.py +9 -2
  85. lusid/models/instrument_event_instruction_request.py +10 -3
  86. lusid/models/instrument_event_type.py +5 -0
  87. lusid/models/instrument_leg.py +3 -3
  88. lusid/models/instrument_type.py +1 -0
  89. lusid/models/interest_rate_swap.py +3 -3
  90. lusid/models/interest_rate_swaption.py +4 -4
  91. lusid/models/intermediate_securities_distribution_event.py +3 -3
  92. lusid/models/loan_facility.py +3 -3
  93. lusid/models/loan_interest_repayment_event.py +97 -0
  94. lusid/models/lusid_instrument.py +6 -5
  95. lusid/models/mark_to_market_conventions.py +74 -0
  96. lusid/models/market_data_key_rule.py +1 -1
  97. lusid/models/market_data_specific_rule.py +1 -1
  98. lusid/models/mastered_instrument.py +3 -3
  99. lusid/models/maturity_event.py +3 -3
  100. lusid/models/mbs_coupon_event.py +3 -3
  101. lusid/models/mbs_interest_deferral_event.py +3 -3
  102. lusid/models/mbs_interest_shortfall_event.py +3 -3
  103. lusid/models/mbs_principal_event.py +3 -3
  104. lusid/models/mbs_principal_write_off_event.py +3 -3
  105. lusid/models/merger_event.py +3 -3
  106. lusid/models/open_event.py +3 -3
  107. lusid/models/option_exercise_cash_event.py +3 -3
  108. lusid/models/option_exercise_physical_event.py +3 -3
  109. lusid/models/output_transaction.py +7 -1
  110. lusid/models/pnl_journal_entry_line.py +95 -0
  111. lusid/models/portfolio.py +3 -3
  112. lusid/models/portfolio_id.py +80 -0
  113. lusid/models/portfolio_search_result.py +3 -3
  114. lusid/models/portfolio_type.py +1 -0
  115. lusid/models/portfolio_without_href.py +3 -3
  116. lusid/models/property_definition.py +6 -4
  117. lusid/models/property_definition_search_result.py +6 -4
  118. lusid/models/property_domain.py +1 -0
  119. lusid/models/protection_payout_cash_flow_event.py +3 -3
  120. lusid/models/raw_vendor_event.py +3 -3
  121. lusid/models/reference_instrument.py +3 -3
  122. lusid/models/repo.py +3 -3
  123. lusid/models/reset_event.py +3 -3
  124. lusid/models/reverse_stock_split_event.py +3 -3
  125. lusid/models/scrip_dividend_event.py +3 -3
  126. lusid/models/side_definition.py +8 -1
  127. lusid/models/side_definition_request.py +9 -2
  128. lusid/models/simple_cash_flow_loan.py +3 -3
  129. lusid/models/simple_instrument.py +3 -3
  130. lusid/models/spin_off_event.py +3 -3
  131. lusid/models/stock_dividend_event.py +3 -3
  132. lusid/models/stock_split_event.py +3 -3
  133. lusid/models/swap_cash_flow_event.py +3 -3
  134. lusid/models/swap_principal_event.py +3 -3
  135. lusid/models/tender_event.py +3 -3
  136. lusid/models/term_deposit.py +3 -3
  137. lusid/models/term_deposit_interest_event.py +3 -3
  138. lusid/models/term_deposit_principal_event.py +3 -3
  139. lusid/models/timeline.py +135 -0
  140. lusid/models/total_return_swap.py +3 -3
  141. lusid/models/trading_conventions.py +73 -0
  142. lusid/models/transition_event.py +3 -3
  143. lusid/models/trigger_event.py +3 -3
  144. lusid/models/update_derived_property_definition_request.py +5 -3
  145. lusid/models/update_timeline_request.py +96 -0
  146. lusid/models/valuation_point_resource_list_of_accounted_transaction.py +125 -0
  147. lusid/models/valuation_point_resource_list_of_pnl_journal_entry_line.py +125 -0
  148. lusid/models/workspace.py +1 -1
  149. lusid/models/workspace_creation_request.py +1 -1
  150. lusid/models/workspace_item.py +4 -2
  151. lusid/models/workspace_item_creation_request.py +11 -2
  152. {lusid_sdk-2.1.590.dist-info → lusid_sdk-2.1.637.dist-info}/METADATA +40 -10
  153. {lusid_sdk-2.1.590.dist-info → lusid_sdk-2.1.637.dist-info}/RECORD +154 -133
  154. {lusid_sdk-2.1.590.dist-info → lusid_sdk-2.1.637.dist-info}/WHEEL +1 -1
@@ -0,0 +1,96 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ LUSID API
5
+
6
+ FINBOURNE Technology # noqa: E501
7
+
8
+ Contact: info@finbourne.com
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """
13
+
14
+
15
+ from __future__ import annotations
16
+ import pprint
17
+ import re # noqa: F401
18
+ import json
19
+
20
+
21
+ from typing import Any, Dict, Optional
22
+ from pydantic.v1 import BaseModel, Field, constr
23
+ from lusid.models.model_property import ModelProperty
24
+
25
+ class UpdateTimelineRequest(BaseModel):
26
+ """
27
+ UpdateTimelineRequest
28
+ """
29
+ display_name: constr(strict=True, max_length=512, min_length=0) = Field(..., alias="displayName", description="The name of the Timeline.")
30
+ description: Optional[constr(strict=True, max_length=512, min_length=0)] = Field(None, description="A description for the Timeline.")
31
+ properties: Optional[Dict[str, ModelProperty]] = Field(None, description="The Timelines properties. These will be from the 'Timeline' domain.")
32
+ __properties = ["displayName", "description", "properties"]
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) -> UpdateTimelineRequest:
49
+ """Create an instance of UpdateTimelineRequest 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 each value in properties (dict)
59
+ _field_dict = {}
60
+ if self.properties:
61
+ for _key in self.properties:
62
+ if self.properties[_key]:
63
+ _field_dict[_key] = self.properties[_key].to_dict()
64
+ _dict['properties'] = _field_dict
65
+ # set to None if description (nullable) is None
66
+ # and __fields_set__ contains the field
67
+ if self.description is None and "description" in self.__fields_set__:
68
+ _dict['description'] = None
69
+
70
+ # set to None if properties (nullable) is None
71
+ # and __fields_set__ contains the field
72
+ if self.properties is None and "properties" in self.__fields_set__:
73
+ _dict['properties'] = None
74
+
75
+ return _dict
76
+
77
+ @classmethod
78
+ def from_dict(cls, obj: dict) -> UpdateTimelineRequest:
79
+ """Create an instance of UpdateTimelineRequest from a dict"""
80
+ if obj is None:
81
+ return None
82
+
83
+ if not isinstance(obj, dict):
84
+ return UpdateTimelineRequest.parse_obj(obj)
85
+
86
+ _obj = UpdateTimelineRequest.parse_obj({
87
+ "display_name": obj.get("displayName"),
88
+ "description": obj.get("description"),
89
+ "properties": dict(
90
+ (_k, ModelProperty.from_dict(_v))
91
+ for _k, _v in obj.get("properties").items()
92
+ )
93
+ if obj.get("properties") is not None
94
+ else None
95
+ })
96
+ return _obj
@@ -0,0 +1,125 @@
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.accounted_transaction import AccountedTransaction
24
+ from lusid.models.diary_entry import DiaryEntry
25
+ from lusid.models.link import Link
26
+ from lusid.models.version import Version
27
+
28
+ class ValuationPointResourceListOfAccountedTransaction(BaseModel):
29
+ """
30
+ ResourceList with extra header fields used by the various ValuationPoint endpoints for returning additional context related to the list of results. # noqa: E501
31
+ """
32
+ start_valuation_point: Optional[DiaryEntry] = Field(None, alias="startValuationPoint")
33
+ version: Version = Field(...)
34
+ values: conlist(AccountedTransaction) = Field(...)
35
+ href: Optional[StrictStr] = None
36
+ next_page: Optional[StrictStr] = Field(None, alias="nextPage")
37
+ previous_page: Optional[StrictStr] = Field(None, alias="previousPage")
38
+ links: Optional[conlist(Link)] = None
39
+ __properties = ["startValuationPoint", "version", "values", "href", "nextPage", "previousPage", "links"]
40
+
41
+ class Config:
42
+ """Pydantic configuration"""
43
+ allow_population_by_field_name = True
44
+ validate_assignment = True
45
+
46
+ def to_str(self) -> str:
47
+ """Returns the string representation of the model using alias"""
48
+ return pprint.pformat(self.dict(by_alias=True))
49
+
50
+ def to_json(self) -> str:
51
+ """Returns the JSON representation of the model using alias"""
52
+ return json.dumps(self.to_dict())
53
+
54
+ @classmethod
55
+ def from_json(cls, json_str: str) -> ValuationPointResourceListOfAccountedTransaction:
56
+ """Create an instance of ValuationPointResourceListOfAccountedTransaction from a JSON string"""
57
+ return cls.from_dict(json.loads(json_str))
58
+
59
+ def to_dict(self):
60
+ """Returns the dictionary representation of the model using alias"""
61
+ _dict = self.dict(by_alias=True,
62
+ exclude={
63
+ },
64
+ exclude_none=True)
65
+ # override the default output from pydantic by calling `to_dict()` of start_valuation_point
66
+ if self.start_valuation_point:
67
+ _dict['startValuationPoint'] = self.start_valuation_point.to_dict()
68
+ # override the default output from pydantic by calling `to_dict()` of version
69
+ if self.version:
70
+ _dict['version'] = self.version.to_dict()
71
+ # override the default output from pydantic by calling `to_dict()` of each item in values (list)
72
+ _items = []
73
+ if self.values:
74
+ for _item in self.values:
75
+ if _item:
76
+ _items.append(_item.to_dict())
77
+ _dict['values'] = _items
78
+ # override the default output from pydantic by calling `to_dict()` of each item in links (list)
79
+ _items = []
80
+ if self.links:
81
+ for _item in self.links:
82
+ if _item:
83
+ _items.append(_item.to_dict())
84
+ _dict['links'] = _items
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 next_page (nullable) is None
91
+ # and __fields_set__ contains the field
92
+ if self.next_page is None and "next_page" in self.__fields_set__:
93
+ _dict['nextPage'] = None
94
+
95
+ # set to None if previous_page (nullable) is None
96
+ # and __fields_set__ contains the field
97
+ if self.previous_page is None and "previous_page" in self.__fields_set__:
98
+ _dict['previousPage'] = None
99
+
100
+ # set to None if links (nullable) is None
101
+ # and __fields_set__ contains the field
102
+ if self.links is None and "links" in self.__fields_set__:
103
+ _dict['links'] = None
104
+
105
+ return _dict
106
+
107
+ @classmethod
108
+ def from_dict(cls, obj: dict) -> ValuationPointResourceListOfAccountedTransaction:
109
+ """Create an instance of ValuationPointResourceListOfAccountedTransaction from a dict"""
110
+ if obj is None:
111
+ return None
112
+
113
+ if not isinstance(obj, dict):
114
+ return ValuationPointResourceListOfAccountedTransaction.parse_obj(obj)
115
+
116
+ _obj = ValuationPointResourceListOfAccountedTransaction.parse_obj({
117
+ "start_valuation_point": DiaryEntry.from_dict(obj.get("startValuationPoint")) if obj.get("startValuationPoint") is not None else None,
118
+ "version": Version.from_dict(obj.get("version")) if obj.get("version") is not None else None,
119
+ "values": [AccountedTransaction.from_dict(_item) for _item in obj.get("values")] if obj.get("values") is not None else None,
120
+ "href": obj.get("href"),
121
+ "next_page": obj.get("nextPage"),
122
+ "previous_page": obj.get("previousPage"),
123
+ "links": [Link.from_dict(_item) for _item in obj.get("links")] if obj.get("links") is not None else None
124
+ })
125
+ return _obj
@@ -0,0 +1,125 @@
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.diary_entry import DiaryEntry
24
+ from lusid.models.link import Link
25
+ from lusid.models.pnl_journal_entry_line import PnlJournalEntryLine
26
+ from lusid.models.version import Version
27
+
28
+ class ValuationPointResourceListOfPnlJournalEntryLine(BaseModel):
29
+ """
30
+ ResourceList with extra header fields used by the various ValuationPoint endpoints for returning additional context related to the list of results. # noqa: E501
31
+ """
32
+ start_valuation_point: Optional[DiaryEntry] = Field(None, alias="startValuationPoint")
33
+ version: Version = Field(...)
34
+ values: conlist(PnlJournalEntryLine) = Field(...)
35
+ href: Optional[StrictStr] = None
36
+ next_page: Optional[StrictStr] = Field(None, alias="nextPage")
37
+ previous_page: Optional[StrictStr] = Field(None, alias="previousPage")
38
+ links: Optional[conlist(Link)] = None
39
+ __properties = ["startValuationPoint", "version", "values", "href", "nextPage", "previousPage", "links"]
40
+
41
+ class Config:
42
+ """Pydantic configuration"""
43
+ allow_population_by_field_name = True
44
+ validate_assignment = True
45
+
46
+ def to_str(self) -> str:
47
+ """Returns the string representation of the model using alias"""
48
+ return pprint.pformat(self.dict(by_alias=True))
49
+
50
+ def to_json(self) -> str:
51
+ """Returns the JSON representation of the model using alias"""
52
+ return json.dumps(self.to_dict())
53
+
54
+ @classmethod
55
+ def from_json(cls, json_str: str) -> ValuationPointResourceListOfPnlJournalEntryLine:
56
+ """Create an instance of ValuationPointResourceListOfPnlJournalEntryLine from a JSON string"""
57
+ return cls.from_dict(json.loads(json_str))
58
+
59
+ def to_dict(self):
60
+ """Returns the dictionary representation of the model using alias"""
61
+ _dict = self.dict(by_alias=True,
62
+ exclude={
63
+ },
64
+ exclude_none=True)
65
+ # override the default output from pydantic by calling `to_dict()` of start_valuation_point
66
+ if self.start_valuation_point:
67
+ _dict['startValuationPoint'] = self.start_valuation_point.to_dict()
68
+ # override the default output from pydantic by calling `to_dict()` of version
69
+ if self.version:
70
+ _dict['version'] = self.version.to_dict()
71
+ # override the default output from pydantic by calling `to_dict()` of each item in values (list)
72
+ _items = []
73
+ if self.values:
74
+ for _item in self.values:
75
+ if _item:
76
+ _items.append(_item.to_dict())
77
+ _dict['values'] = _items
78
+ # override the default output from pydantic by calling `to_dict()` of each item in links (list)
79
+ _items = []
80
+ if self.links:
81
+ for _item in self.links:
82
+ if _item:
83
+ _items.append(_item.to_dict())
84
+ _dict['links'] = _items
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 next_page (nullable) is None
91
+ # and __fields_set__ contains the field
92
+ if self.next_page is None and "next_page" in self.__fields_set__:
93
+ _dict['nextPage'] = None
94
+
95
+ # set to None if previous_page (nullable) is None
96
+ # and __fields_set__ contains the field
97
+ if self.previous_page is None and "previous_page" in self.__fields_set__:
98
+ _dict['previousPage'] = None
99
+
100
+ # set to None if links (nullable) is None
101
+ # and __fields_set__ contains the field
102
+ if self.links is None and "links" in self.__fields_set__:
103
+ _dict['links'] = None
104
+
105
+ return _dict
106
+
107
+ @classmethod
108
+ def from_dict(cls, obj: dict) -> ValuationPointResourceListOfPnlJournalEntryLine:
109
+ """Create an instance of ValuationPointResourceListOfPnlJournalEntryLine from a dict"""
110
+ if obj is None:
111
+ return None
112
+
113
+ if not isinstance(obj, dict):
114
+ return ValuationPointResourceListOfPnlJournalEntryLine.parse_obj(obj)
115
+
116
+ _obj = ValuationPointResourceListOfPnlJournalEntryLine.parse_obj({
117
+ "start_valuation_point": DiaryEntry.from_dict(obj.get("startValuationPoint")) if obj.get("startValuationPoint") is not None else None,
118
+ "version": Version.from_dict(obj.get("version")) if obj.get("version") is not None else None,
119
+ "values": [PnlJournalEntryLine.from_dict(_item) for _item in obj.get("values")] if obj.get("values") is not None else None,
120
+ "href": obj.get("href"),
121
+ "next_page": obj.get("nextPage"),
122
+ "previous_page": obj.get("previousPage"),
123
+ "links": [Link.from_dict(_item) for _item in obj.get("links")] if obj.get("links") is not None else None
124
+ })
125
+ return _obj
lusid/models/workspace.py CHANGED
@@ -27,7 +27,7 @@ class Workspace(BaseModel):
27
27
  """
28
28
  A workspace. # noqa: E501
29
29
  """
30
- name: constr(strict=True, min_length=1) = Field(..., description="A workspace's name; a unique identifier.")
30
+ name: constr(strict=True, min_length=1) = Field(..., description="A workspace's name.")
31
31
  description: constr(strict=True, max_length=6000, min_length=0) = Field(..., description="A friendly description for the workspace.")
32
32
  version: Optional[Version] = None
33
33
  links: Optional[conlist(Link)] = None
@@ -25,7 +25,7 @@ class WorkspaceCreationRequest(BaseModel):
25
25
  """
26
26
  A request to create an empty workspace. # noqa: E501
27
27
  """
28
- name: constr(strict=True, max_length=64, min_length=1) = Field(..., description="A workspace's name; a unique identifier.")
28
+ name: constr(strict=True, max_length=64, min_length=1) = Field(..., description="A workspace's name.")
29
29
  description: constr(strict=True, max_length=6000, min_length=0) = Field(..., description="A friendly description for the workspace.")
30
30
  __properties = ["name", "description"]
31
31
 
@@ -29,12 +29,13 @@ class WorkspaceItem(BaseModel):
29
29
  """
30
30
  type: constr(strict=True, min_length=1) = Field(..., description="The type of the workspace item.")
31
31
  format: StrictInt = Field(..., description="A simple integer format identifier.")
32
- name: constr(strict=True, min_length=1) = Field(..., description="A workspace item's name; a unique identifier.")
32
+ name: constr(strict=True, min_length=1) = Field(..., description="A workspace item's name.")
33
+ group: constr(strict=True, min_length=1) = Field(..., description="The group containing a workspace item.")
33
34
  description: constr(strict=True, max_length=1024, min_length=0) = Field(..., description="The description of a workspace item.")
34
35
  content: Optional[Any] = Field(..., description="The content associated with a workspace item.")
35
36
  version: Optional[Version] = None
36
37
  links: Optional[conlist(Link)] = None
37
- __properties = ["type", "format", "name", "description", "content", "version", "links"]
38
+ __properties = ["type", "format", "name", "group", "description", "content", "version", "links"]
38
39
 
39
40
  @validator('description')
40
41
  def description_validate_regular_expression(cls, value):
@@ -102,6 +103,7 @@ class WorkspaceItem(BaseModel):
102
103
  "type": obj.get("type"),
103
104
  "format": obj.get("format"),
104
105
  "name": obj.get("name"),
106
+ "group": obj.get("group"),
105
107
  "description": obj.get("description"),
106
108
  "content": obj.get("content"),
107
109
  "version": Version.from_dict(obj.get("version")) if obj.get("version") is not None else None,
@@ -26,11 +26,12 @@ class WorkspaceItemCreationRequest(BaseModel):
26
26
  A request to create an item in a workspace. # noqa: E501
27
27
  """
28
28
  format: StrictInt = Field(..., description="A simple integer format identifier.")
29
- name: constr(strict=True, max_length=64, min_length=1) = Field(..., description="A workspace item's name; a unique identifier.")
29
+ name: constr(strict=True, max_length=64, min_length=1) = Field(..., description="A workspace item's name.")
30
+ group: constr(strict=True, max_length=64, min_length=1) = Field(..., description="The group containing a workspace item.")
30
31
  description: constr(strict=True, max_length=1024, min_length=0) = Field(..., description="The description of a workspace item.")
31
32
  content: Optional[Any] = Field(..., description="The content associated with a workspace item.")
32
33
  type: constr(strict=True, max_length=6000, min_length=0) = Field(..., description="The type of the workspace item.")
33
- __properties = ["format", "name", "description", "content", "type"]
34
+ __properties = ["format", "name", "group", "description", "content", "type"]
34
35
 
35
36
  @validator('name')
36
37
  def name_validate_regular_expression(cls, value):
@@ -39,6 +40,13 @@ class WorkspaceItemCreationRequest(BaseModel):
39
40
  raise ValueError(r"must validate the regular expression /^[a-zA-Z0-9\-_]+$/")
40
41
  return value
41
42
 
43
+ @validator('group')
44
+ def group_validate_regular_expression(cls, value):
45
+ """Validates the regular expression"""
46
+ if not re.match(r"^[a-zA-Z0-9\-_]+$", value):
47
+ raise ValueError(r"must validate the regular expression /^[a-zA-Z0-9\-_]+$/")
48
+ return value
49
+
42
50
  @validator('description')
43
51
  def description_validate_regular_expression(cls, value):
44
52
  """Validates the regular expression"""
@@ -89,6 +97,7 @@ class WorkspaceItemCreationRequest(BaseModel):
89
97
  _obj = WorkspaceItemCreationRequest.parse_obj({
90
98
  "format": obj.get("format"),
91
99
  "name": obj.get("name"),
100
+ "group": obj.get("group"),
92
101
  "description": obj.get("description"),
93
102
  "content": obj.get("content"),
94
103
  "type": obj.get("type")