waldur-api-client 7.7.1__py3-none-any.whl → 7.7.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 (71) hide show
  1. waldur_api_client/api/marketplace_checklists/marketplace_checklists_questions_list.py +31 -32
  2. waldur_api_client/api/marketplace_checklists/marketplace_checklists_retrieve.py +15 -14
  3. waldur_api_client/api/marketplace_checklists_admin/__init__.py +1 -0
  4. waldur_api_client/api/marketplace_checklists_admin/marketplace_checklists_admin_checklist_questions.py +187 -0
  5. waldur_api_client/api/marketplace_checklists_admin/marketplace_checklists_admin_create.py +150 -0
  6. waldur_api_client/api/marketplace_checklists_admin/marketplace_checklists_admin_destroy.py +89 -0
  7. waldur_api_client/api/marketplace_checklists_admin/marketplace_checklists_admin_list.py +173 -0
  8. waldur_api_client/api/marketplace_checklists_admin/marketplace_checklists_admin_partial_update.py +164 -0
  9. waldur_api_client/api/marketplace_checklists_admin/marketplace_checklists_admin_retrieve.py +142 -0
  10. waldur_api_client/api/marketplace_checklists_admin/marketplace_checklists_admin_update.py +164 -0
  11. waldur_api_client/api/marketplace_checklists_admin_question_dependencies/__init__.py +1 -0
  12. waldur_api_client/api/marketplace_checklists_admin_question_dependencies/marketplace_checklists_admin_question_dependencies_create.py +150 -0
  13. waldur_api_client/api/marketplace_checklists_admin_question_dependencies/marketplace_checklists_admin_question_dependencies_destroy.py +89 -0
  14. waldur_api_client/api/marketplace_checklists_admin_question_dependencies/marketplace_checklists_admin_question_dependencies_list.py +212 -0
  15. waldur_api_client/api/marketplace_checklists_admin_question_dependencies/marketplace_checklists_admin_question_dependencies_partial_update.py +164 -0
  16. waldur_api_client/api/marketplace_checklists_admin_question_dependencies/marketplace_checklists_admin_question_dependencies_retrieve.py +142 -0
  17. waldur_api_client/api/marketplace_checklists_admin_question_dependencies/marketplace_checklists_admin_question_dependencies_update.py +164 -0
  18. waldur_api_client/api/marketplace_checklists_admin_question_options/__init__.py +1 -0
  19. waldur_api_client/api/marketplace_checklists_admin_question_options/marketplace_checklists_admin_question_options_create.py +150 -0
  20. waldur_api_client/api/marketplace_checklists_admin_question_options/marketplace_checklists_admin_question_options_destroy.py +89 -0
  21. waldur_api_client/api/marketplace_checklists_admin_question_options/marketplace_checklists_admin_question_options_list.py +194 -0
  22. waldur_api_client/api/marketplace_checklists_admin_question_options/marketplace_checklists_admin_question_options_partial_update.py +164 -0
  23. waldur_api_client/api/marketplace_checklists_admin_question_options/marketplace_checklists_admin_question_options_retrieve.py +142 -0
  24. waldur_api_client/api/marketplace_checklists_admin_question_options/marketplace_checklists_admin_question_options_update.py +164 -0
  25. waldur_api_client/api/marketplace_checklists_admin_questions/__init__.py +1 -0
  26. waldur_api_client/api/marketplace_checklists_admin_questions/marketplace_checklists_admin_questions_create.py +148 -0
  27. waldur_api_client/api/marketplace_checklists_admin_questions/marketplace_checklists_admin_questions_destroy.py +89 -0
  28. waldur_api_client/api/marketplace_checklists_admin_questions/marketplace_checklists_admin_questions_list.py +192 -0
  29. waldur_api_client/api/marketplace_checklists_admin_questions/marketplace_checklists_admin_questions_partial_update.py +162 -0
  30. waldur_api_client/api/marketplace_checklists_admin_questions/marketplace_checklists_admin_questions_retrieve.py +140 -0
  31. waldur_api_client/api/marketplace_checklists_admin_questions/marketplace_checklists_admin_questions_update.py +162 -0
  32. waldur_api_client/models/__init__.py +36 -2
  33. waldur_api_client/models/answer_list.py +8 -19
  34. waldur_api_client/models/answer_submit.py +7 -13
  35. waldur_api_client/models/answer_submit_request.py +7 -13
  36. waldur_api_client/models/booking_resource.py +18 -0
  37. waldur_api_client/models/booking_resources_list_field_item.py +2 -0
  38. waldur_api_client/models/booking_resources_retrieve_field_item.py +2 -0
  39. waldur_api_client/models/call_resource_template.py +23 -1
  40. waldur_api_client/models/checklist.py +8 -0
  41. waldur_api_client/models/checklist_admin.py +127 -0
  42. waldur_api_client/models/checklist_type_enum.py +10 -0
  43. waldur_api_client/models/create_checklist.py +131 -0
  44. waldur_api_client/models/create_checklist_request.py +90 -0
  45. waldur_api_client/models/marketplace_provider_resources_details_retrieve_field_item.py +2 -0
  46. waldur_api_client/models/marketplace_provider_resources_list_field_item.py +2 -0
  47. waldur_api_client/models/marketplace_provider_resources_retrieve_field_item.py +2 -0
  48. waldur_api_client/models/marketplace_resources_details_retrieve_field_item.py +2 -0
  49. waldur_api_client/models/marketplace_resources_list_field_item.py +2 -0
  50. waldur_api_client/models/marketplace_resources_retrieve_field_item.py +2 -0
  51. waldur_api_client/models/open_stack_port.py +15 -4
  52. waldur_api_client/models/open_stack_router.py +15 -4
  53. waldur_api_client/models/operator_enum.py +12 -0
  54. waldur_api_client/models/patched_create_checklist_request.py +96 -0
  55. waldur_api_client/models/patched_question_admin_request.py +208 -0
  56. waldur_api_client/models/patched_question_dependency_request.py +94 -0
  57. waldur_api_client/models/patched_question_options_admin_request.py +68 -0
  58. waldur_api_client/models/{checklist_question.py → question.py} +29 -16
  59. waldur_api_client/models/question_admin.py +260 -0
  60. waldur_api_client/models/question_admin_request.py +210 -0
  61. waldur_api_client/models/question_dependency.py +127 -0
  62. waldur_api_client/models/question_dependency_request.py +94 -0
  63. waldur_api_client/models/question_options.py +79 -0
  64. waldur_api_client/models/question_options_admin.py +103 -0
  65. waldur_api_client/models/question_options_admin_request.py +78 -0
  66. waldur_api_client/models/question_type_enum.py +15 -0
  67. waldur_api_client/models/resource.py +18 -0
  68. {waldur_api_client-7.7.1.dist-info → waldur_api_client-7.7.2.dist-info}/METADATA +1 -1
  69. {waldur_api_client-7.7.1.dist-info → waldur_api_client-7.7.2.dist-info}/RECORD +71 -25
  70. {waldur_api_client-7.7.1.dist-info → waldur_api_client-7.7.2.dist-info}/LICENSE +0 -0
  71. {waldur_api_client-7.7.1.dist-info → waldur_api_client-7.7.2.dist-info}/WHEEL +0 -0
@@ -0,0 +1,140 @@
1
+ from http import HTTPStatus
2
+ from typing import Any, Union
3
+ from uuid import UUID
4
+
5
+ import httpx
6
+
7
+ from ... import errors
8
+ from ...client import AuthenticatedClient, Client
9
+ from ...models.question_admin import QuestionAdmin
10
+ from ...types import Response
11
+
12
+
13
+ def _get_kwargs(
14
+ uuid: UUID,
15
+ ) -> dict[str, Any]:
16
+ _kwargs: dict[str, Any] = {
17
+ "method": "get",
18
+ "url": f"/api/marketplace-checklists-admin-questions/{uuid}/",
19
+ }
20
+
21
+ return _kwargs
22
+
23
+
24
+ def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> QuestionAdmin:
25
+ if response.status_code == 200:
26
+ response_200 = QuestionAdmin.from_dict(response.json())
27
+
28
+ return response_200
29
+ raise errors.UnexpectedStatus(response.status_code, response.content)
30
+
31
+
32
+ def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[QuestionAdmin]:
33
+ return Response(
34
+ status_code=HTTPStatus(response.status_code),
35
+ content=response.content,
36
+ headers=response.headers,
37
+ parsed=_parse_response(client=client, response=response),
38
+ )
39
+
40
+
41
+ def sync_detailed(
42
+ uuid: UUID,
43
+ *,
44
+ client: AuthenticatedClient,
45
+ ) -> Response[QuestionAdmin]:
46
+ """
47
+ Args:
48
+ uuid (UUID):
49
+
50
+ Raises:
51
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
52
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
53
+
54
+ Returns:
55
+ Response[QuestionAdmin]
56
+ """
57
+
58
+ kwargs = _get_kwargs(
59
+ uuid=uuid,
60
+ )
61
+
62
+ response = client.get_httpx_client().request(
63
+ **kwargs,
64
+ )
65
+
66
+ return _build_response(client=client, response=response)
67
+
68
+
69
+ def sync(
70
+ uuid: UUID,
71
+ *,
72
+ client: AuthenticatedClient,
73
+ ) -> QuestionAdmin:
74
+ """
75
+ Args:
76
+ uuid (UUID):
77
+
78
+ Raises:
79
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
80
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
81
+
82
+ Returns:
83
+ QuestionAdmin
84
+ """
85
+
86
+ return sync_detailed(
87
+ uuid=uuid,
88
+ client=client,
89
+ ).parsed
90
+
91
+
92
+ async def asyncio_detailed(
93
+ uuid: UUID,
94
+ *,
95
+ client: AuthenticatedClient,
96
+ ) -> Response[QuestionAdmin]:
97
+ """
98
+ Args:
99
+ uuid (UUID):
100
+
101
+ Raises:
102
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
103
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
104
+
105
+ Returns:
106
+ Response[QuestionAdmin]
107
+ """
108
+
109
+ kwargs = _get_kwargs(
110
+ uuid=uuid,
111
+ )
112
+
113
+ response = await client.get_async_httpx_client().request(**kwargs)
114
+
115
+ return _build_response(client=client, response=response)
116
+
117
+
118
+ async def asyncio(
119
+ uuid: UUID,
120
+ *,
121
+ client: AuthenticatedClient,
122
+ ) -> QuestionAdmin:
123
+ """
124
+ Args:
125
+ uuid (UUID):
126
+
127
+ Raises:
128
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
129
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
130
+
131
+ Returns:
132
+ QuestionAdmin
133
+ """
134
+
135
+ return (
136
+ await asyncio_detailed(
137
+ uuid=uuid,
138
+ client=client,
139
+ )
140
+ ).parsed
@@ -0,0 +1,162 @@
1
+ from http import HTTPStatus
2
+ from typing import Any, Union
3
+ from uuid import UUID
4
+
5
+ import httpx
6
+
7
+ from ... import errors
8
+ from ...client import AuthenticatedClient, Client
9
+ from ...models.question_admin import QuestionAdmin
10
+ from ...models.question_admin_request import QuestionAdminRequest
11
+ from ...types import Response
12
+
13
+
14
+ def _get_kwargs(
15
+ uuid: UUID,
16
+ *,
17
+ body: QuestionAdminRequest,
18
+ ) -> dict[str, Any]:
19
+ headers: dict[str, Any] = {}
20
+
21
+ _kwargs: dict[str, Any] = {
22
+ "method": "put",
23
+ "url": f"/api/marketplace-checklists-admin-questions/{uuid}/",
24
+ }
25
+
26
+ _kwargs["json"] = body.to_dict()
27
+
28
+ headers["Content-Type"] = "application/json"
29
+
30
+ _kwargs["headers"] = headers
31
+ return _kwargs
32
+
33
+
34
+ def _parse_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> QuestionAdmin:
35
+ if response.status_code == 200:
36
+ response_200 = QuestionAdmin.from_dict(response.json())
37
+
38
+ return response_200
39
+ raise errors.UnexpectedStatus(response.status_code, response.content)
40
+
41
+
42
+ def _build_response(*, client: Union[AuthenticatedClient, Client], response: httpx.Response) -> Response[QuestionAdmin]:
43
+ return Response(
44
+ status_code=HTTPStatus(response.status_code),
45
+ content=response.content,
46
+ headers=response.headers,
47
+ parsed=_parse_response(client=client, response=response),
48
+ )
49
+
50
+
51
+ def sync_detailed(
52
+ uuid: UUID,
53
+ *,
54
+ client: AuthenticatedClient,
55
+ body: QuestionAdminRequest,
56
+ ) -> Response[QuestionAdmin]:
57
+ """
58
+ Args:
59
+ uuid (UUID):
60
+ body (QuestionAdminRequest):
61
+
62
+ Raises:
63
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
64
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
65
+
66
+ Returns:
67
+ Response[QuestionAdmin]
68
+ """
69
+
70
+ kwargs = _get_kwargs(
71
+ uuid=uuid,
72
+ body=body,
73
+ )
74
+
75
+ response = client.get_httpx_client().request(
76
+ **kwargs,
77
+ )
78
+
79
+ return _build_response(client=client, response=response)
80
+
81
+
82
+ def sync(
83
+ uuid: UUID,
84
+ *,
85
+ client: AuthenticatedClient,
86
+ body: QuestionAdminRequest,
87
+ ) -> QuestionAdmin:
88
+ """
89
+ Args:
90
+ uuid (UUID):
91
+ body (QuestionAdminRequest):
92
+
93
+ Raises:
94
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
95
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
96
+
97
+ Returns:
98
+ QuestionAdmin
99
+ """
100
+
101
+ return sync_detailed(
102
+ uuid=uuid,
103
+ client=client,
104
+ body=body,
105
+ ).parsed
106
+
107
+
108
+ async def asyncio_detailed(
109
+ uuid: UUID,
110
+ *,
111
+ client: AuthenticatedClient,
112
+ body: QuestionAdminRequest,
113
+ ) -> Response[QuestionAdmin]:
114
+ """
115
+ Args:
116
+ uuid (UUID):
117
+ body (QuestionAdminRequest):
118
+
119
+ Raises:
120
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
121
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
122
+
123
+ Returns:
124
+ Response[QuestionAdmin]
125
+ """
126
+
127
+ kwargs = _get_kwargs(
128
+ uuid=uuid,
129
+ body=body,
130
+ )
131
+
132
+ response = await client.get_async_httpx_client().request(**kwargs)
133
+
134
+ return _build_response(client=client, response=response)
135
+
136
+
137
+ async def asyncio(
138
+ uuid: UUID,
139
+ *,
140
+ client: AuthenticatedClient,
141
+ body: QuestionAdminRequest,
142
+ ) -> QuestionAdmin:
143
+ """
144
+ Args:
145
+ uuid (UUID):
146
+ body (QuestionAdminRequest):
147
+
148
+ Raises:
149
+ errors.UnexpectedStatus: If the server returns an undocumented status code.
150
+ httpx.TimeoutException: If the request takes longer than Client.timeout.
151
+
152
+ Returns:
153
+ QuestionAdmin
154
+ """
155
+
156
+ return (
157
+ await asyncio_detailed(
158
+ uuid=uuid,
159
+ client=client,
160
+ body=body,
161
+ )
162
+ ).parsed
@@ -168,9 +168,10 @@ from .category_help_articles_request import CategoryHelpArticlesRequest
168
168
  from .category_serializer_for_for_nested_fields import CategorySerializerForForNestedFields
169
169
  from .category_serializer_for_for_nested_fields_request import CategorySerializerForForNestedFieldsRequest
170
170
  from .checklist import Checklist
171
+ from .checklist_admin import ChecklistAdmin
171
172
  from .checklist_category import ChecklistCategory
172
173
  from .checklist_customer_stats import ChecklistCustomerStats
173
- from .checklist_question import ChecklistQuestion
174
+ from .checklist_type_enum import ChecklistTypeEnum
174
175
  from .cluster_security_group import ClusterSecurityGroup
175
176
  from .cluster_security_group_request import ClusterSecurityGroupRequest
176
177
  from .comment import Comment
@@ -206,6 +207,8 @@ from .count_users_of_service_providers import CountUsersOfServiceProviders
206
207
  from .country import Country
207
208
  from .country_enum import CountryEnum
208
209
  from .create_attachments_request import CreateAttachmentsRequest
210
+ from .create_checklist import CreateChecklist
211
+ from .create_checklist_request import CreateChecklistRequest
209
212
  from .create_customer_credit import CreateCustomerCredit
210
213
  from .create_customer_credit_request import CreateCustomerCreditRequest
211
214
  from .create_feedback import CreateFeedback
@@ -769,6 +772,7 @@ from .openstack_tenants_retrieve_field_item import OpenstackTenantsRetrieveField
769
772
  from .openstack_volumes_list_field_item import OpenstackVolumesListFieldItem
770
773
  from .openstack_volumes_list_state_item import OpenstackVolumesListStateItem
771
774
  from .openstack_volumes_retrieve_field_item import OpenstackVolumesRetrieveFieldItem
775
+ from .operator_enum import OperatorEnum
772
776
  from .option_field import OptionField
773
777
  from .option_field_request import OptionFieldRequest
774
778
  from .option_field_type_enum import OptionFieldTypeEnum
@@ -803,6 +807,7 @@ from .patched_category_help_articles_request import PatchedCategoryHelpArticlesR
803
807
  from .patched_cluster_security_group_request import PatchedClusterSecurityGroupRequest
804
808
  from .patched_comment_request import PatchedCommentRequest
805
809
  from .patched_component_user_usage_limit_request import PatchedComponentUserUsageLimitRequest
810
+ from .patched_create_checklist_request import PatchedCreateChecklistRequest
806
811
  from .patched_create_customer_credit_request import PatchedCreateCustomerCreditRequest
807
812
  from .patched_customer_estimated_cost_policy_request import PatchedCustomerEstimatedCostPolicyRequest
808
813
  from .patched_customer_request import PatchedCustomerRequest
@@ -854,6 +859,9 @@ from .patched_proposal_review_request import PatchedProposalReviewRequest
854
859
  from .patched_protected_call_request import PatchedProtectedCallRequest
855
860
  from .patched_protected_round_request import PatchedProtectedRoundRequest
856
861
  from .patched_provider_plan_details_request import PatchedProviderPlanDetailsRequest
862
+ from .patched_question_admin_request import PatchedQuestionAdminRequest
863
+ from .patched_question_dependency_request import PatchedQuestionDependencyRequest
864
+ from .patched_question_options_admin_request import PatchedQuestionOptionsAdminRequest
857
865
  from .patched_rancher_application_request import PatchedRancherApplicationRequest
858
866
  from .patched_rancher_application_request_answers import PatchedRancherApplicationRequestAnswers
859
867
  from .patched_rancher_catalog_request import PatchedRancherCatalogRequest
@@ -1004,6 +1012,15 @@ from .public_offering_details import PublicOfferingDetails
1004
1012
  from .public_offering_details_attributes import PublicOfferingDetailsAttributes
1005
1013
  from .pull_marketplace_script_resource_request import PullMarketplaceScriptResourceRequest
1006
1014
  from .query_request import QueryRequest
1015
+ from .question import Question
1016
+ from .question_admin import QuestionAdmin
1017
+ from .question_admin_request import QuestionAdminRequest
1018
+ from .question_dependency import QuestionDependency
1019
+ from .question_dependency_request import QuestionDependencyRequest
1020
+ from .question_options import QuestionOptions
1021
+ from .question_options_admin import QuestionOptionsAdmin
1022
+ from .question_options_admin_request import QuestionOptionsAdminRequest
1023
+ from .question_type_enum import QuestionTypeEnum
1007
1024
  from .quota import Quota
1008
1025
  from .quota_request import QuotaRequest
1009
1026
  from .quotas_update_request import QuotasUpdateRequest
@@ -1466,9 +1483,10 @@ __all__ = (
1466
1483
  "CategorySerializerForForNestedFields",
1467
1484
  "CategorySerializerForForNestedFieldsRequest",
1468
1485
  "Checklist",
1486
+ "ChecklistAdmin",
1469
1487
  "ChecklistCategory",
1470
1488
  "ChecklistCustomerStats",
1471
- "ChecklistQuestion",
1489
+ "ChecklistTypeEnum",
1472
1490
  "ClusterSecurityGroup",
1473
1491
  "ClusterSecurityGroupRequest",
1474
1492
  "Comment",
@@ -1502,6 +1520,8 @@ __all__ = (
1502
1520
  "CountUniqueUsersConnectedWithActiveResourcesOfServiceProvider",
1503
1521
  "CountUsersOfServiceProviders",
1504
1522
  "CreateAttachmentsRequest",
1523
+ "CreateChecklist",
1524
+ "CreateChecklistRequest",
1505
1525
  "CreateCustomerCredit",
1506
1526
  "CreateCustomerCreditRequest",
1507
1527
  "CreateFeedback",
@@ -2011,6 +2031,7 @@ __all__ = (
2011
2031
  "OpenstackVolumesListStateItem",
2012
2032
  "OpenstackVolumesRetrieveFieldItem",
2013
2033
  "OpenStackVolumeType",
2034
+ "OperatorEnum",
2014
2035
  "OptionField",
2015
2036
  "OptionFieldRequest",
2016
2037
  "OptionFieldTypeEnum",
@@ -2045,6 +2066,7 @@ __all__ = (
2045
2066
  "PatchedClusterSecurityGroupRequest",
2046
2067
  "PatchedCommentRequest",
2047
2068
  "PatchedComponentUserUsageLimitRequest",
2069
+ "PatchedCreateChecklistRequest",
2048
2070
  "PatchedCreateCustomerCreditRequest",
2049
2071
  "PatchedCustomerEstimatedCostPolicyRequest",
2050
2072
  "PatchedCustomerRequest",
@@ -2092,6 +2114,9 @@ __all__ = (
2092
2114
  "PatchedProtectedCallRequest",
2093
2115
  "PatchedProtectedRoundRequest",
2094
2116
  "PatchedProviderPlanDetailsRequest",
2117
+ "PatchedQuestionAdminRequest",
2118
+ "PatchedQuestionDependencyRequest",
2119
+ "PatchedQuestionOptionsAdminRequest",
2095
2120
  "PatchedRancherApplicationRequest",
2096
2121
  "PatchedRancherApplicationRequestAnswers",
2097
2122
  "PatchedRancherCatalogRequest",
@@ -2234,6 +2259,15 @@ __all__ = (
2234
2259
  "PublicOfferingDetailsAttributes",
2235
2260
  "PullMarketplaceScriptResourceRequest",
2236
2261
  "QueryRequest",
2262
+ "Question",
2263
+ "QuestionAdmin",
2264
+ "QuestionAdminRequest",
2265
+ "QuestionDependency",
2266
+ "QuestionDependencyRequest",
2267
+ "QuestionOptions",
2268
+ "QuestionOptionsAdmin",
2269
+ "QuestionOptionsAdminRequest",
2270
+ "QuestionTypeEnum",
2237
2271
  "Quota",
2238
2272
  "QuotaRequest",
2239
2273
  "QuotasUpdateRequest",
@@ -1,5 +1,5 @@
1
1
  from collections.abc import Mapping
2
- from typing import Any, TypeVar, Union, cast
2
+ from typing import Any, TypeVar, Union
3
3
  from uuid import UUID
4
4
 
5
5
  from attrs import define as _attrs_define
@@ -15,21 +15,17 @@ class AnswerList:
15
15
  """
16
16
  Attributes:
17
17
  question_uuid (UUID):
18
- value (Union[None, Unset, bool]):
18
+ answer_data (Union[Unset, Any]): Flexible answer storage for different question types
19
19
  """
20
20
 
21
21
  question_uuid: UUID
22
- value: Union[None, Unset, bool] = UNSET
22
+ answer_data: Union[Unset, Any] = UNSET
23
23
  additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
24
24
 
25
25
  def to_dict(self) -> dict[str, Any]:
26
26
  question_uuid = str(self.question_uuid)
27
27
 
28
- value: Union[None, Unset, bool]
29
- if isinstance(self.value, Unset):
30
- value = UNSET
31
- else:
32
- value = self.value
28
+ answer_data = self.answer_data
33
29
 
34
30
  field_dict: dict[str, Any] = {}
35
31
  field_dict.update(self.additional_properties)
@@ -38,8 +34,8 @@ class AnswerList:
38
34
  "question_uuid": question_uuid,
39
35
  }
40
36
  )
41
- if value is not UNSET:
42
- field_dict["value"] = value
37
+ if answer_data is not UNSET:
38
+ field_dict["answer_data"] = answer_data
43
39
 
44
40
  return field_dict
45
41
 
@@ -48,18 +44,11 @@ class AnswerList:
48
44
  d = dict(src_dict)
49
45
  question_uuid = UUID(d.pop("question_uuid"))
50
46
 
51
- def _parse_value(data: object) -> Union[None, Unset, bool]:
52
- if data is None:
53
- return data
54
- if isinstance(data, Unset):
55
- return data
56
- return cast(Union[None, Unset, bool], data)
57
-
58
- value = _parse_value(d.pop("value", UNSET))
47
+ answer_data = d.pop("answer_data", UNSET)
59
48
 
60
49
  answer_list = cls(
61
50
  question_uuid=question_uuid,
62
- value=value,
51
+ answer_data=answer_data,
63
52
  )
64
53
 
65
54
  answer_list.additional_properties = d
@@ -1,5 +1,5 @@
1
1
  from collections.abc import Mapping
2
- from typing import Any, TypeVar, Union, cast
2
+ from typing import Any, TypeVar
3
3
  from uuid import UUID
4
4
 
5
5
  from attrs import define as _attrs_define
@@ -13,25 +13,24 @@ class AnswerSubmit:
13
13
  """
14
14
  Attributes:
15
15
  question_uuid (UUID):
16
- value (Union[None, bool]):
16
+ answer_data (Any):
17
17
  """
18
18
 
19
19
  question_uuid: UUID
20
- value: Union[None, bool]
20
+ answer_data: Any
21
21
  additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
22
22
 
23
23
  def to_dict(self) -> dict[str, Any]:
24
24
  question_uuid = str(self.question_uuid)
25
25
 
26
- value: Union[None, bool]
27
- value = self.value
26
+ answer_data = self.answer_data
28
27
 
29
28
  field_dict: dict[str, Any] = {}
30
29
  field_dict.update(self.additional_properties)
31
30
  field_dict.update(
32
31
  {
33
32
  "question_uuid": question_uuid,
34
- "value": value,
33
+ "answer_data": answer_data,
35
34
  }
36
35
  )
37
36
 
@@ -42,16 +41,11 @@ class AnswerSubmit:
42
41
  d = dict(src_dict)
43
42
  question_uuid = UUID(d.pop("question_uuid"))
44
43
 
45
- def _parse_value(data: object) -> Union[None, bool]:
46
- if data is None:
47
- return data
48
- return cast(Union[None, bool], data)
49
-
50
- value = _parse_value(d.pop("value"))
44
+ answer_data = d.pop("answer_data")
51
45
 
52
46
  answer_submit = cls(
53
47
  question_uuid=question_uuid,
54
- value=value,
48
+ answer_data=answer_data,
55
49
  )
56
50
 
57
51
  answer_submit.additional_properties = d
@@ -1,5 +1,5 @@
1
1
  from collections.abc import Mapping
2
- from typing import Any, TypeVar, Union, cast
2
+ from typing import Any, TypeVar
3
3
  from uuid import UUID
4
4
 
5
5
  from attrs import define as _attrs_define
@@ -13,25 +13,24 @@ class AnswerSubmitRequest:
13
13
  """
14
14
  Attributes:
15
15
  question_uuid (UUID):
16
- value (Union[None, bool]):
16
+ answer_data (Any):
17
17
  """
18
18
 
19
19
  question_uuid: UUID
20
- value: Union[None, bool]
20
+ answer_data: Any
21
21
  additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
22
22
 
23
23
  def to_dict(self) -> dict[str, Any]:
24
24
  question_uuid = str(self.question_uuid)
25
25
 
26
- value: Union[None, bool]
27
- value = self.value
26
+ answer_data = self.answer_data
28
27
 
29
28
  field_dict: dict[str, Any] = {}
30
29
  field_dict.update(self.additional_properties)
31
30
  field_dict.update(
32
31
  {
33
32
  "question_uuid": question_uuid,
34
- "value": value,
33
+ "answer_data": answer_data,
35
34
  }
36
35
  )
37
36
 
@@ -42,16 +41,11 @@ class AnswerSubmitRequest:
42
41
  d = dict(src_dict)
43
42
  question_uuid = UUID(d.pop("question_uuid"))
44
43
 
45
- def _parse_value(data: object) -> Union[None, bool]:
46
- if data is None:
47
- return data
48
- return cast(Union[None, bool], data)
49
-
50
- value = _parse_value(d.pop("value"))
44
+ answer_data = d.pop("answer_data")
51
45
 
52
46
  answer_submit_request = cls(
53
47
  question_uuid=question_uuid,
54
- value=value,
48
+ answer_data=answer_data,
55
49
  )
56
50
 
57
51
  answer_submit_request.additional_properties = d
@@ -74,8 +74,10 @@ class BookingResource:
74
74
  project_end_date_requested_by (Union[Unset, str]):
75
75
  customer_uuid (Union[Unset, UUID]):
76
76
  customer_name (Union[Unset, str]):
77
+ offering_slug (Union[Unset, str]):
77
78
  parent_offering_uuid (Union[Unset, UUID]):
78
79
  parent_offering_name (Union[Unset, str]):
80
+ parent_offering_slug (Union[Unset, str]):
79
81
  parent_uuid (Union[Unset, UUID]):
80
82
  parent_name (Union[Unset, str]):
81
83
  backend_metadata (Union[Unset, BackendMetadata]):
@@ -159,8 +161,10 @@ class BookingResource:
159
161
  project_end_date_requested_by: Union[Unset, str] = UNSET
160
162
  customer_uuid: Union[Unset, UUID] = UNSET
161
163
  customer_name: Union[Unset, str] = UNSET
164
+ offering_slug: Union[Unset, str] = UNSET
162
165
  parent_offering_uuid: Union[Unset, UUID] = UNSET
163
166
  parent_offering_name: Union[Unset, str] = UNSET
167
+ parent_offering_slug: Union[Unset, str] = UNSET
164
168
  parent_uuid: Union[Unset, UUID] = UNSET
165
169
  parent_name: Union[Unset, str] = UNSET
166
170
  backend_metadata: Union[Unset, "BackendMetadata"] = UNSET
@@ -344,12 +348,16 @@ class BookingResource:
344
348
 
345
349
  customer_name = self.customer_name
346
350
 
351
+ offering_slug = self.offering_slug
352
+
347
353
  parent_offering_uuid: Union[Unset, str] = UNSET
348
354
  if not isinstance(self.parent_offering_uuid, Unset):
349
355
  parent_offering_uuid = str(self.parent_offering_uuid)
350
356
 
351
357
  parent_offering_name = self.parent_offering_name
352
358
 
359
+ parent_offering_slug = self.parent_offering_slug
360
+
353
361
  parent_uuid: Union[Unset, str] = UNSET
354
362
  if not isinstance(self.parent_uuid, Unset):
355
363
  parent_uuid = str(self.parent_uuid)
@@ -566,10 +574,14 @@ class BookingResource:
566
574
  field_dict["customer_uuid"] = customer_uuid
567
575
  if customer_name is not UNSET:
568
576
  field_dict["customer_name"] = customer_name
577
+ if offering_slug is not UNSET:
578
+ field_dict["offering_slug"] = offering_slug
569
579
  if parent_offering_uuid is not UNSET:
570
580
  field_dict["parent_offering_uuid"] = parent_offering_uuid
571
581
  if parent_offering_name is not UNSET:
572
582
  field_dict["parent_offering_name"] = parent_offering_name
583
+ if parent_offering_slug is not UNSET:
584
+ field_dict["parent_offering_slug"] = parent_offering_slug
573
585
  if parent_uuid is not UNSET:
574
586
  field_dict["parent_uuid"] = parent_uuid
575
587
  if parent_name is not UNSET:
@@ -878,6 +890,8 @@ class BookingResource:
878
890
 
879
891
  customer_name = d.pop("customer_name", UNSET)
880
892
 
893
+ offering_slug = d.pop("offering_slug", UNSET)
894
+
881
895
  _parent_offering_uuid = d.pop("parent_offering_uuid", UNSET)
882
896
  parent_offering_uuid: Union[Unset, UUID]
883
897
  if isinstance(_parent_offering_uuid, Unset):
@@ -887,6 +901,8 @@ class BookingResource:
887
901
 
888
902
  parent_offering_name = d.pop("parent_offering_name", UNSET)
889
903
 
904
+ parent_offering_slug = d.pop("parent_offering_slug", UNSET)
905
+
890
906
  _parent_uuid = d.pop("parent_uuid", UNSET)
891
907
  parent_uuid: Union[Unset, UUID]
892
908
  if isinstance(_parent_uuid, Unset):
@@ -1111,8 +1127,10 @@ class BookingResource:
1111
1127
  project_end_date_requested_by=project_end_date_requested_by,
1112
1128
  customer_uuid=customer_uuid,
1113
1129
  customer_name=customer_name,
1130
+ offering_slug=offering_slug,
1114
1131
  parent_offering_uuid=parent_offering_uuid,
1115
1132
  parent_offering_name=parent_offering_name,
1133
+ parent_offering_slug=parent_offering_slug,
1116
1134
  parent_uuid=parent_uuid,
1117
1135
  parent_name=parent_name,
1118
1136
  backend_metadata=backend_metadata,
@@ -45,6 +45,7 @@ class BookingResourcesListFieldItem(str, Enum):
45
45
  OFFERING_NAME = "offering_name"
46
46
  OFFERING_PLUGIN_OPTIONS = "offering_plugin_options"
47
47
  OFFERING_SHARED = "offering_shared"
48
+ OFFERING_SLUG = "offering_slug"
48
49
  OFFERING_TERMS_OF_SERVICE = "offering_terms_of_service"
49
50
  OFFERING_THUMBNAIL = "offering_thumbnail"
50
51
  OFFERING_TYPE = "offering_type"
@@ -53,6 +54,7 @@ class BookingResourcesListFieldItem(str, Enum):
53
54
  ORDER_IN_PROGRESS = "order_in_progress"
54
55
  PARENT_NAME = "parent_name"
55
56
  PARENT_OFFERING_NAME = "parent_offering_name"
57
+ PARENT_OFFERING_SLUG = "parent_offering_slug"
56
58
  PARENT_OFFERING_UUID = "parent_offering_uuid"
57
59
  PARENT_UUID = "parent_uuid"
58
60
  PAUSED = "paused"