studyfetch-sdk 0.1.0a18__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 +24 -3
- studyfetch_sdk/_version.py +1 -1
- studyfetch_sdk/resources/v1/__init__.py +0 -84
- studyfetch_sdk/resources/v1/assignment_grader.py +81 -1
- studyfetch_sdk/resources/v1/components.py +36 -4
- studyfetch_sdk/resources/v1/materials/materials.py +130 -2
- studyfetch_sdk/resources/v1/materials/upload.py +286 -0
- studyfetch_sdk/resources/v1/usage/analyst.py +143 -15
- studyfetch_sdk/resources/v1/v1.py +66 -192
- studyfetch_sdk/types/v1/__init__.py +2 -20
- studyfetch_sdk/types/v1/assignment_grader_response.py +20 -1
- studyfetch_sdk/types/v1/component.py +9 -1
- studyfetch_sdk/types/v1/component_create_params.py +81 -1
- studyfetch_sdk/types/v1/component_generate_embed_params.py +7 -1
- studyfetch_sdk/types/v1/component_list_params.py +9 -1
- studyfetch_sdk/types/v1/content_param.py +23 -0
- studyfetch_sdk/types/v1/material_create_and_process_params.py +27 -0
- studyfetch_sdk/types/v1/material_create_params.py +4 -17
- studyfetch_sdk/types/v1/materials/__init__.py +2 -0
- 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 +29 -0
- studyfetch_sdk/types/v1/materials/upload_upload_file_params.py +3 -0
- studyfetch_sdk/types/v1/materials/upload_upload_url_and_process_params.py +26 -0
- studyfetch_sdk/types/v1/usage/__init__.py +3 -0
- studyfetch_sdk/types/v1/usage/analyst_get_test_questions_params.py +18 -0
- studyfetch_sdk/types/v1/usage/analyst_list_chat_messages_params.py +18 -0
- studyfetch_sdk/types/v1/usage/analyst_list_chat_messages_response.py +35 -0
- studyfetch_sdk/types/v1/usage/analyst_list_events_params.py +7 -0
- {studyfetch_sdk-0.1.0a18.dist-info → studyfetch_sdk-0.1.0a20.dist-info}/METADATA +1 -1
- {studyfetch_sdk-0.1.0a18.dist-info → studyfetch_sdk-0.1.0a20.dist-info}/RECORD +32 -71
- 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/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/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.0a18.dist-info → studyfetch_sdk-0.1.0a20.dist-info}/WHEEL +0 -0
- {studyfetch_sdk-0.1.0a18.dist-info → studyfetch_sdk-0.1.0a20.dist-info}/licenses/LICENSE +0 -0
@@ -1,160 +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__ = ["ComponentResource", "AsyncComponentResource"]
|
19
|
-
|
20
|
-
|
21
|
-
class ComponentResource(SyncAPIResource):
|
22
|
-
@cached_property
|
23
|
-
def with_raw_response(self) -> ComponentResourceWithRawResponse:
|
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 ComponentResourceWithRawResponse(self)
|
31
|
-
|
32
|
-
@cached_property
|
33
|
-
def with_streaming_response(self) -> ComponentResourceWithStreamingResponse:
|
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 ComponentResourceWithStreamingResponse(self)
|
40
|
-
|
41
|
-
def list(
|
42
|
-
self,
|
43
|
-
component_id: str,
|
44
|
-
*,
|
45
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
46
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
47
|
-
extra_headers: Headers | None = None,
|
48
|
-
extra_query: Query | None = None,
|
49
|
-
extra_body: Body | None = None,
|
50
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
51
|
-
) -> None:
|
52
|
-
"""
|
53
|
-
Args:
|
54
|
-
extra_headers: Send extra headers
|
55
|
-
|
56
|
-
extra_query: Add additional query parameters to the request
|
57
|
-
|
58
|
-
extra_body: Add additional JSON properties to the request
|
59
|
-
|
60
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
61
|
-
"""
|
62
|
-
if not component_id:
|
63
|
-
raise ValueError(f"Expected a non-empty value for `component_id` but received {component_id!r}")
|
64
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
65
|
-
return self._post(
|
66
|
-
f"/api/v1/tests/component/{component_id}/list",
|
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
|
-
|
74
|
-
class AsyncComponentResource(AsyncAPIResource):
|
75
|
-
@cached_property
|
76
|
-
def with_raw_response(self) -> AsyncComponentResourceWithRawResponse:
|
77
|
-
"""
|
78
|
-
This property can be used as a prefix for any HTTP method call to return
|
79
|
-
the raw response object instead of the parsed content.
|
80
|
-
|
81
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#accessing-raw-response-data-eg-headers
|
82
|
-
"""
|
83
|
-
return AsyncComponentResourceWithRawResponse(self)
|
84
|
-
|
85
|
-
@cached_property
|
86
|
-
def with_streaming_response(self) -> AsyncComponentResourceWithStreamingResponse:
|
87
|
-
"""
|
88
|
-
An alternative to `.with_raw_response` that doesn't eagerly read the response body.
|
89
|
-
|
90
|
-
For more information, see https://www.github.com/GoStudyFetchGo/studyfetch-sdk-python#with_streaming_response
|
91
|
-
"""
|
92
|
-
return AsyncComponentResourceWithStreamingResponse(self)
|
93
|
-
|
94
|
-
async def list(
|
95
|
-
self,
|
96
|
-
component_id: str,
|
97
|
-
*,
|
98
|
-
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
|
99
|
-
# The extra values given here take precedence over values defined on the client or passed to this method.
|
100
|
-
extra_headers: Headers | None = None,
|
101
|
-
extra_query: Query | None = None,
|
102
|
-
extra_body: Body | None = None,
|
103
|
-
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
|
104
|
-
) -> None:
|
105
|
-
"""
|
106
|
-
Args:
|
107
|
-
extra_headers: Send extra headers
|
108
|
-
|
109
|
-
extra_query: Add additional query parameters to the request
|
110
|
-
|
111
|
-
extra_body: Add additional JSON properties to the request
|
112
|
-
|
113
|
-
timeout: Override the client-level default timeout for this request, in seconds
|
114
|
-
"""
|
115
|
-
if not component_id:
|
116
|
-
raise ValueError(f"Expected a non-empty value for `component_id` but received {component_id!r}")
|
117
|
-
extra_headers = {"Accept": "*/*", **(extra_headers or {})}
|
118
|
-
return await self._post(
|
119
|
-
f"/api/v1/tests/component/{component_id}/list",
|
120
|
-
options=make_request_options(
|
121
|
-
extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout
|
122
|
-
),
|
123
|
-
cast_to=NoneType,
|
124
|
-
)
|
125
|
-
|
126
|
-
|
127
|
-
class ComponentResourceWithRawResponse:
|
128
|
-
def __init__(self, component: ComponentResource) -> None:
|
129
|
-
self._component = component
|
130
|
-
|
131
|
-
self.list = to_raw_response_wrapper(
|
132
|
-
component.list,
|
133
|
-
)
|
134
|
-
|
135
|
-
|
136
|
-
class AsyncComponentResourceWithRawResponse:
|
137
|
-
def __init__(self, component: AsyncComponentResource) -> None:
|
138
|
-
self._component = component
|
139
|
-
|
140
|
-
self.list = async_to_raw_response_wrapper(
|
141
|
-
component.list,
|
142
|
-
)
|
143
|
-
|
144
|
-
|
145
|
-
class ComponentResourceWithStreamingResponse:
|
146
|
-
def __init__(self, component: ComponentResource) -> None:
|
147
|
-
self._component = component
|
148
|
-
|
149
|
-
self.list = to_streamed_response_wrapper(
|
150
|
-
component.list,
|
151
|
-
)
|
152
|
-
|
153
|
-
|
154
|
-
class AsyncComponentResourceWithStreamingResponse:
|
155
|
-
def __init__(self, component: AsyncComponentResource) -> None:
|
156
|
-
self._component = component
|
157
|
-
|
158
|
-
self.list = async_to_streamed_response_wrapper(
|
159
|
-
component.list,
|
160
|
-
)
|