stackit-stackitmarketplace 1.2.0__tar.gz → 1.4.0__tar.gz

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 (48) hide show
  1. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/PKG-INFO +1 -1
  2. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/pyproject.toml +2 -2
  3. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/__init__.py +4 -0
  4. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/__init__.py +4 -0
  5. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_product_detail.py +7 -2
  6. stackit_stackitmarketplace-1.4.0/src/stackit/stackitmarketplace/models/catalog_product_facets_value_inner.py +83 -0
  7. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/list_catalog_products_response.py +18 -1
  8. stackit_stackitmarketplace-1.4.0/src/stackit/stackitmarketplace/models/offer_type.py +37 -0
  9. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/LICENSE.md +0 -0
  10. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/NOTICE.txt +0 -0
  11. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/README.md +0 -0
  12. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/api/__init__.py +0 -0
  13. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/api/default_api.py +0 -0
  14. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/api_client.py +0 -0
  15. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/api_response.py +0 -0
  16. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/configuration.py +0 -0
  17. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/exceptions.py +0 -0
  18. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/approve_subscription_payload.py +0 -0
  19. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/become_vendor.py +0 -0
  20. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_pricing_option_highlight.py +0 -0
  21. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_product_details_vendor.py +0 -0
  22. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_product_highlight.py +0 -0
  23. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_product_overview.py +0 -0
  24. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_product_overview_vendor.py +0 -0
  25. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_product_pricing_option.py +0 -0
  26. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_product_support_resource.py +0 -0
  27. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/catalog_product_vendor_terms.py +0 -0
  28. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/contact_sales.py +0 -0
  29. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/delivery_method.py +0 -0
  30. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/error_response.py +0 -0
  31. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/inquiries_create_inquiry_payload.py +0 -0
  32. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/inquiry_become_vendor.py +0 -0
  33. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/inquiry_contact_sales.py +0 -0
  34. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/inquiry_form_type.py +0 -0
  35. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/inquiry_register_testing.py +0 -0
  36. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/inquiry_suggest_product.py +0 -0
  37. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/list_vendor_subscriptions_response.py +0 -0
  38. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/price_type.py +0 -0
  39. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/pricing_option_unit.py +0 -0
  40. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/product_lifecycle_state.py +0 -0
  41. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/register_testing.py +0 -0
  42. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/resolve_customer_payload.py +0 -0
  43. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/subscription_lifecycle_state.py +0 -0
  44. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/subscription_product.py +0 -0
  45. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/suggest_product.py +0 -0
  46. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/models/vendor_subscription.py +0 -0
  47. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/py.typed +0 -0
  48. {stackit_stackitmarketplace-1.2.0 → stackit_stackitmarketplace-1.4.0}/src/stackit/stackitmarketplace/rest.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: stackit-stackitmarketplace
3
- Version: 1.2.0
3
+ Version: 1.4.0
4
4
  Summary: STACKIT Marketplace API
5
5
  Author: STACKIT Developer Tools
6
6
  Author-email: developer-tools@stackit.cloud
@@ -3,7 +3,7 @@ name = "stackit-stackitmarketplace"
3
3
 
4
4
  [tool.poetry]
5
5
  name = "stackit-stackitmarketplace"
6
- version = "v1.2.0"
6
+ version = "v1.4.0"
7
7
  authors = [
8
8
  "STACKIT Developer Tools <developer-tools@stackit.cloud>",
9
9
  ]
@@ -105,4 +105,4 @@ per-file-ignores = """
105
105
  # E501: long descriptions/string values might lead to lines that are too long
106
106
  # B028: stacklevel for deprecation warning is irrelevant
107
107
  ./src/stackit/*/api/default_api.py: F841,B028,E501
108
- """
108
+ """
@@ -47,6 +47,9 @@ from stackit.stackitmarketplace.models.catalog_product_detail import (
47
47
  from stackit.stackitmarketplace.models.catalog_product_details_vendor import (
48
48
  CatalogProductDetailsVendor,
49
49
  )
50
+ from stackit.stackitmarketplace.models.catalog_product_facets_value_inner import (
51
+ CatalogProductFacetsValueInner,
52
+ )
50
53
  from stackit.stackitmarketplace.models.catalog_product_highlight import (
51
54
  CatalogProductHighlight,
52
55
  )
@@ -86,6 +89,7 @@ from stackit.stackitmarketplace.models.list_catalog_products_response import (
86
89
  from stackit.stackitmarketplace.models.list_vendor_subscriptions_response import (
87
90
  ListVendorSubscriptionsResponse,
88
91
  )
92
+ from stackit.stackitmarketplace.models.offer_type import OfferType
89
93
  from stackit.stackitmarketplace.models.price_type import PriceType
90
94
  from stackit.stackitmarketplace.models.pricing_option_unit import PricingOptionUnit
91
95
  from stackit.stackitmarketplace.models.product_lifecycle_state import (
@@ -28,6 +28,9 @@ from stackit.stackitmarketplace.models.catalog_product_detail import (
28
28
  from stackit.stackitmarketplace.models.catalog_product_details_vendor import (
29
29
  CatalogProductDetailsVendor,
30
30
  )
31
+ from stackit.stackitmarketplace.models.catalog_product_facets_value_inner import (
32
+ CatalogProductFacetsValueInner,
33
+ )
31
34
  from stackit.stackitmarketplace.models.catalog_product_highlight import (
32
35
  CatalogProductHighlight,
33
36
  )
@@ -67,6 +70,7 @@ from stackit.stackitmarketplace.models.list_catalog_products_response import (
67
70
  from stackit.stackitmarketplace.models.list_vendor_subscriptions_response import (
68
71
  ListVendorSubscriptionsResponse,
69
72
  )
73
+ from stackit.stackitmarketplace.models.offer_type import OfferType
70
74
  from stackit.stackitmarketplace.models.price_type import PriceType
71
75
  from stackit.stackitmarketplace.models.pricing_option_unit import PricingOptionUnit
72
76
  from stackit.stackitmarketplace.models.product_lifecycle_state import (
@@ -46,6 +46,7 @@ from stackit.stackitmarketplace.models.catalog_product_vendor_terms import (
46
46
  CatalogProductVendorTerms,
47
47
  )
48
48
  from stackit.stackitmarketplace.models.delivery_method import DeliveryMethod
49
+ from stackit.stackitmarketplace.models.offer_type import OfferType
49
50
  from stackit.stackitmarketplace.models.product_lifecycle_state import (
50
51
  ProductLifecycleState,
51
52
  )
@@ -69,13 +70,15 @@ class CatalogProductDetail(BaseModel):
69
70
  industries: Optional[List[StrictStr]] = Field(
70
71
  default=None, description="The list of industries associated to the product."
71
72
  )
72
- is_product_listing: StrictBool = Field(
73
- description="If true, the product is not fully integrated but only listed. Product listings may not have prices and support information.",
73
+ is_product_listing: Optional[StrictBool] = Field(
74
+ default=None,
75
+ description="If true, the product is not fully integrated but only listed. Product listings may not have prices and support information. Deprecated: Will be removed after 16.12.2025. Please use `offerType` as replacement.",
74
76
  alias="isProductListing",
75
77
  )
76
78
  lifecycle_state: ProductLifecycleState = Field(alias="lifecycleState")
77
79
  logo: Union[StrictBytes, StrictStr] = Field(description="The logo base64 encoded.")
78
80
  name: Annotated[str, Field(strict=True, max_length=512)] = Field(description="The name of the product.")
81
+ offer_type: OfferType = Field(alias="offerType")
79
82
  pricing_options: List[CatalogProductPricingOption] = Field(
80
83
  description="The list of pricing options.", alias="pricingOptions"
81
84
  )
@@ -111,6 +114,7 @@ class CatalogProductDetail(BaseModel):
111
114
  "lifecycleState",
112
115
  "logo",
113
116
  "name",
117
+ "offerType",
114
118
  "pricingOptions",
115
119
  "productId",
116
120
  "summary",
@@ -262,6 +266,7 @@ class CatalogProductDetail(BaseModel):
262
266
  "lifecycleState": obj.get("lifecycleState"),
263
267
  "logo": obj.get("logo"),
264
268
  "name": obj.get("name"),
269
+ "offerType": obj.get("offerType"),
265
270
  "pricingOptions": (
266
271
  [CatalogProductPricingOption.from_dict(_item) for _item in obj["pricingOptions"]]
267
272
  if obj.get("pricingOptions") is not None
@@ -0,0 +1,83 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ STACKIT Marketplace API
5
+
6
+ API to manage STACKIT Marketplace.
7
+
8
+ The version of the OpenAPI document: 1
9
+ Contact: marketplace@stackit.cloud
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
+
12
+ Do not edit the class manually.
13
+ """ # noqa: E501 docstring might be too long
14
+
15
+ from __future__ import annotations
16
+
17
+ import json
18
+ import pprint
19
+ from typing import Any, ClassVar, Dict, List, Optional, Set
20
+
21
+ from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
22
+ from typing_extensions import Self
23
+
24
+
25
+ class CatalogProductFacetsValueInner(BaseModel):
26
+ """
27
+ CatalogProductFacetsValueInner
28
+ """
29
+
30
+ count: StrictInt = Field(description="The number of items associated with this facet value.")
31
+ value: StrictStr = Field(description="The value of the facet.")
32
+ __properties: ClassVar[List[str]] = ["count", "value"]
33
+
34
+ model_config = ConfigDict(
35
+ populate_by_name=True,
36
+ validate_assignment=True,
37
+ protected_namespaces=(),
38
+ )
39
+
40
+ def to_str(self) -> str:
41
+ """Returns the string representation of the model using alias"""
42
+ return pprint.pformat(self.model_dump(by_alias=True))
43
+
44
+ def to_json(self) -> str:
45
+ """Returns the JSON representation of the model using alias"""
46
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
47
+ return json.dumps(self.to_dict())
48
+
49
+ @classmethod
50
+ def from_json(cls, json_str: str) -> Optional[Self]:
51
+ """Create an instance of CatalogProductFacetsValueInner from a JSON string"""
52
+ return cls.from_dict(json.loads(json_str))
53
+
54
+ def to_dict(self) -> Dict[str, Any]:
55
+ """Return the dictionary representation of the model using alias.
56
+
57
+ This has the following differences from calling pydantic's
58
+ `self.model_dump(by_alias=True)`:
59
+
60
+ * `None` is only added to the output dict for nullable fields that
61
+ were set at model initialization. Other fields with value `None`
62
+ are ignored.
63
+ """
64
+ excluded_fields: Set[str] = set([])
65
+
66
+ _dict = self.model_dump(
67
+ by_alias=True,
68
+ exclude=excluded_fields,
69
+ exclude_none=True,
70
+ )
71
+ return _dict
72
+
73
+ @classmethod
74
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
75
+ """Create an instance of CatalogProductFacetsValueInner from a dict"""
76
+ if obj is None:
77
+ return None
78
+
79
+ if not isinstance(obj, dict):
80
+ return cls.model_validate(obj)
81
+
82
+ _obj = cls.model_validate({"count": obj.get("count"), "value": obj.get("value")})
83
+ return _obj
@@ -21,6 +21,9 @@ from typing import Any, ClassVar, Dict, List, Optional, Set, Union
21
21
  from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
22
  from typing_extensions import Annotated, Self
23
23
 
24
+ from stackit.stackitmarketplace.models.catalog_product_facets_value_inner import (
25
+ CatalogProductFacetsValueInner,
26
+ )
24
27
  from stackit.stackitmarketplace.models.catalog_product_overview import (
25
28
  CatalogProductOverview,
26
29
  )
@@ -34,11 +37,14 @@ class ListCatalogProductsResponse(BaseModel):
34
37
  cursor: StrictStr = Field(
35
38
  description="A pagination cursor that represents a position in the dataset. If given, results will be returned from the item after the cursor. If not given, results will be returned from the beginning."
36
39
  )
40
+ facets: Optional[Dict[str, List[CatalogProductFacetsValueInner]]] = Field(
41
+ default=None, description="A collection of facets, where each key represents a facet category."
42
+ )
37
43
  items: List[CatalogProductOverview]
38
44
  limit: Union[
39
45
  Annotated[float, Field(le=100, strict=True, ge=0)], Annotated[int, Field(le=100, strict=True, ge=0)]
40
46
  ] = Field(description="Limit for returned Objects.")
41
- __properties: ClassVar[List[str]] = ["cursor", "items", "limit"]
47
+ __properties: ClassVar[List[str]] = ["cursor", "facets", "items", "limit"]
42
48
 
43
49
  model_config = ConfigDict(
44
50
  populate_by_name=True,
@@ -77,6 +83,13 @@ class ListCatalogProductsResponse(BaseModel):
77
83
  exclude=excluded_fields,
78
84
  exclude_none=True,
79
85
  )
86
+ # override the default output from pydantic by calling `to_dict()` of each value in facets (dict of array)
87
+ _field_dict_of_array = {}
88
+ if self.facets:
89
+ for _key in self.facets:
90
+ if self.facets[_key] is not None:
91
+ _field_dict_of_array[_key] = [_item.to_dict() for _item in self.facets[_key]]
92
+ _dict["facets"] = _field_dict_of_array
80
93
  # override the default output from pydantic by calling `to_dict()` of each item in items (list)
81
94
  _items = []
82
95
  if self.items:
@@ -98,6 +111,10 @@ class ListCatalogProductsResponse(BaseModel):
98
111
  _obj = cls.model_validate(
99
112
  {
100
113
  "cursor": obj.get("cursor"),
114
+ "facets": dict(
115
+ (_k, [CatalogProductFacetsValueInner.from_dict(_item) for _item in _v] if _v is not None else None)
116
+ for _k, _v in obj.get("facets", {}).items()
117
+ ),
101
118
  "items": (
102
119
  [CatalogProductOverview.from_dict(_item) for _item in obj["items"]]
103
120
  if obj.get("items") is not None
@@ -0,0 +1,37 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ STACKIT Marketplace API
5
+
6
+ API to manage STACKIT Marketplace.
7
+
8
+ The version of the OpenAPI document: 1
9
+ Contact: marketplace@stackit.cloud
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
+
12
+ Do not edit the class manually.
13
+ """ # noqa: E501 docstring might be too long
14
+
15
+ from __future__ import annotations
16
+
17
+ import json
18
+ from enum import Enum
19
+
20
+ from typing_extensions import Self
21
+
22
+
23
+ class OfferType(str, Enum):
24
+ """
25
+ The offer type of a product reflecting the business model.
26
+ """
27
+
28
+ """
29
+ allowed enum values
30
+ """
31
+ OFFER_LISTING = "OFFER_LISTING"
32
+ OFFER_RESELLING = "OFFER_RESELLING"
33
+
34
+ @classmethod
35
+ def from_json(cls, json_str: str) -> Self:
36
+ """Create an instance of OfferType from a JSON string"""
37
+ return cls(json.loads(json_str))