shopware-api-client 1.0.118__py3-none-any.whl → 1.1.1__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 (290) hide show
  1. shopware_api_client/base.py +338 -176
  2. shopware_api_client/cache.py +5 -10
  3. shopware_api_client/endpoints/admin/__init__.py +11 -4
  4. shopware_api_client/endpoints/admin/commercial/b2b_components_role.py +5 -20
  5. shopware_api_client/endpoints/admin/commercial/b2b_components_shopping_list.py +5 -25
  6. shopware_api_client/endpoints/admin/commercial/b2b_components_shopping_list_line_item.py +7 -24
  7. shopware_api_client/endpoints/admin/commercial/b2b_employee.py +5 -27
  8. shopware_api_client/endpoints/admin/commercial/dynamic_access.py +9 -19
  9. shopware_api_client/endpoints/admin/core/acl_role.py +5 -19
  10. shopware_api_client/endpoints/admin/core/api_info.py +11 -12
  11. shopware_api_client/endpoints/admin/core/app.py +5 -42
  12. shopware_api_client/endpoints/admin/core/app_script_condition.py +5 -24
  13. shopware_api_client/endpoints/admin/core/category.py +5 -56
  14. shopware_api_client/endpoints/admin/core/cms_block.py +5 -34
  15. shopware_api_client/endpoints/admin/core/cms_page.py +5 -26
  16. shopware_api_client/endpoints/admin/core/cms_section.py +5 -35
  17. shopware_api_client/endpoints/admin/core/cms_slot.py +5 -31
  18. shopware_api_client/endpoints/admin/core/country.py +5 -37
  19. shopware_api_client/endpoints/admin/core/country_state.py +5 -23
  20. shopware_api_client/endpoints/admin/core/currency.py +5 -33
  21. shopware_api_client/endpoints/admin/core/currency_country_rounding.py +5 -20
  22. shopware_api_client/endpoints/admin/core/custom_entity.py +4 -26
  23. shopware_api_client/endpoints/admin/core/custom_field.py +4 -14
  24. shopware_api_client/endpoints/admin/core/customer.py +5 -57
  25. shopware_api_client/endpoints/admin/core/customer_address.py +6 -33
  26. shopware_api_client/endpoints/admin/core/customer_group.py +5 -24
  27. shopware_api_client/endpoints/admin/core/customer_recovery.py +5 -16
  28. shopware_api_client/endpoints/admin/core/customer_wishlist.py +5 -19
  29. shopware_api_client/endpoints/admin/core/customer_wishlist_product.py +5 -19
  30. shopware_api_client/endpoints/admin/core/delivery_time.py +5 -21
  31. shopware_api_client/endpoints/admin/core/document.py +5 -28
  32. shopware_api_client/endpoints/admin/core/document_base_config.py +5 -27
  33. shopware_api_client/endpoints/admin/core/document_base_config_sales_channel.py +7 -20
  34. shopware_api_client/endpoints/admin/core/document_type.py +5 -19
  35. shopware_api_client/endpoints/admin/core/integration.py +5 -25
  36. shopware_api_client/endpoints/admin/core/landing_page.py +5 -28
  37. shopware_api_client/endpoints/admin/core/language.py +5 -21
  38. shopware_api_client/endpoints/admin/core/locale.py +5 -20
  39. shopware_api_client/endpoints/admin/core/main_category.py +5 -19
  40. shopware_api_client/endpoints/admin/core/media.py +25 -37
  41. shopware_api_client/endpoints/admin/core/media_default_folder.py +4 -17
  42. shopware_api_client/endpoints/admin/core/media_folder.py +5 -26
  43. shopware_api_client/endpoints/admin/core/media_folder_configuration.py +5 -21
  44. shopware_api_client/endpoints/admin/core/media_thumbnail.py +5 -26
  45. shopware_api_client/endpoints/admin/core/media_thumbnail_size.py +7 -18
  46. shopware_api_client/endpoints/admin/core/order.py +12 -48
  47. shopware_api_client/endpoints/admin/core/order_address.py +6 -34
  48. shopware_api_client/endpoints/admin/core/order_customer.py +6 -29
  49. shopware_api_client/endpoints/admin/core/order_delivery.py +5 -30
  50. shopware_api_client/endpoints/admin/core/order_delivery_position.py +5 -26
  51. shopware_api_client/endpoints/admin/core/order_line_item.py +7 -44
  52. shopware_api_client/endpoints/admin/core/order_line_item_download.py +5 -23
  53. shopware_api_client/endpoints/admin/core/order_transaction.py +5 -25
  54. shopware_api_client/endpoints/admin/core/order_transaction_capture.py +5 -27
  55. shopware_api_client/endpoints/admin/core/order_transaction_capture_refund.py +7 -28
  56. shopware_api_client/endpoints/admin/core/order_transaction_capture_refund_position.py +8 -29
  57. shopware_api_client/endpoints/admin/core/payment_method.py +5 -52
  58. shopware_api_client/endpoints/admin/core/product.py +24 -90
  59. shopware_api_client/endpoints/admin/core/product_configurator_setting.py +5 -26
  60. shopware_api_client/endpoints/admin/core/product_cross_selling.py +5 -27
  61. shopware_api_client/endpoints/admin/core/product_cross_selling_assigned_products.py +7 -21
  62. shopware_api_client/endpoints/admin/core/product_download.py +5 -22
  63. shopware_api_client/endpoints/admin/core/product_export.py +5 -34
  64. shopware_api_client/endpoints/admin/core/product_feature_set.py +5 -19
  65. shopware_api_client/endpoints/admin/core/product_manufacturer.py +5 -23
  66. shopware_api_client/endpoints/admin/core/product_media.py +5 -22
  67. shopware_api_client/endpoints/admin/core/product_price.py +5 -24
  68. shopware_api_client/endpoints/admin/core/product_review.py +5 -29
  69. shopware_api_client/endpoints/admin/core/product_search_keyword.py +5 -20
  70. shopware_api_client/endpoints/admin/core/product_stream.py +5 -23
  71. shopware_api_client/endpoints/admin/core/product_visibility.py +5 -18
  72. shopware_api_client/endpoints/admin/core/product_warehouse.py +5 -17
  73. shopware_api_client/endpoints/admin/core/promotion.py +5 -38
  74. shopware_api_client/endpoints/admin/core/promotion_discount.py +5 -24
  75. shopware_api_client/endpoints/admin/core/promotion_discount_prices.py +5 -19
  76. shopware_api_client/endpoints/admin/core/property_group.py +5 -24
  77. shopware_api_client/endpoints/admin/core/property_group_option.py +5 -23
  78. shopware_api_client/endpoints/admin/core/rule.py +5 -24
  79. shopware_api_client/endpoints/admin/core/rule_condition.py +5 -23
  80. shopware_api_client/endpoints/admin/core/sales_channel.py +6 -53
  81. shopware_api_client/endpoints/admin/core/sales_channel_domain.py +5 -23
  82. shopware_api_client/endpoints/admin/core/salutation.py +5 -20
  83. shopware_api_client/endpoints/admin/core/seo_url.py +5 -30
  84. shopware_api_client/endpoints/admin/core/shipping_method.py +8 -30
  85. shopware_api_client/endpoints/admin/core/shipping_method_price.py +20 -0
  86. shopware_api_client/endpoints/admin/core/state_machine.py +5 -21
  87. shopware_api_client/endpoints/admin/core/state_machine_history.py +5 -25
  88. shopware_api_client/endpoints/admin/core/state_machine_state.py +6 -20
  89. shopware_api_client/endpoints/admin/core/state_machine_transition.py +5 -23
  90. shopware_api_client/endpoints/admin/core/system_config.py +5 -19
  91. shopware_api_client/endpoints/admin/core/tag.py +5 -14
  92. shopware_api_client/endpoints/admin/core/tax.py +5 -21
  93. shopware_api_client/endpoints/admin/core/tax_rule.py +5 -22
  94. shopware_api_client/endpoints/admin/core/tax_rule_type.py +5 -21
  95. shopware_api_client/endpoints/admin/core/unit.py +5 -19
  96. shopware_api_client/endpoints/admin/core/user.py +5 -31
  97. shopware_api_client/endpoints/admin/core/warehouse.py +5 -15
  98. shopware_api_client/endpoints/admin/core/warehouse_group.py +6 -18
  99. shopware_api_client/endpoints/admin/core/warehouse_group_warehouse.py +6 -18
  100. shopware_api_client/endpoints/base_fields.py +13 -22
  101. shopware_api_client/endpoints/relations.py +36 -24
  102. shopware_api_client/endpoints/store/__init__.py +37 -4
  103. shopware_api_client/endpoints/store/core/address.py +51 -68
  104. shopware_api_client/endpoints/store/core/cart.py +39 -85
  105. shopware_api_client/endpoints/store/core/category.py +16 -0
  106. shopware_api_client/endpoints/store/core/cms_block.py +10 -0
  107. shopware_api_client/endpoints/store/core/cms_page.py +12 -0
  108. shopware_api_client/endpoints/store/core/cms_section.py +12 -0
  109. shopware_api_client/endpoints/store/core/cms_slot.py +8 -0
  110. shopware_api_client/endpoints/store/core/context.py +58 -0
  111. shopware_api_client/endpoints/store/core/country.py +15 -0
  112. shopware_api_client/endpoints/store/core/country_state.py +19 -0
  113. shopware_api_client/endpoints/store/core/currency.py +12 -0
  114. shopware_api_client/endpoints/store/core/customer.py +34 -0
  115. shopware_api_client/endpoints/store/core/customer_group.py +5 -0
  116. shopware_api_client/endpoints/store/core/delivery_time.py +5 -0
  117. shopware_api_client/endpoints/store/core/document.py +15 -0
  118. shopware_api_client/endpoints/store/core/document_type.py +5 -0
  119. shopware_api_client/endpoints/store/core/landing_page.py +10 -0
  120. shopware_api_client/endpoints/store/core/language.py +18 -0
  121. shopware_api_client/endpoints/store/core/locale.py +5 -0
  122. shopware_api_client/endpoints/store/core/main_category.py +5 -0
  123. shopware_api_client/endpoints/store/core/media.py +8 -0
  124. shopware_api_client/endpoints/store/core/media_thumbnail.py +5 -0
  125. shopware_api_client/endpoints/store/core/order.py +67 -0
  126. shopware_api_client/endpoints/store/core/order_address.py +12 -0
  127. shopware_api_client/endpoints/store/core/order_customer.py +8 -0
  128. shopware_api_client/endpoints/store/core/order_delivery.py +14 -0
  129. shopware_api_client/endpoints/store/core/order_delivery_position.py +5 -0
  130. shopware_api_client/endpoints/store/core/order_line_item.py +14 -0
  131. shopware_api_client/endpoints/store/core/order_transaction.py +12 -0
  132. shopware_api_client/endpoints/store/core/order_transaction_capture.py +12 -0
  133. shopware_api_client/endpoints/store/core/order_transaction_capture_refund.py +12 -0
  134. shopware_api_client/endpoints/store/core/order_transaction_capture_refund_position.py +11 -0
  135. shopware_api_client/endpoints/store/core/payment_method.py +8 -0
  136. shopware_api_client/endpoints/store/core/product.py +60 -0
  137. shopware_api_client/endpoints/store/core/product_configurator_setting.py +10 -0
  138. shopware_api_client/endpoints/store/core/product_cross_selling.py +5 -0
  139. shopware_api_client/endpoints/store/core/product_download.py +10 -0
  140. shopware_api_client/endpoints/store/core/product_manufacturer.py +8 -0
  141. shopware_api_client/endpoints/store/core/product_media.py +10 -0
  142. shopware_api_client/endpoints/store/core/product_review.py +5 -0
  143. shopware_api_client/endpoints/store/core/product_stream.py +5 -0
  144. shopware_api_client/endpoints/store/core/property_group.py +8 -0
  145. shopware_api_client/endpoints/store/core/property_group_option.py +10 -0
  146. shopware_api_client/endpoints/store/core/rule.py +5 -0
  147. shopware_api_client/endpoints/store/core/sales_channel.py +23 -0
  148. shopware_api_client/endpoints/store/core/sales_channel_domain.py +12 -0
  149. shopware_api_client/endpoints/store/core/salutation.py +12 -0
  150. shopware_api_client/endpoints/store/core/seo_url.py +5 -0
  151. shopware_api_client/endpoints/store/core/shipping_method.py +18 -0
  152. shopware_api_client/endpoints/store/core/shipping_method_price.py +5 -0
  153. shopware_api_client/endpoints/store/core/state_machine_state.py +5 -0
  154. shopware_api_client/endpoints/store/core/tag.py +5 -0
  155. shopware_api_client/endpoints/store/core/tax.py +5 -0
  156. shopware_api_client/endpoints/store/core/unit.py +5 -0
  157. shopware_api_client/exceptions.py +4 -0
  158. shopware_api_client/fieldsets.py +12 -0
  159. shopware_api_client/models/__init__.py +0 -0
  160. shopware_api_client/models/acl_role.py +11 -0
  161. shopware_api_client/models/app.py +33 -0
  162. shopware_api_client/models/app_script_condition.py +16 -0
  163. shopware_api_client/models/b2b_components_role.py +12 -0
  164. shopware_api_client/models/b2b_components_shopping_list.py +13 -0
  165. shopware_api_client/models/b2b_components_shopping_list_line_item.py +14 -0
  166. shopware_api_client/models/b2b_employee.py +17 -0
  167. shopware_api_client/models/category.py +44 -0
  168. shopware_api_client/models/cms_block.py +23 -0
  169. shopware_api_client/models/cms_page.py +15 -0
  170. shopware_api_client/models/cms_section.py +20 -0
  171. shopware_api_client/models/cms_slot.py +17 -0
  172. shopware_api_client/models/country.py +27 -0
  173. shopware_api_client/models/country_state.py +12 -0
  174. shopware_api_client/models/currency.py +20 -0
  175. shopware_api_client/models/currency_country_rounding.py +11 -0
  176. shopware_api_client/models/custom_entity.py +19 -0
  177. shopware_api_client/models/custom_field.py +8 -0
  178. shopware_api_client/models/customer.py +47 -0
  179. shopware_api_client/models/customer_address.py +22 -0
  180. shopware_api_client/models/customer_group.py +13 -0
  181. shopware_api_client/models/customer_recovery.py +9 -0
  182. shopware_api_client/models/customer_wishlist.py +9 -0
  183. shopware_api_client/models/customer_wishlist_product.py +10 -0
  184. shopware_api_client/models/delivery_time.py +12 -0
  185. shopware_api_client/models/document.py +20 -0
  186. shopware_api_client/models/document_base_config.py +19 -0
  187. shopware_api_client/models/document_base_config_sales_channel.py +10 -0
  188. shopware_api_client/models/document_type.py +8 -0
  189. shopware_api_client/models/dynamic_access.py +9 -0
  190. shopware_api_client/models/integration.py +15 -0
  191. shopware_api_client/models/landing_page.py +15 -0
  192. shopware_api_client/models/language.py +11 -0
  193. shopware_api_client/models/locale.py +9 -0
  194. shopware_api_client/models/main_category.py +12 -0
  195. shopware_api_client/models/media.py +26 -0
  196. shopware_api_client/models/media_default_folder.py +7 -0
  197. shopware_api_client/models/media_folder.py +16 -0
  198. shopware_api_client/models/media_folder_configuration.py +11 -0
  199. shopware_api_client/models/media_thumbnail.py +15 -0
  200. shopware_api_client/models/media_thumbnail_size.py +8 -0
  201. shopware_api_client/models/order.py +36 -0
  202. shopware_api_client/models/order_address.py +23 -0
  203. shopware_api_client/models/order_customer.py +18 -0
  204. shopware_api_client/models/order_delivery.py +19 -0
  205. shopware_api_client/models/order_delivery_position.py +15 -0
  206. shopware_api_client/models/order_line_item.py +34 -0
  207. shopware_api_client/models/order_line_item_download.py +12 -0
  208. shopware_api_client/models/order_transaction.py +15 -0
  209. shopware_api_client/models/order_transaction_capture.py +15 -0
  210. shopware_api_client/models/order_transaction_capture_refund.py +16 -0
  211. shopware_api_client/models/order_transaction_capture_refund_position.py +15 -0
  212. shopware_api_client/models/payment_method.py +29 -0
  213. shopware_api_client/models/product.py +72 -0
  214. shopware_api_client/models/product_configurator_setting.py +14 -0
  215. shopware_api_client/models/product_cross_selling.py +17 -0
  216. shopware_api_client/models/product_cross_selling_assigned_products.py +11 -0
  217. shopware_api_client/models/product_download.py +11 -0
  218. shopware_api_client/models/product_export.py +27 -0
  219. shopware_api_client/models/product_feature_set.py +11 -0
  220. shopware_api_client/models/product_manufacturer.py +11 -0
  221. shopware_api_client/models/product_media.py +11 -0
  222. shopware_api_client/models/product_price.py +15 -0
  223. shopware_api_client/models/product_review.py +19 -0
  224. shopware_api_client/models/product_search_keyword.py +13 -0
  225. shopware_api_client/models/product_stream.py +14 -0
  226. shopware_api_client/models/product_visibility.py +11 -0
  227. shopware_api_client/models/product_warehouse.py +10 -0
  228. shopware_api_client/models/promotion.py +29 -0
  229. shopware_api_client/models/promotion_discount.py +17 -0
  230. shopware_api_client/models/promotion_discount_prices.py +10 -0
  231. shopware_api_client/models/property_group.py +13 -0
  232. shopware_api_client/models/property_group_option.py +12 -0
  233. shopware_api_client/models/rule.py +16 -0
  234. shopware_api_client/models/rule_condition.py +15 -0
  235. shopware_api_client/models/sales_channel.py +44 -0
  236. shopware_api_client/models/sales_channel_domain.py +13 -0
  237. shopware_api_client/models/salutation.py +9 -0
  238. shopware_api_client/models/seo_url.py +19 -0
  239. shopware_api_client/models/shipping_method.py +18 -0
  240. shopware_api_client/models/shipping_method_price.py +15 -0
  241. shopware_api_client/models/state_machine.py +10 -0
  242. shopware_api_client/models/state_machine_history.py +18 -0
  243. shopware_api_client/models/state_machine_state.py +8 -0
  244. shopware_api_client/models/state_machine_transition.py +11 -0
  245. shopware_api_client/models/system_config.py +12 -0
  246. shopware_api_client/models/tag.py +7 -0
  247. shopware_api_client/models/tax.py +9 -0
  248. shopware_api_client/models/tax_rule.py +15 -0
  249. shopware_api_client/models/tax_rule_type.py +11 -0
  250. shopware_api_client/models/unit.py +8 -0
  251. shopware_api_client/models/user.py +21 -0
  252. shopware_api_client/models/warehouse.py +8 -0
  253. shopware_api_client/models/warehouse_group.py +11 -0
  254. shopware_api_client/models/warehouse_group_warehouse.py +11 -0
  255. shopware_api_client/structs/__init__.py +0 -0
  256. shopware_api_client/structs/absolute_price_definition.py +6 -0
  257. shopware_api_client/structs/calculated_cheapest_price.py +6 -0
  258. shopware_api_client/structs/calculated_price.py +17 -0
  259. shopware_api_client/structs/calculated_tax.py +8 -0
  260. shopware_api_client/structs/cart.py +21 -0
  261. shopware_api_client/structs/cart_price.py +15 -0
  262. shopware_api_client/structs/cash_rounding_config.py +7 -0
  263. shopware_api_client/structs/context.py +15 -0
  264. shopware_api_client/structs/delivery.py +16 -0
  265. shopware_api_client/structs/delivery_date.py +8 -0
  266. shopware_api_client/structs/delivery_information.py +13 -0
  267. shopware_api_client/structs/delivery_position.py +12 -0
  268. shopware_api_client/structs/delivery_time.py +8 -0
  269. shopware_api_client/structs/language_info.py +6 -0
  270. shopware_api_client/structs/line_item.py +39 -0
  271. shopware_api_client/structs/list_price.py +7 -0
  272. shopware_api_client/structs/measurement_units.py +8 -0
  273. shopware_api_client/structs/percentage_price_definition.py +6 -0
  274. shopware_api_client/structs/price.py +14 -0
  275. shopware_api_client/structs/quantity_information.py +7 -0
  276. shopware_api_client/structs/quantity_price_definition.py +14 -0
  277. shopware_api_client/structs/reference_price.py +5 -0
  278. shopware_api_client/structs/reference_price_definition.py +7 -0
  279. shopware_api_client/structs/regulation_price.py +5 -0
  280. shopware_api_client/structs/sales_channel_context.py +33 -0
  281. shopware_api_client/structs/shipping_location.py +12 -0
  282. shopware_api_client/structs/tax_free_config.py +8 -0
  283. shopware_api_client/structs/tax_rule.py +6 -0
  284. shopware_api_client/structs/transaction.py +8 -0
  285. shopware_api_client/structs/variant_listing_config.py +8 -0
  286. {shopware_api_client-1.0.118.dist-info → shopware_api_client-1.1.1.dist-info}/METADATA +45 -273
  287. shopware_api_client-1.1.1.dist-info/RECORD +298 -0
  288. shopware_api_client-1.0.118.dist-info/RECORD +0 -117
  289. {shopware_api_client-1.0.118.dist-info → shopware_api_client-1.1.1.dist-info}/WHEEL +0 -0
  290. {shopware_api_client-1.0.118.dist-info → shopware_api_client-1.1.1.dist-info}/licenses/LICENSE +0 -0
@@ -1,45 +1,15 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ForeignRelation, ManyRelation
3
+ from shopware_api_client.models.cms_section import CmsSectionBase
2
4
 
3
- from pydantic import AliasChoices, Field
4
5
 
5
- from ....base import ApiModelBase, EndpointBase, EndpointClass
6
- from ...base_fields import IdField, Visibility
7
- from ...relations import ForeignRelation, ManyRelation
8
-
9
-
10
- class CmsSectionBase(ApiModelBase[EndpointClass]):
11
- _identifier: str = "cms_section"
12
-
13
- position: int
14
- type: str
15
- locked: bool | None = None
16
- name: str | None = None
17
- sizing_mode: str | None = Field(
18
- default=None, serialization_alias="sizingMode", validation_alias=AliasChoices("sizing_mode", "sizingMode")
19
- )
20
- mobile_behavior: str | None = None
21
- background_color: str | None = None
22
- background_media_id: IdField | None = None
23
- background_media_mode: str | None = None
24
- css_class: str | None = None
25
- page_id: IdField
26
- visibility: Visibility | None = None
27
- custom_fields: dict[str, Any] | None = None
28
- version_id: IdField | None = None
29
- cms_page_version_id: IdField | None = None
30
-
31
-
32
- class CmsSectionRelations:
6
+ class CmsSection(CmsSectionBase, AdminModel["CmsSectionEndpoint"]):
33
7
  page: ForeignRelation["CmsPage"]
34
8
  background_media: ForeignRelation["Media"]
35
9
  blocks: ManyRelation["CmsBlock"]
36
10
 
37
11
 
38
- class CmsSection(CmsSectionBase["CmsSectionEndpoint"], CmsSectionRelations):
39
- pass
40
-
41
-
42
- class CmsSectionEndpoint(EndpointBase[CmsSection]):
12
+ class CmsSectionEndpoint(AdminEndpoint[CmsSection]):
43
13
  name = "cms_section"
44
14
  path = "/cms-section"
45
15
  model_class = CmsSection
@@ -1,39 +1,13 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ForeignRelation
3
+ from shopware_api_client.models.cms_slot import CmsSlotBase
2
4
 
3
- from pydantic import AliasChoices, Field
4
5
 
5
- from ....base import ApiModelBase, EndpointBase, EndpointClass
6
- from ...base_fields import IdField
7
- from ...relations import ForeignRelation
8
-
9
-
10
- class CmsSlotBase(ApiModelBase[EndpointClass]):
11
- _identifier: str = "cms_slot"
12
-
13
- version_id: IdField | None = Field(
14
- default=None, serialization_alias="versionId", validation_alias=AliasChoices("version_id", "versionId")
15
- )
16
- type: str
17
- slot: str
18
- locked: bool | None = None
19
- config: dict[str, Any] | None = None
20
- custom_fields: dict[str, Any] | None = None
21
- data: dict[str, Any] | None = Field(default=None, exclude=True)
22
- block_id: IdField
23
- field_config: dict[str, Any] | None = None
24
- cms_block_version_id: IdField | None = None
25
- translated: dict[str, Any] | None = None
26
-
27
-
28
- class CmsSlotRelations:
6
+ class CmsSlot(CmsSlotBase, AdminModel["CmsSlotEndpoint"]):
29
7
  block: ForeignRelation["CmsBlock"]
30
8
 
31
9
 
32
- class CmsSlot(CmsSlotBase["CmsSlotEndpoint"], CmsSlotRelations):
33
- pass
34
-
35
-
36
- class CmsSlotEndpoint(EndpointBase[CmsSlot]):
10
+ class CmsSlotEndpoint(AdminEndpoint[CmsSlot]):
37
11
  name = "cms_slot"
38
12
  path = "/cms-slot"
39
13
  model_class = CmsSlot
@@ -1,37 +1,9 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ManyRelation
3
+ from shopware_api_client.models.country import CountryBase
2
4
 
3
- from ....base import ApiModelBase, EndpointBase, EndpointClass
4
- from ...base_fields import CompanyTax, CustomerTax
5
- from ...relations import ManyRelation
6
5
 
7
-
8
- class CountryBase(ApiModelBase[EndpointClass]):
9
- _identifier: str = "country"
10
-
11
- name: str
12
- iso: str | None = None
13
- position: int | None = None
14
- active: bool | None = None
15
- shipping_available: bool | None = None
16
- iso3: str | None = None
17
- display_state_in_registration: bool | None = None
18
- force_state_in_registration: bool | None = None
19
- check_vat_id_pattern: bool | None = None
20
- vat_id_required: bool | None = None
21
- vat_id_pattern: str | None = None
22
- custom_fields: dict[str, Any] | None = None
23
- customer_tax: CustomerTax | None = None
24
- company_tax: CompanyTax | None = None
25
- postal_code_required: bool | None = None
26
- check_postal_code_pattern: bool | None = None
27
- check_advanced_postal_code_pattern: bool | None = None
28
- advanced_postal_code_pattern: str | None = None
29
- address_format: dict[str, Any] | list[Any]
30
- default_postal_code_pattern: str | None = None
31
- translated: dict[str, Any] | None = None
32
-
33
-
34
- class CountryRelations:
6
+ class Country(CountryBase, AdminModel["CountryEndpoint"]):
35
7
  states: ManyRelation["CountryState"]
36
8
  customer_addresses: ManyRelation["CustomerAddress"]
37
9
  order_addresses: ManyRelation["OrderAddress"]
@@ -41,11 +13,7 @@ class CountryRelations:
41
13
  currency_country_roundings: ManyRelation["CurrencyCountryRounding"]
42
14
 
43
15
 
44
- class Country(CountryBase["CountryEndpoint"], CountryRelations):
45
- pass
46
-
47
-
48
- class CountryEndpoint(EndpointBase[Country]):
16
+ class CountryEndpoint(AdminEndpoint[Country]):
49
17
  name = "country"
50
18
  path = "/country"
51
19
  model_class = Country
@@ -1,33 +1,15 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ForeignRelation, ManyRelation
3
+ from shopware_api_client.models.country_state import CountryStateBase
2
4
 
3
- from ....base import ApiModelBase, EndpointBase, EndpointClass
4
- from ...base_fields import IdField
5
- from ...relations import ForeignRelation, ManyRelation
6
5
 
7
-
8
- class CountryStateBase(ApiModelBase[EndpointClass]):
9
- _identifier: str = "country_state"
10
-
11
- country_id: IdField
12
- short_code: str
13
- name: str
14
- position: int | None = None
15
- active: bool | None = None
16
- custom_fields: dict[str, Any] | None = None
17
- translated: dict[str, Any] | None = None
18
-
19
-
20
- class CountryStateRelations:
6
+ class CountryState(CountryStateBase, AdminModel["CountryStateEndpoint"]):
21
7
  country: ForeignRelation["Country"]
22
8
  customer_addresses: ManyRelation["CustomerAddress"]
23
9
  order_addresses: ManyRelation["OrderAddress"]
24
10
 
25
11
 
26
- class CountryState(CountryStateBase["CountryStateEndpoint"], CountryStateRelations):
27
- pass
28
-
29
-
30
- class CountryStateEndpoint(EndpointBase[CountryState]):
12
+ class CountryStateEndpoint(AdminEndpoint[CountryState]):
31
13
  name = "country_state"
32
14
  path = "/country_state"
33
15
  model_class = CountryState
@@ -1,33 +1,9 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ManyRelation
3
+ from shopware_api_client.models.currency import CurrencyBase
2
4
 
3
- from pydantic import Field
4
5
 
5
- from ....base import ApiModelBase, EndpointBase, EndpointClass
6
- from ...base_fields import Rounding
7
- from ...relations import ManyRelation
8
-
9
-
10
- class CurrencyBase(ApiModelBase[EndpointClass]):
11
- _identifier: str = "currency"
12
-
13
- factor: float
14
- symbol: str
15
- iso_code: str
16
- short_name: str
17
- name: str
18
- position: int | None = None
19
- is_system_default: bool | None = Field(
20
- None,
21
- description="Runtime field, cannot be used as part of the criteria.",
22
- )
23
- tax_free_from: float | None = None
24
- custom_fields: dict[str, Any] | None = None
25
- item_rounding: Rounding
26
- total_rounding: Rounding
27
- translated: dict[str, Any] | None = None
28
-
29
-
30
- class CurrencyRelations:
6
+ class Currency(CurrencyBase, AdminModel["CurrencyEndpoint"]):
31
7
  sales_channel_default_assignments: ManyRelation["SalesChannel"]
32
8
  orders: ManyRelation["Order"]
33
9
  sales_channels: ManyRelation["SalesChannel"]
@@ -37,11 +13,7 @@ class CurrencyRelations:
37
13
  country_roundings: ManyRelation["CurrencyCountryRounding"]
38
14
 
39
15
 
40
- class Currency(CurrencyBase["CurrencyEndpoint"], CurrencyRelations):
41
- pass
42
-
43
-
44
- class CurrencyEndpoint(EndpointBase[Currency]):
16
+ class CurrencyEndpoint(AdminEndpoint[Currency]):
45
17
  name = "currency"
46
18
  path = "/currency"
47
19
  model_class = Currency
@@ -1,29 +1,14 @@
1
- from ....base import ApiModelBase, EndpointBase, EndpointClass
2
- from ...base_fields import IdField, Rounding
3
- from ...relations import ForeignRelation
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ForeignRelation
3
+ from shopware_api_client.models.currency_country_rounding import CurrencyCountryRoundingBase
4
4
 
5
5
 
6
- class CurrencyCountryRoundingBase(ApiModelBase[EndpointClass]):
7
- _identifier: str = "currency_country_rounding"
8
-
9
- currency_id: IdField
10
- country_id: IdField
11
- item_rounding: Rounding
12
- total_rounding: Rounding
13
-
14
-
15
- class CurrencyCountryRoundingRelations:
6
+ class CurrencyCountryRounding(CurrencyCountryRoundingBase, AdminModel["CurrencyCountryRoundingEndpoint"]):
16
7
  currency: ForeignRelation["Currency"]
17
8
  country: ForeignRelation["Country"]
18
9
 
19
10
 
20
- class CurrencyCountryRounding(
21
- CurrencyCountryRoundingBase["CurrencyCountryRoundingEndpoint"], CurrencyCountryRoundingRelations
22
- ):
23
- pass
24
-
25
-
26
- class CurrencyCountryRoundingEndpoint(EndpointBase[CurrencyCountryRounding]):
11
+ class CurrencyCountryRoundingEndpoint(AdminEndpoint[CurrencyCountryRounding]):
27
12
  name = "currency_country_rounding"
28
13
  path = "/currency-country-rounding"
29
14
  model_class = CurrencyCountryRounding
@@ -1,34 +1,12 @@
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.models.custom_entity import CustomEntityBase
1
3
 
2
- from pydantic import AwareDatetime, Field
3
4
 
4
- from ....base import ApiModelBase, EndpointBase, EndpointClass
5
- from ...base_fields import IdField
6
-
7
-
8
- class CustomEntityBase(ApiModelBase[EndpointClass]):
9
- _identifier: str = "custom_entity"
10
-
11
- name: str
12
- fields: list
13
- flags: list | None = None
14
- app_id: IdField | None = None
15
- plugin_id: IdField | None = None
16
- cms_aware: bool | None = None
17
- store_api_aware: bool | None = None
18
- custom_fields_aware: bool | None = None
19
- label_property: str | None = None
20
- deleted_at: AwareDatetime | None = Field(default=None)
21
-
22
-
23
- class CustomEntityRelations:
24
- pass
25
-
26
-
27
- class CustomEntity(CustomEntityBase["CustomEntityEndpoint"], CustomEntityRelations):
5
+ class CustomEntity(CustomEntityBase, AdminModel["CustomEntityEndpoint"]):
28
6
  pass
29
7
 
30
8
 
31
- class CustomEntityEndpoint(EndpointBase[CustomEntity]):
9
+ class CustomEntityEndpoint(AdminEndpoint[CustomEntity]):
32
10
  name = "custom_entity"
33
11
  path = "/custom-entity"
34
12
  model_class = CustomEntity
@@ -1,22 +1,12 @@
1
- from ....base import ApiModelBase, EndpointBase, EndpointClass
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.models.custom_field import CustomFieldBase
2
3
 
3
4
 
4
- class CustomFieldBase(ApiModelBase[EndpointClass]):
5
- _identifier: str = "custom_field"
6
-
7
- name: str
8
- custom_field_set_id: str | None = None
9
-
10
-
11
- class CustomFieldRelations:
12
- pass
13
-
14
-
15
- class CustomField(CustomFieldBase["CustomFieldEndpoint"], CustomFieldRelations):
5
+ class CustomField(CustomFieldBase, AdminModel["CustomFieldEndpoint"]):
16
6
  pass
17
7
 
18
8
 
19
- class CustomFieldEndpoint(EndpointBase[CustomField]):
9
+ class CustomFieldEndpoint(AdminEndpoint[CustomField]):
20
10
  name = "custom_field"
21
11
  path = "/custom-field"
22
12
  model_class = CustomField
@@ -1,57 +1,9 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ForeignRelation, ManyRelation
3
+ from shopware_api_client.models.customer import CustomerBase
2
4
 
3
- from pydantic import AwareDatetime, Field
4
5
 
5
- from ....base import ApiModelBase, EndpointBase, EndpointClass
6
- from ...base_fields import IdField
7
- from ...relations import ForeignRelation, ManyRelation
8
-
9
-
10
- class CustomerBase(ApiModelBase[EndpointClass]):
11
- _identifier: str = "customer"
12
-
13
- group_id: IdField
14
- default_payment_method_id: IdField | None = None
15
- sales_channel_id: IdField
16
- language_id: IdField
17
- last_payment_method_id: IdField | None = None
18
- default_billing_address_id: IdField
19
- default_shipping_address_id: IdField
20
- auto_increment: int | None = Field(default=None, exclude=True)
21
- customer_number: str
22
- salutation_id: IdField | None = None
23
- first_name: str
24
- last_name: str
25
- company: str | None = None
26
- email: str
27
- title: str | None = None
28
- vat_ids: list[str] | None = None
29
- affiliate_code: str | None = None
30
- campaign_code: str | None = None
31
- active: bool | None = None
32
- double_opt_in_registration: bool | None = None
33
- double_opt_in_email_sent_date: AwareDatetime | None = None
34
- double_opt_in_confirm_date: AwareDatetime | None = None
35
- hash: str | None = None
36
- guest: bool | None = None
37
- first_login: AwareDatetime | None = None
38
- last_login: AwareDatetime | None = None
39
- birthday: str | None = None
40
- last_order_date: AwareDatetime | None = Field(default=None, exclude=True)
41
- order_count: int | None = Field(default=None, exclude=True)
42
- order_total_amount: float | None = Field(default=None, exclude=True)
43
- review_count: int | None = Field(default=None, exclude=True)
44
- custom_fields: dict[str, Any] | None = None
45
- remote_address: str | None = None
46
- tag_ids: list[IdField] | None = Field(default=None, exclude=True)
47
- requested_group_id: IdField | None = None
48
- bound_sales_channel_id: IdField | None = None
49
- account_type: str
50
- created_by_id: IdField | None = None
51
- updated_by_id: IdField | None = None
52
-
53
-
54
- class CustomerBaseRelations:
6
+ class Customer(CustomerBase, AdminModel["CustomerEndpoint"]):
55
7
  group: ForeignRelation["CustomerGroup"]
56
8
  default_payment_method: ForeignRelation["PaymentMethod"]
57
9
  sales_channel: ForeignRelation["SalesChannel"]
@@ -73,11 +25,7 @@ class CustomerBaseRelations:
73
25
  updated_by: ForeignRelation["User"]
74
26
 
75
27
 
76
- class Customer(CustomerBase["CustomerEndpoint"], CustomerBaseRelations):
77
- pass
78
-
79
-
80
- class CustomerEndpoint(EndpointBase[Customer]):
28
+ class CustomerEndpoint(AdminEndpoint[Customer]):
81
29
  name = "customer"
82
30
  path = "/customer"
83
31
  model_class = Customer
@@ -1,43 +1,16 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.models.customer_address import CustomerAddressBase
3
+ from shopware_api_client.endpoints.relations import ForeignRelation
2
4
 
3
- from ....base import ApiModelBase, EndpointBase, EndpointClass
4
- from ...base_fields import IdField
5
- from ...relations import ForeignRelation
6
5
 
7
-
8
- class CustomerAddressBase(ApiModelBase[EndpointClass]):
9
- _identifier: str = "customer_address"
10
-
11
- customer_id: IdField
12
- country_id: IdField
13
- country_state_id: IdField | None = None
14
- salutation_id: IdField | None = None
15
- first_name: str
16
- last_name: str
17
- zipcode: str | None = None
18
- city: str
19
- company: str | None = None
20
- street: str
21
- department: str | None = None
22
- title: str | None = None
23
- phone_number: str | None = None
24
- additional_address_line1: str | None = None
25
- additional_address_line2: str | None = None
26
- custom_fields: dict[str, Any] | None = None
27
-
28
-
29
- class CustomerAddressRelations:
30
- customer: ForeignRelation["Customer"]
6
+ class CustomerAddress(CustomerAddressBase, AdminModel["CustomerAddressEndpoint"]):
31
7
  country: ForeignRelation["Country"]
32
8
  country_state: ForeignRelation["CountryState"]
33
9
  salutation: ForeignRelation["Salutation"]
10
+ customer: ForeignRelation["Customer"]
34
11
 
35
12
 
36
- class CustomerAddress(CustomerAddressBase["CustomerAddressEndpoint"], CustomerAddressRelations):
37
- pass
38
-
39
-
40
- class CustomerAddressEndpoint(EndpointBase[CustomerAddress]):
13
+ class CustomerAddressEndpoint(AdminEndpoint[CustomerAddress]):
41
14
  name = "customer_address"
42
15
  path = "/customer-address"
43
16
  model_class = CustomerAddress
@@ -1,34 +1,15 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminEndpoint, AdminModel
2
+ from shopware_api_client.endpoints.relations import ManyRelation
3
+ from shopware_api_client.models.customer_group import CustomerGroupBase
2
4
 
3
- from ....base import ApiModelBase, EndpointBase, EndpointClass
4
- from ...relations import ManyRelation
5
5
 
6
-
7
- class CustomerGroupBase(ApiModelBase[EndpointClass]):
8
- _identifier = "customer_group"
9
-
10
- name: str
11
- display_gross: bool | None = None
12
- custom_fields: dict[str, Any] | None = None
13
- registration_active: bool | None = None
14
- registration_title: str | None = None
15
- registration_introduction: str | None = None
16
- registration_only_company_registration: bool | None = None
17
- registration_seo_meta_description: str | None = None
18
- translated: dict[str, Any] | None = None
19
-
20
-
21
- class CustomerGroupRelations:
6
+ class CustomerGroup(CustomerGroupBase, AdminModel["CustomerGroupEndpoint"]):
22
7
  customers: ManyRelation["Customer"]
23
8
  sales_channels: ManyRelation["SalesChannel"]
24
9
  registration_sales_channels: ManyRelation["SalesChannel"]
25
10
 
26
11
 
27
- class CustomerGroup(CustomerGroupBase["CustomerGroupEndpoint"], CustomerGroupRelations):
28
- pass
29
-
30
-
31
- class CustomerGroupEndpoint(EndpointBase[CustomerGroup]):
12
+ class CustomerGroupEndpoint(AdminEndpoint[CustomerGroup]):
32
13
  name = "customer_group"
33
14
  path = "/customer-group"
34
15
  model_class = CustomerGroup
@@ -1,24 +1,13 @@
1
- from ....base import ApiModelBase, EndpointBase, EndpointClass
2
- from ...base_fields import IdField
3
- from ...relations import ForeignRelation
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ForeignRelation
3
+ from shopware_api_client.models.customer_recovery import CustomerRecoveryBase
4
4
 
5
5
 
6
- class CustomerRecoveryBase(ApiModelBase[EndpointClass]):
7
- _identifier: str = "customer_recovery"
8
-
9
- hash: str
10
- customer_id: IdField
11
-
12
-
13
- class CustomerRecoveryRelations:
6
+ class CustomerRecovery(CustomerRecoveryBase, AdminModel["CustomerRecoveryEndpoint"]):
14
7
  customer: ForeignRelation["Customer"]
15
8
 
16
9
 
17
- class CustomerRecovery(CustomerRecoveryBase["CustomerRecoveryEndpoint"], CustomerRecoveryRelations):
18
- pass
19
-
20
-
21
- class CustomerRecoveryEndpoint(EndpointBase[CustomerRecovery]):
10
+ class CustomerRecoveryEndpoint(AdminEndpoint[CustomerRecovery]):
22
11
  name = "customer_recovery"
23
12
  path = "/customer-recovery"
24
13
  model_class = CustomerRecovery
@@ -1,29 +1,15 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ForeignRelation, ManyRelation
3
+ from shopware_api_client.models.customer_wishlist import CustomerWishlistBase
2
4
 
3
- from ....base import ApiModelBase, EndpointBase, EndpointClass
4
- from ...base_fields import IdField
5
- from ...relations import ForeignRelation, ManyRelation
6
5
 
7
-
8
- class CustomerWishlistBase(ApiModelBase[EndpointClass]):
9
- _identifier: str = "customer_wishlist"
10
-
11
- customer_id: IdField
12
- sales_channel_id: IdField
13
- custom_fields: dict[str, Any] | None = None
14
-
15
-
16
- class CustomerWishlistRelations:
6
+ class CustomerWishlist(CustomerWishlistBase, AdminModel["CustomerWishlistEndpoint"]):
17
7
  products: ManyRelation["CustomerWishlistProduct"]
18
8
  customer: ForeignRelation["Customer"]
19
9
  sales_channel: ForeignRelation["SalesChannel"]
20
10
 
21
11
 
22
- class CustomerWishlist(CustomerWishlistBase["CustomerWishlistEndpoint"], CustomerWishlistRelations):
23
- pass
24
-
25
-
26
- class CustomerWishlistEndpoint(EndpointBase[CustomerWishlist]):
12
+ class CustomerWishlistEndpoint(AdminEndpoint[CustomerWishlist]):
27
13
  name = "customer_wishlist"
28
14
  path = "/customer-wishlist"
29
15
  model_class = CustomerWishlist
@@ -1,28 +1,14 @@
1
- from ....base import ApiModelBase, EndpointBase, EndpointClass
2
- from ...base_fields import IdField
3
- from ...relations import ForeignRelation
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ForeignRelation
3
+ from shopware_api_client.models.customer_wishlist_product import CustomerWishlistProductBase
4
4
 
5
5
 
6
- class CustomerWishlistProductBase(ApiModelBase[EndpointClass]):
7
- _identifier: str = "customer_wishlist_product"
8
-
9
- product_id: IdField
10
- product_version_id: IdField | None = None
11
- wishlist_id: IdField
12
-
13
-
14
- class CustomerWishlistProductRelations:
6
+ class CustomerWishlistProduct(CustomerWishlistProductBase, AdminModel["CustomerWishlistProductEndpoint"]):
15
7
  wishlist: ForeignRelation["CustomerWishlist"]
16
8
  product: ForeignRelation["Product"]
17
9
 
18
10
 
19
- class CustomerWishlistProduct(
20
- CustomerWishlistProductBase["CustomerWishlistProductEndpoint"], CustomerWishlistProductRelations
21
- ):
22
- pass
23
-
24
-
25
- class CustomerWishlistProductEndpoint(EndpointBase[CustomerWishlistProduct]):
11
+ class CustomerWishlistProductEndpoint(AdminEndpoint[CustomerWishlistProduct]):
26
12
  name = "customer_wishlist_product"
27
13
  path = "/customer-wishlist-product"
28
14
  model_class = CustomerWishlistProduct
@@ -1,30 +1,14 @@
1
- from typing import Any
1
+ from shopware_api_client.base import AdminModel, AdminEndpoint
2
+ from shopware_api_client.endpoints.relations import ManyRelation
3
+ from shopware_api_client.models.delivery_time import DeliveryTimeBase
2
4
 
3
- from ....base import ApiModelBase, EndpointBase, EndpointClass
4
- from ...relations import ManyRelation
5
5
 
6
-
7
- class DeliveryTimeBase(ApiModelBase[EndpointClass]):
8
- _identifier: str = "delivery_time"
9
-
10
- name: str
11
- min: int
12
- max: int
13
- unit: str
14
- custom_fields: dict[str, Any] | None = None
15
- translated: dict[str, Any] | None = None
16
-
17
-
18
- class DeliveryTimeRelations:
6
+ class DeliveryTime(DeliveryTimeBase, AdminModel["DeliveryTimeEndpoint"]):
19
7
  shipping_methods: ManyRelation["ShippingMethod"]
20
8
  products: ManyRelation["Product"]
21
9
 
22
10
 
23
- class DeliveryTime(DeliveryTimeBase["DeliveryTimeEndpoint"], DeliveryTimeRelations):
24
- pass
25
-
26
-
27
- class DeliveryTimeEndpoint(EndpointBase[DeliveryTime]):
11
+ class DeliveryTimeEndpoint(AdminEndpoint[DeliveryTime]):
28
12
  name = "delivery_time"
29
13
  path = "/delivery-time"
30
14
  model_class = DeliveryTime