waldur-api-client 7.8.1__py3-none-any.whl → 7.8.2__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 waldur-api-client might be problematic. Click here for more details.

Files changed (169) hide show
  1. waldur_api_client/api/booking_resources/booking_resources_count.py +10 -13
  2. waldur_api_client/api/booking_resources/booking_resources_list.py +10 -13
  3. waldur_api_client/api/call_managing_organisations/call_managing_organisations_create.py +44 -7
  4. waldur_api_client/api/call_managing_organisations/call_managing_organisations_partial_update.py +46 -7
  5. waldur_api_client/api/call_managing_organisations/call_managing_organisations_update.py +44 -7
  6. waldur_api_client/api/checklists_admin/checklists_admin_checklist_questions.py +49 -0
  7. waldur_api_client/api/checklists_admin/checklists_admin_count.py +43 -0
  8. waldur_api_client/api/checklists_admin/checklists_admin_list.py +43 -0
  9. waldur_api_client/api/checklists_admin_categories/checklists_admin_categories_create.py +44 -7
  10. waldur_api_client/api/checklists_admin_categories/checklists_admin_categories_partial_update.py +44 -7
  11. waldur_api_client/api/checklists_admin_categories/checklists_admin_categories_update.py +44 -7
  12. waldur_api_client/api/customers/customers_create.py +44 -7
  13. waldur_api_client/api/customers/customers_partial_update.py +44 -7
  14. waldur_api_client/api/customers/customers_update.py +44 -7
  15. waldur_api_client/api/external_links/external_links_create.py +44 -7
  16. waldur_api_client/api/external_links/external_links_partial_update.py +44 -7
  17. waldur_api_client/api/external_links/external_links_update.py +44 -7
  18. waldur_api_client/api/invoices/invoices_paid.py +44 -7
  19. waldur_api_client/api/marketplace_categories/marketplace_categories_create.py +44 -7
  20. waldur_api_client/api/marketplace_categories/marketplace_categories_partial_update.py +44 -7
  21. waldur_api_client/api/marketplace_categories/marketplace_categories_update.py +44 -7
  22. waldur_api_client/api/marketplace_category_groups/marketplace_category_groups_create.py +44 -7
  23. waldur_api_client/api/marketplace_category_groups/marketplace_category_groups_partial_update.py +44 -7
  24. waldur_api_client/api/marketplace_category_groups/marketplace_category_groups_update.py +44 -7
  25. waldur_api_client/api/marketplace_offering_files/marketplace_offering_files_create.py +44 -7
  26. waldur_api_client/api/marketplace_orders/marketplace_orders_update_attachment.py +44 -7
  27. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_create.py +44 -7
  28. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_update_image.py +44 -7
  29. waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_update_thumbnail.py +30 -5
  30. waldur_api_client/api/marketplace_provider_resources/marketplace_provider_resources_count.py +10 -13
  31. waldur_api_client/api/marketplace_provider_resources/marketplace_provider_resources_list.py +10 -13
  32. waldur_api_client/api/marketplace_resources/marketplace_resources_count.py +10 -13
  33. waldur_api_client/api/marketplace_resources/marketplace_resources_list.py +10 -13
  34. waldur_api_client/api/marketplace_screenshots/marketplace_screenshots_create.py +44 -7
  35. waldur_api_client/api/marketplace_screenshots/marketplace_screenshots_update.py +44 -7
  36. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_create.py +44 -7
  37. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_partial_update.py +44 -7
  38. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_update.py +44 -7
  39. waldur_api_client/api/override_settings/override_settings.py +30 -5
  40. waldur_api_client/api/payments/payments_create.py +44 -7
  41. waldur_api_client/api/payments/payments_partial_update.py +44 -7
  42. waldur_api_client/api/payments/payments_update.py +44 -7
  43. waldur_api_client/api/projects/projects_create.py +44 -7
  44. waldur_api_client/api/projects/projects_partial_update.py +44 -7
  45. waldur_api_client/api/projects/projects_update.py +44 -7
  46. waldur_api_client/api/proposal_proposals/proposal_proposals_attach_document.py +30 -5
  47. waldur_api_client/api/slurm_jobs/slurm_jobs_create.py +44 -7
  48. waldur_api_client/api/slurm_jobs/slurm_jobs_update.py +44 -7
  49. waldur_api_client/api/support_attachments/support_attachments_create.py +44 -7
  50. waldur_api_client/api/user_group_invitations/user_group_invitations_count.py +15 -0
  51. waldur_api_client/api/user_group_invitations/user_group_invitations_list.py +15 -0
  52. waldur_api_client/api/users/users_create.py +44 -7
  53. waldur_api_client/api/users/users_partial_update.py +44 -7
  54. waldur_api_client/api/users/users_update.py +44 -7
  55. waldur_api_client/models/__init__.py +146 -2
  56. waldur_api_client/models/agent_type_enum.py +13 -0
  57. waldur_api_client/models/attachment_request_form.py +70 -0
  58. waldur_api_client/models/attachment_request_multipart.py +83 -0
  59. waldur_api_client/models/booking_offerings_list_field_item.py +1 -0
  60. waldur_api_client/models/booking_offerings_retrieve_field_item.py +1 -0
  61. waldur_api_client/models/call_managing_organisation_request_form.py +103 -0
  62. waldur_api_client/models/call_managing_organisation_request_multipart.py +122 -0
  63. waldur_api_client/models/call_round.py +11 -1
  64. waldur_api_client/models/category_group_request_form.py +103 -0
  65. waldur_api_client/models/category_group_request_multipart.py +122 -0
  66. waldur_api_client/models/checklist_category_request_form.py +103 -0
  67. waldur_api_client/models/checklist_category_request_multipart.py +122 -0
  68. waldur_api_client/models/checklists_admin_checklist_questions_checklist_type.py +11 -0
  69. waldur_api_client/models/checklists_admin_checklist_questions_checklist_type_in_item.py +11 -0
  70. waldur_api_client/models/checklists_admin_count_checklist_type.py +11 -0
  71. waldur_api_client/models/checklists_admin_count_checklist_type_in_item.py +11 -0
  72. waldur_api_client/models/checklists_admin_list_checklist_type.py +11 -0
  73. waldur_api_client/models/checklists_admin_list_checklist_type_in_item.py +11 -0
  74. waldur_api_client/models/constance_settings.py +9 -0
  75. waldur_api_client/models/constance_settings_request.py +9 -0
  76. waldur_api_client/models/constance_settings_request_form.py +1547 -0
  77. waldur_api_client/models/constance_settings_request_multipart.py +2173 -0
  78. waldur_api_client/models/customer.py +9 -0
  79. waldur_api_client/models/customer_request.py +9 -0
  80. waldur_api_client/models/customer_request_form.py +312 -0
  81. waldur_api_client/models/customer_request_multipart.py +394 -0
  82. waldur_api_client/models/customers_list_field_item.py +1 -0
  83. waldur_api_client/models/customers_retrieve_field_item.py +1 -0
  84. waldur_api_client/models/external_link_request_form.py +111 -0
  85. waldur_api_client/models/external_link_request_multipart.py +132 -0
  86. waldur_api_client/models/firecrest_job_request_form.py +104 -0
  87. waldur_api_client/models/firecrest_job_request_multipart.py +127 -0
  88. waldur_api_client/models/integration_status.py +21 -4
  89. waldur_api_client/models/marketplace_category_request_form.py +153 -0
  90. waldur_api_client/models/marketplace_category_request_multipart.py +187 -0
  91. waldur_api_client/models/marketplace_provider_offerings_list_course_accounts_retrieve_field_item.py +1 -0
  92. waldur_api_client/models/marketplace_provider_offerings_list_customer_service_accounts_retrieve_field_item.py +1 -0
  93. waldur_api_client/models/marketplace_provider_offerings_list_field_item.py +1 -0
  94. waldur_api_client/models/marketplace_provider_offerings_list_project_service_accounts_retrieve_field_item.py +1 -0
  95. waldur_api_client/models/marketplace_provider_offerings_retrieve_field_item.py +1 -0
  96. waldur_api_client/models/marketplace_provider_offerings_stats_retrieve_field_item.py +1 -0
  97. waldur_api_client/models/marketplace_provider_offerings_user_has_resource_access_retrieve_field_item.py +1 -0
  98. waldur_api_client/models/marketplace_public_offerings_list_field_item.py +1 -0
  99. waldur_api_client/models/marketplace_public_offerings_retrieve_field_item.py +1 -0
  100. waldur_api_client/models/marketplace_service_providers_offerings_list_field_item.py +1 -0
  101. waldur_api_client/models/nested_round.py +9 -0
  102. waldur_api_client/models/nested_round_request.py +9 -0
  103. waldur_api_client/models/offering.py +20 -0
  104. waldur_api_client/models/offering_create.py +20 -0
  105. waldur_api_client/models/offering_create_request.py +20 -0
  106. waldur_api_client/models/offering_create_request_form.py +479 -0
  107. waldur_api_client/models/offering_create_request_form_limits.py +57 -0
  108. waldur_api_client/models/offering_create_request_multipart.py +599 -0
  109. waldur_api_client/models/offering_create_request_multipart_limits.py +57 -0
  110. waldur_api_client/models/offering_file_request_form.py +78 -0
  111. waldur_api_client/models/offering_file_request_multipart.py +93 -0
  112. waldur_api_client/models/offering_image_request_form.py +62 -0
  113. waldur_api_client/models/offering_image_request_multipart.py +73 -0
  114. waldur_api_client/models/offering_thumbnail_request_form.py +62 -0
  115. waldur_api_client/models/offering_thumbnail_request_multipart.py +73 -0
  116. waldur_api_client/models/offering_user.py +5 -5
  117. waldur_api_client/models/{offering_user_state_enum.py → offering_user_state.py} +1 -1
  118. waldur_api_client/models/order_attachment_request_form.py +84 -0
  119. waldur_api_client/models/order_attachment_request_multipart.py +98 -0
  120. waldur_api_client/models/paid_request_form.py +81 -0
  121. waldur_api_client/models/paid_request_multipart.py +94 -0
  122. waldur_api_client/models/patched_call_managing_organisation_request_form.py +92 -0
  123. waldur_api_client/models/patched_call_managing_organisation_request_multipart.py +109 -0
  124. waldur_api_client/models/patched_category_group_request_form.py +101 -0
  125. waldur_api_client/models/patched_category_group_request_multipart.py +121 -0
  126. waldur_api_client/models/patched_checklist_category_request_form.py +102 -0
  127. waldur_api_client/models/patched_checklist_category_request_multipart.py +122 -0
  128. waldur_api_client/models/patched_customer_request.py +9 -0
  129. waldur_api_client/models/patched_customer_request_form.py +310 -0
  130. waldur_api_client/models/patched_customer_request_multipart.py +393 -0
  131. waldur_api_client/models/patched_external_link_request_form.py +110 -0
  132. waldur_api_client/models/patched_external_link_request_multipart.py +133 -0
  133. waldur_api_client/models/patched_marketplace_category_request_form.py +151 -0
  134. waldur_api_client/models/patched_marketplace_category_request_multipart.py +186 -0
  135. waldur_api_client/models/patched_payment_request_form.py +119 -0
  136. waldur_api_client/models/patched_payment_request_multipart.py +142 -0
  137. waldur_api_client/models/patched_project_request_form.py +279 -0
  138. waldur_api_client/models/patched_project_request_multipart.py +342 -0
  139. waldur_api_client/models/patched_service_provider_request_form.py +101 -0
  140. waldur_api_client/models/patched_service_provider_request_multipart.py +121 -0
  141. waldur_api_client/models/patched_user_request_form.py +241 -0
  142. waldur_api_client/models/patched_user_request_multipart.py +306 -0
  143. waldur_api_client/models/payment_request_form.py +113 -0
  144. waldur_api_client/models/payment_request_multipart.py +134 -0
  145. waldur_api_client/models/project_request_form.py +280 -0
  146. waldur_api_client/models/project_request_multipart.py +341 -0
  147. waldur_api_client/models/project_user.py +9 -0
  148. waldur_api_client/models/proposal.py +8 -0
  149. waldur_api_client/models/proposal_documentation_request_form.py +84 -0
  150. waldur_api_client/models/proposal_documentation_request_multipart.py +98 -0
  151. waldur_api_client/models/proposal_proposals_count_o_item.py +3 -1
  152. waldur_api_client/models/proposal_proposals_list_o_item.py +3 -1
  153. waldur_api_client/models/proposal_review.py +40 -0
  154. waldur_api_client/models/protected_proposal_list.py +8 -0
  155. waldur_api_client/models/protected_proposal_list_request.py +8 -0
  156. waldur_api_client/models/protected_round.py +8 -0
  157. waldur_api_client/models/provider_offering.py +21 -1
  158. waldur_api_client/models/provider_offering_details.py +20 -0
  159. waldur_api_client/models/public_offering_details.py +20 -0
  160. waldur_api_client/models/screenshot_request_form.py +87 -0
  161. waldur_api_client/models/screenshot_request_multipart.py +105 -0
  162. waldur_api_client/models/service_provider_request_form.py +112 -0
  163. waldur_api_client/models/service_provider_request_multipart.py +134 -0
  164. waldur_api_client/models/user_request_form.py +250 -0
  165. waldur_api_client/models/user_request_multipart.py +316 -0
  166. {waldur_api_client-7.8.1.dist-info → waldur_api_client-7.8.2.dist-info}/METADATA +1 -1
  167. {waldur_api_client-7.8.1.dist-info → waldur_api_client-7.8.2.dist-info}/RECORD +169 -98
  168. {waldur_api_client-7.8.1.dist-info → waldur_api_client-7.8.2.dist-info}/WHEEL +0 -0
  169. {waldur_api_client-7.8.1.dist-info → waldur_api_client-7.8.2.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,394 @@
1
+ from collections.abc import Mapping
2
+ from io import BytesIO
3
+ from typing import Any, TypeVar, Union, cast
4
+
5
+ from attrs import define as _attrs_define
6
+ from attrs import field as _attrs_field
7
+
8
+ from .. import types
9
+ from ..models.blank_enum import BlankEnum
10
+ from ..models.country_enum import CountryEnum
11
+ from ..types import UNSET, File, Unset
12
+
13
+ T = TypeVar("T", bound="CustomerRequestMultipart")
14
+
15
+
16
+ @_attrs_define
17
+ class CustomerRequestMultipart:
18
+ """
19
+ Attributes:
20
+ name (str):
21
+ backend_id (Union[Unset, str]): Organization identifier in another application.
22
+ image (Union[File, None, Unset]):
23
+ slug (Union[Unset, str]):
24
+ native_name (Union[Unset, str]):
25
+ abbreviation (Union[Unset, str]):
26
+ description (Union[Unset, str]):
27
+ contact_details (Union[Unset, str]):
28
+ email (Union[Unset, str]):
29
+ phone_number (Union[Unset, str]):
30
+ registration_code (Union[Unset, str]):
31
+ homepage (Union[Unset, str]):
32
+ vat_code (Union[Unset, str]): VAT number
33
+ postal (Union[Unset, str]):
34
+ address (Union[Unset, str]):
35
+ bank_name (Union[Unset, str]):
36
+ latitude (Union[None, Unset, float]):
37
+ longitude (Union[None, Unset, float]):
38
+ bank_account (Union[Unset, str]):
39
+ country (Union[BlankEnum, CountryEnum, Unset]):
40
+ notification_emails (Union[Unset, str]): Comma-separated list of notification email addresses
41
+ """
42
+
43
+ name: str
44
+ backend_id: Union[Unset, str] = UNSET
45
+ image: Union[File, None, Unset] = UNSET
46
+ slug: Union[Unset, str] = UNSET
47
+ native_name: Union[Unset, str] = UNSET
48
+ abbreviation: Union[Unset, str] = UNSET
49
+ description: Union[Unset, str] = UNSET
50
+ contact_details: Union[Unset, str] = UNSET
51
+ email: Union[Unset, str] = UNSET
52
+ phone_number: Union[Unset, str] = UNSET
53
+ registration_code: Union[Unset, str] = UNSET
54
+ homepage: Union[Unset, str] = UNSET
55
+ vat_code: Union[Unset, str] = UNSET
56
+ postal: Union[Unset, str] = UNSET
57
+ address: Union[Unset, str] = UNSET
58
+ bank_name: Union[Unset, str] = UNSET
59
+ latitude: Union[None, Unset, float] = UNSET
60
+ longitude: Union[None, Unset, float] = UNSET
61
+ bank_account: Union[Unset, str] = UNSET
62
+ country: Union[BlankEnum, CountryEnum, Unset] = UNSET
63
+ notification_emails: Union[Unset, str] = UNSET
64
+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
65
+
66
+ def to_dict(self) -> dict[str, Any]:
67
+ name = self.name
68
+
69
+ backend_id = self.backend_id
70
+
71
+ image: Union[None, Unset, types.FileTypes]
72
+ if isinstance(self.image, Unset):
73
+ image = UNSET
74
+ elif isinstance(self.image, File):
75
+ image = self.image.to_tuple()
76
+
77
+ else:
78
+ image = self.image
79
+
80
+ slug = self.slug
81
+
82
+ native_name = self.native_name
83
+
84
+ abbreviation = self.abbreviation
85
+
86
+ description = self.description
87
+
88
+ contact_details = self.contact_details
89
+
90
+ email = self.email
91
+
92
+ phone_number = self.phone_number
93
+
94
+ registration_code = self.registration_code
95
+
96
+ homepage = self.homepage
97
+
98
+ vat_code = self.vat_code
99
+
100
+ postal = self.postal
101
+
102
+ address = self.address
103
+
104
+ bank_name = self.bank_name
105
+
106
+ latitude: Union[None, Unset, float]
107
+ if isinstance(self.latitude, Unset):
108
+ latitude = UNSET
109
+ else:
110
+ latitude = self.latitude
111
+
112
+ longitude: Union[None, Unset, float]
113
+ if isinstance(self.longitude, Unset):
114
+ longitude = UNSET
115
+ else:
116
+ longitude = self.longitude
117
+
118
+ bank_account = self.bank_account
119
+
120
+ country: Union[Unset, str]
121
+ if isinstance(self.country, Unset):
122
+ country = UNSET
123
+ elif isinstance(self.country, CountryEnum):
124
+ country = self.country.value
125
+ else:
126
+ country = self.country.value
127
+
128
+ notification_emails = self.notification_emails
129
+
130
+ field_dict: dict[str, Any] = {}
131
+ field_dict.update(self.additional_properties)
132
+ field_dict.update(
133
+ {
134
+ "name": name,
135
+ }
136
+ )
137
+ if backend_id is not UNSET:
138
+ field_dict["backend_id"] = backend_id
139
+ if image is not UNSET:
140
+ field_dict["image"] = image
141
+ if slug is not UNSET:
142
+ field_dict["slug"] = slug
143
+ if native_name is not UNSET:
144
+ field_dict["native_name"] = native_name
145
+ if abbreviation is not UNSET:
146
+ field_dict["abbreviation"] = abbreviation
147
+ if description is not UNSET:
148
+ field_dict["description"] = description
149
+ if contact_details is not UNSET:
150
+ field_dict["contact_details"] = contact_details
151
+ if email is not UNSET:
152
+ field_dict["email"] = email
153
+ if phone_number is not UNSET:
154
+ field_dict["phone_number"] = phone_number
155
+ if registration_code is not UNSET:
156
+ field_dict["registration_code"] = registration_code
157
+ if homepage is not UNSET:
158
+ field_dict["homepage"] = homepage
159
+ if vat_code is not UNSET:
160
+ field_dict["vat_code"] = vat_code
161
+ if postal is not UNSET:
162
+ field_dict["postal"] = postal
163
+ if address is not UNSET:
164
+ field_dict["address"] = address
165
+ if bank_name is not UNSET:
166
+ field_dict["bank_name"] = bank_name
167
+ if latitude is not UNSET:
168
+ field_dict["latitude"] = latitude
169
+ if longitude is not UNSET:
170
+ field_dict["longitude"] = longitude
171
+ if bank_account is not UNSET:
172
+ field_dict["bank_account"] = bank_account
173
+ if country is not UNSET:
174
+ field_dict["country"] = country
175
+ if notification_emails is not UNSET:
176
+ field_dict["notification_emails"] = notification_emails
177
+
178
+ return field_dict
179
+
180
+ def to_multipart(self) -> types.RequestFiles:
181
+ files: types.RequestFiles = []
182
+
183
+ files.append(("name", (None, str(self.name).encode(), "text/plain")))
184
+
185
+ if not isinstance(self.backend_id, Unset):
186
+ files.append(("backend_id", (None, str(self.backend_id).encode(), "text/plain")))
187
+
188
+ if not isinstance(self.image, Unset):
189
+ if isinstance(self.image, File):
190
+ files.append(("image", self.image.to_tuple()))
191
+ else:
192
+ files.append(("image", (None, str(self.image).encode(), "text/plain")))
193
+
194
+ if not isinstance(self.slug, Unset):
195
+ files.append(("slug", (None, str(self.slug).encode(), "text/plain")))
196
+
197
+ if not isinstance(self.native_name, Unset):
198
+ files.append(("native_name", (None, str(self.native_name).encode(), "text/plain")))
199
+
200
+ if not isinstance(self.abbreviation, Unset):
201
+ files.append(("abbreviation", (None, str(self.abbreviation).encode(), "text/plain")))
202
+
203
+ if not isinstance(self.description, Unset):
204
+ files.append(("description", (None, str(self.description).encode(), "text/plain")))
205
+
206
+ if not isinstance(self.contact_details, Unset):
207
+ files.append(("contact_details", (None, str(self.contact_details).encode(), "text/plain")))
208
+
209
+ if not isinstance(self.email, Unset):
210
+ files.append(("email", (None, str(self.email).encode(), "text/plain")))
211
+
212
+ if not isinstance(self.phone_number, Unset):
213
+ files.append(("phone_number", (None, str(self.phone_number).encode(), "text/plain")))
214
+
215
+ if not isinstance(self.registration_code, Unset):
216
+ files.append(("registration_code", (None, str(self.registration_code).encode(), "text/plain")))
217
+
218
+ if not isinstance(self.homepage, Unset):
219
+ files.append(("homepage", (None, str(self.homepage).encode(), "text/plain")))
220
+
221
+ if not isinstance(self.vat_code, Unset):
222
+ files.append(("vat_code", (None, str(self.vat_code).encode(), "text/plain")))
223
+
224
+ if not isinstance(self.postal, Unset):
225
+ files.append(("postal", (None, str(self.postal).encode(), "text/plain")))
226
+
227
+ if not isinstance(self.address, Unset):
228
+ files.append(("address", (None, str(self.address).encode(), "text/plain")))
229
+
230
+ if not isinstance(self.bank_name, Unset):
231
+ files.append(("bank_name", (None, str(self.bank_name).encode(), "text/plain")))
232
+
233
+ if not isinstance(self.latitude, Unset):
234
+ if isinstance(self.latitude, float):
235
+ files.append(("latitude", (None, str(self.latitude).encode(), "text/plain")))
236
+ else:
237
+ files.append(("latitude", (None, str(self.latitude).encode(), "text/plain")))
238
+
239
+ if not isinstance(self.longitude, Unset):
240
+ if isinstance(self.longitude, float):
241
+ files.append(("longitude", (None, str(self.longitude).encode(), "text/plain")))
242
+ else:
243
+ files.append(("longitude", (None, str(self.longitude).encode(), "text/plain")))
244
+
245
+ if not isinstance(self.bank_account, Unset):
246
+ files.append(("bank_account", (None, str(self.bank_account).encode(), "text/plain")))
247
+
248
+ if not isinstance(self.country, Unset):
249
+ if isinstance(self.country, CountryEnum):
250
+ files.append(("country", (None, str(self.country.value).encode(), "text/plain")))
251
+ else:
252
+ files.append(("country", (None, str(self.country.value).encode(), "text/plain")))
253
+
254
+ if not isinstance(self.notification_emails, Unset):
255
+ files.append(("notification_emails", (None, str(self.notification_emails).encode(), "text/plain")))
256
+
257
+ for prop_name, prop in self.additional_properties.items():
258
+ files.append((prop_name, (None, str(prop).encode(), "text/plain")))
259
+
260
+ return files
261
+
262
+ @classmethod
263
+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
264
+ d = dict(src_dict)
265
+ name = d.pop("name")
266
+
267
+ backend_id = d.pop("backend_id", UNSET)
268
+
269
+ def _parse_image(data: object) -> Union[File, None, Unset]:
270
+ if data is None:
271
+ return data
272
+ if isinstance(data, Unset):
273
+ return data
274
+ try:
275
+ if not isinstance(data, bytes):
276
+ raise TypeError()
277
+ image_type_0 = File(payload=BytesIO(data))
278
+
279
+ return image_type_0
280
+ except: # noqa: E722
281
+ pass
282
+ return cast(Union[File, None, Unset], data)
283
+
284
+ image = _parse_image(d.pop("image", UNSET))
285
+
286
+ slug = d.pop("slug", UNSET)
287
+
288
+ native_name = d.pop("native_name", UNSET)
289
+
290
+ abbreviation = d.pop("abbreviation", UNSET)
291
+
292
+ description = d.pop("description", UNSET)
293
+
294
+ contact_details = d.pop("contact_details", UNSET)
295
+
296
+ email = d.pop("email", UNSET)
297
+
298
+ phone_number = d.pop("phone_number", UNSET)
299
+
300
+ registration_code = d.pop("registration_code", UNSET)
301
+
302
+ homepage = d.pop("homepage", UNSET)
303
+
304
+ vat_code = d.pop("vat_code", UNSET)
305
+
306
+ postal = d.pop("postal", UNSET)
307
+
308
+ address = d.pop("address", UNSET)
309
+
310
+ bank_name = d.pop("bank_name", UNSET)
311
+
312
+ def _parse_latitude(data: object) -> Union[None, Unset, float]:
313
+ if data is None:
314
+ return data
315
+ if isinstance(data, Unset):
316
+ return data
317
+ return cast(Union[None, Unset, float], data)
318
+
319
+ latitude = _parse_latitude(d.pop("latitude", UNSET))
320
+
321
+ def _parse_longitude(data: object) -> Union[None, Unset, float]:
322
+ if data is None:
323
+ return data
324
+ if isinstance(data, Unset):
325
+ return data
326
+ return cast(Union[None, Unset, float], data)
327
+
328
+ longitude = _parse_longitude(d.pop("longitude", UNSET))
329
+
330
+ bank_account = d.pop("bank_account", UNSET)
331
+
332
+ def _parse_country(data: object) -> Union[BlankEnum, CountryEnum, Unset]:
333
+ if isinstance(data, Unset):
334
+ return data
335
+ try:
336
+ if not isinstance(data, str):
337
+ raise TypeError()
338
+ country_type_0 = CountryEnum(data)
339
+
340
+ return country_type_0
341
+ except: # noqa: E722
342
+ pass
343
+ if not isinstance(data, str):
344
+ raise TypeError()
345
+ country_type_1 = BlankEnum(data)
346
+
347
+ return country_type_1
348
+
349
+ country = _parse_country(d.pop("country", UNSET))
350
+
351
+ notification_emails = d.pop("notification_emails", UNSET)
352
+
353
+ customer_request_multipart = cls(
354
+ name=name,
355
+ backend_id=backend_id,
356
+ image=image,
357
+ slug=slug,
358
+ native_name=native_name,
359
+ abbreviation=abbreviation,
360
+ description=description,
361
+ contact_details=contact_details,
362
+ email=email,
363
+ phone_number=phone_number,
364
+ registration_code=registration_code,
365
+ homepage=homepage,
366
+ vat_code=vat_code,
367
+ postal=postal,
368
+ address=address,
369
+ bank_name=bank_name,
370
+ latitude=latitude,
371
+ longitude=longitude,
372
+ bank_account=bank_account,
373
+ country=country,
374
+ notification_emails=notification_emails,
375
+ )
376
+
377
+ customer_request_multipart.additional_properties = d
378
+ return customer_request_multipart
379
+
380
+ @property
381
+ def additional_keys(self) -> list[str]:
382
+ return list(self.additional_properties.keys())
383
+
384
+ def __getitem__(self, key: str) -> Any:
385
+ return self.additional_properties[key]
386
+
387
+ def __setitem__(self, key: str, value: Any) -> None:
388
+ self.additional_properties[key] = value
389
+
390
+ def __delitem__(self, key: str) -> None:
391
+ del self.additional_properties[key]
392
+
393
+ def __contains__(self, key: str) -> bool:
394
+ return key in self.additional_properties
@@ -33,6 +33,7 @@ class CustomersListFieldItem(str, Enum):
33
33
  MAX_SERVICE_ACCOUNTS = "max_service_accounts"
34
34
  NAME = "name"
35
35
  NATIVE_NAME = "native_name"
36
+ NOTIFICATION_EMAILS = "notification_emails"
36
37
  ORGANIZATION_GROUPS = "organization_groups"
37
38
  PAYMENT_PROFILES = "payment_profiles"
38
39
  PHONE_NUMBER = "phone_number"
@@ -33,6 +33,7 @@ class CustomersRetrieveFieldItem(str, Enum):
33
33
  MAX_SERVICE_ACCOUNTS = "max_service_accounts"
34
34
  NAME = "name"
35
35
  NATIVE_NAME = "native_name"
36
+ NOTIFICATION_EMAILS = "notification_emails"
36
37
  ORGANIZATION_GROUPS = "organization_groups"
37
38
  PAYMENT_PROFILES = "payment_profiles"
38
39
  PHONE_NUMBER = "phone_number"
@@ -0,0 +1,111 @@
1
+ from collections.abc import Mapping
2
+ from io import BytesIO
3
+ from typing import Any, TypeVar, Union, cast
4
+
5
+ from attrs import define as _attrs_define
6
+ from attrs import field as _attrs_field
7
+
8
+ from .. import types
9
+ from ..types import UNSET, File, Unset
10
+
11
+ T = TypeVar("T", bound="ExternalLinkRequestForm")
12
+
13
+
14
+ @_attrs_define
15
+ class ExternalLinkRequestForm:
16
+ """
17
+ Attributes:
18
+ name (str):
19
+ link (str):
20
+ description (Union[Unset, str]):
21
+ image (Union[File, None, Unset]):
22
+ """
23
+
24
+ name: str
25
+ link: str
26
+ description: Union[Unset, str] = UNSET
27
+ image: Union[File, None, Unset] = UNSET
28
+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
29
+
30
+ def to_dict(self) -> dict[str, Any]:
31
+ name = self.name
32
+
33
+ link = self.link
34
+
35
+ description = self.description
36
+
37
+ image: Union[None, Unset, types.FileTypes]
38
+ if isinstance(self.image, Unset):
39
+ image = UNSET
40
+ elif isinstance(self.image, File):
41
+ image = self.image.to_tuple()
42
+
43
+ else:
44
+ image = self.image
45
+
46
+ field_dict: dict[str, Any] = {}
47
+ field_dict.update(self.additional_properties)
48
+ field_dict.update(
49
+ {
50
+ "name": name,
51
+ "link": link,
52
+ }
53
+ )
54
+ if description is not UNSET:
55
+ field_dict["description"] = description
56
+ if image is not UNSET:
57
+ field_dict["image"] = image
58
+
59
+ return field_dict
60
+
61
+ @classmethod
62
+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
63
+ d = dict(src_dict)
64
+ name = d.pop("name")
65
+
66
+ link = d.pop("link")
67
+
68
+ description = d.pop("description", UNSET)
69
+
70
+ def _parse_image(data: object) -> Union[File, None, Unset]:
71
+ if data is None:
72
+ return data
73
+ if isinstance(data, Unset):
74
+ return data
75
+ try:
76
+ if not isinstance(data, bytes):
77
+ raise TypeError()
78
+ image_type_0 = File(payload=BytesIO(data))
79
+
80
+ return image_type_0
81
+ except: # noqa: E722
82
+ pass
83
+ return cast(Union[File, None, Unset], data)
84
+
85
+ image = _parse_image(d.pop("image", UNSET))
86
+
87
+ external_link_request_form = cls(
88
+ name=name,
89
+ link=link,
90
+ description=description,
91
+ image=image,
92
+ )
93
+
94
+ external_link_request_form.additional_properties = d
95
+ return external_link_request_form
96
+
97
+ @property
98
+ def additional_keys(self) -> list[str]:
99
+ return list(self.additional_properties.keys())
100
+
101
+ def __getitem__(self, key: str) -> Any:
102
+ return self.additional_properties[key]
103
+
104
+ def __setitem__(self, key: str, value: Any) -> None:
105
+ self.additional_properties[key] = value
106
+
107
+ def __delitem__(self, key: str) -> None:
108
+ del self.additional_properties[key]
109
+
110
+ def __contains__(self, key: str) -> bool:
111
+ return key in self.additional_properties
@@ -0,0 +1,132 @@
1
+ from collections.abc import Mapping
2
+ from io import BytesIO
3
+ from typing import Any, TypeVar, Union, cast
4
+
5
+ from attrs import define as _attrs_define
6
+ from attrs import field as _attrs_field
7
+
8
+ from .. import types
9
+ from ..types import UNSET, File, Unset
10
+
11
+ T = TypeVar("T", bound="ExternalLinkRequestMultipart")
12
+
13
+
14
+ @_attrs_define
15
+ class ExternalLinkRequestMultipart:
16
+ """
17
+ Attributes:
18
+ name (str):
19
+ link (str):
20
+ description (Union[Unset, str]):
21
+ image (Union[File, None, Unset]):
22
+ """
23
+
24
+ name: str
25
+ link: str
26
+ description: Union[Unset, str] = UNSET
27
+ image: Union[File, None, Unset] = UNSET
28
+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
29
+
30
+ def to_dict(self) -> dict[str, Any]:
31
+ name = self.name
32
+
33
+ link = self.link
34
+
35
+ description = self.description
36
+
37
+ image: Union[None, Unset, types.FileTypes]
38
+ if isinstance(self.image, Unset):
39
+ image = UNSET
40
+ elif isinstance(self.image, File):
41
+ image = self.image.to_tuple()
42
+
43
+ else:
44
+ image = self.image
45
+
46
+ field_dict: dict[str, Any] = {}
47
+ field_dict.update(self.additional_properties)
48
+ field_dict.update(
49
+ {
50
+ "name": name,
51
+ "link": link,
52
+ }
53
+ )
54
+ if description is not UNSET:
55
+ field_dict["description"] = description
56
+ if image is not UNSET:
57
+ field_dict["image"] = image
58
+
59
+ return field_dict
60
+
61
+ def to_multipart(self) -> types.RequestFiles:
62
+ files: types.RequestFiles = []
63
+
64
+ files.append(("name", (None, str(self.name).encode(), "text/plain")))
65
+
66
+ files.append(("link", (None, str(self.link).encode(), "text/plain")))
67
+
68
+ if not isinstance(self.description, Unset):
69
+ files.append(("description", (None, str(self.description).encode(), "text/plain")))
70
+
71
+ if not isinstance(self.image, Unset):
72
+ if isinstance(self.image, File):
73
+ files.append(("image", self.image.to_tuple()))
74
+ else:
75
+ files.append(("image", (None, str(self.image).encode(), "text/plain")))
76
+
77
+ for prop_name, prop in self.additional_properties.items():
78
+ files.append((prop_name, (None, str(prop).encode(), "text/plain")))
79
+
80
+ return files
81
+
82
+ @classmethod
83
+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
84
+ d = dict(src_dict)
85
+ name = d.pop("name")
86
+
87
+ link = d.pop("link")
88
+
89
+ description = d.pop("description", UNSET)
90
+
91
+ def _parse_image(data: object) -> Union[File, None, Unset]:
92
+ if data is None:
93
+ return data
94
+ if isinstance(data, Unset):
95
+ return data
96
+ try:
97
+ if not isinstance(data, bytes):
98
+ raise TypeError()
99
+ image_type_0 = File(payload=BytesIO(data))
100
+
101
+ return image_type_0
102
+ except: # noqa: E722
103
+ pass
104
+ return cast(Union[File, None, Unset], data)
105
+
106
+ image = _parse_image(d.pop("image", UNSET))
107
+
108
+ external_link_request_multipart = cls(
109
+ name=name,
110
+ link=link,
111
+ description=description,
112
+ image=image,
113
+ )
114
+
115
+ external_link_request_multipart.additional_properties = d
116
+ return external_link_request_multipart
117
+
118
+ @property
119
+ def additional_keys(self) -> list[str]:
120
+ return list(self.additional_properties.keys())
121
+
122
+ def __getitem__(self, key: str) -> Any:
123
+ return self.additional_properties[key]
124
+
125
+ def __setitem__(self, key: str, value: Any) -> None:
126
+ self.additional_properties[key] = value
127
+
128
+ def __delitem__(self, key: str) -> None:
129
+ del self.additional_properties[key]
130
+
131
+ def __contains__(self, key: str) -> bool:
132
+ return key in self.additional_properties