studyfetch-sdk 0.1.0a19__py3-none-any.whl → 0.1.0a20__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.
- studyfetch_sdk/_models.py +23 -2
- studyfetch_sdk/_version.py +1 -1
- studyfetch_sdk/resources/v1/__init__.py +0 -98
- studyfetch_sdk/resources/v1/materials/upload.py +24 -0
- studyfetch_sdk/resources/v1/v1.py +0 -224
- studyfetch_sdk/types/v1/__init__.py +0 -23
- studyfetch_sdk/types/v1/component_create_params.py +24 -0
- studyfetch_sdk/types/v1/component_generate_embed_params.py +7 -1
- studyfetch_sdk/types/v1/materials/upload_create_presigned_url_params.py +3 -0
- studyfetch_sdk/types/v1/materials/upload_upload_file_and_process_params.py +3 -0
- studyfetch_sdk/types/v1/materials/upload_upload_file_params.py +3 -0
- {studyfetch_sdk-0.1.0a19.dist-info → studyfetch_sdk-0.1.0a20.dist-info}/METADATA +1 -1
- {studyfetch_sdk-0.1.0a19.dist-info → studyfetch_sdk-0.1.0a20.dist-info}/RECORD +15 -70
- studyfetch_sdk/resources/v1/audio_recaps/__init__.py +0 -33
- studyfetch_sdk/resources/v1/audio_recaps/audio_recaps.py +0 -328
- studyfetch_sdk/resources/v1/audio_recaps/sections.py +0 -250
- studyfetch_sdk/resources/v1/chat/__init__.py +0 -47
- studyfetch_sdk/resources/v1/chat/chat.py +0 -574
- studyfetch_sdk/resources/v1/chat/sessions.py +0 -222
- studyfetch_sdk/resources/v1/chat/test.py +0 -190
- studyfetch_sdk/resources/v1/data_analyst/__init__.py +0 -47
- studyfetch_sdk/resources/v1/data_analyst/data_analyst.py +0 -582
- studyfetch_sdk/resources/v1/data_analyst/sessions.py +0 -222
- studyfetch_sdk/resources/v1/data_analyst/test.py +0 -190
- studyfetch_sdk/resources/v1/explainers.py +0 -441
- studyfetch_sdk/resources/v1/flashcards.py +0 -783
- studyfetch_sdk/resources/v1/scenarios/__init__.py +0 -61
- studyfetch_sdk/resources/v1/scenarios/component.py +0 -426
- studyfetch_sdk/resources/v1/scenarios/scenarios.py +0 -936
- studyfetch_sdk/resources/v1/scenarios/sessions.py +0 -236
- studyfetch_sdk/resources/v1/scenarios/submissions/__init__.py +0 -33
- studyfetch_sdk/resources/v1/scenarios/submissions/submissions.py +0 -102
- studyfetch_sdk/resources/v1/scenarios/submissions/user.py +0 -210
- studyfetch_sdk/resources/v1/tests/__init__.py +0 -33
- studyfetch_sdk/resources/v1/tests/component.py +0 -160
- studyfetch_sdk/resources/v1/tests/tests.py +0 -682
- studyfetch_sdk/types/v1/audio_recaps/__init__.py +0 -3
- studyfetch_sdk/types/v1/chat/__init__.py +0 -5
- studyfetch_sdk/types/v1/chat/session_retrieve_params.py +0 -11
- studyfetch_sdk/types/v1/chat_get_session_params.py +0 -13
- studyfetch_sdk/types/v1/chat_send_message_params.py +0 -54
- studyfetch_sdk/types/v1/chat_stream_params.py +0 -28
- studyfetch_sdk/types/v1/data_analyst/__init__.py +0 -5
- studyfetch_sdk/types/v1/data_analyst/session_retrieve_params.py +0 -11
- studyfetch_sdk/types/v1/data_analyst_retrieve_session_params.py +0 -13
- studyfetch_sdk/types/v1/data_analyst_send_message_params.py +0 -54
- studyfetch_sdk/types/v1/data_analyst_stream_params.py +0 -28
- studyfetch_sdk/types/v1/explainer_create_params.py +0 -45
- studyfetch_sdk/types/v1/explainer_handle_webhook_params.py +0 -53
- studyfetch_sdk/types/v1/flashcard_batch_process_params.py +0 -36
- studyfetch_sdk/types/v1/flashcard_batch_process_response.py +0 -39
- studyfetch_sdk/types/v1/flashcard_get_algorithm_response.py +0 -37
- studyfetch_sdk/types/v1/flashcard_get_all_params.py +0 -23
- studyfetch_sdk/types/v1/flashcard_get_due_params.py +0 -19
- studyfetch_sdk/types/v1/flashcard_get_stats_params.py +0 -17
- studyfetch_sdk/types/v1/flashcard_get_types_response.py +0 -14
- studyfetch_sdk/types/v1/flashcard_rate_params.py +0 -23
- studyfetch_sdk/types/v1/scenario_create_params.py +0 -48
- studyfetch_sdk/types/v1/scenario_submit_answer_params.py +0 -18
- studyfetch_sdk/types/v1/scenario_update_params.py +0 -45
- studyfetch_sdk/types/v1/scenarios/__init__.py +0 -5
- studyfetch_sdk/types/v1/scenarios/component_update_params.py +0 -45
- studyfetch_sdk/types/v1/scenarios/submissions/__init__.py +0 -3
- studyfetch_sdk/types/v1/test_create_params.py +0 -20
- studyfetch_sdk/types/v1/test_retake_params.py +0 -14
- studyfetch_sdk/types/v1/test_submit_answer_params.py +0 -20
- studyfetch_sdk/types/v1/test_submit_params.py +0 -14
- studyfetch_sdk/types/v1/tests/__init__.py +0 -3
- {studyfetch_sdk-0.1.0a19.dist-info → studyfetch_sdk-0.1.0a20.dist-info}/WHEEL +0 -0
- {studyfetch_sdk-0.1.0a19.dist-info → studyfetch_sdk-0.1.0a20.dist-info}/licenses/LICENSE +0 -0
@@ -1,328 +0,0 @@
|
|
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 .sections import (
|
8
|
-
SectionsResource,
|
9
|
-
AsyncSectionsResource,
|
10
|
-
SectionsResourceWithRawResponse,
|
11
|
-
AsyncSectionsResourceWithRawResponse,
|
12
|
-
SectionsResourceWithStreamingResponse,
|
13
|
-
AsyncSectionsResourceWithStreamingResponse,
|
14
|
-
)
|
15
|
-
from ...._types import NOT_GIVEN, Body, Query, Headers, NoneType, NotGiven
|
16
|
-
from ...._compat import cached_property
|
17
|
-
from ...._resource import SyncAPIResource, AsyncAPIResource
|
18
|
-
from ...._response import (
|
19
|
-
to_raw_response_wrapper,
|
20
|
-
to_streamed_response_wrapper,
|
21
|
-
async_to_raw_response_wrapper,
|
22
|
-
async_to_streamed_response_wrapper,
|
23
|
-
)
|
24
|
-
from ...._base_client import make_request_options
|
25
|
-
|
26
|
-
__all__ = ["AudioRecapsResource", "AsyncAudioRecapsResource"]
|
27
|
-
|
28
|
-
|
29
|
-
class AudioRecapsResource(SyncAPIResource):
|
30
|
-
@cached_property
|
31
|
-
def sections(self) -> SectionsResource:
|
32
|
-
return SectionsResource(self._client)
|
33
|
-
|
34
|
-
@cached_property
|
35
|
-
def with_raw_response(self) -> AudioRecapsResourceWithRawResponse:
|
36
|
-
"""
|
37
|
-
This property can be used as a prefix for any HTTP method call to return
|
38
|
-
the raw response object instead of the parsed content.
|
39
|
-
|
40
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#accessing-raw-response-data-eg-headers
|
41
|
-
"""
|
42
|
-
return AudioRecapsResourceWithRawResponse(self)
|
43
|
-
|
44
|
-
@cached_property
|
45
|
-
def with_streaming_response(self) -> AudioRecapsResourceWithStreamingResponse:
|
46
|
-
"""
|
47
|
-
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
48
|
-
|
49
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#with_streaming_response
|
50
|
-
"""
|
51
|
-
return AudioRecapsResourceWithStreamingResponse(self)
|
52
|
-
|
53
|
-
def create(
|
54
|
-
self,
|
55
|
-
*,
|
56
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
57
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
58
|
-
extra_headers: Headers | None = None,
|
59
|
-
extra_query: Query | None = None,
|
60
|
-
extra_body: Body | None = None,
|
61
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
62
|
-
) -> None:
|
63
|
-
"""Create a new audio recap"""
|
64
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
65
|
-
return self._post(
|
66
|
-
"/api/v1/audio-recaps/create",
|
67
|
-
options=make_request_options(
|
68
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
69
|
-
),
|
70
|
-
cast_to=NoneType,
|
71
|
-
)
|
72
|
-
|
73
|
-
def retrieve(
|
74
|
-
self,
|
75
|
-
recap_id: str,
|
76
|
-
*,
|
77
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
78
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
79
|
-
extra_headers: Headers | None = None,
|
80
|
-
extra_query: Query | None = None,
|
81
|
-
extra_body: Body | None = None,
|
82
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
83
|
-
) -> None:
|
84
|
-
"""
|
85
|
-
Get audio recap by ID
|
86
|
-
|
87
|
-
Args:
|
88
|
-
extra_headers: Send extra headers
|
89
|
-
|
90
|
-
extra_query: Add additional query parameters to the request
|
91
|
-
|
92
|
-
extra_body: Add additional JSON properties to the request
|
93
|
-
|
94
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
95
|
-
"""
|
96
|
-
if not recap_id:
|
97
|
-
raise ValueError(f"Expected a non-empty value for `recap_id` but received {recap_id!r}")
|
98
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
99
|
-
return self._get(
|
100
|
-
f"/api/v1/audio-recaps/{recap_id}/get",
|
101
|
-
options=make_request_options(
|
102
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
103
|
-
),
|
104
|
-
cast_to=NoneType,
|
105
|
-
)
|
106
|
-
|
107
|
-
def ask_question(
|
108
|
-
self,
|
109
|
-
recap_id: str,
|
110
|
-
*,
|
111
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
112
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
113
|
-
extra_headers: Headers | None = None,
|
114
|
-
extra_query: Query | None = None,
|
115
|
-
extra_body: Body | None = None,
|
116
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
117
|
-
) -> None:
|
118
|
-
"""
|
119
|
-
Ask a question about the audio recap
|
120
|
-
|
121
|
-
Args:
|
122
|
-
extra_headers: Send extra headers
|
123
|
-
|
124
|
-
extra_query: Add additional query parameters to the request
|
125
|
-
|
126
|
-
extra_body: Add additional JSON properties to the request
|
127
|
-
|
128
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
129
|
-
"""
|
130
|
-
if not recap_id:
|
131
|
-
raise ValueError(f"Expected a non-empty value for `recap_id` but received {recap_id!r}")
|
132
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
133
|
-
return self._post(
|
134
|
-
f"/api/v1/audio-recaps/{recap_id}/ask-question",
|
135
|
-
options=make_request_options(
|
136
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
137
|
-
),
|
138
|
-
cast_to=NoneType,
|
139
|
-
)
|
140
|
-
|
141
|
-
|
142
|
-
class AsyncAudioRecapsResource(AsyncAPIResource):
|
143
|
-
@cached_property
|
144
|
-
def sections(self) -> AsyncSectionsResource:
|
145
|
-
return AsyncSectionsResource(self._client)
|
146
|
-
|
147
|
-
@cached_property
|
148
|
-
def with_raw_response(self) -> AsyncAudioRecapsResourceWithRawResponse:
|
149
|
-
"""
|
150
|
-
This property can be used as a prefix for any HTTP method call to return
|
151
|
-
the raw response object instead of the parsed content.
|
152
|
-
|
153
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#accessing-raw-response-data-eg-headers
|
154
|
-
"""
|
155
|
-
return AsyncAudioRecapsResourceWithRawResponse(self)
|
156
|
-
|
157
|
-
@cached_property
|
158
|
-
def with_streaming_response(self) -> AsyncAudioRecapsResourceWithStreamingResponse:
|
159
|
-
"""
|
160
|
-
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
161
|
-
|
162
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#with_streaming_response
|
163
|
-
"""
|
164
|
-
return AsyncAudioRecapsResourceWithStreamingResponse(self)
|
165
|
-
|
166
|
-
async def create(
|
167
|
-
self,
|
168
|
-
*,
|
169
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
170
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
171
|
-
extra_headers: Headers | None = None,
|
172
|
-
extra_query: Query | None = None,
|
173
|
-
extra_body: Body | None = None,
|
174
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
175
|
-
) -> None:
|
176
|
-
"""Create a new audio recap"""
|
177
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
178
|
-
return await self._post(
|
179
|
-
"/api/v1/audio-recaps/create",
|
180
|
-
options=make_request_options(
|
181
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
182
|
-
),
|
183
|
-
cast_to=NoneType,
|
184
|
-
)
|
185
|
-
|
186
|
-
async def retrieve(
|
187
|
-
self,
|
188
|
-
recap_id: str,
|
189
|
-
*,
|
190
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
191
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
192
|
-
extra_headers: Headers | None = None,
|
193
|
-
extra_query: Query | None = None,
|
194
|
-
extra_body: Body | None = None,
|
195
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
196
|
-
) -> None:
|
197
|
-
"""
|
198
|
-
Get audio recap by ID
|
199
|
-
|
200
|
-
Args:
|
201
|
-
extra_headers: Send extra headers
|
202
|
-
|
203
|
-
extra_query: Add additional query parameters to the request
|
204
|
-
|
205
|
-
extra_body: Add additional JSON properties to the request
|
206
|
-
|
207
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
208
|
-
"""
|
209
|
-
if not recap_id:
|
210
|
-
raise ValueError(f"Expected a non-empty value for `recap_id` but received {recap_id!r}")
|
211
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
212
|
-
return await self._get(
|
213
|
-
f"/api/v1/audio-recaps/{recap_id}/get",
|
214
|
-
options=make_request_options(
|
215
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
216
|
-
),
|
217
|
-
cast_to=NoneType,
|
218
|
-
)
|
219
|
-
|
220
|
-
async def ask_question(
|
221
|
-
self,
|
222
|
-
recap_id: str,
|
223
|
-
*,
|
224
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
225
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
226
|
-
extra_headers: Headers | None = None,
|
227
|
-
extra_query: Query | None = None,
|
228
|
-
extra_body: Body | None = None,
|
229
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
230
|
-
) -> None:
|
231
|
-
"""
|
232
|
-
Ask a question about the audio recap
|
233
|
-
|
234
|
-
Args:
|
235
|
-
extra_headers: Send extra headers
|
236
|
-
|
237
|
-
extra_query: Add additional query parameters to the request
|
238
|
-
|
239
|
-
extra_body: Add additional JSON properties to the request
|
240
|
-
|
241
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
242
|
-
"""
|
243
|
-
if not recap_id:
|
244
|
-
raise ValueError(f"Expected a non-empty value for `recap_id` but received {recap_id!r}")
|
245
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
246
|
-
return await self._post(
|
247
|
-
f"/api/v1/audio-recaps/{recap_id}/ask-question",
|
248
|
-
options=make_request_options(
|
249
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
250
|
-
),
|
251
|
-
cast_to=NoneType,
|
252
|
-
)
|
253
|
-
|
254
|
-
|
255
|
-
class AudioRecapsResourceWithRawResponse:
|
256
|
-
def __init__(self, audio_recaps: AudioRecapsResource) -> None:
|
257
|
-
self._audio_recaps = audio_recaps
|
258
|
-
|
259
|
-
self.create = to_raw_response_wrapper(
|
260
|
-
audio_recaps.create,
|
261
|
-
)
|
262
|
-
self.retrieve = to_raw_response_wrapper(
|
263
|
-
audio_recaps.retrieve,
|
264
|
-
)
|
265
|
-
self.ask_question = to_raw_response_wrapper(
|
266
|
-
audio_recaps.ask_question,
|
267
|
-
)
|
268
|
-
|
269
|
-
@cached_property
|
270
|
-
def sections(self) -> SectionsResourceWithRawResponse:
|
271
|
-
return SectionsResourceWithRawResponse(self._audio_recaps.sections)
|
272
|
-
|
273
|
-
|
274
|
-
class AsyncAudioRecapsResourceWithRawResponse:
|
275
|
-
def __init__(self, audio_recaps: AsyncAudioRecapsResource) -> None:
|
276
|
-
self._audio_recaps = audio_recaps
|
277
|
-
|
278
|
-
self.create = async_to_raw_response_wrapper(
|
279
|
-
audio_recaps.create,
|
280
|
-
)
|
281
|
-
self.retrieve = async_to_raw_response_wrapper(
|
282
|
-
audio_recaps.retrieve,
|
283
|
-
)
|
284
|
-
self.ask_question = async_to_raw_response_wrapper(
|
285
|
-
audio_recaps.ask_question,
|
286
|
-
)
|
287
|
-
|
288
|
-
@cached_property
|
289
|
-
def sections(self) -> AsyncSectionsResourceWithRawResponse:
|
290
|
-
return AsyncSectionsResourceWithRawResponse(self._audio_recaps.sections)
|
291
|
-
|
292
|
-
|
293
|
-
class AudioRecapsResourceWithStreamingResponse:
|
294
|
-
def __init__(self, audio_recaps: AudioRecapsResource) -> None:
|
295
|
-
self._audio_recaps = audio_recaps
|
296
|
-
|
297
|
-
self.create = to_streamed_response_wrapper(
|
298
|
-
audio_recaps.create,
|
299
|
-
)
|
300
|
-
self.retrieve = to_streamed_response_wrapper(
|
301
|
-
audio_recaps.retrieve,
|
302
|
-
)
|
303
|
-
self.ask_question = to_streamed_response_wrapper(
|
304
|
-
audio_recaps.ask_question,
|
305
|
-
)
|
306
|
-
|
307
|
-
@cached_property
|
308
|
-
def sections(self) -> SectionsResourceWithStreamingResponse:
|
309
|
-
return SectionsResourceWithStreamingResponse(self._audio_recaps.sections)
|
310
|
-
|
311
|
-
|
312
|
-
class AsyncAudioRecapsResourceWithStreamingResponse:
|
313
|
-
def __init__(self, audio_recaps: AsyncAudioRecapsResource) -> None:
|
314
|
-
self._audio_recaps = audio_recaps
|
315
|
-
|
316
|
-
self.create = async_to_streamed_response_wrapper(
|
317
|
-
audio_recaps.create,
|
318
|
-
)
|
319
|
-
self.retrieve = async_to_streamed_response_wrapper(
|
320
|
-
audio_recaps.retrieve,
|
321
|
-
)
|
322
|
-
self.ask_question = async_to_streamed_response_wrapper(
|
323
|
-
audio_recaps.ask_question,
|
324
|
-
)
|
325
|
-
|
326
|
-
@cached_property
|
327
|
-
def sections(self) -> AsyncSectionsResourceWithStreamingResponse:
|
328
|
-
return AsyncSectionsResourceWithStreamingResponse(self._audio_recaps.sections)
|
@@ -1,250 +0,0 @@
|
|
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 NOT_GIVEN, Body, Query, Headers, NoneType, NotGiven
|
8
|
-
from ...._compat import cached_property
|
9
|
-
from ...._resource import SyncAPIResource, AsyncAPIResource
|
10
|
-
from ...._response import (
|
11
|
-
to_raw_response_wrapper,
|
12
|
-
to_streamed_response_wrapper,
|
13
|
-
async_to_raw_response_wrapper,
|
14
|
-
async_to_streamed_response_wrapper,
|
15
|
-
)
|
16
|
-
from ...._base_client import make_request_options
|
17
|
-
|
18
|
-
__all__ = ["SectionsResource", "AsyncSectionsResource"]
|
19
|
-
|
20
|
-
|
21
|
-
class SectionsResource(SyncAPIResource):
|
22
|
-
@cached_property
|
23
|
-
def with_raw_response(self) -> SectionsResourceWithRawResponse:
|
24
|
-
"""
|
25
|
-
This property can be used as a prefix for any HTTP method call to return
|
26
|
-
the raw response object instead of the parsed content.
|
27
|
-
|
28
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#accessing-raw-response-data-eg-headers
|
29
|
-
"""
|
30
|
-
return SectionsResourceWithRawResponse(self)
|
31
|
-
|
32
|
-
@cached_property
|
33
|
-
def with_streaming_response(self) -> SectionsResourceWithStreamingResponse:
|
34
|
-
"""
|
35
|
-
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
36
|
-
|
37
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#with_streaming_response
|
38
|
-
"""
|
39
|
-
return SectionsResourceWithStreamingResponse(self)
|
40
|
-
|
41
|
-
def retrieve(
|
42
|
-
self,
|
43
|
-
section_id: str,
|
44
|
-
*,
|
45
|
-
recap_id: str,
|
46
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
47
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
48
|
-
extra_headers: Headers | None = None,
|
49
|
-
extra_query: Query | None = None,
|
50
|
-
extra_body: Body | None = None,
|
51
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
52
|
-
) -> None:
|
53
|
-
"""
|
54
|
-
Get specific audio recap section
|
55
|
-
|
56
|
-
Args:
|
57
|
-
extra_headers: Send extra headers
|
58
|
-
|
59
|
-
extra_query: Add additional query parameters to the request
|
60
|
-
|
61
|
-
extra_body: Add additional JSON properties to the request
|
62
|
-
|
63
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
64
|
-
"""
|
65
|
-
if not recap_id:
|
66
|
-
raise ValueError(f"Expected a non-empty value for `recap_id` but received {recap_id!r}")
|
67
|
-
if not section_id:
|
68
|
-
raise ValueError(f"Expected a non-empty value for `section_id` but received {section_id!r}")
|
69
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
70
|
-
return self._get(
|
71
|
-
f"/api/v1/audio-recaps/{recap_id}/sections/{section_id}",
|
72
|
-
options=make_request_options(
|
73
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
74
|
-
),
|
75
|
-
cast_to=NoneType,
|
76
|
-
)
|
77
|
-
|
78
|
-
def list(
|
79
|
-
self,
|
80
|
-
recap_id: str,
|
81
|
-
*,
|
82
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
83
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
84
|
-
extra_headers: Headers | None = None,
|
85
|
-
extra_query: Query | None = None,
|
86
|
-
extra_body: Body | None = None,
|
87
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
88
|
-
) -> None:
|
89
|
-
"""
|
90
|
-
Get audio recap sections
|
91
|
-
|
92
|
-
Args:
|
93
|
-
extra_headers: Send extra headers
|
94
|
-
|
95
|
-
extra_query: Add additional query parameters to the request
|
96
|
-
|
97
|
-
extra_body: Add additional JSON properties to the request
|
98
|
-
|
99
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
100
|
-
"""
|
101
|
-
if not recap_id:
|
102
|
-
raise ValueError(f"Expected a non-empty value for `recap_id` but received {recap_id!r}")
|
103
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
104
|
-
return self._get(
|
105
|
-
f"/api/v1/audio-recaps/{recap_id}/sections",
|
106
|
-
options=make_request_options(
|
107
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
108
|
-
),
|
109
|
-
cast_to=NoneType,
|
110
|
-
)
|
111
|
-
|
112
|
-
|
113
|
-
class AsyncSectionsResource(AsyncAPIResource):
|
114
|
-
@cached_property
|
115
|
-
def with_raw_response(self) -> AsyncSectionsResourceWithRawResponse:
|
116
|
-
"""
|
117
|
-
This property can be used as a prefix for any HTTP method call to return
|
118
|
-
the raw response object instead of the parsed content.
|
119
|
-
|
120
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#accessing-raw-response-data-eg-headers
|
121
|
-
"""
|
122
|
-
return AsyncSectionsResourceWithRawResponse(self)
|
123
|
-
|
124
|
-
@cached_property
|
125
|
-
def with_streaming_response(self) -> AsyncSectionsResourceWithStreamingResponse:
|
126
|
-
"""
|
127
|
-
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
128
|
-
|
129
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#with_streaming_response
|
130
|
-
"""
|
131
|
-
return AsyncSectionsResourceWithStreamingResponse(self)
|
132
|
-
|
133
|
-
async def retrieve(
|
134
|
-
self,
|
135
|
-
section_id: str,
|
136
|
-
*,
|
137
|
-
recap_id: str,
|
138
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
139
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
140
|
-
extra_headers: Headers | None = None,
|
141
|
-
extra_query: Query | None = None,
|
142
|
-
extra_body: Body | None = None,
|
143
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
144
|
-
) -> None:
|
145
|
-
"""
|
146
|
-
Get specific audio recap section
|
147
|
-
|
148
|
-
Args:
|
149
|
-
extra_headers: Send extra headers
|
150
|
-
|
151
|
-
extra_query: Add additional query parameters to the request
|
152
|
-
|
153
|
-
extra_body: Add additional JSON properties to the request
|
154
|
-
|
155
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
156
|
-
"""
|
157
|
-
if not recap_id:
|
158
|
-
raise ValueError(f"Expected a non-empty value for `recap_id` but received {recap_id!r}")
|
159
|
-
if not section_id:
|
160
|
-
raise ValueError(f"Expected a non-empty value for `section_id` but received {section_id!r}")
|
161
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
162
|
-
return await self._get(
|
163
|
-
f"/api/v1/audio-recaps/{recap_id}/sections/{section_id}",
|
164
|
-
options=make_request_options(
|
165
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
166
|
-
),
|
167
|
-
cast_to=NoneType,
|
168
|
-
)
|
169
|
-
|
170
|
-
async def list(
|
171
|
-
self,
|
172
|
-
recap_id: str,
|
173
|
-
*,
|
174
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
175
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
176
|
-
extra_headers: Headers | None = None,
|
177
|
-
extra_query: Query | None = None,
|
178
|
-
extra_body: Body | None = None,
|
179
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
180
|
-
) -> None:
|
181
|
-
"""
|
182
|
-
Get audio recap sections
|
183
|
-
|
184
|
-
Args:
|
185
|
-
extra_headers: Send extra headers
|
186
|
-
|
187
|
-
extra_query: Add additional query parameters to the request
|
188
|
-
|
189
|
-
extra_body: Add additional JSON properties to the request
|
190
|
-
|
191
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
192
|
-
"""
|
193
|
-
if not recap_id:
|
194
|
-
raise ValueError(f"Expected a non-empty value for `recap_id` but received {recap_id!r}")
|
195
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
196
|
-
return await self._get(
|
197
|
-
f"/api/v1/audio-recaps/{recap_id}/sections",
|
198
|
-
options=make_request_options(
|
199
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
200
|
-
),
|
201
|
-
cast_to=NoneType,
|
202
|
-
)
|
203
|
-
|
204
|
-
|
205
|
-
class SectionsResourceWithRawResponse:
|
206
|
-
def __init__(self, sections: SectionsResource) -> None:
|
207
|
-
self._sections = sections
|
208
|
-
|
209
|
-
self.retrieve = to_raw_response_wrapper(
|
210
|
-
sections.retrieve,
|
211
|
-
)
|
212
|
-
self.list = to_raw_response_wrapper(
|
213
|
-
sections.list,
|
214
|
-
)
|
215
|
-
|
216
|
-
|
217
|
-
class AsyncSectionsResourceWithRawResponse:
|
218
|
-
def __init__(self, sections: AsyncSectionsResource) -> None:
|
219
|
-
self._sections = sections
|
220
|
-
|
221
|
-
self.retrieve = async_to_raw_response_wrapper(
|
222
|
-
sections.retrieve,
|
223
|
-
)
|
224
|
-
self.list = async_to_raw_response_wrapper(
|
225
|
-
sections.list,
|
226
|
-
)
|
227
|
-
|
228
|
-
|
229
|
-
class SectionsResourceWithStreamingResponse:
|
230
|
-
def __init__(self, sections: SectionsResource) -> None:
|
231
|
-
self._sections = sections
|
232
|
-
|
233
|
-
self.retrieve = to_streamed_response_wrapper(
|
234
|
-
sections.retrieve,
|
235
|
-
)
|
236
|
-
self.list = to_streamed_response_wrapper(
|
237
|
-
sections.list,
|
238
|
-
)
|
239
|
-
|
240
|
-
|
241
|
-
class AsyncSectionsResourceWithStreamingResponse:
|
242
|
-
def __init__(self, sections: AsyncSectionsResource) -> None:
|
243
|
-
self._sections = sections
|
244
|
-
|
245
|
-
self.retrieve = async_to_streamed_response_wrapper(
|
246
|
-
sections.retrieve,
|
247
|
-
)
|
248
|
-
self.list = async_to_streamed_response_wrapper(
|
249
|
-
sections.list,
|
250
|
-
)
|
@@ -1,47 +0,0 @@
|
|
1
|
-
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
2
|
-
|
3
|
-
from .chat import (
|
4
|
-
ChatResource,
|
5
|
-
AsyncChatResource,
|
6
|
-
ChatResourceWithRawResponse,
|
7
|
-
AsyncChatResourceWithRawResponse,
|
8
|
-
ChatResourceWithStreamingResponse,
|
9
|
-
AsyncChatResourceWithStreamingResponse,
|
10
|
-
)
|
11
|
-
from .test import (
|
12
|
-
TestResource,
|
13
|
-
AsyncTestResource,
|
14
|
-
TestResourceWithRawResponse,
|
15
|
-
AsyncTestResourceWithRawResponse,
|
16
|
-
TestResourceWithStreamingResponse,
|
17
|
-
AsyncTestResourceWithStreamingResponse,
|
18
|
-
)
|
19
|
-
from .sessions import (
|
20
|
-
SessionsResource,
|
21
|
-
AsyncSessionsResource,
|
22
|
-
SessionsResourceWithRawResponse,
|
23
|
-
AsyncSessionsResourceWithRawResponse,
|
24
|
-
SessionsResourceWithStreamingResponse,
|
25
|
-
AsyncSessionsResourceWithStreamingResponse,
|
26
|
-
)
|
27
|
-
|
28
|
-
__all__ = [
|
29
|
-
"SessionsResource",
|
30
|
-
"AsyncSessionsResource",
|
31
|
-
"SessionsResourceWithRawResponse",
|
32
|
-
"AsyncSessionsResourceWithRawResponse",
|
33
|
-
"SessionsResourceWithStreamingResponse",
|
34
|
-
"AsyncSessionsResourceWithStreamingResponse",
|
35
|
-
"TestResource",
|
36
|
-
"AsyncTestResource",
|
37
|
-
"TestResourceWithRawResponse",
|
38
|
-
"AsyncTestResourceWithRawResponse",
|
39
|
-
"TestResourceWithStreamingResponse",
|
40
|
-
"AsyncTestResourceWithStreamingResponse",
|
41
|
-
"ChatResource",
|
42
|
-
"AsyncChatResource",
|
43
|
-
"ChatResourceWithRawResponse",
|
44
|
-
"AsyncChatResourceWithRawResponse",
|
45
|
-
"ChatResourceWithStreamingResponse",
|
46
|
-
"AsyncChatResourceWithStreamingResponse",
|
47
|
-
]
|