payi 0.1.0a25__py3-none-any.whl → 0.1.0a27__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 payi might be problematic. Click here for more details.

Files changed (44) hide show
  1. payi/_base_client.py +13 -3
  2. payi/_client.py +24 -8
  3. payi/_response.py +3 -0
  4. payi/_version.py +1 -1
  5. payi/resources/__init__.py +42 -14
  6. payi/resources/billing_models.py +492 -0
  7. payi/resources/budgets/budgets.py +4 -4
  8. payi/resources/categories/resources.py +9 -9
  9. payi/resources/{evaluations/experiences.py → csat.py} +49 -49
  10. payi/resources/ingest.py +23 -11
  11. payi/resources/price_modifiers.py +353 -0
  12. payi/types/__init__.py +10 -1
  13. payi/types/billing_model.py +29 -0
  14. payi/types/billing_model_create_params.py +20 -0
  15. payi/types/billing_model_list_response.py +10 -0
  16. payi/types/billing_model_update_params.py +20 -0
  17. payi/types/budget_create_params.py +2 -2
  18. payi/types/budget_response.py +2 -2
  19. payi/types/bulk_ingest_response.py +7 -0
  20. payi/types/categories/resource_create_params.py +10 -4
  21. payi/types/category_resource_response.py +10 -4
  22. payi/types/cost_data.py +0 -1
  23. payi/types/{shared/evaluation_response.py → csat.py} +3 -4
  24. payi/types/csat_create_params.py +14 -0
  25. payi/types/experience_instance.py +0 -1
  26. payi/types/experiences/experience_type.py +0 -1
  27. payi/types/ingest_event_param.py +14 -6
  28. payi/types/ingest_response.py +7 -1
  29. payi/types/ingest_units_params.py +13 -6
  30. payi/types/paged_budget_list.py +2 -2
  31. payi/types/price_modifier.py +26 -0
  32. payi/types/price_modifier_create_params.py +17 -0
  33. payi/types/price_modifier_retrieve_response.py +10 -0
  34. payi/types/price_modifier_update_params.py +17 -0
  35. payi/types/requests_data.py +2 -1
  36. payi/types/shared/__init__.py +0 -1
  37. payi/types/total_cost_data.py +0 -1
  38. {payi-0.1.0a25.dist-info → payi-0.1.0a27.dist-info}/METADATA +5 -1
  39. {payi-0.1.0a25.dist-info → payi-0.1.0a27.dist-info}/RECORD +41 -33
  40. payi/resources/evaluations/__init__.py +0 -47
  41. payi/resources/evaluations/evaluations.py +0 -134
  42. payi/resources/evaluations/requests.py +0 -200
  43. {payi-0.1.0a25.dist-info → payi-0.1.0a27.dist-info}/WHEEL +0 -0
  44. {payi-0.1.0a25.dist-info → payi-0.1.0a27.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,353 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ import httpx
6
+
7
+ from ..types import price_modifier_create_params, price_modifier_update_params
8
+ from .._types import NOT_GIVEN, Body, Query, Headers, NotGiven
9
+ from .._utils import (
10
+ maybe_transform,
11
+ async_maybe_transform,
12
+ )
13
+ from .._compat import cached_property
14
+ from .._resource import SyncAPIResource, AsyncAPIResource
15
+ from .._response import (
16
+ to_raw_response_wrapper,
17
+ to_streamed_response_wrapper,
18
+ async_to_raw_response_wrapper,
19
+ async_to_streamed_response_wrapper,
20
+ )
21
+ from .._base_client import make_request_options
22
+ from ..types.price_modifier import PriceModifier
23
+ from ..types.price_modifier_retrieve_response import PriceModifierRetrieveResponse
24
+
25
+ __all__ = ["PriceModifiersResource", "AsyncPriceModifiersResource"]
26
+
27
+
28
+ class PriceModifiersResource(SyncAPIResource):
29
+ @cached_property
30
+ def with_raw_response(self) -> PriceModifiersResourceWithRawResponse:
31
+ """
32
+ This property can be used as a prefix for any HTTP method call to return the
33
+ the raw response object instead of the parsed content.
34
+
35
+ For more information, see https://www.github.com/Pay-i/pay-i-python#accessing-raw-response-data-eg-headers
36
+ """
37
+ return PriceModifiersResourceWithRawResponse(self)
38
+
39
+ @cached_property
40
+ def with_streaming_response(self) -> PriceModifiersResourceWithStreamingResponse:
41
+ """
42
+ An alternative to `.with_raw_response` that doesn't eagerly read the response body.
43
+
44
+ For more information, see https://www.github.com/Pay-i/pay-i-python#with_streaming_response
45
+ """
46
+ return PriceModifiersResourceWithStreamingResponse(self)
47
+
48
+ def create(
49
+ self,
50
+ *,
51
+ billing_model_id: str,
52
+ category: str,
53
+ price_modifier: float,
54
+ resource: str,
55
+ # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
56
+ # The extra values given here take precedence over values defined on the client or passed to this method.
57
+ extra_headers: Headers | None = None,
58
+ extra_query: Query | None = None,
59
+ extra_body: Body | None = None,
60
+ timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
61
+ ) -> PriceModifier:
62
+ """
63
+ Args:
64
+ extra_headers: Send extra headers
65
+
66
+ extra_query: Add additional query parameters to the request
67
+
68
+ extra_body: Add additional JSON properties to the request
69
+
70
+ timeout: Override the client-level default timeout for this request, in seconds
71
+ """
72
+ return self._post(
73
+ "/api/v1/price-modifier",
74
+ body=maybe_transform(
75
+ {
76
+ "billing_model_id": billing_model_id,
77
+ "category": category,
78
+ "price_modifier": price_modifier,
79
+ "resource": resource,
80
+ },
81
+ price_modifier_create_params.PriceModifierCreateParams,
82
+ ),
83
+ options=make_request_options(
84
+ extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
85
+ ),
86
+ cast_to=PriceModifier,
87
+ )
88
+
89
+ def retrieve(
90
+ self,
91
+ billing_model_id: str,
92
+ *,
93
+ # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
94
+ # The extra values given here take precedence over values defined on the client or passed to this method.
95
+ extra_headers: Headers | None = None,
96
+ extra_query: Query | None = None,
97
+ extra_body: Body | None = None,
98
+ timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
99
+ ) -> PriceModifierRetrieveResponse:
100
+ """
101
+ Args:
102
+ extra_headers: Send extra headers
103
+
104
+ extra_query: Add additional query parameters to the request
105
+
106
+ extra_body: Add additional JSON properties to the request
107
+
108
+ timeout: Override the client-level default timeout for this request, in seconds
109
+ """
110
+ if not billing_model_id:
111
+ raise ValueError(f"Expected a non-empty value for `billing_model_id` but received {billing_model_id!r}")
112
+ return self._get(
113
+ f"/api/v1/price-modifier/{billing_model_id}",
114
+ options=make_request_options(
115
+ extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
116
+ ),
117
+ cast_to=PriceModifierRetrieveResponse,
118
+ )
119
+
120
+ def update(
121
+ self,
122
+ *,
123
+ billing_model_id: str,
124
+ category: str,
125
+ price_modifier: float,
126
+ resource: str,
127
+ # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
128
+ # The extra values given here take precedence over values defined on the client or passed to this method.
129
+ extra_headers: Headers | None = None,
130
+ extra_query: Query | None = None,
131
+ extra_body: Body | None = None,
132
+ timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
133
+ ) -> PriceModifier:
134
+ """
135
+ Args:
136
+ extra_headers: Send extra headers
137
+
138
+ extra_query: Add additional query parameters to the request
139
+
140
+ extra_body: Add additional JSON properties to the request
141
+
142
+ timeout: Override the client-level default timeout for this request, in seconds
143
+ """
144
+ return self._put(
145
+ "/api/v1/price-modifier",
146
+ body=maybe_transform(
147
+ {
148
+ "billing_model_id": billing_model_id,
149
+ "category": category,
150
+ "price_modifier": price_modifier,
151
+ "resource": resource,
152
+ },
153
+ price_modifier_update_params.PriceModifierUpdateParams,
154
+ ),
155
+ options=make_request_options(
156
+ extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
157
+ ),
158
+ cast_to=PriceModifier,
159
+ )
160
+
161
+
162
+ class AsyncPriceModifiersResource(AsyncAPIResource):
163
+ @cached_property
164
+ def with_raw_response(self) -> AsyncPriceModifiersResourceWithRawResponse:
165
+ """
166
+ This property can be used as a prefix for any HTTP method call to return the
167
+ the raw response object instead of the parsed content.
168
+
169
+ For more information, see https://www.github.com/Pay-i/pay-i-python#accessing-raw-response-data-eg-headers
170
+ """
171
+ return AsyncPriceModifiersResourceWithRawResponse(self)
172
+
173
+ @cached_property
174
+ def with_streaming_response(self) -> AsyncPriceModifiersResourceWithStreamingResponse:
175
+ """
176
+ An alternative to `.with_raw_response` that doesn't eagerly read the response body.
177
+
178
+ For more information, see https://www.github.com/Pay-i/pay-i-python#with_streaming_response
179
+ """
180
+ return AsyncPriceModifiersResourceWithStreamingResponse(self)
181
+
182
+ async def create(
183
+ self,
184
+ *,
185
+ billing_model_id: str,
186
+ category: str,
187
+ price_modifier: float,
188
+ resource: str,
189
+ # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
190
+ # The extra values given here take precedence over values defined on the client or passed to this method.
191
+ extra_headers: Headers | None = None,
192
+ extra_query: Query | None = None,
193
+ extra_body: Body | None = None,
194
+ timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
195
+ ) -> PriceModifier:
196
+ """
197
+ Args:
198
+ extra_headers: Send extra headers
199
+
200
+ extra_query: Add additional query parameters to the request
201
+
202
+ extra_body: Add additional JSON properties to the request
203
+
204
+ timeout: Override the client-level default timeout for this request, in seconds
205
+ """
206
+ return await self._post(
207
+ "/api/v1/price-modifier",
208
+ body=await async_maybe_transform(
209
+ {
210
+ "billing_model_id": billing_model_id,
211
+ "category": category,
212
+ "price_modifier": price_modifier,
213
+ "resource": resource,
214
+ },
215
+ price_modifier_create_params.PriceModifierCreateParams,
216
+ ),
217
+ options=make_request_options(
218
+ extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
219
+ ),
220
+ cast_to=PriceModifier,
221
+ )
222
+
223
+ async def retrieve(
224
+ self,
225
+ billing_model_id: str,
226
+ *,
227
+ # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
228
+ # The extra values given here take precedence over values defined on the client or passed to this method.
229
+ extra_headers: Headers | None = None,
230
+ extra_query: Query | None = None,
231
+ extra_body: Body | None = None,
232
+ timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
233
+ ) -> PriceModifierRetrieveResponse:
234
+ """
235
+ Args:
236
+ extra_headers: Send extra headers
237
+
238
+ extra_query: Add additional query parameters to the request
239
+
240
+ extra_body: Add additional JSON properties to the request
241
+
242
+ timeout: Override the client-level default timeout for this request, in seconds
243
+ """
244
+ if not billing_model_id:
245
+ raise ValueError(f"Expected a non-empty value for `billing_model_id` but received {billing_model_id!r}")
246
+ return await self._get(
247
+ f"/api/v1/price-modifier/{billing_model_id}",
248
+ options=make_request_options(
249
+ extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
250
+ ),
251
+ cast_to=PriceModifierRetrieveResponse,
252
+ )
253
+
254
+ async def update(
255
+ self,
256
+ *,
257
+ billing_model_id: str,
258
+ category: str,
259
+ price_modifier: float,
260
+ resource: str,
261
+ # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
262
+ # The extra values given here take precedence over values defined on the client or passed to this method.
263
+ extra_headers: Headers | None = None,
264
+ extra_query: Query | None = None,
265
+ extra_body: Body | None = None,
266
+ timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
267
+ ) -> PriceModifier:
268
+ """
269
+ Args:
270
+ extra_headers: Send extra headers
271
+
272
+ extra_query: Add additional query parameters to the request
273
+
274
+ extra_body: Add additional JSON properties to the request
275
+
276
+ timeout: Override the client-level default timeout for this request, in seconds
277
+ """
278
+ return await self._put(
279
+ "/api/v1/price-modifier",
280
+ body=await async_maybe_transform(
281
+ {
282
+ "billing_model_id": billing_model_id,
283
+ "category": category,
284
+ "price_modifier": price_modifier,
285
+ "resource": resource,
286
+ },
287
+ price_modifier_update_params.PriceModifierUpdateParams,
288
+ ),
289
+ options=make_request_options(
290
+ extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
291
+ ),
292
+ cast_to=PriceModifier,
293
+ )
294
+
295
+
296
+ class PriceModifiersResourceWithRawResponse:
297
+ def __init__(self, price_modifiers: PriceModifiersResource) -> None:
298
+ self._price_modifiers = price_modifiers
299
+
300
+ self.create = to_raw_response_wrapper(
301
+ price_modifiers.create,
302
+ )
303
+ self.retrieve = to_raw_response_wrapper(
304
+ price_modifiers.retrieve,
305
+ )
306
+ self.update = to_raw_response_wrapper(
307
+ price_modifiers.update,
308
+ )
309
+
310
+
311
+ class AsyncPriceModifiersResourceWithRawResponse:
312
+ def __init__(self, price_modifiers: AsyncPriceModifiersResource) -> None:
313
+ self._price_modifiers = price_modifiers
314
+
315
+ self.create = async_to_raw_response_wrapper(
316
+ price_modifiers.create,
317
+ )
318
+ self.retrieve = async_to_raw_response_wrapper(
319
+ price_modifiers.retrieve,
320
+ )
321
+ self.update = async_to_raw_response_wrapper(
322
+ price_modifiers.update,
323
+ )
324
+
325
+
326
+ class PriceModifiersResourceWithStreamingResponse:
327
+ def __init__(self, price_modifiers: PriceModifiersResource) -> None:
328
+ self._price_modifiers = price_modifiers
329
+
330
+ self.create = to_streamed_response_wrapper(
331
+ price_modifiers.create,
332
+ )
333
+ self.retrieve = to_streamed_response_wrapper(
334
+ price_modifiers.retrieve,
335
+ )
336
+ self.update = to_streamed_response_wrapper(
337
+ price_modifiers.update,
338
+ )
339
+
340
+
341
+ class AsyncPriceModifiersResourceWithStreamingResponse:
342
+ def __init__(self, price_modifiers: AsyncPriceModifiersResource) -> None:
343
+ self._price_modifiers = price_modifiers
344
+
345
+ self.create = async_to_streamed_response_wrapper(
346
+ price_modifiers.create,
347
+ )
348
+ self.retrieve = async_to_streamed_response_wrapper(
349
+ price_modifiers.retrieve,
350
+ )
351
+ self.update = async_to_streamed_response_wrapper(
352
+ price_modifiers.update,
353
+ )
payi/types/__init__.py CHANGED
@@ -2,10 +2,12 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
- from .shared import EvaluationResponse as EvaluationResponse
5
+ from .csat import Csat as Csat
6
6
  from .cost_data import CostData as CostData
7
7
  from .cost_details import CostDetails as CostDetails
8
+ from .billing_model import BillingModel as BillingModel
8
9
  from .requests_data import RequestsData as RequestsData
10
+ from .price_modifier import PriceModifier as PriceModifier
9
11
  from .budget_response import BudgetResponse as BudgetResponse
10
12
  from .ingest_response import IngestResponse as IngestResponse
11
13
  from .total_cost_data import TotalCostData as TotalCostData
@@ -13,6 +15,7 @@ from .default_response import DefaultResponse as DefaultResponse
13
15
  from .category_response import CategoryResponse as CategoryResponse
14
16
  from .paged_budget_list import PagedBudgetList as PagedBudgetList
15
17
  from .budget_list_params import BudgetListParams as BudgetListParams
18
+ from .csat_create_params import CsatCreateParams as CsatCreateParams
16
19
  from .ingest_bulk_params import IngestBulkParams as IngestBulkParams
17
20
  from .ingest_event_param import IngestEventParam as IngestEventParam
18
21
  from .experience_instance import ExperienceInstance as ExperienceInstance
@@ -24,5 +27,11 @@ from .category_list_response import CategoryListResponse as CategoryListResponse
24
27
  from .budget_history_response import BudgetHistoryResponse as BudgetHistoryResponse
25
28
  from .category_delete_response import CategoryDeleteResponse as CategoryDeleteResponse
26
29
  from .category_resource_response import CategoryResourceResponse as CategoryResourceResponse
30
+ from .billing_model_create_params import BillingModelCreateParams as BillingModelCreateParams
31
+ from .billing_model_list_response import BillingModelListResponse as BillingModelListResponse
32
+ from .billing_model_update_params import BillingModelUpdateParams as BillingModelUpdateParams
33
+ from .price_modifier_create_params import PriceModifierCreateParams as PriceModifierCreateParams
34
+ from .price_modifier_update_params import PriceModifierUpdateParams as PriceModifierUpdateParams
27
35
  from .category_list_resources_response import CategoryListResourcesResponse as CategoryListResourcesResponse
36
+ from .price_modifier_retrieve_response import PriceModifierRetrieveResponse as PriceModifierRetrieveResponse
28
37
  from .category_delete_resource_response import CategoryDeleteResourceResponse as CategoryDeleteResourceResponse
@@ -0,0 +1,29 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import Optional
4
+ from datetime import datetime
5
+ from typing_extensions import Literal
6
+
7
+ from .._models import BaseModel
8
+
9
+ __all__ = ["BillingModel"]
10
+
11
+
12
+ class BillingModel(BaseModel):
13
+ billing_model_id: Optional[str] = None
14
+
15
+ created_on: datetime
16
+
17
+ default: bool
18
+
19
+ name: str
20
+
21
+ type: Literal["costplus"]
22
+
23
+ updated_on: datetime
24
+
25
+ prepaid_amount: Optional[float] = None
26
+
27
+ prepaid_max: Optional[float] = None
28
+
29
+ threshold: Optional[float] = None
@@ -0,0 +1,20 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+ from typing_extensions import Literal, Required, TypedDict
7
+
8
+ __all__ = ["BillingModelCreateParams"]
9
+
10
+
11
+ class BillingModelCreateParams(TypedDict, total=False):
12
+ name: Required[str]
13
+
14
+ type: Required[Literal["costplus"]]
15
+
16
+ prepaid_amount: Optional[float]
17
+
18
+ prepaid_max: Optional[float]
19
+
20
+ threshold: Optional[float]
@@ -0,0 +1,10 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import List
4
+ from typing_extensions import TypeAlias
5
+
6
+ from .billing_model import BillingModel
7
+
8
+ __all__ = ["BillingModelListResponse"]
9
+
10
+ BillingModelListResponse: TypeAlias = List[BillingModel]
@@ -0,0 +1,20 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+ from typing_extensions import Literal, Required, TypedDict
7
+
8
+ __all__ = ["BillingModelUpdateParams"]
9
+
10
+
11
+ class BillingModelUpdateParams(TypedDict, total=False):
12
+ type: Required[Literal["costplus"]]
13
+
14
+ name: Optional[str]
15
+
16
+ prepaid_amount: Optional[float]
17
+
18
+ prepaid_max: Optional[float]
19
+
20
+ threshold: Optional[float]
@@ -21,8 +21,8 @@ class BudgetCreateParams(TypedDict, total=False):
21
21
 
22
22
  budget_tags: Optional[List[str]]
23
23
 
24
- budget_type: Literal["conservative", "liberal"]
25
-
26
24
  cost_basis: Literal["base", "billed"]
27
25
 
28
26
  currency: Literal["usd"]
27
+
28
+ threshold: Optional[float]
@@ -21,8 +21,6 @@ class Budget(BaseModel):
21
21
 
22
22
  budget_response_type: Literal["block", "allow"]
23
23
 
24
- budget_type: Literal["conservative", "liberal"]
25
-
26
24
  budget_update_timestamp: datetime
27
25
 
28
26
  currency: Literal["usd"]
@@ -33,6 +31,8 @@ class Budget(BaseModel):
33
31
 
34
32
  budget_tags: Optional[List[str]] = None
35
33
 
34
+ threshold: Optional[float] = None
35
+
36
36
 
37
37
  class BudgetResponse(BaseModel):
38
38
  budget: Budget
@@ -28,6 +28,13 @@ class Error(BaseModel):
28
28
  item_index: Optional[int] = None
29
29
 
30
30
  xproxy_result: Optional[ErrorXproxyResult] = None
31
+ """
32
+ Represents an generic error that occurred as a result of processing a request.
33
+ APIM returns an (not customizable) error response body of { "statusCode",
34
+ "message" } and this class matches this schema. Derived classes may add
35
+ additional required fields if these classes are specified as produced as a
36
+ return type specific endpoints.
37
+ """
31
38
 
32
39
 
33
40
  class BulkIngestResponse(BaseModel):
@@ -2,24 +2,30 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
- from typing import Union
5
+ from typing import Dict, Union
6
6
  from datetime import datetime
7
7
  from typing_extensions import Required, Annotated, TypedDict
8
8
 
9
9
  from ..._utils import PropertyInfo
10
10
 
11
- __all__ = ["ResourceCreateParams"]
11
+ __all__ = ["ResourceCreateParams", "Units"]
12
12
 
13
13
 
14
14
  class ResourceCreateParams(TypedDict, total=False):
15
15
  category: Required[str]
16
16
 
17
- input_price: float
17
+ units: Required[Dict[str, Units]]
18
18
 
19
19
  max_input_units: int
20
20
 
21
21
  max_output_units: int
22
22
 
23
- output_price: float
23
+ max_total_units: int
24
24
 
25
25
  start_timestamp: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")]
26
+
27
+
28
+ class Units(TypedDict, total=False):
29
+ input_price: Required[float]
30
+
31
+ output_price: Required[float]
@@ -1,11 +1,17 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
- from typing import Optional
3
+ from typing import Dict, Optional
4
4
  from datetime import datetime
5
5
 
6
6
  from .._models import BaseModel
7
7
 
8
- __all__ = ["CategoryResourceResponse"]
8
+ __all__ = ["CategoryResourceResponse", "Units"]
9
+
10
+
11
+ class Units(BaseModel):
12
+ input_price: float
13
+
14
+ output_price: float
9
15
 
10
16
 
11
17
  class CategoryResourceResponse(BaseModel):
@@ -17,10 +23,10 @@ class CategoryResourceResponse(BaseModel):
17
23
 
18
24
  start_timestamp: datetime
19
25
 
20
- input_price: Optional[float] = None
26
+ units: Dict[str, Units]
21
27
 
22
28
  max_input_units: Optional[int] = None
23
29
 
24
30
  max_output_units: Optional[int] = None
25
31
 
26
- output_price: Optional[float] = None
32
+ max_total_units: Optional[int] = None
payi/types/cost_data.py CHANGED
@@ -1,7 +1,6 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
 
4
-
5
4
  from .._models import BaseModel
6
5
  from .cost_details import CostDetails
7
6
 
@@ -1,11 +1,10 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
 
4
+ from .._models import BaseModel
4
5
 
5
- from ..._models import BaseModel
6
+ __all__ = ["Csat"]
6
7
 
7
- __all__ = ["EvaluationResponse"]
8
8
 
9
-
10
- class EvaluationResponse(BaseModel):
9
+ class Csat(BaseModel):
11
10
  request_id: str
@@ -0,0 +1,14 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+ from typing_extensions import Required, TypedDict
7
+
8
+ __all__ = ["CsatCreateParams"]
9
+
10
+
11
+ class CsatCreateParams(TypedDict, total=False):
12
+ csat_rating: Required[int]
13
+
14
+ user_id: Optional[str]
@@ -1,7 +1,6 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
 
4
-
5
4
  from .._models import BaseModel
6
5
 
7
6
  __all__ = ["ExperienceInstance"]
@@ -1,7 +1,6 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
 
4
-
5
4
  from ..._models import BaseModel
6
5
 
7
6
  __all__ = ["ExperienceType"]